-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
Control: tags -1 patch
Hi!
On 09/11/2015 12:08 PM, Cyril Brulebois wrote:
> That doesn't seem unreasonable; helping the new maintainer with a
> few patches would probably be appreciated as well, especially if
> you're a regular user for your local mirror.
I have patched my local installation of debmirror now to always try to
download xz files instead of bz2 files. This is basically a lazy fix
which solves the issue I currently had with debmirror but introduces
a new regression by not being able to download the Translation files
anymore which, to my big surprise, are still bz2-compressed [1].
Since I don't really care about the translations, I just disabled
those in /etc/apt/apt.conf on the clients and I can now continue
to use debmirror normally. For anyone who doesn't know, adding
Acquire::Languages "none"; to the apt configuration is enough.
Feel free to merge my patch, but be aware that it removes bz2 support
from debmirror completely. However, I expect that the translation
files will move away from bz2 to xz in the future as well, so
this might solve itself then.
Cheers,
Adrian
> [1] ftp://ftp.debian.org/debian/dists/sid/main/i18n/
- --
.''`. John Paul Adrian Glaubitz
: :' : Debian Developer - [email protected]
`. `' Freie Universitaet Berlin - [email protected]
`- GPG: 62FF 8A75 84E0 2956 9546 0006 7426 3B37 F5B5 F913
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iQIcBAEBCAAGBQJV9AgfAAoJEHQmOzf1tfkTm4YP/jIg686bDmDpkcPEA5p/UcR2
EDAoeqRBMIF3OjPMyDkcOHAr/HsA7xehSLIBtro65kP458BwLWOYisPDhT79N0UE
BfZnHXEcDSZtVz8J9wQFrBB0N9cvLiKd7CDYbbmfiSQJANST7wovu9bkyUs1A8CU
qQgK1BGPGfTxpjcLSNaFCNVMpnEKKqm3LM7NTzYwpOkHTu9vuATW3FM+aklDVvI0
49aIPY1yT+vlgoRRfrAwEDHtvAw2dWFDf3XCqpU4gfyebVe84E4noEn4ztCigJ6W
VtrFYz5J5nXzof8Od25uc0q2whigUf8Tx1/RiGGkGR4uoGRZMJY+erqhzEgRNuby
G1Ct1qSK04IO7evTo9rywYy1n/FjsIXXt4aeEAWW+ncb14il10HyCxHT0qnXcfo3
pYWBNdcBYVaYS/m4gUkro7Ps0Irac0VqV3xkU3XoPpzVRyU9PBQpNpOi+vuNU4Mf
X1IP4fNf+VG2NsA7Nb4Ydv6n63PzEZWDo6zeDJPPgknOutLUZ+GQeEyGLRTu1epG
Vo+2+ekL80NyI4RbyV8xOe3I3k5ccpzmFh5WANjaEea2zTbX0ES6gtyj3BmB2sMn
seJsJO4LyzF49Z3ucBY8Zd6YPGLcRY72PcMfmNrqV6sMpVXkpzmXxc3gXOALyW8H
SvtIwWav/Cj5D6i+K+6l
=LRQZ
-----END PGP SIGNATURE-----
--- /usr/bin/debmirror~ 2013-06-23 18:34:26.000000000 +0200
+++ /usr/bin/debmirror 2015-09-11 12:22:44.329419806 +0200
@@ -1029,7 +1029,7 @@
foreach my $arch (@arches) {
add_bytes("dists/$dist/$section/binary-$arch/Packages");
add_bytes("dists/$dist/$section/binary-$arch/Packages.gz");
- add_bytes("dists/$dist/$section/binary-$arch/Packages.bz2");
+ add_bytes("dists/$dist/$section/binary-$arch/Packages.xz");
add_bytes("dists/$dist/$section/binary-$arch/Release");
add_bytes("dists/$dist/$section/binary-$arch/Packages.diff/Index") unless ($diff_mode eq "none");
}
@@ -1037,7 +1037,7 @@
if ($do_source && $section !~ /debian-installer/) {
add_bytes("dists/$dist/$section/source/Sources");
add_bytes("dists/$dist/$section/source/Sources.gz");
- add_bytes("dists/$dist/$section/source/Sources.bz2");
+ add_bytes("dists/$dist/$section/source/Sources.xz");
add_bytes("dists/$dist/$section/source/Release");
add_bytes("dists/$dist/$section/source/Sources.diff/Index") unless ($diff_mode eq "none");
}
@@ -2180,7 +2180,7 @@
if (check_lists("$tempdir/$subdir/$file")) {
if (! $slow_cpu) {
system_redirect_io("gzip $gzip_options", "$tempdir/$subdir/$file", "$tempdir/$subdir/$file.gz");
- system_redirect_io("bzip2", "$tempdir/$subdir/$file", "$tempdir/$subdir/$file.bz2");
+ system_redirect_io("xz", "$tempdir/$subdir/$file", "$tempdir/$subdir/$file.xz");
}
}
}
@@ -2190,7 +2190,7 @@
if (check_lists("$tempdir/$subdir/$file")) {
if (! $slow_cpu) {
system_redirect_io("gzip $gzip_options", "$tempdir/$subdir/$file", "$tempdir/$subdir/$file.gz");
- system_redirect_io("bzip2", "$tempdir/$subdir/$file", "$tempdir/$subdir/$file.bz2");
+ system_redirect_io("xz", "$tempdir/$subdir/$file", "$tempdir/$subdir/$file.xz");
}
}
}
@@ -2203,7 +2203,7 @@
if (remote_get("$subdir/$file.gz")) {
system_redirect_io("gzip -d", "$tempdir/$subdir/$file.gz", "$tempdir/$subdir/$file");
if (! $slow_cpu) {
- system_redirect_io("bzip2", "$tempdir/$subdir/$file", "$tempdir/$subdir/$file.bz2");
+ system_redirect_io("xz", "$tempdir/$subdir/$file", "$tempdir/$subdir/$file.xz");
}
} else {
push (@errlog,"$subdir/$file.gz failed checksum verification\n");
@@ -2230,7 +2230,7 @@
if (!check_lists("$tempdir/$subdir/$file")) {
if (remote_get("$subdir/$file")) {
if (! $slow_cpu) {
- system_redirect_io("bzip2", "$tempdir/$subdir/$file", "$tempdir/$subdir/$file.bz2");
+ system_redirect_io("xz", "$tempdir/$subdir/$file", "$tempdir/$subdir/$file.xz");
}
} else {
push (@errlog,"$subdir/$file failed checksum verification\n");
@@ -2240,13 +2240,13 @@
$bytes_gotten += $file_lists{"$tempdir/$subdir/$file"}{size};
}
}
- if (exists $file_lists{"$tempdir/$subdir/$file.bz2"}) {
- if (!check_lists("$tempdir/$subdir/$file.bz2")) {
- if (!remote_get("$subdir/$file.bz2")) {
- push (@errlog,"$subdir/$file.bz2 failed checksum verification, removing\n");
+ if (exists $file_lists{"$tempdir/$subdir/$file.xz"}) {
+ if (!check_lists("$tempdir/$subdir/$file.xz")) {
+ if (!remote_get("$subdir/$file.xz")) {
+ push (@errlog,"$subdir/$file.xz failed checksum verification, removing\n");
}
} else {
- $bytes_gotten += $file_lists{"$tempdir/$subdir/$file.bz2"}{size};
+ $bytes_gotten += $file_lists{"$tempdir/$subdir/$file.xz"}{size};
}
}
if (exists $file_lists{"$tempdir/$subdir/Release"}) {
@@ -2266,12 +2266,12 @@
die "get_index called with unknown type $file\n";
}
$files{"$subdir/$file.gz"}=1;
- $files{"$subdir/$file.bz2"}=1;
+ $files{"$subdir/$file.xz"}=1;
# Uncompressed files are no longer kept on the mirrors
$files{"$subdir/$file"}=1 unless exists $file_lists{"$tempdir/$subdir/$file.gz"};
$files{"$subdir/Release"}=1;
$files{"$tempdir/$subdir/$file.gz"}=1;
- $files{"$tempdir/$subdir/$file.bz2"}=1;
+ $files{"$tempdir/$subdir/$file.xz"}=1;
$files{"$tempdir/$subdir/$file"}=1;
$files{"$tempdir/$subdir/Release"}=1;
}
@@ -2370,10 +2370,10 @@
link("$tempdir/dists/$dist/$section/$archdir/$file.gz",
"$mirrordir/dists/$dist/$next/$section/$archdir/$file.gz")
or die "Error while linking $tempdir/dists/$dist/$section/$archdir/$file.gz: $!\n";
- unlink("$mirrordir/dists/$dist/$next/$section/$archdir/$file.bz2");
- link("$tempdir/dists/$dist/$section/$archdir/$file.bz2",
- "$mirrordir/dists/$dist/$next/$section/$archdir/$file.bz2")
- or die "Error while linking $tempdir/dists/$dist/$section/$archdir/$file.bz2: $!\n";
+ unlink("$mirrordir/dists/$dist/$next/$section/$archdir/$file.xz");
+ link("$tempdir/dists/$dist/$section/$archdir/$file.xz",
+ "$mirrordir/dists/$dist/$next/$section/$archdir/$file.xz")
+ or die "Error while linking $tempdir/dists/$dist/$section/$archdir/$file.xz: $!\n";
}
sub i18n_from_release {
@@ -2394,7 +2394,7 @@
next if substr($path, 0, length($compdir)) ne $compdir;
my $filename = substr($path, length($compdir)+1, length($path)-length($compdir)-1);
- next if $filename !~ /bz2$/;
+ next if $filename !~ /xz$/;
my ($sha1, $size) = ($file_lists{$path}{SHA1}, $file_lists{$path}{size});
if(!(defined($include) && ($subdir."/".$filename)=~/$include/o)) {