- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: Running python from ssh
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2008 11:08 AM
тАО06-09-2008 11:08 AM
Running python from ssh
The issue is that when running 2.5.1 from python, I don't need to put a full path before python but if I run 2.5.2, I had to put the full path /usr/local/bin for python, although I have /usr/local/bin in $PATH.
How does ssh treat the PATH for running a remote command?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2008 11:33 AM
тАО06-09-2008 11:33 AM
Re: Running python from ssh
if you type env or echo $PATH, you can see the value of PATH variable in your system. the order of phyton's binary in PATH shows which phyton binary to run. if you want 2.5.2 version to be run it's path must be after than the older.
Kenan.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2008 11:37 AM
тАО06-09-2008 11:37 AM
Re: Running python from ssh
/opt/ssh/etc/sshd_config
you will see something like
# This sshd was compiled with PATH=/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin
this should tell you what ssh takes as its default path on the server where this sshd is running. Provided that I have not done this myself, but it should be possible to add /usr/local/bin to the path in the source file and compile it for your own use.
Hope this helps
UNIX because I majored in cryptology...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2008 06:38 PM
тАО06-09-2008 06:38 PM
Re: Running python from ssh
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-09-2008 10:32 PM
тАО06-09-2008 10:32 PM
Re: Running python from ssh
Any reason you just don't use the absolute paths for all commands other than /usr/bin?
And if using a script, do what Bill says?
That's what you need to do for remsh, except it does have /usr/local/bin:
/usr/bin:/usr/ccs/bin:/usr/bin/X11:/usr/contrib/bin:/usr/local/bin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО06-11-2008 08:00 AM
тАО06-11-2008 08:00 AM