Results 1 to 4 of 4

Thread: howto Statup Scripts

  1. #1
    Junior Member
    Join Date
    Sep 2013
    Posts
    2

    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

  2. #2
    Senior Member registered user
    Join Date
    Feb 2010
    Posts
    512
    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'.

  3. #3
    Junior Member
    Join Date
    Sep 2013
    Posts
    2
    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?

  4. #4
    Senior Member registered user
    Join Date
    Feb 2010
    Posts
    512

    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
  •  


Asus P8H61-M LE/CSM R2.0 LGA1155 DDR3 Micro ATX Desktop Motherboard W/IO Shield  picture

Asus P8H61-M LE/CSM R2.0 LGA1155 DDR3 Micro ATX Desktop Motherboard W/IO Shield

$26.99



Logic Board MQD32LL/A 1.8GHz i5 8GB | Apple MacBook Air 13

Logic Board MQD32LL/A 1.8GHz i5 8GB | Apple MacBook Air 13" 2017 | A1466

$149.46



2.3 GHz i5 16GB RAM Logic Board 820-00840-A MacBook Pro A1708 2017 picture

2.3 GHz i5 16GB RAM Logic Board 820-00840-A MacBook Pro A1708 2017

$159.99



ASUS ROG STRIX B550-F GAMING AM4 AMD B550 SATA 6Gb/s ATX AMD Motherboard picture

ASUS ROG STRIX B550-F GAMING AM4 AMD B550 SATA 6Gb/s ATX AMD Motherboard

$129.99



GIGABYTE Z590 AORUS MASTER LGA 1200 Intel ATX Motherboard with Triple M.2 Slots picture

GIGABYTE Z590 AORUS MASTER LGA 1200 Intel ATX Motherboard with Triple M.2 Slots

$129.99



ASRock Z590 PRO4 LGA 1200 Intel Z590 SATA 6Gb/s ATX Intel Motherboard picture

ASRock Z590 PRO4 LGA 1200 Intel Z590 SATA 6Gb/s ATX Intel Motherboard

$79.99



GIGABYTE B450M DS3H WIFI AM4 AMD B450 SATA 6Gb/s picture

GIGABYTE B450M DS3H WIFI AM4 AMD B450 SATA 6Gb/s

$79.99



ASUS H110M-R Motherboard Intel 6th/7th Gen LGA1151 DDR4 Micro-ATX i/o shield picture

ASUS H110M-R Motherboard Intel 6th/7th Gen LGA1151 DDR4 Micro-ATX i/o shield

$48.00



Logic Board MJVM2LL/A 1.6GHz i5 4GB Apple MacBook Air 11

Logic Board MJVM2LL/A 1.6GHz i5 4GB Apple MacBook Air 11" 2015 A1465 820-00164-A

$56.39



Logic Board MF843LL/A 3.1GHz i7 16GB | Apple Macbook Pro Retina 13

Logic Board MF843LL/A 3.1GHz i7 16GB | Apple Macbook Pro Retina 13" 2015 | A1502

$111.86