Hi Everyone,
Question: Is Python installed by default in cPanel Business Hosting?
I'm a SSH access & Python newbie and don't see anything in the /bin folder when connected via SSH so am assuming Python is not installed?
S3cmd Tool
What I'm trying to do is install S3cmd tool so I can connect to Amazon S3 and upload some MySQL backup files via a cron job & script on a regular schedule. For the S3cmd tool to install & run it needs Python to be present inside of cPanel.
How to Guide
Thanks for explaining to a SSH & Python newbie but otherwise experienced coder.
Aly
Solved! Go to Solution.
Pretty much correct - 2.6 is what is installed but the AWS script actually needs 3.x
As I said earlier - I believe you can only do this on a VPS as you actually need full root access to be able to install / map 3.x
Once it was running it was great and allowed for scp and other commands but getting to that point was a royal pain
Once your issue is resolved,
please be sure to come back and click accept for the solution
Get Better Support on the Community Boards!
Etiquette When Asking for Help from the Community
Hi @PL281 ,
I figured out a solution that works with cPanel Business Hosting (shared hosting environment).
I'm using it to backup our MySQL databases and whatever file directories I need copied over to S3 on a regular basis.
Let me test this out some more then I'll write up the solution in more detail for the community.
Interesting Notes:
Aly
I recently set this up on my VPS - I had to upgrade Python and it was about a 2hr + project as I had to get all the source files etc
If you are just on a cPanel server I don't believe you will be able to do what you are looking for
Once your issue is resolved,
please be sure to come back and click accept for the solution
Get Better Support on the Community Boards!
Etiquette When Asking for Help from the Community
Hi @PL281 ,
Thanks for the reply and good information, much appreciated.
Python 2.7 does appear as shown in the 'top' processes (see screen shot below).
Here are the paths returned on querying pythons location.
python: /usr/bin/python2.6 /usr/bin/python /usr/lib/python2.6 /usr/lib64/python2.6 /usr/include/python2.6 /opt/python35/bin/python3.5m-config /opt/python35/bin/python3.5 /opt/python35/bin/python3.5m /usr/share/man/man1/python.1.gz
However...
python setup.py install
Using xml.etree.ElementTree for XML processing running install error: can't create or remove files in install directory The following error occurred while trying to add or remove files in the installation directory: [Errno 30] Read-only file system: '/usr/lib/python2.6/site-packages/test-easy-install-1017400.write-test' The installation directory you specified (via --install-dir, --prefix, or the distutils default setting) was: /usr/lib/python2.6/site-packages/ Perhaps your account does not have write access to this directory? If the installation directory is a system-owned directory, you may need to sign in as the administrator or "root" account. If you do not have administrative access to this machine, you may wish to choose a different installation directory, preferably one that is listed in your PYTHONPATH environment variable. For information on other options, you may wish to consult the documentation at: http://peak.telecommunity.com/EasyInstall.html Please make the appropriate changes for your system and try again
Do you have any ideas? Many thanks if you do.
Aly
Pretty much correct - 2.6 is what is installed but the AWS script actually needs 3.x
As I said earlier - I believe you can only do this on a VPS as you actually need full root access to be able to install / map 3.x
Once it was running it was great and allowed for scp and other commands but getting to that point was a royal pain
Once your issue is resolved,
please be sure to come back and click accept for the solution
Get Better Support on the Community Boards!
Etiquette When Asking for Help from the Community
Hi @PL281 ,
I figured out a solution that works with cPanel Business Hosting (shared hosting environment).
I'm using it to backup our MySQL databases and whatever file directories I need copied over to S3 on a regular basis.
Let me test this out some more then I'll write up the solution in more detail for the community.
Interesting Notes:
Aly
Here is the expanded solution: