Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Ubuntu This forum is for the discussion of Ubuntu Linux.


  Search this Thread
Old 01-12-2012, 07:09 PM   #1
LQ Newbie
Registered: Jan 2012
Posts: 3

Rep: Reputation: Disabled
apt error after upgrade and 'apt-get -f install' does not sort it out

Greetings. Apt broke with conflicts between some libreoffice packages today after an 'apt-get upgrade'. There were several packages that broke. I restarted and it wouldn't boot up at all because of some error. After a few tries with old kernels I got in and figured out how to upgrade to the new kernel. That seems to have helped but some packages still show the conflict. I would have remembered more about this but I didn't think I'd be here asking for help so I hope that is sufficient. The terminal readout is below. Many thanks.

Some disclosure, My HDD failed last week and I had not got around to installing the nvidia drivers yet in my new install, so the problems on restart might be a combination promlem and may not be all that relevant.

gir@steamie:~$ sudo apt-get -f install
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... Done
The following package was automatically installed and is no longer required:
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  libhunspell-1.3-0 libreoffice-common libreoffice-core
  libreoffice-style-oxygen librsvg2-2
Suggested packages:
  libreoffice-style-hicontrast libreoffice-style-tango
  libreoffice-style-crystal kde-icons-oxygen oxygencursors librsvg2-bin
The following packages will be REMOVED:
  libreoffice-l10n-en-gb libreoffice-l10n-en-za
The following NEW packages will be installed:
The following packages will be upgraded:
  libreoffice-common libreoffice-core libreoffice-style-oxygen librsvg2-2
4 upgraded, 1 newly installed, 2 to remove and 696 not upgraded.
66 not fully installed or removed.
Need to get 0 B/61.4 MB of archives.
After this operation, 7,953 kB disk space will be freed.
Do you want to continue [Y/n]? y
(Reading database ... 127998 files and directories currently installed.)
Preparing to replace libreoffice-core 1:3.4.3-3ubuntu2 (using .../libreoffice-core_1%3a3.5.0~beta2-2ubuntu2_amd64.deb) ...
rmdir: failed to remove `usr/lib/libreoffice/basis3.4/program/': Directory not empty
dpkg: error processing /var/cache/apt/archives/libreoffice-core_1%3a3.5.0~beta2-2ubuntu2_amd64.deb (--unpack):
 subprocess new pre-installation script returned error exit status 1
Errors were encountered while processing:
E: Sub-process /usr/bin/dpkg returned an error code (1)
Old 01-12-2012, 11:09 PM   #2
David the H.
Bash Guru
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Arch + Xfce
Posts: 6,852

Rep: Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037
Sometimes you have to read the error messages carefully and do a bit of guesswork to figure out solutions.

The only line that explicitly states what happened is this:
rmdir: failed to remove `usr/lib/libreoffice/basis3.4/program/': Directory not empty
Usually this kind of error doesn't cause the whole installation to fail, but maybe it's something necessary this time. I don't know. First see what's in that directory that's causing it to fail. Then either move it out, or just rename the directory away, and re-running the command. You may need to use "apt-get install -f" first. If everything works correctly, you should be able to delete them permanently.

Speaking of which, it's often a good idea to pay careful attention whenever apt wants to remove a package. It can sometimes want to uninstall optional packages that you may actually want to keep.

Finally, while probably not the case here, remember that most errors caused by package conflicts tend to be temporary. Often you just have wait a few days until they get resolved upstream.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Can't boot after apt-update / apt-upgrade ozymandias Debian 2 09-06-2008 10:31 AM
Howabout apt-get update ; apt-get upgrade -f -y --force-yes in the crontab every week frenchn00b Debian 1 04-05-2008 08:47 AM
Error with apt, on any command; update, upgrade, install etc Brian5 Ubuntu 2 11-28-2007 12:52 AM
Question about 'apt-get upgrade' versus 'apt-get install' eur0dad Red Hat 8 07-16-2006 06:41 PM
What's the difference between apt-get upgrade and apt-get dist-upgrade? davidas Linux - Newbie 4 04-04-2004 09:19 PM > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 10:02 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration