- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- : bad interpreter: no such file or directory error
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
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
тАО11-05-2002 03:41 AM
тАО11-05-2002 03:41 AM
: bad interpreter: no such file or directory error
I'm trying to put this simple script in /etc/init.d/ and link it under /etc/rc3.d/ in order to be run after each reboot.
When i try to execute it i have the error:
: bad interpreter: no such file or directory
It's very strange, because if i copy and paste all the lines of the script it works.
I attach the script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2002 03:48 AM
тАО11-05-2002 03:48 AM
Re: : bad interpreter: no such file or directory error
echo "250 32000 32 128">/proc/sys/kernel/sem
echo "2147483648">/proc/sys/kernel/shmmax
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2002 01:50 PM
тАО11-05-2002 01:50 PM
Re: : bad interpreter: no such file or directory error
Try to change the first line accordingly (either /bin/sh or /usr/bin/bash).
Another point : some distributions pre-install the "sysctl" software that can be used for what you are trying to achieve. To use this feature :
=> Check that sysctl is installed (/etc/sysctl.conf should exist)
=> Check that sysctl is invoked at system boot-up (grep -rli sysctl /etc/rc.d)
=> Edit /etc/sysctl.conf as follows :
kernel.sem = 250 32000 32 128
kernel.shmmax = 2147483648
=> To apply changes, type : sysctl -p. You can also reboot, as this will be automatically done at every reboot.
Good luck.
Kodjo
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2002 11:21 PM
тАО11-05-2002 11:21 PM
Re: : bad interpreter: no such file or directory error
The problem is nowhere related to Kernel paramters mentioned. But due to the unwanted control characters present in the script. Do this to remove the control characters from your
script.
#dos2ux your_script
#chmod +x your_script
Execute the script and the error will not appear.
regards,
U.SivaKumar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-12-2002 09:38 AM
тАО11-12-2002 09:38 AM
Re: : bad interpreter: no such file or directory error
To set up these kernel sysctl's you don't need to write up a script - assuming that you're running RedHat >= 6.2.
Instead, modify /etc/sysctl.conf and add the lines:
sys.kernel.sem = "250 32000 32 128"
sys.kernel.shmmax = 2147483648
After adding these lines, they will tune these parameters in each reboot - no scripts neccessary.
HTH
Paulo Fessel
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-12-2002 09:43 AM
тАО11-12-2002 09:43 AM
Re: : bad interpreter: no such file or directory error
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-08-2012 05:27 AM
тАО05-08-2012 05:27 AM