[ale] lastlog

James P. Kinney III jkinney at localnetsolutions.com
Tue Dec 20 10:25:12 EST 2005


On Mon, 2005-12-19 at 23:20 -0500, Chris Ricker wrote:
> On Mon, 19 Dec 2005, James P. Kinney III wrote:
> 
> > My /var/log/lastlog shows a file size of 1.2T.
> > 
> > It would be kind of cool if that were possible. But I don't _have_ even
> > 1T of drive space on the machine. 
> > 
> > So a digging around of man pages shows lastlog as _always_ having a
> > bogus large file size. ls -s shows it as 60(B) while ls -h shows 1.2T
> > 
> > Does ext(3) have issues with sparse files (which is what lastlog is)?
> 
> That's more-or-less normal. The apparent size (ls -h) of lastlog will vary 
> with architecture, vendor, Unix flavor, UIDs on the system, etc., but it 
> should be sparse and will likely appear huge (for some value of huge ;-)
> 
> The idea is that lastlog is indexed by uid but is sparse so you don't 
> waste disk space. The huge sparseness you're seeing is because nfsnobody 
> on your OS is uid -1. nfsnobody uid of -1 on x86_64 is 4294967294, and 
> indexing to 4294967294 reserves 1.2 terabytes

Ah HA!! You hit it dead on. Many thanks for the tutoring lesson on
indexing a filesystem.

> 
> ext3 is fine with it, but your utils (tar, cpio, etc) may or may not do 
> what you want -- treat it as a sparse file, rather than as a really long 
> really compressible string -- depending on rev, vendor, options used, etc.
> 
> later,
> chris
> _______________________________________________
> Ale mailing list
> Ale at ale.org
> http://www.ale.org/mailman/listinfo/ale
-- 
James P. Kinney III          \Changing the mobile computing world/
CEO & Director of Engineering \          one Linux user         /
Local Net Solutions,LLC        \           at a time.          /
770-493-8244                    \.___________________________./
http://www.localnetsolutions.com

GPG ID: 829C6CA7 James P. Kinney III (M.S. Physics)
<jkinney at localnetsolutions.com>
Fingerprint = 3C9E 6366 54FC A3FE BA4D 0659 6190 ADC3 829C 6CA7
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part




More information about the Ale mailing list