Funcţionează la cineva acest script ?
.
'' This script will work on most linux dist. including enigma1/2.
The script will check if the CCCam proccess are running with a crontab and restart CCcam if stopped for some reason.
Make a file called checkcccam.sh and place it under /bin. chmod with 755 and paste this into the file:
#!/bin/bash
CCCAM_CONFIG_FILE_PATH="/etc"
CCCAM_EXECUTABLE_PATH="/bin"
NAME_OFF_CCCAM_EXECUTABLE="CCcam.x86"
#
function Check_CCcam {
ps -eo comm,pid,etime > tmpcat
PID=$(grep -i $NAME_OFF_CCCAM_EXECUTABLE tmpcat | awk -F" " '{ print $2}')
TIME=$(grep -i $NAME_OFF_CCCAM_EXECUTABLE tmpcat | awk -F" " '{ print $3}')
}
#
Check_CCcam
if [ "$PID" = "" ]; then
cd $CCCAM_EXECUTABLE_PATH
./$NAME_OFF_CCCAM_EXECUTABLE -C $CCCAM_CONFIG_FILE_PATH/CCcam.cfg
fi
exit 0
Modify the 3 lines marked with red to fit your local settings for paths and name of cccam file.
Then make a crontab to run this script every 1 min.:
# crontab -e
Insert this line and save the file:
* * * * * /bin/checkcccam.sh
Try to kill your cccam process and check that it starts again in max. 1 min. ''
Don't dream your life - live your DREAMbox ! DON'T FORGET TO SAY '' THANKS '' Note: Viewing Pay TV without a valid subscription is illegal All the files available here are kept for experimental and educational purpose only!
Funcţionează la cineva acest script ?
.
Fost membru al acestui forum
Hi
I use Cccam 2.1.4 to DM 800 ( Orginal)with Gemini 5.0 and DreamEite 13 Image,
can you Write a sample Instead of red setting, please?
CCCAM_CONFIG_FILE_PATH="/etc"
CCCAM_EXECUTABLE_PATH="/bin"
NAME_OFF_CCCAM_EXECUTABLE="CCcam.x86"
Best regards
Daca mai are nevoie cineva de un script care sa verifice si sa dea restart la CCcam in caz in care e nevoie, eu pe BH folosesc scriptul urmator denumit ccheck.sh si plasat in/usr/scriptSe adauga liniade mai jos in fisieru root si bh.cron aflate in /etc/bhcron/#!/bin/sh
if ps x |grep -v grep |grep -c CCcam >/dev/null
then
echo "cccam... ok"
else
echo "cccam... restarting"
/usr/bin/CCcam
fi
*/5 * * * * /usr/script/ccheck.sh
Last edited by franta; 19-12-12 at 21:18.