-
howto Statup Scripts
Hello!
How do I get a script to execute on boot in a persistent usb knoppix install?
I tried this, but it didn't work:
Code:
knoppix@Microknoppix:~$ cat /home/knoppix/.config/autostart/startup.desktop
[Desktop Entry]
Name=Startup
ServerExec="/bin/mkdir /tmp/test"
Icon=
Type=Application
...but there's no /tmp/test directory on boot :\
more info about my setup:
Code:
knoppix@Microknoppix:~$ uname -a
Linux Microknoppix 3.9.6 #25 SMP PREEMPT Sat Jun 15 15:27:01 CEST 2013 i686 GNU/Linux
-
Senior Member
registered user
I would suggest that you read the latest Desktop Entry Specification. On the page Recognized desktop entry keys you will find out that there is no key 'ServerExec'.
-
Thanks for your fast response!
I updated the "ServerExec" line to "Exec" as per the link you provided, but there's still no /tmp/test file getting created on boot.
Code:
knoppix@Microknoppix:~$ cat .config/autostart/startup.desktop
[Desktop Entry]
Name=Startup
Exec="/bin/mkdir /tmp/external"
Icon=
Type=Application
If there's errors with processing .config/autostart/* files, is there anywhere these errors will be logged so I can check for messages?
-
Senior Member
registered user
Examples
The first desktop file will create a new directory /tmp/testdir if it does not already exist.
Code:
knoppix@Knoppix720cd:~$ cat /home/knoppix/.config/autostart/mkTestdir.desktop
[Desktop Entry]
Name=mkTestdir
Exec=/bin/mkdir -p /tmp/testdir
Terminal=false
Type=Application
The second desktop file will create an empty file /tmp/testfile if it does not already exist.
Code:
knoppix@Knoppix720cd:~$ cat /home/knoppix/.config/autostart/mkTestfile.desktop
[Desktop Entry]
Name=mkTestfile
Exec=/usr/bin/touch /tmp/testfile
Terminal=false
Type=Application
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
G5T03 Dell Intel DC S3700 Series 800GB SATA 6Gb/s 2.5" SSD 0G5T03 SSDSC2BA800G3E
$55.00
HPGYT DELL 960GB SATA 6Gb/s 2.5in Internal SSD 0HPGYT MTFDDAK960TCB
$59.00
M.2 NVME SATA SSD Enclosure USB 3.2 Gen 2 10Gbps for M-Key or M+B Key SSD to 8TB
$40.86
ACASIS 2.5/3.5 inch 2 Bay SATA USB 3.0 Hard Drive Disk HDD SSD Enclosure 4 RAID
$58.99
Patriot P210 128GB 256GB 512GB 1TB 2TB 2.5" SATA 3 6GB/s Internal SSD PC/MAC Lot
$14.99
Netac 1TB 2TB 512GB Internal SSD 2.5'' SATA III 6Gb/s Solid State Drive lot
$13.99
Micron 2300 256GB M.2 GEN 3x4 PCIe NVMe Solid State Drive 2280 SSD 00C2G4
$14.99
Fanxiang 4TB 2TB 1TB SSD 550MB/s 2.5'' SATA III Internal Solid State Drive lot
$13.99
Fanxiang SSD 512GB 1TB 2TB 4TB 2.5''SATA III Internal Solid State Hard Drive LOT
$188.99
Fanxiang SSD 512GB 1TB 2TB 4TB 2.5'' SSD SATA III Internal Solid State Drive lot
$107.99