Very weird behavior when running cron on a OPENVZ container.

michaelvv

Renowned Member
Oct 9, 2008
103
3
83
Hi Proxmox...

I have a very serious problem. I have installed the following Proxmox version

server1:~# pveversion -v
pve-manager: 1.5-10 (pve-manager/1.5/4822)
running kernel: 2.6.24-11-pve
proxmox-ve-2.6.24: 1.5-23
pve-kernel-2.6.24-11-pve: 2.6.24-23
pve-kernel-2.6.18-2-pve: 2.6.18-5
qemu-server: 1.1-16
pve-firmware: 1.0-5
libpve-storage-perl: 1.0-13
vncterm: 0.9-2
vzctl: 3.0.23-1pve11
vzdump: 1.2-5
vzprocps: 2.0.11-1dso2
vzquota: 3.0.11-1
pve-qemu-kvm: 0.12.4-1

and in a OPENVZ container CentOS release 5.5 (Final)...

Everything seems to be running fine except from cron , it runs the scripts for a few
secounds and then it terminate for no reason....

When i made the same cronjob and run it from the HOST on proxmox with this
command /usr/sbin/vzctl exec CID 'what to execute' it runs just fine.

I'm sure i run the script as root and i have the sufficient ENV variables on the
GUEST OS ...

I'm just lost .. Have anyone seem this kind of problem before ????

Thanks Michael
 
Hi Tom...

Just checked there is no failcounts at all...

POST to long but all are on zero...


I can run a simple cronscript for 60 sec without any problems.

when i from the same cronscript run a more advanced php-script from
within bash is terminate without any reason at all , nothing in the
logs. I have a debugged output from my failed script here and for me it
seems that it just stop executing...

___THIS ONE FAILS from CRON___________________________________
alias is : dbaseserver ''
Prog Started on -> 07-21-2010 12:47:01 running as 'root'
alias is : dbaseserver ''
PATH -> /usr/bin:/bin:/sbin:/usr/sbin:/mnt/sysimage/bin:/mnt/sysimage/usr/bin:/mnt/sysimage/usr/sbin:/mnt/sysimage/sbin:/mnt/sysimage/usr/X11R6/bin:/sbin:/usr/sbin:/usr/local/bin:/myshell:/myperl
alias is : dbaseserver ''
Remote Database Backups Starting using path -> /mnt/samba/dbbackup
/usr/local/bin/php /mnt/samba/script/checklinux.php zmanda tar cashserver1 new
execode -> 0
array (
0 => '***************************',
1 => '** Checking Linux ver 1.00.',
2 => '***************************',
3 => 'Function Tar (cashserver1)!!',
4 => 'exe (find /mnt/samba/mysql -iname bin-log* -ctime -2 | sort)',
5 => 'maxbinlog (96)',
6 => 'Number of Backups is *** 2 ***',
7 => 'Newest is Backup ID is XXX (1)',
8 => 'running PARTS(Array) SIZE(72.98 Mb.) DATE(21/07-2010 00:10:10-21/07-2010 12:30:04)',
9 => 'cmd(/bin/tar -cf /mnt/samba/dbbackup/cashserver1_20100721_124701.tar --files-from /tmp/zmanda_1279709221.5492)',
10 => 'Completed in 0.19 Sec(s).',
)
/usr/local/bin/php /mnt/samba/script/checklinux.php zmanda tar vfraud new
execode -> 0
______________________________________

as you can see it just stops


__THIS one is okay from command line_______

alias is : dbaseserver ''
Prog Started on -> 07-21-2010 12:56:40 running as 'root'
alias is : dbaseserver ''
PATH -> /usr/bin:/bin:/sbin:/usr/sbin:/mnt/sysimage/bin:/mnt/sysimage/usr/bin:/mnt/sysimage/usr/sbin:/mnt/sysimage/sbin:/mnt/sysimage/usr/X11R6/bin:/sbin:/usr/sbin:/usr/local/bin:/myshell:/myperl
alias is : dbaseserver ''
Remote Database Backups Starting using path -> /mnt/samba/dbbackup
/usr/local/bin/php /mnt/samba/script/checklinux.php zmanda tar cashserver1 new
execode -> 0
array (
0 => '***************************',
1 => '** Checking Linux ver 1.00.',
2 => '***************************',
3 => 'Function Tar (cashserver1)!!',
4 => 'exe (find /mnt/samba/mysql -iname bin-log* -ctime -2 | sort)',
5 => 'maxbinlog (96)',
6 => 'Number of Backups is *** 2 ***',
7 => 'Newest is Backup ID is XXX (1)',
8 => 'running PARTS(Array) SIZE(72.98 Mb.) DATE(21/07-2010 00:10:10-21/07-2010 12:30:04)',
9 => 'cmd(/bin/tar -cf /mnt/samba/dbbackup/cashserver1_20100721_125640.tar --files-from /tmp/zmanda_1279709800.8076)',
10 => 'Completed in 0.20 Sec(s).',
)
/usr/local/bin/php /mnt/samba/script/checklinux.php zmanda tar vfraud new
execode -> 0
array (
0 => '***************************',
1 => '** Checking Linux ver 1.00.',
2 => '***************************',
3 => 'Function Tar (vfraud)!!',
4 => 'exe (find /mnt/samba/mysql -iname bin-log* -ctime -2 | sort)',
5 => 'maxbinlog (96)',
6 => 'Number of Backups is *** 2 ***',
7 => 'Newest is Backup ID is XXX (1)',
8 => 'running PARTS(Array) SIZE(42.42 Mb.) DATE(21/07-2010 00:10:46-21/07-2010 12:30:06)',
9 => 'cmd(/bin/tar -cf /mnt/samba/dbbackup/vfraud_20100721_125641.tar --files-from /tmp/zmanda_1279709801.0883)',
10 => 'Completed in 0.12 Sec(s).',
)
/usr/local/bin/php /mnt/samba/script/checklinux.php zmanda tar cashserver new
execode -> 0
array (
0 => '***************************',
1 => '** Checking Linux ver 1.00.',
2 => '***************************',
3 => 'Function Tar (cashserver)!!',
4 => 'exe (find /mnt/samba/mysql -iname bin-log* -ctime -2 | sort)',
5 => 'maxbinlog (96)',
6 => 'Number of Backups is *** 2 ***',
7 => 'Newest is Backup ID is XXX (1)',
8 => 'running PARTS(Array) SIZE(861.72 Mb.) DATE(21/07-2010 00:05:01-21/07-2010 12:30:02)',
9 => 'cmd(/bin/tar -cf /mnt/samba/dbbackup/cashserver_20100721_125641.tar --files-from /tmp/zmanda_1279709801.2851)',
10 => 'Completed in 2.03 Sec(s).',
)
______________________________________





Best

/MIchael
 
Last edited:

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!