Ubuntu 11.10: Apt-get / dpkg fails to install anything

Asked by Faisal Humayun

 apt-get install -f / apt-get autoremove all fail when the package manager kicks off the dpkg process.

dpkg --configure -a
Setting up base-files (6.4ubuntu5) ...
+ [ ! -e /etc/dpkg/origins/default ]
+ [ configure = configure ]
+ [ = ]
+ install_from_default /usr/share/base-files/nsswitch.conf /etc/nsswitch.conf
+ [ ! -f /etc/nsswitch.conf ]
+ install_from_default /usr/share/base-files/dot.profile /root/.profile
+ [ ! -f /root/.profile ]
+ install_from_default /usr/share/base-files/dot.bashrc /root/.bashrc
+ [ ! -f /root/.bashrc ]
+ install_from_default /usr/share/base-files/profile /etc/profile
+ [ ! -f /etc/profile ]
+ install_from_default /usr/share/base-files/networks /etc/networks
+ [ ! -f /etc/networks ]
+ install_directory srv 755 root
+ [ ! -d /srv ]
+ install_directory opt 755 root
+ [ ! -d /opt ]
+ install_directory etc/opt 755 root
+ [ ! -d /etc/opt ]
+ install_directory var/opt 755 root
+ [ ! -d /var/opt ]
+ install_directory media 755 root
+ [ ! -d /media ]
+ install_directory var/mail 2775 mail
+ [ ! -d /var/mail ]
+ [ ! -L /var/spool/mail ]
+ install_directory run/lock 1777 root
+ [ ! -d /run/lock ]
+ migrate_directory /var/run /run
+ [ ! -L /var/run ]
+ rmdir /var/run
rmdir: failed to remove `/var/run': Directory not empty
dpkg: error processing base-files (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
base-files

Is there a patch, script workaround to circumvent/correct this condition?
Thanks,
Faisal

Question information

Language:
English Edit question
Status:
Answered
For:
Ubuntu apt Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
marcobra (Marco Braida) (marcobra) said :
#1
Revision history for this message
Faisal Humayun (faisal-humayun) said :
#2

Thanks for the pointer Marco. I did follow the guide; regrettably, the dpkg --configure -a portion continues to fail with the exact error.

rmdir: failed to remove `/var/run': Directory not empty
dpkg: error processing base-files (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
base-files

Revision history for this message
Mark Rijckenberg (markrijckenberg) said :
#3

Seems like the following bug for which there is no solution yet:

https://bugs.launchpad.net/ubuntu/+source/multistrap/+bug/874505

Revision history for this message
mfauzirahman (mfauzirahman) said :
#4

sudo apt-get clean
cd /var/lib/apt
sudo mv lists lists.old
sudo rm -rf lists.old
sudo mkdir -p lists/partial
sudo apt-get clean
sudo apt-get update

Revision history for this message
mfauzirahman (mfauzirahman) said :
#5

Any update on this issue?
Please change to solved status if the problem is solved

Can you help with this problem?

Provide an answer of your own, or ask Faisal Humayun for more information if necessary.

To post a message you must log in.