Ubuntu: Unable to install anything on Ubuntu 17.10 due to libreoffice



Question:

I upgraded Ubuntu 17.04 to 17.10 today. It gave me few errors while upgrading mentioning images _helpimg.zip.dpkg-new, libreoffice and 3-4 more. In last it prompted that upgraded with error.

Now I'm not able to install / update anything. It gives this error

unable to open '/usr/share/libreoffice/share/config/images_helpimg.zip.dpkg-new':  Operation not permitted  

I have already tried the following commands

sudo apt-get purge libreoffice* openoffice*   

It gives

Package 'libreoffice-wiki-publisher' is not installed, so not removed  You might want to run 'apt --fix-broken install' to correct these.  The following packages have unmet dependencies:     gir1.2-lokdocview-0.1 :        Depends: libreoffice-core (= 1:5.4.2-0ubuntu0.17.10.1) but it is not going to be installed       liblibreofficekitgtk :        Depends: libreofficekit-data but it is not going to be installed        Depends: libreoffice-core (= 1:5.4.2-0ubuntu0.17.10.1) but it is not going to be installed        Recommends: libreoffice-gtk3 but it is not going to be installed     python3-uno :        Depends: libreoffice-core (= 1:5.4.2-0ubuntu0.17.10.1) but it is not going to be installed  E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).  

So I tried

sudo apt --fix-broken install  

Which tried to install but failed

Reading package lists... Done  Building dependency tree         Reading state information... Done  Correcting dependencies... Done  The following additional packages will be installed:    libreoffice-common  Suggested packages:    libreoffice-style-hicontrast libreoffice-style-oxygen libreoffice-style-sifr  The following packages will be upgraded:    libreoffice-common  1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.  28 not fully installed or removed.  Need to get 0 B/20.8 MB of archives.  After this operation, 15.7 MB disk space will be freed.  Do you want to continue? [Y/n] Y  (Reading database ... 292277 files and directories currently installed.)  Preparing to unpack .../libreoffice-common_1%3a5.4.2-0ubuntu0.17.10.1_all.deb ...  Unpacking libreoffice-common (1:5.4.2-0ubuntu0.17.10.1) over (1:5.3.1-0ubuntu2) ...  dpkg: error processing archive /var/cache/apt/archives/libreoffice-common_1%3a5.4.2-0ubuntu0.17.10.1_all.deb (--unpack):   unable to open '/usr/share/libreoffice/share/config/images_helpimg.zip.dpkg-new': Operation not permitted  rmdir: failed to remove '/var/lib/libreoffice/share/prereg/': No such file or directory  rmdir: failed to remove '/var/lib/libreoffice/share/': No such file or directory  rmdir: failed to remove '/var/lib/libreoffice/program/': No such file or directory  rmdir: failed to remove '/var/lib/libreoffice': No such file or directory  rmdir: failed to remove '/var/lib/libreoffice': No such file or directory  Errors were encountered while processing:   /var/cache/apt/archives/libreoffice-common_1%3a5.4.2-0ubuntu0.17.10.1_all.deb  E: Sub-process /usr/bin/dpkg returned an error code (1)  

Hence I tried to install it manually

$sudo gdebi  /var/cache/apt/archives/libreoffice-common_1%3a5.4.2-  0ubuntu0.17.10.1_all.deb  Reading package lists... Done  Building dependency tree          Reading state information... Done  Reading state information... Done  This package is uninstallable  Failed to satisfy all dependencies (broken cache)  

Since it didn't help, I tried following

$ sudo dpkg --configure -a  :  Errors were encountered while processing:   libreoffice-style-galaxy   libreoffice-l10n-hi   libreoffice-core   libreoffice-calc   libreoffice-l10n-ja   libreoffice-l10n-en-gb   libreofficekit-data   libreoffice-style-elementary   gir1.2-lokdocview-0.1   libreoffice-l10n-en-za   libreoffice-style-tango   gnome-menus   libreoffice-gtk3   libreoffice-style-breeze   libreoffice-gnome   libreoffice-pdfimport   libreoffice-draw   libreoffice-help-en-us   libreoffice-avmedia-backend-gstreamer   libreoffice-ogltrans   libreoffice-writer   libreoffice-help-ja   libreoffice-impress   liblibreofficekitgtk   libreoffice-help-hi   libreoffice-math   libreoffice-help-en-gb   libreoffice-base-core  

But nothing worked.


Solution:1

Finally I installed Synaptic Package Manager from Ubuntu Software Center which is basically GUI alternative for apt-get. It let me install all the packages which I was facing difficulty with in APT. So I installed libreoffice, python3, and python3-minimal. It solved my problem. Now I'm able to install other packages too.


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »