Package Operation Failed : package 'evince' is missing final newline

Asked by sumith

Hi experts,

I am a newbie to linux . I am always getting error Package Operation failed while performing an update from "Update Manager"
Can you please help fixing the error while installing/updating package.

Logs Below

installArchives() failed:
Extracting templates from packages: 15%%
Extracting templates from packages: 31%%
Extracting templates from packages: 47%%
Extracting templates from packages: 62%%
Extracting templates from packages: 78%%
Extracting templates from packages: 94%%
Extracting templates from packages: 100%%
Preconfiguring packages ...
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign

Extracting templates from packages: 15%%
Extracting templates from packages: 31%%
Extracting templates from packages: 47%%
Extracting templates from packages: 62%%
Extracting templates from packages: 78%%
Extracting templates from packages: 94%%
Extracting templates from packages: 100%%
Preconfiguring packages ...
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign

Extracting templates from packages: 15%%
Extracting templates from packages: 31%%
Extracting templates from packages: 47%%
Extracting templates from packages: 62%%
Extracting templates from packages: 78%%
Extracting templates from packages: 94%%
Extracting templates from packages: 100%%
Preconfiguring packages ...
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign
(Reading database ...
(Reading database ... 5%%
(Reading database ... 10%%
(Reading database ... 15%%
(Reading database ... 20%%
(Reading database ... 25%%
(Reading database ... 30%%
(Reading database ... 35%%
(Reading database ... 40%%
(Reading database ... 45%%
(Reading database ... 50%%
(Reading database ... 55%%dpkg: unrecoverable fatal error, aborting:
 files list file for package 'evince' is missing final newline
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign

Thanks in advance,
Sumith/-

Question information

Language:
English Edit question
Status:
Answered
For:
Ubuntu apt Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:

This question was reopened

Revision history for this message
Daniel Letzeisen (dtl131) said :
#1

The evince package file in the cache may be corrupted. Clean the cache with:
sudo apt-get clean

Then, reinstall evince:
sudo apt-get install --reinstall evince

Revision history for this message
sumith (sumithsunder) said :
#2

Hi Dave,

Thanks for the suggestion.
But the issue is not solved. Please let me know if I need to follow any more steps.

Logs below

sumith@sumith-HP-Pavilion-dv6-Notebook-PC:~$ sudo apt-get clean
[sudo] password for sumith:
sumith@sumith-HP-Pavilion-dv6-Notebook-PC:~$ sudo apt-get install --reinstall evince
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  libevince3-3
Suggested packages:
  unrar poppler-data
The following packages will be upgraded:
  evince libevince3-3
2 upgraded, 0 newly installed, 0 to remove and 254 not upgraded.
Need to get 561 kB of archives.
After this operation, 0 B of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://lk.archive.ubuntu.com/ubuntu/ oneiric-updates/main evince i386 3.2.1-0ubuntu2.2 [206 kB]
Get:2 http://lk.archive.ubuntu.com/ubuntu/ oneiric-updates/main libevince3-3 i386 3.2.1-0ubuntu2.2 [355 kB]
Fetched 561 kB in 5s (102 kB/s)
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign
(Reading database ... 55%dpkg: unrecoverable fatal error, aborting:
 files list file for package 'evince' is missing final newline
E: Sub-process /usr/bin/dpkg returned an error code (2)
sumith@sumith-HP-Pavilion-dv6-Notebook-PC:~$

Thanks,
Sumith/-

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

please try below step at terminal

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

Revision history for this message
sumith (sumithsunder) said :
#4

Hi mfauzirahman,

Thanks for the suggestion. Followed your steps. But getting the same error while updating

Logs below

installArchives() failed:
Extracting templates from packages: 15%%
Extracting templates from packages: 30%%
Extracting templates from packages: 46%%
Extracting templates from packages: 61%%
Extracting templates from packages: 76%%
Extracting templates from packages: 92%%
Extracting templates from packages: 100%%
Preconfiguring packages ...
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign

Extracting templates from packages: 15%%
Extracting templates from packages: 30%%
Extracting templates from packages: 46%%
Extracting templates from packages: 61%%
Extracting templates from packages: 76%%
Extracting templates from packages: 92%%
Extracting templates from packages: 100%%
Preconfiguring packages ...
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign

Extracting templates from packages: 15%%
Extracting templates from packages: 30%%
Extracting templates from packages: 46%%
Extracting templates from packages: 61%%
Extracting templates from packages: 76%%
Extracting templates from packages: 92%%
Extracting templates from packages: 100%%
Preconfiguring packages ...
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign
(Reading database ...
(Reading database ... 5%%
(Reading database ... 10%%
(Reading database ... 15%%
(Reading database ... 20%%
(Reading database ... 25%%
(Reading database ... 30%%
(Reading database ... 35%%
(Reading database ... 40%%
(Reading database ... 45%%
(Reading database ... 50%%
(Reading database ... 55%%dpkg: unrecoverable fatal error, aborting:
 files list file for package 'evince' is missing final newline
Error in function:
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign

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

have you try to check at synaptic if there any broken link?

Revision history for this message
sumith (sumithsunder) said :
#6

I am newbee to ubuntu. How can i check it?

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

I assume that you not yet install synaptic.
"sudo apt-get install synaptic" without quote
open synaptic, go to custom filter, click on Broken

Revision history for this message
sumith (sumithsunder) said :
#8

Below are the logs after executing the command 'sudo apt-get install synaptic'.
Do I want to re-install ubuntu?

sumith@sumith-HP-Pavilion-dv6-Notebook-PC:~$ sudo apt-get install synaptic
[sudo] password for sumith:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
  dwww menu deborphan
The following NEW packages will be installed:
  synaptic
0 upgraded, 1 newly installed, 0 to remove and 260 not upgraded.
Need to get 2,150 kB of archives.
After this operation, 7,148 kB of additional disk space will be used.
Get:1 http://lk.archive.ubuntu.com/ubuntu/ oneiric/universe synaptic i386 0.75.2ubuntu8 [2,150 kB]
Fetched 2,150 kB in 17s (122 kB/s)
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign
Selecting previously deselected package synaptic.
(Reading database ... 55%dpkg: unrecoverable fatal error, aborting:
 files list file for package 'evince' is missing final newline
E: Sub-process /usr/bin/dpkg returned an error code (2)
sumith@sumith-HP-Pavilion-dv6-Notebook-PC:~$

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

0 upgraded, 1 newly installed, 0 to remove and 260 not upgraded.

Notice that you have 260 files need to be upgrade.
Can you try to upgrade it first

sudo apt-get dist-upgrade

Revision history for this message
sumith (sumithsunder) said :
#10

Hi,

I am not able to perform upgrade because of the same error. I think its totally a deadlock

sumith@sumith-HP-Pavilion-dv6-Notebook-PC:~$ sudo apt-get dist-upgrade
[sudo] password for sumith:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following NEW packages will be installed:
  linux-headers-3.0.0-16 linux-headers-3.0.0-16-generic
  linux-image-3.0.0-16-generic
The following packages will be upgraded:
  accountsservice acpid app-install-data-partner at-spi2-core bamfdaemon
  banshee banshee-extension-soundmenu banshee-extension-ubuntuonemusicstore
  binutils brasero brasero-cdrkit brasero-common bzip2 chromium-browser
  chromium-browser-l10n chromium-codecs-ffmpeg colord compiz compiz-core
  compiz-gnome compiz-plugins-default compiz-plugins-main-default cups
  cups-bsd cups-client cups-common cups-ppdc evince evince-common
  evolution-data-server evolution-data-server-common fglrx-amdcccle-updates
  fglrx-updates file-roller firefox firefox-globalmenu firefox-gnome-support
  firefox-locale-en flashplugin-downloader flashplugin-installer gbrainy
  gcalctool gedit gedit-common ghostscript ghostscript-cups ghostscript-x
  gir1.2-atspi-2.0 gir1.2-gtk-3.0 gir1.2-webkit-3.0 gnome-keyring
  gnome-session gnome-session-bin gnome-session-common gnome-session-fallback
  gnome-settings-daemon hpijs hplip hplip-cups hplip-data ifupdown
  indicator-sound initscripts isc-dhcp-client isc-dhcp-common jockey-common
  jockey-gtk kate-data katepart kde-runtime kde-runtime-data kdebase-runtime
  kdelibs-bin kdelibs5-data kdelibs5-plugins kdoctools language-pack-en
  language-pack-en-base language-pack-gnome-en language-pack-gnome-en-base
  language-selector-common language-selector-gnome libaccountsservice0
  libarchive1 libatspi2.0-0 libavcodec-extra-53 libavformat53
  libavutil-extra-51 libbamf0 libbamf3-0 libbrasero-media3-1 libbz2-1.0
  libcamel-1.2-29 libcolord1 libcups2 libcupscgi1 libcupsdriver1 libcupsimage2
  libcupsmime1 libcupsppdc1 libcurl3-gnutls libdecoration0 libebackend-1.2-1
  libebook1.2-12 libecal1.2-10 libedata-book-1.2-11 libedata-cal-1.2-13
  libedataserver1.2-15 libedataserverui-3.0-1 libevince3-3 libgail-3-0
  libgail-3-common libgck-1-0 libgcr-3-1 libgs9 libgs9-common libgssapi-krb5-2
  libgtk-3-0 libgtk-3-bin libgtk-3-common libgudev-1.0-0 libgweather-3-0
  libgweather-common libhpmud0 libicu44 libjasper1 libk5crypto3
  libkatepartinterfaces4 libkcddb4 libkcmutils4 libkde3support4 libkdecore5
  libkdesu5 libkdeui5 libkdewebkit5 libkdnssd4 libkemoticons4 libkfile4
  libkhtml5 libkidletime4 libkio5 libkjsapi4 libkjsembed4 libkmediaplayer4
  libknewstuff3-4 libknotifyconfig4 libkntlm4 libkparts4 libkpty4 libkrb5-3
  libkrb5support0 libkrosscore4 libktexteditor4 liblightdm-gobject-1-0
  libmetacity-private0 libmono-zeroconf1.0-cil libnautilus-extension1
  libnepomuk4 libnepomukquery4a libnepomukutils4 libnm-glib-vpn1 libnm-glib4
  libnm-util2 libnux-1.0-0 libnux-1.0-common libpam-gnome-keyring libplasma3
  libpng12-0 libpolkit-qt-1-1 libpostproc52 libqt4-dbus libqt4-declarative
  libqt4-designer libqt4-network libqt4-opengl libqt4-qt3support libqt4-script
  libqt4-sql libqt4-sql-mysql libqt4-svg libqt4-xml libqt4-xmlpatterns
  libqtcore4 libqtgui4 libsane-hpaio libsolid4 libsoprano4 libssl1.0.0
  libswscale2 libsyncdaemon-1.0-1 libt1-5 libthreadweaver4 libubuntuone-1.0-1
  libubuntuone1.0-cil libudev0 libunity-core-4.0-4 libusbmuxd1 libvorbis0a
  libvorbisenc2 libvorbisfile3 libwebkitgtk-1.0-0 libwebkitgtk-1.0-common
  libwebkitgtk-3.0-0 libwebkitgtk-3.0-common libxml2 libxml2-utils lightdm
  linux-generic linux-headers-generic linux-image-generic linux-libc-dev
  metacity metacity-common mobile-broadband-provider-info mousetweaks nautilus
  nautilus-data network-manager nux-tools openjdk-6-jre openjdk-6-jre-headless
  openjdk-6-jre-lib openssl plasma-scriptengine-javascript python-cups
  python-httplib2 python-launchpadlib python-libxml2 python-pkg-resources
  python-software-properties python-ubuntuone-client qdbus shotwell
  software-center software-properties-common software-properties-gtk
  soprano-daemon sysv-rc sysvinit-utils thunderbird thunderbird-globalmenu
  thunderbird-gnome-support tomboy ubuntuone-client ubuntuone-couch udev unity
  unity-common unity-lens-applications unity-services update-manager
  update-manager-core update-notifier update-notifier-common usbmuxd vino
  x11-common xorg xserver-xorg xserver-xorg-input-all xserver-xorg-video-all
  xul-ext-ubufox
262 upgraded, 3 newly installed, 0 to remove and 0 not upgraded.
Need to get 984 kB/306 MB of archives.
After this operation, 237 MB of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://lk.archive.ubuntu.com/ubuntu/ oneiric-updates/main libxml2 i386 2.7.8.dfsg-4ubuntu0.2 [663 kB]
Get:2 http://lk.archive.ubuntu.com/ubuntu/ oneiric-updates/main libxml2-utils i386 2.7.8.dfsg-4ubuntu0.2 [37.9 kB]
Get:3 http://lk.archive.ubuntu.com/ubuntu/ oneiric-updates/main python-libxml2 i386 2.7.8.dfsg-4ubuntu0.2 [276 kB]
Get:4 http://lk.archive.ubuntu.com/ubuntu/ oneiric-updates/main ubuntuone-couch all 0.3.0-0ubuntu2.1 [7,514 B]
Fetched 984 kB in 8s (112 kB/s)
Extracting templates from packages: 100%
Preconfiguring packages ...
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign
dpkg: warning: ignoring option --foreign-architecture=i386: this architecture cannot be foreign
(Reading database ... 55%dpkg: unrecoverable fatal error, aborting:
 files list file for package 'evince' is missing final newline
E: Sub-process /usr/bin/dpkg returned an error code (2)
sumith@sumith-HP-Pavilion-dv6-Notebook-PC:~$

Thanks,
Sumith

Revision history for this message
sumith (sumithsunder) said :
#11

PLease help me, I am not able to install/upgrade/remove any softwares.
Shall I format and install new ubuntu version. 11.10 is a crap
Also i am not able to open document viewer, also unable to re-install evince package.
I believe I am the only got this kind of error.

Please help me

Thanks in Advance,

Sumith/-

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

you use 32 bit or 64 bit?
Why don't you use 12.04 LTS?

Revision history for this message
Sébastien Pierrel (sebastien-pierrel) said :
#13

Can you help with this problem?

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

To post a message you must log in.