Comment 121 for bug 349469

Revision history for this message
Steve Langasek (vorlon) wrote : Re: [Bug 349469] Re: debconf: DbDriver "config": /var/cache/debconf/config.dat is locked by another process: Resource temporarily unavailable

On Wed, Jan 20, 2016 at 03:42:23AM -0000, Brad Chesney wrote:
> If you want to see this in action I have a set of provisioning scripts
> that reprocuce the problem in an automated way...

> On a brand new Debian 8.1 linode, if you run my script it will prompt
> you for a mysql password-- the thing is I tried to pre-set the mysql
> password with debconf.

> git clone https://github.com/bradchesney79/2015DebianJessieWebserverProject.git
> pushd 2015DebianJessieWebserverProject-master/
> git checkout ef2dd6e396c0b88652c47c39f2cf692d562d9d23
> popd
> mkdir -p /root/bin
> cp -R /root/2015DebianJessieWebserverProject-master/* /root/bin/
> ./root/bin/build-script.sh

> The system will begin to build.

> <CTRL> + <Z> the password prompt to get back to the command line.

> I try to run the debconf command after the fact:

> root@server/root/# echo "mysql-server mysql-server/root_password select
> passw0rd" | debconf-set-selections

Ok, well, this is user error. The database *is* locked. The reason this
bug is open is because it's assumed that somehow, two packages are trying to
use the debconf database in parallel; if you're trying to access it yourself
while the debconf frontend is running, that's not a bug.