1. Hello,

    I've tried to make a automatic Linux Restart Script using Crontab.
    My problem is that it somehow wont start the server.

    I've tried multiple ways.

    Those are my crontab settings to execute a script every 6 hours: Gyazo - 4d0a72c861d7fd20e51f0e1cc9781fda.png

    This is my restart.sh script:
    Code:
    sleep 60s ; kill -9 `ps -ef | grep RustDedicated | grep -v grep | awk '{print $$
    sleep 30s ; echo "`/bin/sh /home/rust/start.sh`"
    
    And this is my start.sh script:
    Code:
    cd /home/rustscreen -t RustServer ./RustDedicated -batchmode -load -rcon.port 28016 -rcon.password 'Blank' -server.ip 'Blank' -server.hostname 'Blank' -server.port 28015 -server.identity my_server1 -server.maxplayers 150 -server.headerimage "Blank" -server.description "Blank" -server.saveinterval 120 -server.seed 864037092 -server.worldsize 4000 -server.tickrate 10 -global.maxthreads 16 -autoupdate
    Any help is appreciated.
     
  2. And then just use the command "restart" ?
     
  3. Wulf

    Wulf Community Admin

    The restart command or quit would work, they do the same thing aside from showing a countdown message. This won't fix your server not starting though. Keep in mind that Rust's Linux server has no console, so it may be starting just fine.
     
  4. The server is not starting with crontab etc.
    If I try to connect via Rusty its not working and there's no RustDedicated process...
     
  5. Wulf

    Wulf Community Admin

    Try with just this:
    Code:
    cd /home/rustscreen -t RustServer ./RustDedicated -batchmode
     
  6. Well if I use the restart.sh script by my own (via putty) it works.
    Even if I use the start.sh script.
    But when I use crontab to execute the restart.sh script it kills the RustDedicated process but doesnt start the server...