• Run an application or a script at boot as root?


    I want to run at boot

    systemctl start sabnzbd.service

    or

    ExecStart=/usr/bin/python2 /opt/sabnzbd/SABnzbd.py -d

    as ROOT

    I have tried many things around the web but unfortunately nothing is working.
    Before I could do it with rc.local as a service but now is not working.
    I dont know what I am doing wrong or maybe something changed with systemd? 😥

    if someone could guide me step by step or at least give me some tips would be much appreciated.

    Kyrisk

  • sorry for late reply, notifications on forum was screwed up…

    to enable a systemd service at boot you need to use enable
    sudo systemctl enable sabnzbd.service

    Archwiki say:
    Both sabnzbd and sabnzbd-git provide the sabnzbd.service systemd unit, create the user and group sabnzbd, and use /opt/sabnzbd/sabnzbd.ini for configuration.
    Add users to the sabnzbd group to allow access to SABnzbd files.

    sudo useradd -r -s /bin/false sabnzbd
    sudo groupadd sabnzbd
    

    if i understand it right: you need to add the new created user and your personal user to the newly created group:

    sudo gpasswd -d sabnzbd sabnzbd
    sudo gpasswd -d *yourusername* sabnzbd
    

    https://wiki.archlinux.org/index.php/SABnzbd#Using_systemd

    [updates once a week] = [90% less problems]
    antergos:_rescue
    how to add system logs:
    wget http://bit.ly/2GCG9k2 && sh 2GCG9k2
    :handshake: donate antergos

  • Well I was a bit mad about this and I bought a Synology DS 718+.

    Actually the main reason is that I had a 1000w desktop PC running these apps and it was not efficient so I bought a Synology NAS(DS 718+) that supports docker and installed everything there + some more things I wanted to do.

    Thanks for your reply 🙂

  • does it work now?
    as i am not sure that this user is nessesarry:

    sudo useradd -r -s /bin/false sabnzbd
    

    i copy the fact only from Archwiki, but it looks a bit unusual to me that a user is needed… but similar we need for avahi as far as i remember, so may it is totally o.k.

    [updates once a week] = [90% less problems]
    antergos:_rescue
    how to add system logs:
    wget http://bit.ly/2GCG9k2 && sh 2GCG9k2
    :handshake: donate antergos

  • B.T.W. nice device:
    Bild Text

    [updates once a week] = [90% less problems]
    antergos:_rescue
    how to add system logs:
    wget http://bit.ly/2GCG9k2 && sh 2GCG9k2
    :handshake: donate antergos

boot252 application26 root19 Posts 5Views 356
Log in to reply
Bloom Email Optin Plugin

Looks like your connection to Antergos Community Forum was lost, please wait while we try to reconnect.