-
Shell scripts running at Knoppix
Is is possible to run shell scripts under CD booted Knoppix?
I've tried to run simple script in root shell but I've had no luck.
I've got an error ": bad interpreter : No such file or directoryin/sh"
The first line of my script is just "#!/bin/sh"
Did I miss something?
MaJaLes
-
been there too
some thing have to be run from console not x-term
go CTRL-ALT-F2 [remember ALT-F5 to get back!]
this brings up root console
enter "password" to set a new root password!
drill down the directory till you find your script and you should be all set!
Now you can run shell scripts "sh runme" and they should work just fine
Some scripts will run without the extra work, but you have to be very literal about where you run them from. You have to remember to specify the proper directory path to them. I've found if you save them to the Desktop that more will run from X-term because the x-term can "see" the Desktop folder without a bunch of monkey business. An added benifit is that you can save the files for later with the save config menu option too! [choose to save desktop files!] They restore when you use the floppyconfig or myconfig=scan command!
-
Re: Shell scripts running at Knoppix
![Quote](images/misc/quote_icon.png)
Originally Posted by
majales
Is is possible to run shell scripts under CD booted Knoppix?
I've tried to run simple script in root shell but I've had no luck.
I've got an error ": bad interpreter : No such file or directoryin/sh"
The first line of my script is just "#!/bin/sh"
Did I miss something?
MaJaLes
This works fine in mine. I created the script on the Desktop and ran it from the root shell.
Post your script so that others can try it and help troubleshoot the problem. This should work! On my system, the shell interprets everything just fine.
try creating the following script on the Desktop. Call it testscript:
Code:
#! /bin/sh
ls -asl / >> test.txt
Then make it executable:
chmod u+x testscript
now execute it either with sh testscript or by itself (since we made it executable) with testscript
It should just work
Similar Threads
-
By sunburnt in forum Tips and Tricks
Replies: 5
Last Post: 05-28-2005, 05:39 PM
-
By splittik in forum General Support
Replies: 1
Last Post: 03-22-2005, 07:38 AM
-
By helios17 in forum General Support
Replies: 1
Last Post: 10-01-2004, 06:53 AM
-
By pankajgadhari in forum General Support
Replies: 1
Last Post: 01-07-2004, 06:33 AM
-
By colinmc151 in forum Customising & Remastering
Replies: 3
Last Post: 11-10-2003, 11:40 PM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
![Gigabyte Z370P D3 ATX Z370 LGA1151 Motherboard (Support Intel 6/7th 8th 9th) picture](/store/img/g/QrkAAOSwMGNmLxf0/s-l225/Gigabyte-Z370P-D3-ATX-Z370-LGA1151-Motherboard-Sup.jpg)
Gigabyte Z370P D3 ATX Z370 LGA1151 Motherboard (Support Intel 6/7th 8th 9th)
$59.99
![ASUS H110M-R Motherboard Intel 6th/7th Gen LGA1151 DDR4 Micro-ATX i/o shield picture](/store/img/g/FhQAAOSwzL9iDqc3/s-l225/ASUS-H110M-R-Motherboard-Intel-6th-7th-Gen-LGA1151.jpg)
ASUS H110M-R Motherboard Intel 6th/7th Gen LGA1151 DDR4 Micro-ATX i/o shield
$42.00
![ASRock B550M Pro SE AM4 DDR4 SATA 6Gb/s 1 PCIe 4.0 x16 Micro ATX Motherboard picture](/store/img/g/oXIAAOSwCn1k30lD/s-l225/ASRock-B550M-Pro-SE-AM4-DDR4-SATA-6Gb-s-1-PCIe-4-0.jpg)
ASRock B550M Pro SE AM4 DDR4 SATA 6Gb/s 1 PCIe 4.0 x16 Micro ATX Motherboard
$84.99
![ASRock H170 Pro4S Motherboard ATX Intel H170 LGA1151 DDR4 SATA3 HDMI picture](/store/img/g/guoAAOSwk7lmex9j/s-l225/ASRock-H170-Pro4S-Motherboard-ATX-Intel-H170-LGA11.jpg)
ASRock H170 Pro4S Motherboard ATX Intel H170 LGA1151 DDR4 SATA3 HDMI
$39.99
![Asus Prime H310M-A R2.0 Intel LGA 1151 DDR4 Desktop Motherboard picture](/store/img/g/ld0AAOSw7q5mV2ql/s-l225/Asus-Prime-H310M-A-R2-0-Intel-LGA-1151-DDR4-Deskto.jpg)
Asus Prime H310M-A R2.0 Intel LGA 1151 DDR4 Desktop Motherboard
$54.99
![Asus H81M-C Intel LGA1150 DDR3 Desktop Motherboard MicroATX Socket H3 picture](/store/img/g/CZ4AAOSwg8pmYirU/s-l225/Asus-H81M-C-Intel-LGA1150-DDR3-Desktop-Motherboard.jpg)
Asus H81M-C Intel LGA1150 DDR3 Desktop Motherboard MicroATX Socket H3
$23.99
![Asus Prime A320M-K mATX AM4 Motherboard (Ryzen 1000-5000 Ready) picture](/store/img/g/v2sAAOSwFuxlhzOj/s-l225/Asus-Prime-A320M-K-mATX-AM4-Motherboard-Ryzen-1000.jpg)
Asus Prime A320M-K mATX AM4 Motherboard (Ryzen 1000-5000 Ready)
$49.99
![MSI PRO Z690-A WiFi ProSeries Intel LGA 1700 DDR5 Wi-Fi 6E ATX Motherboard picture](/store/img/g/D3cAAOSwfudmYAFK/s-l225/MSI-PRO-Z690-A-WiFi-ProSeries-Intel-LGA-1700-DDR5-.jpg)
MSI PRO Z690-A WiFi ProSeries Intel LGA 1700 DDR5 Wi-Fi 6E ATX Motherboard
$84.95
![GIGABYTE MB10-Datto Motherboard Xeon D-1521- SR2DF 2.40 GHz- Open Box picture](/store/img/g/emsAAOSwMgplusj6/s-l225/GIGABYTE-MB10-Datto-Motherboard-Xeon-D-1521-SR2DF-.jpg)
GIGABYTE MB10-Datto Motherboard Xeon D-1521- SR2DF 2.40 GHz- Open Box
$139.05
![Gigabyte M-ATX motherboard with Intel Core i3 8100 CPU and 8GB DDR4 RAM picture](/store/img/g/CCsAAOSw9mtkQuoe/s-l225/Gigabyte-M-ATX-motherboard-with-Intel-Core-i3-8100.jpg)
Gigabyte M-ATX motherboard with Intel Core i3 8100 CPU and 8GB DDR4 RAM
$84.00