- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: sh: command not found
Operating System - Linux
1753863
Members
7765
Online
108809
Solutions
Forums
Categories
Company
Local Language
юдл
back
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
юдл
back
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
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- 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
тАО11-22-2007 09:01 PM
тАО11-22-2007 09:01 PM
sh: command not found
Hi there
When I'm running:
'mongrel_rails cluster::restart' from command line it's fine.
When I'm running this command from program I'm heving this error:
sh: mongrel_rails: command not found
The command is in /usr/local/bin - which is in user PATH:
newsfeeder@webserver2:~$ $PATH
-bash: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/bin/X11:/usr/games
Can enyone help ?
Best Regards
Peter
When I'm running:
'mongrel_rails cluster::restart' from command line it's fine.
When I'm running this command from program I'm heving this error:
sh: mongrel_rails: command not found
The command is in /usr/local/bin - which is in user PATH:
newsfeeder@webserver2:~$ $PATH
-bash: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/bin/X11:/usr/games
Can enyone help ?
Best Regards
Peter
Jesus is the King
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-22-2007 09:42 PM
тАО11-22-2007 09:42 PM
Re: sh: command not found
From what program? How is the program launched?
It will be a path issue, and it all dependson how the program is launched.
It will be a path issue, and it all dependson how the program is launched.
One long-haired git at your service...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-22-2007 10:16 PM
тАО11-22-2007 10:16 PM
Re: sh: command not found
The user environment could not be available depending on how you run the program.
If you can, define the PATH variable inside the program/script, source the user's profile at run time or specify the full path to the program when is called.
If you can, define the PATH variable inside the program/script, source the user's profile at run time or specify the full path to the program when is called.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-22-2007 11:58 PM
тАО11-22-2007 11:58 PM
Re: sh: command not found
If /usr/local/bin/mongrel_rails exists and is accessible (scripts must be both readable & executable to work), the error message might mean that the interpreter of mongrel_rails cannot be found.
Run "head /usr/local/bin/mongrel_rails".
The first line should be something like:
#!/script/interpreter/path
Make sure the /script/interpreter/path is a correct full pathname of the correct script interpreter.
I'm not familiar with mongrel_rails, but a quick Googling suggests that it should be something like:
#!/opt/ruby/bin/ruby1.8
(or whatever your ruby version is & wherever your ruby installation is located)
MK
Run "head /usr/local/bin/mongrel_rails".
The first line should be something like:
#!/script/interpreter/path
Make sure the /script/interpreter/path is a correct full pathname of the correct script interpreter.
I'm not familiar with mongrel_rails, but a quick Googling suggests that it should be something like:
#!/opt/ruby/bin/ruby1.8
(or whatever your ruby version is & wherever your ruby installation is located)
MK
MK
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
News and Events
Support
© Copyright 2024 Hewlett Packard Enterprise Development LP