Operating System - HP-UX
1753322 Members
6665 Online
108792 Solutions
New Discussion юеВ

fsck - invalid super block

 
SOLVED
Go to solution
Ratzie
Super Advisor

fsck - invalid super block

I had a disk that after a reboot did not come back up. When I tried to do:
# fsck -F vxfs -o full /dev/dsk/c0t4d0
invalid super-block
search for auxiliary super-block? (ynq)y
vxfs fsck: read failure at 589824

I have tried 3 other super blocks that I have read in the forums that are basically default but same issue.
As well, we do not have the sbtab file anywhere on the server. I thought this is created by default when you newfs a file system???
So we did a newfs on the system and when we try the same command we get the same error..
But, if I just run:
# fsck /dev/dsk/c0t4d0
fsck: /etc/default/fs is used for determining the file system type
** /dev/dsk/c0t4d0
** Last Mounted on
** Phase 1 - Check Blocks and Sizes
** Phase 2 - Check Pathnames
** Phase 3 - Check Connectivity
** Phase 4 - Check Reference Counts
** Phase 5 - Check Cyl groups
2 files, 0 icont, 9 used, 4103189 free (13 frags, 512897 blocks)

Everything checks out ok.
What are we missing???

Thanks for the help.



10 REPLIES 10
Steven E. Protter
Exalted Contributor
Solution

Re: fsck - invalid super block

You are running fsck on a disk.

I've always run it on a filesystem.

fs I thought stood for filesystem.

I'm not saying you can't do what you are doing, it just seems unusual.

You may have a problem with your disk. Or there may be something on it that prevents fsck from udnerstanding it.

At this point, I'd use mstm,cstm or xstm and test that disk thoroughly. Something is wrong with it and it needs to be fixed or replaced.

pvdisplay -v /dev/dsk/c0t4d0

maybe rdsk, I get confused.

See whats on it and then make arrangements to back it allup.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Ratzie
Super Advisor

Re: fsck - invalid super block

Maybe I am going about this all wrong.

I can not do a pvdisplay:
# ioscan -funC disk
disk 1 10/0.4.0 sdisk CLAIMED DEVICE SEAGATE ST34371W
/dev/dsk/c0t4d0 /dev/rdsk/c0t4d0

Also, when I run cstm, I get an error:
Waiting to obtain host information from the local host shelby.mts.mb.ca.
The diagnostic daemon "diagmond" may have been started recently and is busy
building the device map.

If this message persists for a long time, it is possible that either the
diagnostic daemon is not running, or that networking is improperly configured.
The networking configuration can be verified by comparing 'nslookup `hostname`'
with the output of ifconfig of the LANs identified by lanscan.


But, everything looks correct!
A. Clay Stephenson
Acclaimed Contributor

Re: fsck - invalid super block

fsck -F vxfs -o full /dev/dsk/c0t4d0

This command only makes sense if you are testing a filesystem using whole-disk allocation. Whole disk is almost never used anymore and especially when you also mention pvcreate, your test makes no sense.

Now this would make sense:
fsck -F vxfs -o full /dev/vg02/lvol1

assuming /dev/vg02/lvol1 houses an vxfs filesystem.


Now, if you do want to test a disk for errors, this makes more sense:

dd if=/dev/rdsk/c0t4d0 bs=64k of=/dev/null
If it ain't broke, I can fix that.
Ratzie
Super Advisor

Re: fsck - invalid super block

I have ran the test for the disk:
# dd if=/dev/rdsk/c0t4d0 bs=64k of=/dev/null
dd read error: I/O error
9+0 records in
9+0 records out


Does not tell me alot...
A. Clay Stephenson
Acclaimed Contributor

Re: fsck - invalid super block

Well, it tells me that you have a bad disk (or at least some sort of hardware problem -- cable, controller, terminator, disk, etc) -- but probably a bad disk.
If it ain't broke, I can fix that.
Steven E. Protter
Exalted Contributor

Re: fsck - invalid super block

Dead disk.

Say a prayer for it, if you do that sort of thing, and figure out which one is dead. Then arrange a hardware service call to replace it.

If possible, get the disk out of the volume group its in with vgreduce. At this point it might still work.

Still could be a cable issue, but seems the disk is kinda gone.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Bill Hassell
Honored Contributor

Re: fsck - invalid super block

Easy answer: whenever fsck says there is an error reading the disk, there is nothing fsck can do about it--the disk is bad and must be replaced. The verification is with dd. The reason that fsck works after newfs is that there is nothing in the filesystem so the data to check is very small, located at the begimnning of the disk. Contrary to popular opinion, fsck is NOT a disk checker/fixer. It is a directory structure repair tool. It reads the directory and filesystem codes and fixes links and pointers that are incorrect. This has nothing to do with bad spots on the disk. If a filesystem structure cannot be read, fsck aborts as there is nothing more that can be done.

You'll have to backup any other lvols on this disk, remove the disk from the volume group, replace it, then add the new disk back into the volume group, recreate the lvols and restore your data.


Bill Hassell, sysadmin
Aykut Guven
Regular Advisor

Re: fsck - invalid super block

Hello I am not expert on this but just writing may be learn a few things by helping. As far as i know you need sbtab file for only HFS file system, JFS manages its disk metadata itself. In this case fcsk could not find neither primary super block nor backups. Really bad situation i hope you have backup of the disk because the case shows physically error of the disk.

Good luck.
UPS
Amit_68
Occasional Contributor

Re: fsck - invalid super block

Hi ,
dear first find out block size of yur file system .

and then try to make dummy file sysrem of exact block size of yur old file system.last line of output will give you superblocks of yur file system. try it with "fsck" .you will get overcome of yur problem.