Re: hard disk error , run fsck manually
hi sirs, thanks to all who give me good helps and hints on my problem. but i afraid that i really need to replace hard disk. i try David Wolfskill's last help but fialed. i mean i could not re-allocate hard disk back. but that is /home partion. my other partion such as /usr /var / are still clean. at this time i simply want to backup /var ( actually is mysql data), /etc and /usr/local/www/data, should only dump enough for backup ? once again thanks so much to all of you. --- David Wolfskill [EMAIL PROTECTED] wrote: Date: Sun, 29 Jun 2003 00:17:27 -0700 (PDT) From: manee [EMAIL PROTECTED] Subject: Re: hard disk error , run fsck manually To: David Wolfskill [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] i got , after running fsck -p THE FOLLOWING FILE SYSTEM HAD AN UNEXPECTED INCONSISTENCY: /dev/ad0s2g (/home) so that i ran fsck OK. and the following messages come Phase 1 ad0s2g: hard error reading fsbn 98971950 of 21364912-21365023( ad0s2 nb 98971950; cn 6160 tn 183 sn 21) status=59 error=40; CAN NOT READ: BLK 21364912 continue? [yn] i had to hit y and a few messages simila to the above popped up and before Phase 2 started, i got FILE SYSTEM STILL DIRTY PLEASE RERUN fsck MANULLY. Well, you had data on your disk that is no longer readable. If you are lucky, you may be able to get the disk to re-allocate some of the bad sectors. If there were more than about 6 or 8 of these, though, I suspect that you will need to replace the disk soon enough that it is not worth your time. To try to get the disk to re-allocate block 21364912, I would do: dd bs=512 count=1 if=/dev/zero of=/dev/ad0s2g seek=21364912 Note that this has a very high probability of ensuring that whatever data is now written to block 21364912 is different from what it had been; its only saving grace is that it is data that may possibly be readable Once you have done this for each block that was reported as CAN NOT READ: BLK , then re-run fsck. Because things are almost assuredly going to be inconsistent, you may wish to merely do fsck -y An alternate, and possibly faster approach would be to skip the fsck altogether, and just use newfs. Of course, that will obliterate any data you once had on the file system, and you would then need to reconstruct the data -- from backups or other sources. But then, you may well need to do that anyway, especially for files affected by the bad blocks. at this ponit i had to edit /etc/fstab and put /home as read only in order to bring system up and running. Seems that you have a disk drive that is getting bad enough that its continued usefulness is in question. with best regards, = ÁÒ¹Õ http://www.thai-aec.org __ Do you Yahoo!? SBC Yahoo! DSL - Now only $29.95 per month! http://sbc.yahoo.com ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
Re: hard disk error , run fsck manually
hi sirs, thanks for your time indeed. --- David Wolfskill [EMAIL PROTECTED] wrote: Reboot your system. During the 10-second spinning propeller count-down, press the space bar once. You should see the prompt boot At that point, type boot -s and press Enter. This will enable you to boot into single-user mode. The machine should show the usual device probes, but instead of mounting filesystems and starting daemons, you will get a prompt like: Enter full pathname of shell or RETURN for /bin/sh: At that point, press Enter. The prompt should read # This means that you are in single-user mode; you are running as root. At this point, I would (first) try fsck -p reboot That is, do the fsck in preen mode; if that works OK, just reboot. If that does not automatically reboot, you have problems that fsck -p cannot fix easily. In that case, try as expected, i need to run fsck fsck and answer the questions as best you can. If you are (finally!) able to get through that OK, try i got , after running fsck -p THE FOLLOWING FILE SYSTEM HAD AN UNEXPECTED INCONSISTENCY: /dev/ad0s2g (/home) so that i ran fsck and the following messages come Phase 1 ad0s2g: hard error reading fsbn 98971950 of 21364912-21365023( ad0s2 nb 98971950; cn 6160 tn 183 sn 21) status=59 error=40; CAN NOT READ: BLK 21364912 continue? [yn] i had to hit y and a few messages simila to the above popped up and before Phase 2 started, i got FILE SYSTEM STILL DIRTY PLEASE RERUN fsck MANULLY. at this ponit i had to edit /etc/fstab and put /home as read only in order to bring system up and running. reboot and see how far you ge. Peace, david -- David H. Wolfskill[EMAIL PROTECTED] Based on what I have seen to date, the use of Microsoft products is not consistent with reliability. I recommend FreeBSD for reliable systems. once again please cc to me with best regards, = ÁÒ¹Õ http://www.thai-aec.org __ Do you Yahoo!? SBC Yahoo! DSL - Now only $29.95 per month! http://sbc.yahoo.com ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]
hard disk error , run fsck manually
hi sirs, i face problem of hard disk error because of the power downed during using the machine. once the power is coming, my machine stuck at file system is still dirty please run fsck manually. the partion that is dirty is /dev/ad0s2g, a home partion one. i did run fsck /dev/ad0s2g several times but still get the same message. what i decided to do was that to edit /etc/fstab and put read only option for /dev/ad0s2g and exited a single mode. i got a message said that /home was not dismount, as you see in the attachment. up to this point, only root that can log in. my question is that are there any method to recover an fsck error during boot time? please cc to me since i do not a member of the list. with best regards, = ÁÒ¹Õ http://www.thai-aec.org __ Do you Yahoo!? SBC Yahoo! DSL - Now only $29.95 per month! http://sbc.yahoo.comCopyright (c) 1992-2003 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved. FreeBSD 4.8-STABLE #2: Sun Jun 1 18:59:28 ICT 2003 [EMAIL PROTECTED]:/usr/obj/usr/src/sys/Bank Timecounter i8254 frequency 1193182 Hz CPU: Intel(R) Celeron(TM) CPU1100MHz (1102.51-MHz 686-class CPU) Origin = GenuineIntel Id = 0x6b1 Stepping = 1 Features=0x383fbffFPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,MMX,FXSR,SSE real memory = 125763584 (122816K bytes) config di sn0 config di lnc0 config di ie0 config di fe0 config di cs0 config q avail memory = 118005760 (115240K bytes) Preloaded elf kernel kernel at 0xc0447000. Preloaded userconfig_script /boot/kernel.conf at 0xc044709c. Preloaded elf module snd_via8233.ko at 0xc04470ec. Preloaded elf module snd_pcm.ko at 0xc0447190. Preloaded elf module snd_via82c686.ko at 0xc0447230. Pentium Pro MTRR support enabled md0: Malloc disk Using $PIR table, 6 entries at 0xc00fdd40 npx0: math processor on motherboard npx0: INT 16 interface pcib0: Host to PCI bridge on motherboard pci0: PCI bus on pcib0 agp0: VIA Generic host to PCI bridge mem 0xe000-0xe3ff at device 0.0 on pci0 pcib1: PCI to PCI bridge (vendor=1106 device=8601) at device 1.0 on pci0 pci1: PCI bus on pcib1 pci1: Trident model 8500 VGA-compatible display device at 0.0 irq 10 isab0: VIA 82C686 PCI-ISA bridge at device 7.0 on pci0 isa0: ISA bus on isab0 atapci0: VIA 82C686 ATA100 controller port 0xd000-0xd00f at device 7.1 on pci0 ata0: at 0x1f0 irq 14 on atapci0 ata1: at 0x170 irq 15 on atapci0 uhci0: VIA 83C572 USB controller port 0xd400-0xd41f irq 9 at device 7.2 on pci0 usb0: VIA 83C572 USB controller on uhci0 usb0: USB revision 1.0 uhub0: VIA UHCI root hub, class 9/0, rev 1.00/1.00, addr 1 uhub0: 2 ports with 2 removable, self powered pci0: unknown card (vendor=0x1106, dev=0x3057) at 7.4 pcm0: VIA VT82C686A port 0xe400-0xe403,0xe000-0xe003,0xdc00-0xdcff irq 11 at device 7.5 on pci0 pcm0: Avance Logic ALC200/200P ac97 codec ed0: NE2000 PCI Ethernet (RealTek 8029) port 0xe800-0xe81f irq 11 at device 10.0 on pci0 ed0: address 00:00:21:2d:ad:f7, type NE2000 (16 bit) orm0: Option ROM at iomem 0xc-0xcbfff on isa0 fdc0: NEC 72065B or clone at port 0x3f0-0x3f5,0x3f7 irq 6 drq 2 on isa0 fdc0: FIFO enabled, 8 bytes threshold fd0: 1440-KB 3.5 drive on fdc0 drive 0 atkbdc0: Keyboard controller (i8042) at port 0x60,0x64 on isa0 atkbd0: AT Keyboard flags 0x1 irq 1 on atkbdc0 kbd0 at atkbd0 psm0: PS/2 Mouse irq 12 on atkbdc0 psm0: model IntelliMouse, device ID 3 vga0: Generic ISA VGA at port 0x3c0-0x3df iomem 0xa-0xb on isa0 sc0: System console at flags 0x100 on isa0 sc0: VGA 16 virtual consoles, flags=0x300 sio0 at port 0x3f8-0x3ff irq 4 flags 0x10 on isa0 sio0: type 16550A sio1 at port 0x2f8-0x2ff irq 3 on isa0 sio1: type 16550A ppc0: Parallel port at port 0x378-0x37f irq 7 on isa0 ppc0: SMC-like chipset (ECP/EPP/PS2/NIBBLE) in COMPATIBLE mode ppc0: FIFO with 16/16/8 bytes threshold plip0: PLIP network interface on ppbus0 lpt0: Printer on ppbus0 lpt0: Interrupt-driven port ppi0: Parallel I/O on ppbus0 IP packet filtering initialized, divert enabled, rule-based forwarding enabled, default to deny, logging disabled ad0: 38166MB ST340810A [77545/16/63] at ata0-master UDMA100 acd0: CDROM LTN526 at ata1-slave PIO4 Mounting root from ufs:/dev/ad0s2a ad0s2g: hard error reading fsbn 98971886 of 21364912-21365023 (ad0s2 bn 98971886; cn 6160 tn 182 sn 20) trying PIO mode ad0: DMA problem fallback to PIO mode ad0: DMA problem fallback to PIO mode ad0: DMA problem fallback to PIO mode ad0: DMA problem fallback to PIO mode ad0s2g: hard error reading fsbn 98971950 of 21364912-21365023 (ad0s2 bn 98971950; cn 6160 tn 183 sn 21) status=59 error=40 WARNING: /home was not properly dismounted dmesg ended here here is /etc/fstab, editted one # DeviceMountpoint FStype Options DumpPass# /dev/ad0s2b noneswapsw 0 0
Re: hard disk error , run fsck manually
On Saturday 28 June 2003 07:17 pm, manee wrote: hi sirs, i face problem of hard disk error because of the power downed during using the machine. once the power is coming, my machine stuck at file system is still dirty please run fsck manually. the partion that is dirty is /dev/ad0s2g, a home partion one. i did run fsck /dev/ad0s2g several times but still get the same message. what i decided to do was that to edit /etc/fstab and put read only option for /dev/ad0s2g and exited a single mode. i got a message said that /home was not dismount, as you see in the attachment. up to this point, only root that can log in. my question is that are there any method to recover an fsck error during boot time? please cc to me since i do not a member of the list. You need to do something like fsck -y from single user mode. The fs has to be unmounted to fix it. Kent -- Kent Stewart Richland, WA http://users.owt.com/kstewart/index.html ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to [EMAIL PROTECTED]