This should patch it:
--- /usr/bin/debmirror 2017-07-22 01:09:37.000000000 +0000
+++ ./debmirror 2020-05-19 07:49:07.409643328 +0000
@@ -2679,7 +2679,7 @@
if ($use_cache) {
say(": using cache.");
foreach my $file (sort keys %files) {
- next if (@di_dists && $file =~ m:installer-\w(-|\w)*/current/images/:);
+ next if (@di_dists && $file =~
m:installer-\w(-|\w)*/current/[a-z-]*images/:);
if ($files{$file} == 2 && -f $file) {
say("deleting $file") if ($verbose);
if (! $do_dry_run) {
@@ -2696,7 +2696,7 @@
foreach my $file (`find . -type f 2>/dev/null`) {
chomp $file;
$file=~s:^\./::;
- next if (@di_dists && $file =~ m:installer-\w(-|\w)*/current/images/:);
+ next if (@di_dists && $file =~
m:installer-\w(-|\w)*/current/[a-z-]*images/:);
unless ((exists $files{$file} &&
$files{$file} != -1 && $files{$file} != 2) or
(defined($ignore) && $file=~/$ignore/o)) {
@@ -2764,9 +2764,18 @@
my $image_dir = "dists/$dist/main/installer-$arch/current/images";
make_dir ("$tdir/$image_dir");
+ my @old_errlog = @errlog;
+ my $old_num_errors = $num_errors;
if (!remote_get("$image_dir/MD5SUMS", $tdir)) {
- say("Failed to download $image_dir/MD5SUMS; skipping.");
- return;
+ say("Failed to download $image_dir/MD5SUMS; trying legacy-images.");
+ $image_dir = "dists/$dist/main/installer-$arch/current/legacy-images";
+ make_dir ("$tdir/$image_dir");
+ if (!remote_get("$image_dir/MD5SUMS", $tdir)) {
+ say("Failed to download $image_dir/MD5SUMS; skipping.");
+ return;
+ }
+ @errlog = @old_errlog;
+ $num_errors = $old_num_errors;
}
if (-f "$tdir/$image_dir/MD5SUMS") {
$bytes_to_get += -s _; # As we did not have the size earlier
@@ -2841,7 +2850,7 @@
sub di_cleanup {
# Clean up obsolete files
foreach my $image_dir (`find dists/ -type d -name images 2>/dev/null`) {
- next unless $image_dir =~ m:/installer-\w(-|\w)*/current/images$:;
+ next unless $image_dir =~ m:/installer-\w(-|\w)*/current/[a-z-]*images$:;
chomp $image_dir;
chdir("$image_dir") or die "unable to chdir($image_dir): $!\n";
foreach my $file (`find . -type f 2>/dev/null`) {
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1879348
Title:
debmirror fails on focal because of legacy-images
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/debmirror/+bug/1879348/+subscriptions
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs