LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices

Reply
 
Search this Thread
Old 02-09-2010, 04:48 PM   #1
akhund_bilal
LQ Newbie
 
Registered: Sep 2008
Posts: 12

Rep: Reputation: 0
apt-get dpkg error 5%dpkg


hi
when i try to install or remove any package i get this error

Quote:
(Reading database ... 5%dpkg: unrecoverable fatal error, aborting:
files list file for package `libsox-fmt-alsa' contains empty filename
E: Sub-process /usr/bin/dpkg returned an error code (2)
i'm using ubuntu 9.10
can't install or uninstall or update any thing coz of this error.
pls help me out..

Last edited by akhund_bilal; 02-09-2010 at 04:50 PM.
 
Old 02-09-2010, 06:02 PM   #2
PunksUndead
LQ Newbie
 
Registered: Jan 2009
Location: Central California
Distribution: Kubuntu 10.10 and BackTrack4
Posts: 22

Rep: Reputation: 16
have you tried running sudo dpkg --configure -a
 
Old 02-09-2010, 10:03 PM   #3
evo2
Guru
 
Registered: Jan 2009
Location: Japan
Distribution: Mostly Debian and Scientific Linux
Posts: 5,526

Rep: Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217
Can you post your /var/lib/dpkg/info/libsox-fmt-alsa.list file?

Code:
cat /var/lib/dpkg/info/libsox-fmt-alsa.list
The last line is probably blank: delete it.

Evo2.

Last edited by evo2; 02-09-2010 at 10:04 PM.
 
Old 02-10-2010, 04:36 AM   #4
akhund_bilal
LQ Newbie
 
Registered: Sep 2008
Posts: 12

Original Poster
Rep: Reputation: 0
sorry for late reply
here are the contents of file

Quote:
root@akhund-laptop.akhund-laptop
root@akhund-laptop.akhund-laptop

Received: (nullmailer pid 12500 invoked by uid 0);
Mon, 30 Nov 2009 12:40:32 -0000
From: root@akhund-laptop.akhund-laptop (Cron Daemon)
To: root@akhund-laptop.akhund-laptop
Subject: Cron <root@akhund-laptop> /usr/share/ebox-usersandgroups/slave-sync
Content-Type: text/plain; charset=ANSI_X3.4-1968
X-Cron-Env: <SHELL=/bin/sh>
X-Cron-Env: <PATH=/usr/bin:/bin>
X-Cron-Env: <HOME=/root>
X-Cron-Env: <LOGNAME=root>
Date: Mon, 30 Nov 2009 17:40:32 +0500
Message-Id: <1259584832.761298.12499.nullmailer@akhund-laptop>

Failed to contact configuration server; some possible causes are that you need to enable TCP/IP networking for ORBit, or you have stale NFS locks due to a system crash. See http://projects.gnome.org/gconf/ for information. (Details - 1: Not running within active session) at /usr/share/perl5/EBox/GConfModule.pm line 48.
 
Old 02-10-2010, 05:04 AM   #5
evo2
Guru
 
Registered: Jan 2009
Location: Japan
Distribution: Mostly Debian and Scientific Linux
Posts: 5,526

Rep: Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217
Wow, somehow that file has become completely corrupted. From the following page

http://packages.ubuntu.com/karmic/i3...-alsa/filelist

I think the contents should be:

Code:
/usr
/usr/lib
/usr/lib/sox
/usr/lib/sox/libsox_fmt_alsa.so
/usr/share
/usr/share/doc
/usr/share/doc/libsox-fmt-alsa
/usr/share/doc/libsox-fmt-alsa/AUTHORS
/usr/share/doc/libsox-fmt-alsa/NEWS.gz
/usr/share/doc/libsox-fmt-alsa/README.gz
/usr/share/doc/libsox-fmt-alsa/changelog.Debian.gz
/usr/share/doc/libsox-fmt-alsa/copyright
So please open up the file with a text editor an replace the contents with what I put in the code block above. Make sure you don't leave any blank lines.
That should fix this problem, but it is possible there will be other problems.

Evo2.

Last edited by evo2; 02-10-2010 at 05:06 AM. Reason: typo
 
Old 02-10-2010, 05:15 AM   #6
akhund_bilal
LQ Newbie
 
Registered: Sep 2008
Posts: 12

Original Poster
Rep: Reputation: 0
thanks for quick reply
now the error is changed

Quote:

dpkg: warning: files list file for package `kubuntu-default-settings' missing, assuming package has no files currently installed.


(Reading database ... 5%dpkg: unrecoverable fatal error, aborting:

failed in buffer_read(fd): files list for package `libgtkhex0': Is a directory


Last edited by akhund_bilal; 02-10-2010 at 05:17 AM.
 
Old 02-10-2010, 05:16 AM   #7
akhund_bilal
LQ Newbie
 
Registered: Sep 2008
Posts: 12

Original Poster
Rep: Reputation: 0
is there a way i can refresh all the conf files, just like a fresh instalation.
 
Old 02-10-2010, 05:25 AM   #8
evo2
Guru
 
Registered: Jan 2009
Location: Japan
Distribution: Mostly Debian and Scientific Linux
Posts: 5,526

Rep: Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217
Quote:
Originally Posted by akhund_bilal View Post
is there a way i can refresh all the conf files, just like a fresh instalation.
If you could reinstall the package, that would work, but your first post indicates that you are unable to do that. Having said that, it is probably worth trying to reinstall it directly with dpkg. Try the following:

Code:
wget http://mirrors.kernel.org/ubuntu/pool/universe/s/sox/libsox-fmt-alsa_14.3.0-1build1_i386.deb
sudo dpkg -i libsox-fmt-alsa_14.3.0-1build1_i386.deb
Evo2.
 
Old 02-10-2010, 05:30 AM   #9
akhund_bilal
LQ Newbie
 
Registered: Sep 2008
Posts: 12

Original Poster
Rep: Reputation: 0
please do not mind for my english
evo2 it did not worked

Quote:
sudo dpkg -i libsox-fmt-alsa_14.3.0-1build1_i386.deb
(Reading database ...
dpkg: warning: files list file for package `kubuntu-default-settings' missing, assuming package has no files currently installed.
(Reading database ... 5%dpkg: unrecoverable fatal error, aborting:
failed in buffer_read(fd): files list for package `libgtkhex0': Is a directory
the above error came up with a new file
 
Old 02-10-2010, 05:32 AM   #10
evo2
Guru
 
Registered: Jan 2009
Location: Japan
Distribution: Mostly Debian and Scientific Linux
Posts: 5,526

Rep: Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217
Sorry I didn't see post #6, only post #7. Looks like kubuntu-default-settings.list has been deleted. You can recreate this file in the same way that you fixed libsox_fmt_als.list. However I'm worried that many of these files are missing or corrupt.
Did something strange happen to your /var directory/partition?

One way to recover these files in bulk is to copy them from another machine that has the same packages installed.

Evo2.
 
Old 02-10-2010, 05:37 AM   #11
akhund_bilal
LQ Newbie
 
Registered: Sep 2008
Posts: 12

Original Poster
Rep: Reputation: 0
Quote:
One way to recover these files in bulk is to copy them from another machine that has the same packages installed.
you mean kubuntu default packages or including all the packages i have installed
 
Old 02-10-2010, 05:43 AM   #12
evo2
Guru
 
Registered: Jan 2009
Location: Japan
Distribution: Mostly Debian and Scientific Linux
Posts: 5,526

Rep: Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217
Quote:
Originally Posted by akhund_bilal View Post
you mean kubuntu default packages or including all the packages i have installed
All the packages that you have installed. One way to get that list is:

Code:
dpkg -l | grep ^ii | awk '{ print $2 }'
However that may fail since dpkg is having problems... If the above fails, you should be able to get a list of the packages with the following trick:

Code:
echo  /usr/share/doc/* | tr ' ' '\n' |  cut -f5 -d'/'
Evo2.
 
Old 02-10-2010, 05:51 AM   #13
akhund_bilal
LQ Newbie
 
Registered: Sep 2008
Posts: 12

Original Poster
Rep: Reputation: 0
i think i have all messed up ubuntu that will not be possible to install all the packages on the other machine

any other way to do it?

if i reinstall all karmic then can i reinstall all the software in one go which i have installed here
 
Old 02-10-2010, 06:08 AM   #14
evo2
Guru
 
Registered: Jan 2009
Location: Japan
Distribution: Mostly Debian and Scientific Linux
Posts: 5,526

Rep: Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217Reputation: 1217
[QUOTE=akhund_bilal;3858800]i think i have all messed up ubuntu that will not be possible to install all the packages on the other machine
[quote]
It should not be that hard. Just get the list of packages using one of the methods I described in in my earlier post: you can put the list directly into a file with:
Code:
dpkg -l | grep ^ii | awk '{ print $2 }' > packages.txt
Then copy that file to the freshly installed machine, and on that fresh machine do:

Code:
sudo apt-get install $(cat packages.txt)
Assuming that works, you now have to copy all the .list files back to the broken machine.

On new machine
Code:
mkdir ~/listfiles
cd /var/lib/dpkg/info/
cp $(for p in $(cat packages.txt) ; do echo $p.list ; done ) ~/listfiles/
Now you have all the file you need to copy in a directory called ~/listfiles/
Next you have to copy them to your broken machine. This could be done with a usb stick or scp depending on your situation.

Quote:
if i reinstall all karmic then can i reinstall all the software in one go which i have installed here
Reinstalling is totally up to you, but you will loose anything you customized and everything in your home directory (unless it is on separate partition). Reinstalling all the packages is easy since you already have a list of them.

Evo2

Last edited by evo2; 02-10-2010 at 06:09 AM.
 
1 members found this post helpful.
Old 02-10-2010, 06:26 AM   #15
akhund_bilal
LQ Newbie
 
Registered: Sep 2008
Posts: 12

Original Poster
Rep: Reputation: 0
thanks i am going for a fresh install both methods takes same time

thanks for your time i have learned many new things
thanks
 
  


Reply

Tags
code, error


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
Input/Output Error; dpkg sub-process /usr/bin/dpkg returned and error code (2) NosLycn Linux - Software 7 12-12-2011 03:50 AM
APT/dpkg errors! /var/lib/dpkg/status bassclarinet Debian 16 12-01-2011 10:24 AM
dpkg is dead! error in /var/lib/dpkg/available dezert_fox Debian 4 11-22-2011 11:28 AM
Ubuntu 'dpkg--configure-a' E: dpkg was interrupted error Mountain Man 77 Linux - Newbie 7 05-25-2010 11:52 AM


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

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