Bug#970323: dpkg-deb fails to create package > 2 GB

2020-09-15 Thread Francois Gouget
On Tue, 15 Sep 2020, Guillem Jover wrote:
[...]
> From the error message printed, it looks like your temporary directory
> is not big enough. If you set TMPDIR to something else it should work
> I guess?

Argh! That's it. Sorry for missing it.
The bug can be closed then.

-- 
Francois Gouget 



Bug#970323: dpkg-deb fails to create package > 2 GB

2020-09-14 Thread Guillem Jover
Hi!

On Mon, 2020-09-14 at 18:52:57 +0200, Francois Gouget wrote:
> Package: dpkg
> Version: 1.19.7
> Severity: normal

> dpkg-deb fails to create a package with a size greater than 2 GB.
> To reproduce this issue use the attached file to create a 2.4 GB
> package, this despite being on a 64-bit system:
> 
> $ tar xfz testpkg.tar.gz
> $ cd testpkg
> $ fakeroot ./build
> [...]
> + dh_builddeb --destdir=.
> dpkg-deb: building package 'testpkg' in './testpkg_1.0-1_all.deb'.
> dpkg-deb (subprocess): compressing tar member: lzma write error: No space 
> left on device
> dpkg-deb: error:  from tar -cf subprocess returned error exit 
> status 2
> dh_builddeb: dpkg-deb --build debian/testpkg . returned exit code 2
> dh_builddeb: Aborting due to earlier error
> 
> Note that neither tar nor ar have any trouble dealing with archives with
> a size greater than 2 GB.
> Also this is not specific to the lzma compressor: using gzip instead
> produces the same error.

From the error message printed, it looks like your temporary directory
is not big enough. If you set TMPDIR to something else it should work
I guess?

Thanks for the test case, although this is already part of the
external dpkg functional test suite:

  

Perhaps the temporary filename should be printed to give a better
hint, even though that file gets unlinked so it would not be present
in the filesystem and so it might be even more confusing. Ideally
though no temporary file would be used, and these would be streamed
directly into the generated .deb archive (which AFAIR is on the TODO
list :).

Thanks,
Guillem



Bug#970323: dpkg-deb fails to create package > 2 GB

2020-09-14 Thread Francois Gouget
Package: dpkg
Version: 1.19.7
Severity: normal

Dear Maintainer,

dpkg-deb fails to create a package with a size greater than 2 GB.
To reproduce this issue use the attached file to create a 2.4 GB
package, this despite being on a 64-bit system:

$ tar xfz testpkg.tar.gz
$ cd testpkg
$ fakeroot ./build
[...]
+ dh_builddeb --destdir=.
dpkg-deb: building package 'testpkg' in './testpkg_1.0-1_all.deb'.
dpkg-deb (subprocess): compressing tar member: lzma write error: No space left 
on device
dpkg-deb: error:  from tar -cf subprocess returned error exit status 2
dh_builddeb: dpkg-deb --build debian/testpkg . returned exit code 2
dh_builddeb: Aborting due to earlier error

Note that neither tar nor ar have any trouble dealing with archives with
a size greater than 2 GB.
Also this is not specific to the lzma compressor: using gzip instead
produces the same error.


-- Package-specific info:

-- System Information:
Debian Release: 10.5
  APT prefers stable
  APT policy: (500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.19.0-10-amd64 (SMP w/8 CPU cores)
Kernel taint flags: TAINT_WARN, TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8), 
LANGUAGE=fr:en_US (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages dpkg depends on:
ii  libbz2-1.0   1.0.6-9.2~deb10u1
ii  libc62.28-10
ii  liblzma5 5.2.4-1
ii  libselinux1  2.8-1+b1
ii  tar  1.30+dfsg-6
ii  zlib1g   1:1.2.11.dfsg-1

dpkg recommends no packages.

Versions of packages dpkg suggests:
ii  apt1.8.2.1
pn  debsig-verify  

-- no debconf information


testpkg.tar.gz
Description: application/gzip