Home > Openvz and Virtuozzo > Virtuozzo : “Error: lock timeout exceeded”

Virtuozzo : “Error: lock timeout exceeded”

 

 

ISSUE: Application template installation/removal into a container was failing with error “Error: lock timeout exceeded“. The same timeout exceeded error was reported in ‘/var/log/vztt.log‘.

 

[root@virtuozzo ~]#  /usr/sbin/vzpkg install 1272 cpanel
Error: lock timeout exceeded
[root@virtuozzo ~]# /usr/sbin/vzpkg remove 1272 cpanel
Error: lock timeout exceeded
[root@virtuozzo ~]# tail /var/log/vztt.log
2012-06-12T14:16:02-0400 : Error: lock timeout exceeded
2012-06-12T14:20:45-0400 : Error: lock timeout exceeded
2012-06-12T14:26:02-0400 : Error: lock timeout exceeded
2012-06-12T14:26:02-0400 : Error: lock timeout exceeded
2012-06-12T14:31:35-0400 : Error: lock timeout exceeded
2012-06-12T14:36:02-0400 : Error: lock timeout exceeded
2012-06-12T14:36:02-0400 : Error: lock timeout exceeded
2012-06-12T14:45:08-0400 : Error: lock timeout exceeded
2012-06-12T14:46:02-0400 : Error: lock timeout exceeded
2012-06-12T14:46:02-0400 : Error: lock timeout exceeded
[root@virtuozzo ~]# 

 

 

FIX: There was a lock file(/vz/template/centos/5/x86_64/.lock ) present inside the vps os template directory which prevented the installation of application templates. You can use the strace command(strace -e trace=open /usr/sbin/vzpkg remove 1272 cpanel ) to view the files opened by the vzpkg process. In my case strace reported the existence of a lock. Removing the lock file fixed the issue for me.

 

[root@virtuozzo ~]# cat /vz/template/centos/5/x86_64/.lock 
[root@virtuozzo ~]# file /vz/template/centos/5/x86_64/.lock 
/vz/template/centos/5/x86_64/.lock: empty
[root@virtuozzo ~]# ls -l /vz/template/centos/5/x86_64/.lock
-rw------- 1 root root 0 Jun 12 15:16 /vz/template/centos/5/x86_64/.lock
[root@virtuozzo ~]# rm -f /vz/template/centos/5/x86_64/.lock
[root@virtuozzo ~]# 
Advertisements
Categories: Openvz and Virtuozzo
  1. Eby
    August 19, 2013 at 8:44 pm

    Thanks. Worked for me… 🙂

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: