Re: [Hampshire] Errors when doing an aptitude safe-upgrade

Top Page

Reply to this message
Author: john lewis
Date:  
To: Hampshire LUG Discussion List
Subject: Re: [Hampshire] Errors when doing an aptitude safe-upgrade
On Sat, 29 Nov 2008 11:15:02 +0000
"Graham Bleach" <graham@???> wrote:

> 2008/11/28 john lewis <johnlewis@???>
> >
> > I had some corrupted files on my server following a power failure. I
> > have managed to clear most of the errors dpkg found when doing an
> > upgrade with the exception of the following
> >
> > Use of uninitialized value $value in substitution (s///)
> > at /usr/share/perl5/Debconf/Format/822.pm line 65, <$__ANONIO__>
> > line 3.
>
> This perl module is having some problem dealing with the data it is
> processing. So it's likely that the cause is not actually a corruption
> of /usr/share/perl5/Debconf/Format/822.pm, but of a file whose
> contents this perl modules tries to parse.
>
> Unfortunately it's not immediately obvious which file is being read in
> this case. If you pasted the full output from aptitude/apt-get we
> might see some more clues about what it is trying to do when it falls
> over.


Here it is but I don't think it will help:-

> jayell@landing:~$ sudo aptitude safe-upgrade
> Reading package lists... Done
> Building dependency tree
> Reading state information... Done
> Reading extended state information
> Initializing package states... Done
> The following packages will be upgraded:
> dpkg dpkg-dev dselect kernel-package login passwd
> 6 packages upgraded, 0 newly installed, 0 to remove and 0 not
> upgraded. Need to get 0B/6149kB of archives. After unpacking 205kB
> will be used. Do you want to continue? [Y/n/?]
> Writing extended state information... Done
> Use of uninitialized value $value in substitution (s///)
> at /usr/share/perl5/Debconf/Format/822.pm line 65, <$__ANONIO__> line
> 3. Use of uninitialized value $item in hash element
> at /usr/share/perl5/Debconf/DbDriver/File.pm line 70, <$__ANONIO__>
> chunk 3. (Reading database ... 27459 files and directories currently
> installed.) Preparing to replace dpkg 1.14.22
> (using .../archives/dpkg_1.14.23_i386.deb) ... Unpacking replacement
> dpkg ... Processing triggers for man-db ... Setting up dpkg
> (1.14.23) ... (Reading database ... 27459 files and directories
> currently installed.) Preparing to replace login 1:4.1.1-5
> (using .../login_1%3a4.1.1-6_i386.deb) ... Unpacking replacement
> login ... Processing triggers for man-db ... Setting up login
> (1:4.1.1-6) ... (Reading database ... 27497 files and directories
> currently installed.) Preparing to replace passwd 1:4.1.1-5
> (using .../passwd_1%3a4.1.1-6_i386.deb) ... Unpacking replacement
> passwd ... Processing triggers for man-db ...
> Setting up passwd (1:4.1.1-6) ...
> (Reading database ... 27497 files and directories currently
> installed.) Preparing to replace dpkg-dev 1.14.22
> (using .../dpkg-dev_1.14.23_all.deb) ... Unpacking replacement
> dpkg-dev ... Preparing to replace dselect 1.14.22
> (using .../dselect_1.14.23_i386.deb) ... Unpacking replacement
> dselect ... Preparing to replace kernel-package 11.0011
> (using .../kernel-package_11.015_all.deb) ... Unpacking replacement
> kernel-package ... Processing triggers for man-db ...
> Setting up dpkg-dev (1.14.23) ...
> Setting up dselect (1.14.23) ...
> Setting up kernel-package (11.015) ...
> Reading package lists... Done
> Building dependency tree
> Reading state information... Done
> Reading extended state information
> Initializing package states... Done
>
> Current status: 0 updates [-6].
> jayell@landing:~$                                  


that was from the upgrade I have just done (10.14 Sun morning)

> Line 65 in that module looks like like this on my etch system:
>
> ----
>                 elsif (length $key) {
>                         $value=~s/\\n/\n/g;   # line 65
>                         $ret{fields}->{$key}=$value;
>                 }
> ----

>
> Which version of Debian are you using and what do the lines
> surrounding line 65 look like?


jayell@landing:~$ cat /etc/apt/sources.list
deb http://mirror.ox.ac.uk/debian lenny main contrib non-free

> > Use of uninitialized value $item in hash element
> > at /usr/share/perl5/Debconf/DbDriver/File.pm line 70, <$__ANONIO__>
> > chunk 3.
>
> I'm pretty sure that this error is caused by the first problem it
> encountered.
>
> Unfortunately, I'm not familiar enough with the internals of debconf
> to be able to work out the likely cause, but the error is being thrown
> somewhere in the code that handles the debconf config database. You
> might want to take a peek at the files in /var/cache/debconf/ and see
> if you can see anything obviously wrong, such as zero length files. I
> am not sure that it would be safe to replace these files with copies
> from another system, though. If you have backups, comparing them with
> the last known good backups would probably be useful.


there appears to be nothing odd in /var/cache/debconf

I tried to reconfigure debconf with following result

> landing:/home/jayell# dpkg-reconfigure debconf
> Use of uninitialized value $value in substitution (s///)
> at /usr/share/perl5/Debconf/Format/822.pm line 65, <$__ANONIO__> line
> 3. Use of uninitialized value $item in hash element
> at /usr/share/perl5/Debconf/DbDriver/File.pm line 70, <$__ANONIO__>
> chunk 3. Use of uninitialized value $value in substitution (s///)
> at /usr/share/perl5/Debconf/Format/822.pm line 65, <$__ANONIO__> line
> 3. Use of uninitialized value $item in hash element
> at /usr/share/perl5/Debconf/DbDriver/File.pm line 70, <$__ANONIO__>
> chunk 3. landing:/home/jayell#


putting the error line into google reveals 8 questions on various
forums, including Ubuntu, but no answers

this is a typical query

> I am trying Xubuntu through wubi on my old Toshiba laptop; everything
> works OK, except that I have some serious trouble with the update
> manager. The dpkg-status file was showing several errors and I had to
> make a new one with the script provided here:
> http://ubuntuforums.org/showpost.php?p=4093836&postcount=4
>
> However, after again updating, I ran into trouble and had to do dpkg
> --configure -a to clean up the mess. Subsequently, I got the
> following error:
>
> Use of uninitialized value in substitution (s///) at
> /usr/share/perl5/Debconf/Format/822.pm line 65, <$__ANONIO__> line 1.
> Use of uninitialized value in substitution (s///) at
> /usr/share/perl5/Debconf/Format/822.pm line 65, <$__ANONIO__> line 2.
> Use of uninitialized value in substitution (s///) at
> /usr/share/perl5/Debconf/Format/822.pm line 65, <$__ANONIO__> line 3.
> Use of uninitialized value in hash element at
> /usr/share/perl5/Debconf/DbDriver/File.pm line 70, <$__ANONIO__>
> chunk 3.
>
> This problem has also been reported under bug nr. 13130 in Launchpad,
> but they did not provide a workaround.
> Some websites advice that I should just reinstall xubuntu, but I
> wouldn't like to go through the installation again.
>
> Any ideas how to solve this problem without reinstallation?


so it look like I am not alone

--
John Lewis
using Debian Sid with windowmaker for a nicer desktop