LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Other *NIX Forums > *BSD
User Name
Password
*BSD This forum is for the discussion of all BSD variants.
FreeBSD, OpenBSD, NetBSD, etc.

Notices

Reply
 
Search this Thread
Old 01-11-2004, 03:27 PM   #1
mjolnir
Member
 
Registered: Apr 2003
Posts: 665

Rep: Reputation: 68
fsck many bad blocks


I am dual booting obsd 3.4 and mdk9.1 on a toshiba sat.
While trying to configure X on bsd I managed to lock it up
and had an unclean shutdown. I finally got it to boot again
but /dev/rwd0h is full of bad blocks. It won't do an automatic
fsck and tells me to do it manually. I have worn out two fingers
hitting y and enter with no end in sight! Any help appreciated.
 
Old 01-11-2004, 05:25 PM   #2
jailbait
Guru
 
Registered: Feb 2003
Location: Blue Ridge Mountain
Distribution: Debian Wheezy, Debian Jessie
Posts: 7,527

Rep: Reputation: 177Reputation: 177
"I have worn out two fingers
hitting y and enter with no end in sight! Any help appreciated."

Boot a rescue CD or rescue floppy to run fsck.
Use the -a option and fsck will stop asking you to reply for every error it finds.

------------------------
Steve Stites
 
Old 01-11-2004, 05:33 PM   #3
J_Szucs
Senior Member
 
Registered: Nov 2001
Location: Budapest, Hungary
Distribution: SuSE 6.4-11.3, Dsl linux, FreeBSD 4.3-6.2, Mandrake 8.2, Redhat, UHU, Debian Etch
Posts: 1,126

Rep: Reputation: 58
If you do not have a rescue CD or floppy, I think you can boot up in single user mode (do 'INIT 1'), then you can run fsck manually. (I hope I remember well; it was so long ago I had to do this...)
 
Old 01-11-2004, 06:46 PM   #4
chort
Senior Member
 
Registered: Jul 2003
Location: Silicon Valley, USA
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660

Rep: Reputation: 69
/usr/bin/yes | fsck

IIRC that's how it's done.

By the way, you should mount all your partitions with "softdep". That is similar (and some say, better!) than file system journaling in Linux (RiserFS, EXT3, etc).

Here's an example from my /etc/fstab
Code:
/dev/wd1a / ffs rw,softdep 1 1
/dev/wd1g /home ffs rw,nodev,nosuid,softdep 1 2
/dev/wd1h /tmp ffs rw,nodev,nosuid,softdep 1 2
/dev/wd1f /usr ffs rw,nodev,softdep 1 2
/dev/wd1d /var ffs rw,nodev,nosuid,softdep 1 2
/dev/wd1e /var/log ffs rw,nodev,nosuid,softdep 1 2
/dev/cd0c /mnt/cdrom cd9660 ro,noauto
/dev/fd0c /mnt/floppy msdos rw,noauto
 
Old 01-11-2004, 09:31 PM   #5
mjolnir
Member
 
Registered: Apr 2003
Posts: 665

Original Poster
Rep: Reputation: 68
Thanks for the replies guys. I have run fsck several times but I keep getting a warning when I
reboot about a dirty file system at /home. Something like: DIRECTORY ?: EMPTY BLOCKS
Adjust length(yn). No matter how I answer it I always end up with a message to rerun fsck.
I think I will probably just do a reinstall since I need the practice anyway. I googled softdep
and it looks promising chort thanks for the tip.
 
Old 01-13-2004, 06:35 AM   #6
mjolnir
Member
 
Registered: Apr 2003
Posts: 665

Original Poster
Rep: Reputation: 68
Update

I did a reinstall and things are fine now. I also added "softdep" to my fstab.
A lot to learn about this OS but I think it will be worth it.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
bad blocks bong.mau Linux - General 1 11-16-2005 02:17 PM
ReiserFS with bad blocks bruce ford Linux - Software 2 07-23-2005 04:15 AM
How to do a bad blocks check yelo Linux - General 2 04-02-2004 10:14 PM
RedHat 9 with Bad blocks? chrismc2 Red Hat 3 01-22-2004 07:48 AM
e2fsck and bad blocks MunterMan Linux - Software 0 11-23-2003 09:58 AM


All times are GMT -5. The time now is 05:14 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration