oscam crondjob help

There are 6 replies in this Thread which was already clicked 1,345 times. The last Post () by jo-jo.

  • Hello to you all,
    I now have oscam all running i want to add a script to my stb to check oscam is running and if not to restart it automatically can anyone point me in the right direction i have a script and edited it but stuck at the crontab part i am unsure how to setup a crond job for every 5 minutes.



    Thank you in advance.

  • think I must be doping something wrong as I have this script


    ###########systemlinuxs#########!
    #!/bin/sh
    if ps x |grep -v grep |grep -c oscam_9790>/dev/null
    then
    echo "oscam_9790... ok"
    else
    echo "oscam_9790... restarting"
    /usr/bin/oscam_9790 &
    fi



    names check.sh attributes set to 775 located in /usr/script


    and then in /etc/cron/crontabs in the root file I have this to check every minute the script


    * * * * * /usr/script/check.sh



    is there something I have missed ?


    - - - Updated - - -


    p.s my oscam in usr/bin is names oscam_9790


    - - - Updated - - -


    also tried this crontab


    */1 * * * * /usr/script/check.sh

  • what image are you using


    cuz
    in the script i would tell the cam script to start oscam
    not try and start via the /usr/bin



    i use openpli4
    with oscam-ymod
    see how i start oscam-ymod with the cam script in red



    change the names and paths to suit


    oscam.check.sh



    #!/bin/sh
    #Script to check if oscam_ymod is running.
    process=`ps auxwww | grep oscam_ymod | grep -v grep | awk '{print $1}'`
    if [ -z '$process' ]; then
    echo "Couldn't find oscam_ymod running Restarting oscam_ymod Server" >> /var/log/oscam.check
    echo && date >> /var/log/oscam.check
    Sleep 1
    /etc/init.d/softcam.oscam_ymod start
    echo "oscam_ymod is still OK!" >> /var/log/oscam.check
    fi



    make a oscam.check log flie with telnet


    touch /var/log/oscam.check


    chmod 644 /var/log/oscam.check



    crontab


    */5 * * * * /usr/script/oscam.check.sh

    Edited 7 times, last by davvo ().

  • I am using an amino alien shd 8900 with openatv 4.1e2 image to be honest it's the only image I have got to work reliably so stuck with it

OSCam Support Forum

Configs, discussion, downloads and guides for OSCam Softcam.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!