--- Begin Message ---
- To: Debian Bug Tracking System <submit@bugs.debian.org>
- Subject: linux-image-2.6.18-2-486: ..fancy new post-rm script oughtta mention grub or "exit 0" instead of bombing out a lilo style 128 error.
- From: Arnt Karlsen <arnt@c2i.net>
- Date: Sun, 12 Nov 2006 00:13:35 +0100
- Message-id: <20061111231335.8335.58328.reportbug@a45.fmb.no>
Package: linux-image-2.6.18-2-486
Version: 2.6.18-5
Severity: important
...as all my 2.6.18-1-X86 worked nicely and not linux-image-2.6.18-2-X86, I diffed:
arnt@a45:/var/www/mmc/BT/2006.0625 $ diff -uN0 /var/lib/dpkg/info/linux-image-2.6.18-*-486.preinst >/tmp/linux-image-2.6.18-X-486.preinst
arnt@a45:/var/www/mmc/BT/2006.0625 $ diff -uN0 /var/lib/dpkg/info/linux-image-2.6.18-*-486.postinst >/tmp/linux-image-2.6.18-X-486.postinst
arnt@a45:/var/www/mmc/BT/2006.0625 $ diff -uN0 /var/lib/dpkg/info/linux-image-2.6.18-*-486.prerm >/tmp/linux-image-2.6.18-X-486.prerm
arnt@a45:/var/www/mmc/BT/2006.0625 $ diff -uN0 /var/lib/dpkg/info/linux-image-2.6.18-*-486.postrm >/tmp/linux-image-2.6.18-X-486.postrm
arnt@a45:/var/www/mmc/BT/2006.0625 $ ll /tmp/linux-image-2.6.18-X-486.p*
-rw-r--r-- 1 arnt arnt 7894 2006-11-11 23:48 /tmp/linux-image-2.6.18-X-486.postinst
-rw-r--r-- 1 arnt arnt 413 2006-11-11 23:49 /tmp/linux-image-2.6.18-X-486.postrm
-rw-r--r-- 1 arnt arnt 276 2006-11-11 23:47 /tmp/linux-image-2.6.18-X-486.preinst
-rw-r--r-- 1 arnt arnt 272 2006-11-11 23:49 /tmp/linux-image-2.6.18-X-486.prerm
arnt@a45:/var/www/mmc/BT/2006.0625 $ cat /tmp/linux-image-2.6.18-X-486.prerm
--- /var/lib/dpkg/info/linux-image-2.6.18-1-486.prerm 2006-10-22 01:44:18.000000000 +0200
+++ /var/lib/dpkg/info/linux-image-2.6.18-2-486.prerm 2006-11-09 02:59:32.000000000 +0100
@@ -26 +26 @@
-my $version = "2.6.18-1-486";
+my $version = "2.6.18-2-486";
arnt@a45:/var/www/mmc/BT/2006.0625 $ cat /tmp/linux-image-2.6.18-X-486.preinst
--- /var/lib/dpkg/info/linux-image-2.6.18-1-486.preinst 2006-10-22 01:44:18.000000000 +0200
+++ /var/lib/dpkg/info/linux-image-2.6.18-2-486.preinst 2006-11-09 02:59:32.000000000 +0100
@@ -27 +27 @@
-my $version = "2.6.18-1-486";
+my $version = "2.6.18-2-486";
arnt@a45:/var/www/mmc/BT/2006.0625 $ cat /tmp/linux-image-2.6.18-X-486.postrm
--- /var/lib/dpkg/info/linux-image-2.6.18-1-486.postrm 2006-10-22 01:44:17.000000000 +0200
+++ /var/lib/dpkg/info/linux-image-2.6.18-2-486.postrm 2006-11-09 02:59:32.000000000 +0100
@@ -38 +38 @@
-my $version = "2.6.18-1-486";
+my $version = "2.6.18-2-486";
@@ -354,0 +355,3 @@
+ if (-f $realimageloc . "initrd.img-$version.bak") {
+ unlink $realimageloc . "initrd.img-$version.bak";
+ }
arnt@a45:/var/www/mmc/BT/2006.0625 $
arnt@a45:/var/www/mmc/BT/2006.0625 $ cat /tmp/linux-image-2.6.18-X-486.postinst
--- /var/lib/dpkg/info/linux-image-2.6.18-1-486.postinst 2006-10-22 01:44:17.000000000 +0200
+++ /var/lib/dpkg/info/linux-image-2.6.18-2-486.postinst 2006-11-09 02:59:32.000000000 +0100
@@ -28 +28 @@
-my $version = "2.6.18-1-486";
+my $version = "2.6.18-2-486";
@@ -353,31 +353,31 @@
-sub CanonicalizePath {
- my $path = join '/', @_;
- my @work = split '/', $path;
- my @out;
- my $is_absolute;
-
- if (@work && $work[0] eq "") {
- $is_absolute = 1; shift @work;
- }
-
- while (@work) {
- my $seg = shift @work;
- if ($seg eq "." || $seg eq "") {
- }
- elsif ($seg eq "..") {
- if (@out && $out[-1] ne "..") {
- pop @out;
- }
- else {
- # Leading "..", or "../..", etc.
- push @out, $seg;
- }
- }
- else {
- push @out, $seg;
- }
- }
-
- unshift @out, "" if $is_absolute;
- return join('/', @out);
-}
+# sub CanonicalizePath {
+# my $path = join '/', @_;
+# my @work = split '/', $path;
+# my @out;
+# my $is_absolute;
+
+# if (@work && $work[0] eq "") {
+# $is_absolute = 1; shift @work;
+# }
+
+# while (@work) {
+# my $seg = shift @work;
+# if ($seg eq "." || $seg eq "") {
+# }
+# elsif ($seg eq "..") {
+# if (@out && $out[-1] ne "..") {
+# pop @out;
+# }
+# else {
+# # Leading "..", or "../..", etc.
+# push @out, $seg;
+# }
+# }
+# else {
+# push @out, $seg;
+# }
+# }
+
+# unshift @out, "" if $is_absolute;
+# return join('/', @out);
+# }
@@ -396,2 +396,2 @@
- my @olddir = split '/', CanonicalizePath $params{'Old'};
- my @newdir = split '/', CanonicalizePath $params{'New'};
+ my @olddir = split '/', `readlink -q -m $params{'Old'}`;
+ my @newdir = split '/', `readlink -q -m $params{'New'}`;
@@ -471,3 +470,0 @@
-
- } elsif ($relative_links) {
- $Old = spath('Old' => "$Old", 'New' => "$src_dir" );
@@ -521 +518 @@
- my $target = CanonicalizePath("$realimageloc" . "$kimage-$version");
+ my $target = `readlink -q -m "${realimageloc}${kimage-$version}"`;
@@ -541 +538 @@
- $vmlinuz_target = CanonicalizePath($vmlinuz_target);
+ $vmlinuz_target = `readlink -q -m $vmlinuz_target`;
@@ -558 +555 @@
- $old_target = CanonicalizePath($old_target);
+ $old_target = `readlink -q -m $old_target`;
@@ -618,3 +614,0 @@
- elsif ($relative_links) {
- $Old = spath('Old' => "$Old", 'New' => $cwd);
- }
@@ -626,2 +620,2 @@
- warn "ln " . $Old . "$image_name " . "$kimage" if $DEBUG;
- if (! link($Old . "$image_name", "$kimage")) {
+ warn "ln ${Old}${image_name} $kimage" if $DEBUG;
+ if (! link("${Old}${image_name}", "$kimage")) {
@@ -629,2 +623,2 @@
- die("Failed to link " . $realimageloc .
- "$image_name to " . $image_dest . "$kimage .\n");
+ die("Failed to link ${Old}${image_name} to " .
+ "${image_dest}${kimage}.\n");
@@ -634,2 +628,2 @@
- warn "ln -s " . $Old . "$image_name " . "$kimage" if $DEBUG;
- if (! symlink($Old . "$image_name", "$kimage")) {
+ warn "ln -s ${Old}${image_name} $kimage" if $DEBUG;
+ if (! symlink("${Old}${image_name}", "$kimage")) {
@@ -637,2 +631,2 @@
- die("Failed to symbolic-link " . $realimageloc .
- "$image_name to " . $image_dest . "$kimage .\n");
+ die("Failed to symbolic-link ${Old}${image_name} to " .
+ "${image_dest}${kimage}.\n");
@@ -716,0 +711,5 @@
+ my $Old = $realimageloc;
+ my $New = $image_dest;
+ my $Name = "$image_name";
+ my $Link_Dest = "$kimage";
+
@@ -718,34 +717,9 @@
- my $Old = $image_dest;
- if (test_relative ('Old Dir' => $Old,
- 'New Dir' => $realimageloc,
- 'Test File' => "$kimage")) {
- $Old =~ s|^/*||o;
- } elsif ($relative_links) {
- $Old = spath('Old' => "$Old", 'New' => $realimageloc);
- }
- # Special case is they are in the same dir
- my $rel_path = spath('Old' => "$Old", 'New' => "$realimageloc" );
- $Old ="" if $rel_path =~ m/^\s*$/o;
-
- symlink($Old . "$kimage", $realimageloc . "$image_name")
- || die("Failed to symbolic-link " . $realimageloc
- . "$image_name to " . $image_dest . "$kimage .\n");
- warn "ln -s " . $Old . "$kimage " . $realimageloc . "$image_name" if $DEBUG;
- }
- else {
- my $Old = $realimageloc;
- if (test_relative ('Old Dir' => $Old,
- 'New Dir' => $image_dest,
- 'Test File' => "$image_name")) {
- $Old =~ s|^/*||o;
- } elsif ($relative_links) {
- $Old = spath('Old' => "$Old", 'New' => $image_dest);
- }
- # Special case is they are in the same dir
- my $rel_path = spath('Old' => "$Old", 'New' => "$image_dest" );
- $Old ="" if $rel_path =~ m/^\s*$/o;
-
- symlink($Old . "$image_name", "$kimage") ||
- die("Failed to symbolic-link " . $realimageloc
- . "$image_name to " . $image_dest . "$kimage .\n");
- warn "ln -s " . $Old . "$image_name " . "$kimage" if $DEBUG;
+ $Old = $image_dest;
+ $New = $realimageloc;
+ $Name = "$kimage";
+ $Link_Dest = $realimageloc . "$image_name";
+ }
+ if (test_relative ('Old Dir' => $Old,
+ 'New Dir' => $New,
+ 'Test File' => $Name)) {
+ $Old =~ s|^/*||o;
@@ -752,0 +727,8 @@
+ # Special case is they are in the same dir
+ my $rel_path = spath('Old' => "$Old", 'New' => "$New" );
+ $Old ="" if $rel_path =~ m/^\s*$/o;
+
+ symlink($Old . "$Name", "$Link_Dest") ||
+ die("Failed to symbolic-link ${Old}$Name to $Link_Dest.\n");
+ warn "ln -s ${Old}$Name $Link_Dest" if $DEBUG;
+
@@ -807,2 +788,0 @@
- } elsif ($relative_links) {
- $Old = spath('Old' => "$Old", 'New' => $realimageloc);
@@ -841,2 +820,0 @@
- } elsif ($relative_links) {
- $Old = spath('Old' => "$Old", 'New' => $cwd);
@@ -1174,25 +1151,0 @@
-LOADER: {
- last unless $do_boot_enable; # Exit if explicitly asked to
-
- last if $loader =~ /silo/i; # SILO does not have to be executed.
- last if $loader =~ /yaboot/i; # yaboot does not have to be executed.
- last if $loader =~ /milo/i; # MILO does not have to be executed.
- last if $loader =~ /nettrom/i; # NETTROM does not have to be executed.
- last if $loader =~ /arcboot/i; # ARCBOOT does not have to be executed.
- last if $loader =~ /delo/i; # DELO does not have to be executed.
- if ($official_image =~ /^\s*YES\s*$/o) {
- last if $loader =~ /quik/i; # maintainer asked quik invocation to be ignored
- }
-
- last unless $loaderloc;
- last unless -x $loaderloc;
- last unless $do_bootloader;
-
- if (-T "/etc/$loader.conf") {
- # Trust and use the existing lilo.conf.
- print STDERR "You already have a $Loader configuration in /etc/$loader.conf\n";
- my $ret = &run_lilo();
- exit $ret if $ret;
- }
-}
-
@@ -1267,0 +1221,25 @@
+LOADER: {
+ last unless $do_boot_enable; # Exit if explicitly asked to
+
+ last if $loader =~ /silo/i; # SILO does not have to be executed.
+ last if $loader =~ /yaboot/i; # yaboot does not have to be executed.
+ last if $loader =~ /milo/i; # MILO does not have to be executed.
+ last if $loader =~ /nettrom/i; # NETTROM does not have to be executed.
+ last if $loader =~ /arcboot/i; # ARCBOOT does not have to be executed.
+ last if $loader =~ /delo/i; # DELO does not have to be executed.
+ if ($official_image =~ /^\s*YES\s*$/o) {
+ last if $loader =~ /quik/i; # maintainer asked quik invocation to be ignored
+ }
+
+ last unless $loaderloc;
+ last unless -x $loaderloc;
+ last unless $do_bootloader;
+
+ if (-T "/etc/$loader.conf") {
+ # Trust and use the existing lilo.conf.
+ print STDERR "You already have a $Loader configuration in /etc/$loader.conf\n";
+ my $ret = &run_lilo();
+ exit $ret if $ret;
+ }
+}
+
arnt@a45:/var/www/mmc/BT/2006.0625 $
...possible workaround might be offer both -1- and -2- style scripts until
the -2- style works.
...also, make those new /boot/*.bak, /boot/*.new etc optional, some of us use
separate /boot's and leave less than 50% space vacant.
-- System Information:
Debian Release: 4.0
APT prefers unstable
APT policy: (500, 'unstable')
Architecture: i386 (i586)
Shell: /bin/sh linked to /bin/bash
Kernel: Linux 2.6.18-1-486
Locale: LANG=nb_NO.UTF-8, LC_CTYPE=nb_NO.UTF-8 (charmap=UTF-8)
Versions of packages linux-image-2.6.18-2-486 depends on:
ii initramfs-tools [linux-initra 0.85a tools for generating an initramfs
ii module-init-tools 3.2.2-3 tools for managing Linux kernel mo
ii yaird [linux-initramfs-tool] 0.0.12-18 Yet Another mkInitRD
linux-image-2.6.18-2-486 recommends no packages.
--- End Message ---