[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#221666: refuses to download if /var/cache/apt/archives is on ram disk



Package: apt
Version: 0.5.14
Severity: minor

Hi,

when the directory /var/cache/apt/archives is mounted to a ram disk
(ramfs), apt-get refuses to download packages:

tammuz:~# apt-get upgrade
Reading Package Lists... Done
Building Dependency Tree... Done
The following packages will be upgraded
bsdmainutils console-common console-data dnsutils gpdf
libdbix-searchbuilder-perl libdns11
libisc7 liblwres1 libpango1.0-0 libpango1.0-common libtool man-db
python python2.2 python2.3
zlib1g zlib1g-dev
18 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 9715kB of archives.
After unpacking 1148kB of additional disk space will be used.
E: You don't have enough free space in /var/cache/apt/archives/.
tammuz:~# cat /proc/mounts
rootfs / rootfs rw 0 0
/dev/root / ext3 rw 0 0
proc /proc proc rw 0 0
devpts /dev/pts devpts rw 0 0
/dev/hda1 /boot ext3 rw 0 0
/dev/hda5 /var ext3 rw 0 0
/dev/hda6 /home ext3 rw 0 0
/dev/loop0 /mnt/efs ext2 rw,nosuid,nodev,noexec 0 0
none /mnt/rd ramfs rw 0 0
none /var/cache/apt/archives ramfs rw 0 0
tammuz:~# df /mnt/rd/
Filesystem           1K-blocks      Used Available Use% Mounted on
none                         0         0         0   -  /mnt/rd
tammuz:~#
      

Okay, the reason is that there seems to be no space on that partition,
but it grows dynamically. So there /is/ enough space.

A proper solution is probably to check if it is a ramfs partition, in
that case assume there is enough space available, or better as much
as there is free memory.

The easy solution would be to have a command line option to override
that check.

See also #214119, a solution for that bug may be combined with a
solution to this one.


Sidenote: the reason I want to use a ram disk is that I want to use apt
on an embedded system with a compact flash as root file system. That
space is limited, and also there should not be too many rewrites on a
CF. Another advantage is that /var/cache/apt/archives is automatically
freed on reboot.

Greetings,
Oliver

-- Package-specific info:

-- apt-config dump --

APT "";
APT::Architecture "i386";
APT::Build-Essential "";
APT::Build-Essential:: "build-essential";
Dir "/";
Dir::State "var/lib/apt/";
Dir::State::lists "lists/";
Dir::State::cdroms "cdroms.list";
Dir::State::userstatus "status.user";
Dir::State::status "/var/lib/dpkg/status";
Dir::Cache "var/cache/apt/";
Dir::Cache::archives "archives/";
Dir::Cache::srcpkgcache "srcpkgcache.bin";
Dir::Cache::pkgcache "pkgcache.bin";
Dir::Etc "etc/apt/";
Dir::Etc::sourcelist "sources.list";
Dir::Etc::vendorlist "vendors.list";
Dir::Etc::vendorparts "vendors.list.d";
Dir::Etc::main "apt.conf";
Dir::Etc::parts "apt.conf.d";
Dir::Etc::preferences "preferences";
Dir::Bin "";
Dir::Bin::methods "/usr/lib/apt/methods";
Dir::Bin::dpkg "/usr/bin/dpkg";
DPkg "";
DPkg::Pre-Install-Pkgs "";
DPkg::Pre-Install-Pkgs:: "/usr/sbin/dpkg-preconfigure --apt || true";

-- (no /etc/apt/preferences present) --


-- (/etc/apt/sources.list present, but not submitted) --


-- System Information:
Debian Release: testing/unstable
Architecture: i386
Kernel: Linux tammuz 2.4.21 #4 Wed Oct 22 10:37:55 CEST 2003 i686
Locale: LANG=C, LC_CTYPE=C

Versions of packages apt depends on:
ii  libc6                       2.3.2.ds1-10 GNU C Library: Shared libraries an
ii  libgcc1                     1:3.3.2-4    GCC support library
ii  libstdc++5                  1:3.3.2-4    The GNU Standard C++ Library v3

-- no debconf information




Reply to: