Upgrade problem: Sub-process /usr/bin/dpkg returned an error code (1)

Asked by John Erskine

Running Kubuntu 8.04

I'm having a problem with no sound on my machine. After a lot of checking, running apt-get, aptitude, synaptic, and adept still won't work

With apt-get install I get

(Reading database ... dpkg: error processing /var/cache/apt/archives/linux-image -2.6.24-19-generic_2.6.24-19.36_i386.deb (--unpack):
 files list file for package `linux-image-2.6.24-19-generic' is missing final ne wline
Errors were encountered while processing:
 /var/cache/apt/archives/linux-image-2.6.24-19-generic_2.6.24-19.36_i386.deb
Processing was halted because there were too many errors.
E: Sub-process /usr/bin/dpkg returned an error code (1)

With aptitude I get

E: I wasn't able to locate the file for the linux-image-2.6.24-19-generic package. This might mean you might have to manually fix this package.

E: Internal error. Couldn't generate list of packages to download.

With synaptic I get

E: The package linux-image-2.6.24-19-generic needs to be reinstalled, but I can't find an archive for it.
E: Internal error opening cache (1). Please report.

With adept I get

There was an error commiting changes. Possibly there was a problem downloading some packages or the commit would break packages.

Is the key to the problem at

files list file for package `linux-image-2.6.24-19-generic' is missing final ne wline

If so, where will I find this file, and how can I add the missing final new line?

Or should I re-build the kernel? I'm not sure that I've got the knowledge to do this.

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu Edit question
Assignee:
No assignee Edit question
Solved by:
John Erskine
Solved:
Last query:
Last reply:
Revision history for this message
Trygve Vea (trygve-vea-gmail) said :
#1

Hello!

I believe that you might find your answer here:

https://lists.ubuntu.com/archives/ubuntu-users/2007-January/104520.html

I hope this helps :)

Regards, Trygve

Revision history for this message
John Erskine (john-erskine) said :
#2

I've just tried this

After running sudo apt-get --reinstall install linux-image-2.6.24-19-generic

I get a large number of dpkg error messages

dpkg: serious warning: files list file for package ???, assuming package has no files currently installed.

then

User postinst hook script [/sbin/update-grub] exited with value 10
dpkg: error processing linux-image-2.6.24-19-generic (--configure):
 subprocess post-installation script returned error exit status 10
Errors were encountered while processing:
 linux-image-2.6.24-19-generic
E: Sub-process /usr/bin/dpkg returned an error code (1)

then I ran

sudo mv info/* info.bak/
sudo rm -rf info
sudo mv info.bak info

I then ran adept, which installed all the required upgrades. I'm still not getting sound, but I will try to reboot and see what happens.

Revision history for this message
John Erskine (john-erskine) said :
#3

This worked!

Many thanks Trygve!

Revision history for this message
sillat (sillatntwrx-inc) said :
#4

Thanks Trygve Vea
Worked like a Charm . .
I had this same problem in Ubuntu Jaunty 9.04 Upgrading to linux-image-2.6.28-13-generic

My Error was :
Package linux-image-2.6.28-13-generic is not configured yet.
dpkg: error processing linux-restricted-modules-2.6.28-13-generic (--configure):
 dependency problems - leaving unconfigured
Sub-process /usr/bin/dpkg returned an error code (1))

Thanks Again

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

This helped me also with the update to 10.04 ! Thousand thanks! Struggled a lot!