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

Re: Disk quota not working with 64bit kernel, 32 bit userland.

Frederik Schueler <fs@lowpingbastards.de> writes:
> On Fri, May 21, 2004 at 12:33:36PM +0200, Lars Wessels wrote:
>> Are any patches for 
>> the quota source itself required? I think I tried all possible
>> kernel config switches so far but still no luck. :-/
> Try with a static 64bit version, this should work.

Okay.  This indeed seems to work.  Here are some of the details of
what I did:

Booted a stock Linux 2.6.6 built in the biarch chroot for x86_64 and
with x86 32bit support.

Built quota in the biarch chroot doing the following (some of it from

chroot /mnt/chroot/biarch
apt-get build-dep quota
apt-get source quota
cd quota-3.04
./debian/rules          # does the ./configure step
(edit Makefile add the lines:
LDFLAGS       = -static
CFLAGS       += "-I/usr/src/linux/include -m64"
./debian/rules binary
(exit chroot, back to i386 dist)
cd /mnt/chroot/biarch/<path-to>/quota-3.04
cp quota /usr/bin
cp edquota repquota warnquota quotastats setquota quot xqmstats rpc.rquotad /usr/sbin
cp quotacheck quotaon convertquota /sbin 

I had to add in the path to 2.6.6 kernel includes to get at FIOQSIZE
macro that was undefined in the biarch /usr/include version of the
kernel headers.  

The resulting package is obviously not installable on i386 Debian but
the these binaries run (under the biarch kernel) and seem to do what
they should.  But there were a few link warnings like this one:

  : warning: Using 'setpwent' in statically linked applications
  requires at runtime the shared libraries from the glibc version used
  for linking

For the record my two libcs are:

  biarch: 2.3.2-7.biarch
  i386:   2.3.2.ds1-11

As I've shown (and with grave apologies to the decade of work that has
gone into the Debian package system) I've just cp'ed the binaries over
the 32bit ones from the installed quota package.  If 2.6.7 solves this
issues an "apt-get install --reinstall quota" should put this


Reply to: