tech-kern archive

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

Re: Unallocated inode



On Mon, Nov 24, 2014 at 08:01:57PM -0500, Christos Zoulas wrote:
> On Nov 25, 10:59am, stix%stix.id.au@localhost (Paul Ripke) wrote:
> -- Subject: Re: Unallocated inode
> 
> | On Tue, Sep 02, 2014 at 06:15:49PM -0400, Christos Zoulas wrote:
> | > On Sep 2,  2:27pm, stix%stix.id.au@localhost (Paul Ripke) wrote:
> | > -- Subject: Re: Unallocated inode
> | > 
> | > | Yeah, that's what scares me - it was the daily rsync and security cron
> | > | jobs starting to generate errors that alerted me - those inodes must've
> | > | been marked partially allocated only recently. Makes me wish I dumped
> | > | out the contents of those two inodes before running the fsck (maybe
> | > | fsdb should be able to do that?).
> | > 
> | > Yes, I think fsdb can do that...
> | 
> | Ok, this happened again. And with a tweaked fsdb, I get:
> | 
> | fsdb (inum: 125770625)> print
> | command `print
> | '
> | current inode 125770625: unallocated inode
> | current inode: unallocated
> | I=125770625 MODE=0 SIZE=0
> |         MTIME=Jan  1 10:00:00 1970 [0 nsec]
> |         CTIME=Nov 25 10:34:43 2014 [282996506 nsec]
> |         ATIME=Jan  1 10:00:00 1970 [0 nsec]
> | OWNER=root GRP=wheel LINKCNT=0 FLAGS=0x0 BLKCNT=0x0 GEN=0x0
> | 
> | Nothing was being touched in that part of the filesystem at the time...
> | I think the CTIME may be related to me mv'ing the file elsewhere, the
> | time somewhat matches. I find this somewhat scary. For reference:
> 
> Is that inode accessible from the filesystem? Can you reproduce this
> running find on that subtree?

Nope, it's inaccessible - again, it was the daily security reports
that alerted me:

slave:ksh$ find /home/tmp > /dev/null
find: /home/tmp/badfile: Bad file descriptor

(I renamed the inaccessible file into a convenient location as I
couldn't figure out in 10 seconds how to cd thru directories with
spaces in the names in fsdb...)

> | slave:ksh$ uptime
> | 10:48AM  up 185 days, 10:02, 22 users, load averages: 0.10, 0.12, 0.09
> | slave:ksh$ uname -a
> | NetBSD slave 6.1_STABLE NetBSD 6.1_STABLE (SLAVE) #4: Fri May 23 23:42:30 EST 2014  stix@slave:/home/netbsd/netbsd-6/obj.amd64/home/netbsd/netbsd-6/src/sys/arch/amd64/compile/SLAVE amd64
> | slave:ksh$ dumpfs -s /home
> | file system: /dev/rraid0g
> | format  FFSv2
> | endian  little-endian
> | location 65536  (-b 128)
> | magic   19540119        time    Tue Nov 25 10:53:00 2014
> | superblock location     65536   id      [ 4f0a6e35 5072c3da ]
> | cylgrp  dynamic inodes  FFSv2   sblock  FFSv2   fslevel 5
> | nbfree  43523811        ndir    485483  nifree  225883757       nffree  1938557
> | ncg     10072   size    953688576       blocks  924600521
> | bsize   16384   shift   14      mask    0xffffc000
> | fsize   2048    shift   11      mask    0xfffff800
> | frag    8       shift   3       fsbtodb 2
> | bpg     11836   fpg     94688   ipg     22976
> | minfree 5%      optim   time    maxcontig 4     maxbpg  2048
> | symlinklen 120  contigsumsize 4
> | maxfilesize 0x000080100202ffff
> | nindir  2048    inopb   64
> | avgfilesize 16384       avgfpdir 64
> | sblkno  40      cblkno  48      iblkno  56      dblkno  2928
> | sbsize  2048    cgsize  16384
> | csaddr  2928    cssize  161792
> | cgrotor 0       fmod    0       ronly   0       clean   0x02
> | wapbl version 0x1       location 2      flags 0x0
> | wapbl loc0 1907406880   loc1 131072     loc2 512        loc3 3
> | flags   wapbl
> | fsmnt   /home
> | volname         swuid   0
> 
> Everything looks normal here I think.
> 
> christos

--
Paul Ripke
"Great minds discuss ideas, average minds discuss events, small minds
 discuss people."
-- Disputed: Often attributed to Eleanor Roosevelt. 1948.


Home | Main Index | Thread Index | Old Index