Damage to filesystem - help needed with xfs_repair

Open discussion on or around SGI; software/hardware related posts should go in the appropriate subforum.
Forum rules
Any posts concerning pirated software or offering to buy/sell/trade commercial software are subject to removal.
Gavin
Posts: 5
Joined: Sat Jun 07, 2003 4:47 am

Damage to filesystem - help needed with xfs_repair

Unread postby Gavin » Sat Jun 07, 2003 5:52 am

Hi

I've got an Octane system (300MHz R12k with SSE) that I bought on EBay so I
could learn about SGI & IRIX systems equipment at home. I really love using
this machine and have managed to work out how to get a fresh copy of IRIX
installed, update to 6.5.16m, connect to the internet, and install some really
useful freeware (Phoenix, Sylpheed, GIMP etc).

Unfortunately I've got a slight problem with my system and I don't really know
anyone locally who can help me so I thought I'd try posting here. Please accept
my apologies in in advance if my knowledge and experience are lacking (my
background is in supporting wintel servers).

My problem is that the power to my Octane got cut off yesterday (a circuit was
overloaded and the breaker 'popped'). So I ran fsck, found out in the man
pages that it only covers EFS, and looked at the man entries for xfs_check and
xfs_repair
.

The system has a single 9GB/10k disk. When I run xfs_check on /dev/dsk/root I
get the following:

Code: Select all

lancewood 18# pwd
/hw/disk
lancewood 19# ls
dks0d1s0  dks0d1s1  root      swap
lancewood 20# xfs_check root
agi unlinked bucket 3 is 707 in ag 6
agi unlinked bucket 4 is 44164 in ag 6
agi unlinked bucket 10 is 20682 in ag 6
agi unlinked bucket 11 is 20683 in ag 6
agi unlinked bucket 12 is 78732 in ag 6
agi unlinked bucket 14 is 718 in ag 6
agi unlinked bucket 30 is 20702 in ag 6
agi unlinked bucket 32 is 304800 in ag 6
agi unlinked bucket 33 is 304801 in ag 6
agi unlinked bucket 34 is 231330 in ag 6
agi unlinked bucket 35 is 675 in ag 6
agi unlinked bucket 38 is 678 in ag 6
agi unlinked bucket 39 is 304807 in ag 6
agi unlinked bucket 41 is 20713 in ag 6
agi unlinked bucket 48 is 113456 in ag 6
agi unlinked bucket 60 is 231740 in ag 6
agi unlinked bucket 61 is 44157 in ag 6
agi unlinked bucket 62 is 291710 in ag 6
agi unlinked bucket 36 is 1060 in ag 7
agi unlinked bucket 37 is 1061 in ag 7
agi unlinked bucket 38 is 1062 in ag 7
agi unlinked bucket 39 is 1063 in ag 7
agi unlinked bucket 40 is 1064 in ag 7
agi unlinked bucket 41 is 1065 in ag 7
allocated inode 25397152 has 0 link count
allocated inode 25397154 has 0 link count
allocated inode 25209981 has 0 link count
allocated inode 25209988 has 0 link count
allocated inode 25234151 has 0 link count
allocated inode 25470624 has 0 link count
allocated inode 25470625 has 0 link count
allocated inode 25470631 has 0 link count
allocated inode 25279280 has 0 link count
allocated inode 25397564 has 0 link count
allocated inode 25457534 has 0 link count
allocated inode 25244556 has 0 link count
allocated inode 25166499 has 0 link count
allocated inode 25166502 has 0 link count
allocated inode 25166531 has 0 link count
allocated inode 25186506 has 0 link count
allocated inode 25186507 has 0 link count
allocated inode 25166542 has 0 link count
allocated inode 25186526 has 0 link count
allocated inode 25186537 has 0 link count
allocated inode 29361188 has 0 link count
allocated inode 29361189 has 0 link count
allocated inode 29361190 has 0 link count
allocated inode 29361191 has 0 link count
allocated inode 29361192 has 0 link count
allocated inode 29361193 has 0 link count


So there are clearly some problems related to the power failure. To clarify
what was wrong I ran xfs_repair with the 'no modify' switch. This produced the
following output:

Code: Select all

lancewood 23# xfs_repair -n root
Phase 1 - find and verify superblock...
Phase 2 - scan filesystem freespace and inode maps...
        - found root inode chunk
