I tried to install the
mysql-server
package on my Ubuntu VPS. Theapt-get
process crashed and I had to kill it. Now I have this error message whenever I try to install it again:$ sudo apt-get install mysql-server Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: mysql-server 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. 4 not fully installed or removed. Need to get 0 B/6,452 B of archives. After this operation, 98.3 kB of additional disk space will be used. debconf: DbDriver "config": /var/cache/debconf/config.dat is locked by another process: Resource temporarily unavailable Selecting previously deselected package mysql-server. (Reading database ... 36812 files and directories currently installed.) Unpacking mysql-server (from .../mysql-server_5.1.61-0ubuntu0.11.10.1_all.deb) ... Setting up mysql-server-5.1 (5.1.61-0ubuntu0.11.10.1) ... debconf: DbDriver "config": /var/cache/debconf/config.dat is locked by another process: Resource temporarily unavailable dpkg: error processing mysql-server-5.1 (--configure): subprocess installed post-installation script returned error exit status 1 Setting up man-db (2.6.0.2-2) ... debconf: DbDriver "config": /var/cache/debconf/config.dat is locked by another process: Resource temporarily unavailable dpkg: error processing man-db (--configure): subprocess installed post-installation script returned error exit status 1 Setting up libapache2-mod-php5 (5.3.6-13ubuntu3.6) ... debconf: DbDriver "config": /var/cache/debconf/config.dat is locked by another process: Resource temporarily unavailable dpkg: error processing libapache2-mod-php5 (--configure): subprocess installed post-installation script returned error exit status 1 Setting up php5-cli (5.3.6-13ubuntu3.6) ... debconf: DbDriver "config": /var/cache/debconf/config.dat is locked by another process: Resource temporarily unavailable dpkg: error processing php5-cli (--configure): subprocess installed post-installation script returned error exit status 1 No apport report written because MaxReports is reached already dpkg: dependency problems prevent configuration of mysql-server: mysql-server depends on mysql-server-5.1; however: Package mysql-server-5.1 is not configured yet. dpkg: error processing mysql-server (--configure): dependency problems - leaving unconfigured No apport report written because MaxReports is reached already Errors were encountered while processing: mysql-server-5.1 man-db libapache2-mod-php5 php5-cli mysql-server E: Sub-process /usr/bin/dpkg returned an error code (1)
Please help, it’s kind of urgend.
Answer
run fuser /var/cache/debconf/config.dat
to find the process which locked that file. (you might have to install the psmisc package to get fuser). I’d try to kill that process (but gracefully, not with -9)
Attribution
Source : Link , Question Author : Lanbo , Answer Author : stew