baslinux AT lists.ibiblio.org
Subject: Baslinux mailing list
List archive
- From: Sindi Keesan <keesan AT iamjlamb.com>
- To: baslinux AT lists.ibiblio.org
- Subject: Re: [BL] hard drive/fsck problem
- Date: Thu, 17 Jun 2004 11:43:10 -0400 (EDT)
The inodes problem discussed below apparently resulted from my powering
off the computer without rebooting, because I could not reboot when I got
into a sort of endless loop of error messages when untarring which I could
not even stop with Ctrl-C. When I looked at /usr/src/linux-2.2.16 there
were a lot of 0 length subdirectories before I fixed things.
I finally figured out that I have BL2 installed not to /dev/hdb3 but
/dev/hdb2, and I am running e2fsck /dev/hdb2 now. It asks me about things
like
Inode 41077 has illegal block(s). Clear<y>? Yes
Indoes 41080, i_size is 12915, should be 21504. Fix<y>? Yes
Too many illegal blocks in inode 41081. Clear inode<y> Yes
I answered y about 100 times and it is restarting e2fsck from the
beginning.
Still finding errors. Duplicate blocks found in two inodes.
Reconciling duplicate blocks. Clone/duplicate bad blocks? yes
Already reassigned or cloned.
Checking directory structure. Clear a deleted/unused node. yes
(Many of these, all, not surprisingly, in /usr/src/linux-2.2.16/include)
I hit the enter key 66 times.
Free inodes count wrong for group #117 (and many other groups)
Directories count wrong.... FIXED
******FILE SYSTEM WAS MODIFIED******
Rebooting and attempting to boot BL2 from hard drive again, now that it is
fixed. Booting Win98 DOS from floppy disk so that linux will boot since
it won't boot on this computer if I start with DR-DOS.
Can't find any files in c: now, strange. I have BL2 in D, luckily.
I have had similar problems before with a hard drive set up with DR-DOS
and then booted with Win98 DOS.
I have /usr/src/linux (as before) and also /usr/src/linux-2.2.16, with
subdirectories and files in them. I might risk untarring the kernel
source code tar file again since I know how to fix problems now, but I can
probably just delete it since the source code appears to be all there.
In /include there are various asm- directories. Can I safely delete
asm-alpha -arm -m68k -mips s390 spard sparc64 and keep just asm
asm-generic and asm-i386?
Do I need both /linux and /linux-2.2.16? They have identical
subdirectories in them and are both 7462 in size. Would just the latter
be enough?
BL3 has apparently rescued BL2, but would not have worked for me on this
particular computer from C: because of my problem in not being able to
boot linux from DR-DOS and having to boot from a Win98 boot disk, which
won't recognize c: when it is set up with DR-DOS.
Steven, thanks for all the useful tools, and especially for making BL3
usable from D:. (I have not yet tried the floppy disk version).
On Thu, 17 Jun 2004, Sindi Keesan wrote:
> I read about fsck and followed the instructions to run e2fsck on an
> unmounted file system (using BL3 to check the BL2 partition), both with
> and without -a (automatically fix?) option. BL2 ramdisk did not have
> fsck/e2fsck so I could not use that. The warning message when I tried to
> boot BL2 hard drive said to run e2fsck without the -a option. It also
> said to reboot immediately, which implies that I am not supposed to use
> BL2 to check itself.
>
> Both times it checked if /dev/hdb3 was mounted (it was not) and then told
> me 'clean, 11/226440 files, 29096/905184 blocks'.
> I thought this meant it had fixed the inode problem but it had not.
> BL3 does not have a lot of help on e2fsck (part of busybox?).
> Switch: -l bad_blocks-file - would this help?
> The problem is 'wrong free inode count' and something about illegal
> blocks.
>
> This computer, again, won't boot linux when I first boot into DR-DOS so I
> boot DOS from a Win98 boot disk. (The other computer at this location
> won't run Xvesa if I boot from Win98 unless I hit F5 to bypass system
> files, and booting from DR-DOS did not help.) Probably irrelevant to the
> inode problem. I have three computers of the same model with the same
> problem in linux.
>
>
>
> On Tue, 15 Jun 2004, Sindi Keesan wrote:
>
> > While trying to get the linux source code for 2.2.16 into /usr/src/
> > on my second computer (the first would not recognize the CD-ROM drive),
> > after installing bzip2 and bunzip2-ing the file from the source CD
> > (linux-2.2.16-tar.bz2 copied to the hard drive first), I did tar
> > on the resulting 75MB file (up from 13M) and was getting an occasional
> > error (reset? two lines of error, it resumed). Then I went away and
> > came
> > back to find a screen full of error messages about reset and status and
> > command and I could not do Ctrl-C. Something wrong with hdb so I powered
> > off and tried to go back into linux.
> >
> > Linuxz contains a file system with errors, check forced.
> >
> > It got slightly into the check and gave up and told me to run fsck
> > manually. When I typed root to login there were a lot of error messages
> > about EXT2 error Wrong free inode count (followed by various numbers).
> >
> > Before logging in (I think) there was some complaint about
> > Inode 41067 has illegal blocks.
> >
> > I dutifully typed fsck without any switches but that did not help. I
> > have
> > no idea what fsck is supposed to do or how to use it.
> >
> > This now happens every time I try to run linux.
> >
> > What got messed up? Is it a bad hard drive? Just a software problem?
> > Can I fix this? Only half the source files got installed, even though I
> > saw the others go by on the list. the /net directory is 0, as is README.
> > Would it help to reformat and reinstall Linux on there again. Change
> > hard
> > drives? Change computers?
> >
> > THis computer is the one that used to not boot linux half the time
> > (unless
> > I booted from Win98 DOS or MS-DOS 6) but it now boots linux without any
> > complaints until the fsck/inodes thing. I tried to use the problem-free
> > one but it could not find the CD-ROM drive. (And now my keyboard drawer
> > just fell off again....)
> >
> > I was trying to compile the kernel module for a replacement ethernet card
> > but I can put back the original card to reinstall linux with as it uses a
> > more standard ethernet module. One problem leads to too many others.
> >
> > Any ideas welcome.
> > Sindi
> >
> > _______________________________________________
> > BasLinux mailing list
> > BasLinux AT lists.ibiblio.org
> > http://lists.ibiblio.org/mailman/listinfo/baslinux
> >
>
> _______________________________________________
> BasLinux mailing list
> BasLinux AT lists.ibiblio.org
> http://lists.ibiblio.org/mailman/listinfo/baslinux
>
[1]Table of Contents
[2]
NAME
fsck - file system consistency check and interactive repair
[3]
SYNOPSIS
fsck -p [ -m mode ]
fsck [ -b block# ] [ -c ] [ -y ] [ -n ] [ -m mode ] [ filesystem ] ...
[4]
DESCRIPTION
The first form of fsck preens a standard set of filesystems or the
specified file systems. It is normally used in the script /etc/rc
during automatic reboot. Here fsck reads the table /etc/fstab to
determine which file systems to check. Only partitions in fstab that
are mounted ``rw,'' ``rq'' or ``ro'' and that have non-zero pass
number are checked. Filesystems with pass number 1 (normally just the
root filesystem) are checked one at a time. When pass 1 completes, all
remaining filesystems are checked, running one process per disk drive.
The disk drive containing each filesystem is inferred from the longest
prefix of the device name that ends in a digit; the remaining
characters are assumed to be the partition designator.
The system takes care that only a restricted class of innocuous
inconsistencies can happen unless hardware or software failures
intervene. These are limited to the following:
Unreferenced inodes
Link counts in inodes too large
Missing blocks in the free map
Blocks in the free map also in files
Counts in the super-block wrong
These are the only inconsistencies that fsck with the -p option will
correct; if it encounters other inconsistencies, it exits with an
abnormal return status and an automatic reboot will then fail. For
each corrected inconsistency one or more lines will be printed
identifying the file system on which the correction will take place,
and the nature of the correction. After successfully correcting a file
system, fsck will print the number of files on that file system, the
number of used and free blocks, and the percentage of fragmentation.
If sent a QUIT signal, fsck will finish the file system checks, then
exit with an abnormal return status that causes an automatic reboot to
fail. This is useful when to finish the file system checks during an
automatic reboot, but do not want the machine to come up multiuser
after the checks complete.
Without the -p option, fsck audits and interactively repairs
inconsistent conditions for file systems. If the file system is
inconsistent the operator is prompted for concurrence before each
correction is attempted. It should be noted that some of the
corrective actions which are not correctable under the -p option will
result in some loss of data. The amount and severity of data lost may
be determined from the diagnostic output. The default action for each
consistency correction is to wait for the operator to respond yes or
no. If the operator does not have write permission on the file system
fsck will default to a -n action.
Fsck has more consistency checks than its predecessors check, dcheck,
fcheck, and icheck combined.
The following flags are interpreted by fsck.
-b
Use the block specified immediately after the flag as the super
block for the file system. Block 32 is usually an alternate
super block.
-l
Limit the number of parallel checks to the number specified in
the following argument. By default, the limit is the number of
disks, running one process per disk. If a smaller limit is
given, the disks are checked round-robin, one filesystem at a
time.
-m
Use the mode specified in octal immediately after the flag as
the permission bits to use when creating the lost+found
directory rather than the default 1777. In particular, systems
that do not wish to have lost files accessible by all users on
the system should use a more restrictive set of permissions
such as 700.
-y
Assume a yes response to all questions asked by fsck; this
should be used with great caution as this is a free license to
continue after essentially unlimited trouble has been
encountered.
-n
Assume a no response to all questions asked by fsck except for
``CONTINUE?'', which is assumed to be affirmative; do not open
the file system for writing.
-c
If the file system is in the old (static table) format, convert
it to the new (dynamic table) format. If the file system is in
the new format, convert it to the old format provided the old
format can support the filesystem configuration. In interactive
mode, fsck will list the direction the conversion is to be made
and ask whether the conversion should be done. If a negative
answer is given, no further operations are done on the
filesystem. In preen mode, the direction of the conversion is
listed and done if possible without user interaction.
Conversion in preen mode is best used when all the file systems
are being converted at once. The format of a file system can be
determined from the first line of output from [5]dumpfs(8).
If no filesystems are given to fsck then a default list of file
systems is read from the file /etc/fstab.
Inconsistencies checked are as follows:
1.
Blocks claimed by more than one inode or the free map.
2.
Blocks claimed by an inode outside the range of the file
system.
3.
Incorrect link counts.
4.
Size checks: Directory size not of proper format. Partially
truncated file.
5.
Bad inode format.
6.
Blocks not accounted for anywhere.
7.
Directory checks: File pointing to unallocated inode. Inode
number out of range. Dot or dot-dot not the first two entries
of a directory or having the wrong inode number.
8.
Super Block checks: More blocks for inodes than there are in
the file system.
9.
Bad free block map format. 10. Total free block and/or free
inode count incorrect.
Orphaned files and directories (allocated but unreferenced) are, with
the operator's concurrence, reconnected by placing them in the
lost+found directory. The name assigned is the inode number. If the
lost+found directory does not exist, it is created. If there is
insufficient space its size is increased.
Because of inconsistencies between the block device and the buffer
cache, the raw device should always be used.
[6]
FILES
/etc/fstab
contains default list of file systems to check.
[7]
DIAGNOSTICS
The diagnostics produced by fsck are fully enumerated and explained in
Appendix A of ``Fsck - The UNIX File System Check Program'' (SMM:5).
[8]
SEE ALSO
[9]fstab(5), [10]fs(5), [11]fsdb(8), [12]newfs(8), [13]mkfs(8),
[14]reboot(8)
_________________________________________________________________
Table of Contents
* [15]NAME
* [16]SYNOPSIS
* [17]DESCRIPTION
* [18]FILES
* [19]DIAGNOSTICS
* [20]SEE ALSO
References
1. http://www.neosoft.com/neosoft/man/fsck.8.html#toc
2. http://www.neosoft.com/neosoft/man/fsck.8.html#toc0
3. http://www.neosoft.com/neosoft/man/fsck.8.html#toc1
4. http://www.neosoft.com/neosoft/man/fsck.8.html#toc2
5. http://www.neosoft.com/neosoft/man/dumpfs.8.html
6. http://www.neosoft.com/neosoft/man/fsck.8.html#toc3
7. http://www.neosoft.com/neosoft/man/fsck.8.html#toc4
8. http://www.neosoft.com/neosoft/man/fsck.8.html#toc5
9. http://www.neosoft.com/neosoft/man/fstab.5.html
10. http://www.neosoft.com/neosoft/man/fs.5.html
11. http://www.neosoft.com/neosoft/man/fsdb.8.html
12. http://www.neosoft.com/neosoft/man/newfs.8.html
13. http://www.neosoft.com/neosoft/man/mkfs.8.html
14. http://www.neosoft.com/neosoft/man/reboot.8.html
15. http://www.neosoft.com/neosoft/man/fsck.8.html#sect0
16. http://www.neosoft.com/neosoft/man/fsck.8.html#sect1
17. http://www.neosoft.com/neosoft/man/fsck.8.html#sect2
18. http://www.neosoft.com/neosoft/man/fsck.8.html#sect3
19. http://www.neosoft.com/neosoft/man/fsck.8.html#sect4
20. http://www.neosoft.com/neosoft/man/fsck.8.html#sect5
-
[BL] hard drive/fsck problem,
Sindi Keesan, 06/15/2004
-
Re: [BL] hard drive/fsck problem,
Sindi Keesan, 06/17/2004
-
Re: [BL] hard drive/fsck problem,
Sindi Keesan, 06/17/2004
- Re[2]: [BL] hard drive/fsck problem, Dodo Serge, 06/17/2004
-
Re: [BL] hard drive/fsck problem,
3aoo-cvfd, 06/17/2004
-
Re: [BL] hard drive/fsck problem,
Sindi Keesan, 06/17/2004
-
Re: [BL] hard drive/fsck problem,
3aoo-cvfd, 06/17/2004
- Re: [BL] hard drive/fsck problem, Sindi Keesan, 06/18/2004
-
Re: [BL] hard drive/fsck problem,
3aoo-cvfd, 06/17/2004
-
Re: [BL] hard drive/fsck problem,
Sindi Keesan, 06/17/2004
-
Re: [BL] hard drive/fsck problem,
Sindi Keesan, 06/17/2004
-
Re: [BL] hard drive/fsck problem,
Sindi Keesan, 06/17/2004
Archive powered by MHonArc 2.6.24.