Phase 3 - for each AG...
        - scan (but don't clear) agi unlinked lists...
error following ag 6 unlinked list
error following ag 7 unlinked list
        - process known inodes and perform inode discovery...
        - agno = 0
        - agno = 1
        - agno = 2
        - agno = 3
        - agno = 4
        - agno = 5
        - agno = 6
        - agno = 7
        - agno = 8
        - process newly discovered inodes...
Phase 4 - check for duplicate blocks...
        - setting up duplicate extent list...
        - check for inodes claiming duplicate blocks...
        - agno = 0
        - agno = 1
        - agno = 2
        - agno = 3
        - agno = 4
        - agno = 5
        - agno = 6
        - agno = 7
        - agno = 8
No modify flag set, skipping phase 5
Phase 6 - check inode connectivity...
        - traversing filesystem starting at / ...
entry "browse.dat" in shortform dir inode 25324598 points to free inode 25287730
would junk entry "browse.dat"
        - traversal finished ...
        - traversing all unattached subtrees ...
        - traversals finished ...
        - moving disconnected inodes to lost+found ...
disconnected inode 25166499, would move to lost+found
disconnected inode 25166502, would move to lost+found
disconnected inode 25166531, would move to lost+found
disconnected inode 25166542, would move to lost+found
disconnected inode 25186506, would move to lost+found
disconnected inode 25186507, would move to lost+found
disconnected inode 25186526, would move to lost+found
disconnected inode 25186537, would move to lost+found
disconnected inode 25209981, would move to lost+found
disconnected inode 25209988, would move to lost+found
disconnected inode 25234151, would move to lost+found
disconnected inode 25244556, would move to lost+found
disconnected inode 25279280, would move to lost+found
disconnected inode 25397152, would move to lost+found
disconnected inode 25397154, would move to lost+found
disconnected inode 25397564, would move to lost+found
disconnected inode 25457534, would move to lost+found
disconnected inode 25470624, would move to lost+found
disconnected inode 25470625, would move to lost+found
disconnected inode 25470631, would move to lost+found
disconnected inode 25470636, would move to lost+found
disconnected inode 25470640, would move to lost+found
disconnected inode 25470641, would move to lost+found
disconnected inode 25470642, would move to lost+found
disconnected inode 25558424, would move to lost+found
disconnected inode 29361188, would move to lost+found
disconnected inode 29361189, would move to lost+found
disconnected inode 29361190, would move to lost+found
disconnected inode 29361191, would move to lost+found
disconnected inode 29361192, would move to lost+found
disconnected inode 29361193, would move to lost+found
disconnected inode 29361217, would move to lost+found
disconnected inode 29361220, would move to lost+found
Phase 7 - verify link counts...
would have reset inode 25166499 nlinks from 0 to 1
would have reset inode 25166502 nlinks from 0 to 1
would have reset inode 25166531 nlinks from 0 to 1
would have reset inode 25166542 nlinks from 0 to 1
would have reset inode 25186506 nlinks from 0 to 1
would have reset inode 25186507 nlinks from 0 to 1
would have reset inode 25186526 nlinks from 0 to 1
would have reset inode 25186537 nlinks from 0 to 1
would have reset inode 25209981 nlinks from 0 to 1
would have reset inode 25209988 nlinks from 0 to 1
would have reset inode 25234151 nlinks from 0 to 1
would have reset inode 25244556 nlinks from 0 to 1
would have reset inode 25279280 nlinks from 0 to 1
would have reset inode 25397152 nlinks from 0 to 1
would have reset inode 25397154 nlinks from 0 to 1
would have reset inode 25397564 nlinks from 0 to 1
would have reset inode 25457534 nlinks from 0 to 1
would have reset inode 25470624 nlinks from 0 to 1
would have reset inode 25470625 nlinks from 0 to 1
would have reset inode 25470631 nlinks from 0 to 1
would have reset inode 25470636 nlinks from 0 to 1
would have reset inode 25470640 nlinks from 0 to 1
would have reset inode 25470641 nlinks from 0 to 1
would have reset inode 25470642 nlinks from 0 to 1
would have reset inode 25558424 nlinks from 0 to 1
would have reset inode 29361188 nlinks from 0 to 1
would have reset inode 29361189 nlinks from 0 to 1
would have reset inode 29361190 nlinks from 0 to 1
would have reset inode 29361191 nlinks from 0 to 1
would have reset inode 29361192 nlinks from 0 to 1
would have reset inode 29361193 nlinks from 0 to 1
would have reset inode 29361217 nlinks from 0 to 1
would have reset inode 29361220 nlinks from 0 to 1
No modify flag set, skipping filesystem flush and exiting.


When I try to run xfs_repair on /dev/dsk/root I get told that

Code: Select all

lancewood 25# xfs_repair root
root contains a mounted filesystem

fatal error -- couldn't initialize simulation library


I don't really know what to do next. I understand that root can't be unmounted while the system is booted, so am I supposed to boot into a mini-root from the install CD and run xfs_repair from there?

I would really appreciate it if someone could look at the console output I've posted above, tell me what the impact of these errors are, and suggest a way of fixing them.

Thanks in advance for your help.

--Gavin



P.S. This is totally unrelated - but how come I can't copy text into Phoenix (version 0.5)? I had to copy the console output I used above into Sylpheed, email it to myself, and copy and paste it from a web-mail client in a separate browser tab. Is this a bug or a feature?

User avatar
dexter1
Moderator
Moderator
Posts: 2771
Joined: Thu Feb 20, 2003 6:57 am
Location: Zoetermeer, The Netherlands

Unread postby dexter1 » Sat Jun 07, 2003 7:37 am

Maybe this will work:

- Shutdown the machine and go to the ARCS64 PROM
- Boot miniroot installation
- when miniroot is done loading, select "Admin" option in the menu
-

Code: Select all

sh df
lists the mounted partitions
-

Code: Select all

sh umount /root

-

Code: Select all

sh xfs_repair /dev/root


... should attempt to repair your root disk. I have no idea if this works, i just copied it from a swedish site. You can wait until i've checked this with one of my spare indy's at work, but YMMV. Don't sue me if it doesn't work...

Good luck!

PS: anyone additional suggestions?

Gavin
Posts: 5
Joined: Sat Jun 07, 2003 4:47 am

Unread postby Gavin » Sat Jun 07, 2003 8:21 am

Thanks dexter1

That is exactly what I thought I would have to do.

One thing that worries me is the list of disconnected inodes reported by xfs_check. In my (limited) understanding, each inode is a placeholder that holds information about an individual file and the filesystem is just an abstraction that sits on top. In other words, all those lost inodes represent files that were orphaned by the filesystem when the power went down (kind of like the FILExxxx.CHK files produced by running chkdsk /f on an old FAT based DOS/Windows machine).

Is there any way (script, program, method etc) for working out what those lost files were and putting them back in their rightful place? I know my Octane isn't a PC with access to tools like Norton Utilities, and I realise I may have to just read their contents and try and guess what they are/were, but I would appreciate any guidance on this.

Hopefully they are/were just /tmp or /usr/tmp type scratch files.

--Gavin

User avatar
semi-fly
Posts: 786
Joined: Fri Feb 21, 2003 5:29 am
Location: Ypsitucky, MI
Contact:

Re: Damage to filesystem - help needed with xfs_repair

Unread postby semi-fly » Sat Jun 07, 2003 8:39 am

Gavin wrote:P.S. This is totally unrelated - but how come I can't copy text into Phoenix (version 0.5)? I had to copy the console output I used above into Sylpheed, email it to myself, and copy and paste it from a web-mail client in a separate browser tab. Is this a bug or a feature?


I've noticed some strange things when running Phoenix; not being able to save images to disk, cut & paste problems, sometimes I'll randomly get redirected if I don't include the "www" sufix when typing a url into the location bar. I actually went back to Mozilla 1.4 and uninstalled Phoenix, using that as my primary browser.

Gavin
Posts: 5
Joined: Sat Jun 07, 2003 4:47 am

Re: Damage to filesystem - help needed with xfs_repair

Unread postby Gavin » Sat Jun 07, 2003 8:52 am

semi-fly wrote:
Gavin wrote:P.S. This is totally unrelated - but how come I can't copy text into Phoenix (version 0.5)? I had to copy the console output I used above into Sylpheed, email it to myself, and copy and paste it from a web-mail client in a separate browser tab. Is this a bug or a feature?


I've noticed some strange things when running Phoenix; not being able to save images to disk, cut & paste problems, sometimes I'll randomly get redirected if I don't include the "www" sufix when typing a url into the location bar. I actually went back to Mozilla 1.4 and uninstalled Phoenix, using that as my primary browser.


I've only been using it for a few days (the version I'm using might be a bit old as I got it from freeware.sgi.com). Some of the features e.g. tabbed browsing and popup blocking, are really good and it is definitely better than the old Netscape browser that comes with IRIX. However there are some annoying bugs.

Problems with X11 copy and paste is the main complaint. Another is that the the toolbar customisation menu (right click on toolbar, choose customise) doesn't fit into the (non-resizable) child window. The themes options (under Tools/Preferences) doesn't work. The occasional completely random redirection is a bit aggravating.

According to the about About Phoenix menu item, the version I'm using is Mozilla/5.0 (X11; U; IRIX64 IP30; en-US; rv:1.3a) Gecko/20030311 Phoenix/0.5.

--Gavin


Return to “SGI: Discussion”

Who is online

Users browsing this forum: No registered users and 1 guest