DaemonForums  

Go Back   DaemonForums > OpenBSD > OpenBSD General

OpenBSD General Other questions regarding OpenBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 5th May 2008
Sunnz's Avatar
Sunnz Sunnz is offline
Real Name: I don't have real time
Just a computer user...
 
Join Date: May 2008
Location: See Google Maps
Posts: 101
Default Media error... are there any way to help this?

I have the following partitions on /dev/sd0:

Code:
$ mount | grep sd0
/dev/sd0a on / type ffs (local, noatime, softdep)
/dev/sd0d on /usr type ffs (local, noatime, nodev, softdep)
And I am constantly getting errors from it in xconsole, for a few days:

Code:
sd0(umass0:1:0): Check Condition (error 0x70) on opcode 0x28
    SENSE KEY: Media Error
         INFO: 0x14dce8 (VALID flag on)
     ASC/ASCQ: Medium Format Corrupted
sd0(umass0:1:0): Check Condition (error 0x70) on opcode 0x28
    SENSE KEY: Media Error
         INFO: 0x14dce8 (VALID flag on)
     ASC/ASCQ: Medium Format Corrupted
The computer is still running, but I am afraid that it won't boot up next time it had to be turn off or reboot.

sd0 is 1 Gig in size by the way, so I've found myself an old CompactFlash (sd1) card in a used camera that is also 1 Gig... which I think my computer can boot from.

So I did a `fdisk -iy sd1`, and then create appropiate disk labels in sd1, newfs the two partitions, and did a dump and restore from sd0:

Code:
# /sbin/dump -0au -f /backup/root /dev/rsd0a                                   
  DUMP: Date of this level 0 dump: Sun May  4 21:51:08 2008
  DUMP: Date of last level 0 dump: the epoch
  DUMP: Dumping /dev/rsd0a (/) to /backup/root
  DUMP: mapping (Pass I) [regular files]
  DUMP: mapping (Pass II) [directories]
  DUMP: estimated 44155 tape blocks.
  DUMP: Volume 1 started at: Sun May  4 21:51:09 2008
  DUMP: dumping (Pass III) [directories]
  DUMP: dumping (Pass IV) [regular files]
  DUMP: read error from /dev/rsd0a: Input/output error: [block 30402]: count=10240
  DUMP: read error from /dev/rsd0a: Input/output error: [block 30432]: count=5120
  DUMP: read error from /dev/rsd0a: Input/output error: [sector 30434]: count=512
  DUMP: read error from /dev/rsd0a: Input/output error: [sector 30410]: count=512
  DUMP: read error from /dev/rsd0a: Input/output error: [sector 30418]: count=512
  DUMP: read error from /dev/rsd0a: Input/output error: [block 30464]: count=9216
  DUMP: read error from /dev/rsd0a: Input/output error: [sector 30466]: count=512
  DUMP: read error from /dev/rsd0a: Input/output error: [block 30562]: count=10240
  DUMP: read error from /dev/rsd0a: Input/output error: [sector 30563]: count=512
  DUMP: read error from /dev/rsd0a: Input/output error: [sector 30578]: count=512
  DUMP: 44825 tape blocks on 1 volume
  DUMP: Date of this level 0 dump: Sun May  4 21:51:08 2008
  DUMP: Volume 1 completed at: Sun May  4 21:51:25 2008
  DUMP: Volume 1 took 0:00:16
  DUMP: Volume 1 transfer rate: 2801 KB/s
  DUMP: Date this dump completed:  Sun May  4 21:51:25 2008
  DUMP: Average transfer rate: 2801 KB/s
  DUMP: level 0 dump on Sun May  4 21:51:08 2008
  DUMP: Closing /backup/root
  DUMP: DUMP IS DONE
# /sbin/dump -0au -f /backup/usr /dev/rsd0d                                    
  DUMP: Date of this level 0 dump: Sun May  4 21:51:40 2008
  DUMP: Date of last level 0 dump: the epoch
  DUMP: Dumping /dev/rsd0d (/usr) to /backup/usr
  DUMP: mapping (Pass I) [regular files]
  DUMP: read error from /dev/rsd0d: Input/output error: [block 414720]: count=16384
  DUMP: read error from /dev/rsd0d: Input/output error: [sector 414733]: count=512
  DUMP: read error from /dev/rsd0d: Input/output error: [block 829376]: count=16384
  DUMP: read error from /dev/rsd0d: Input/output error: [sector 829401]: count=512
  DUMP: read error from /dev/rsd0d: Input/output error: [sector 829402]: count=512
  DUMP: read error from /dev/rsd0d: Input/output error: [block 1244288]: count=16384
  DUMP: read error from /dev/rsd0d: Input/output error: [sector 1244296]: count=512
  DUMP: read error from /dev/rsd0d: Input/output error: [sector 1244312]: count=512
  DUMP: mapping (Pass II) [directories]
  DUMP: estimated 572715 tape blocks.
  DUMP: Volume 1 started at: Sun May  4 21:51:42 2008
  DUMP: dumping (Pass III) [directories]
  DUMP: read error from /dev/rsd0d: Input/output error: [block 1244288]: count=16384
  DUMP: read error from /dev/rsd0d: Input/output error: [sector 1244296]: count=512
  DUMP: read error from /dev/rsd0d: Input/output error: [sector 1244312]: count=512
  DUMP: dumping (Pass IV) [regular files]
  DUMP: read error from /dev/rsd0d: Input/output error: [block 1244288]: count=16384
  DUMP: read error from /dev/rsd0d: Input/output error: [sector 1244296]: count=512
  DUMP: read error from /dev/rsd0d: Input/output error: [sector 1244312]: count=512
  DUMP: 586893 tape blocks on 1 volume
  DUMP: Date of this level 0 dump: Sun May  4 21:51:40 2008
  DUMP: Volume 1 completed at: Sun May  4 21:55:22 2008
  DUMP: Volume 1 took 0:03:40
  DUMP: Volume 1 transfer rate: 2667 KB/s
  DUMP: Date this dump completed:  Sun May  4 21:55:22 2008
  DUMP: Average transfer rate: 2667 KB/s
  DUMP: level 0 dump on Sun May  4 21:51:40 2008
  DUMP: Closing /backup/usr
  DUMP: DUMP IS DONE
# mount /dev/sd1a /mnt/root/                                          
# mount /dev/sd1d /mnt/usr                                            
# cd /mnt/root/                                                                
# restore -rs 1 -f /backup/root                                                
expected next file 5893, got 5880
# cd /mnt/usr                                                                  
# restore -rs 1 -f /backup/usr                                                 
./xobj/data/xkbdata/keycodes/sgi: (inode 78945) not found on tape
./xobj/data/xkbdata/keycodes/digital: (inode 78947) not found on tape
./xobj/xserver/GL/mesa/main/mm.h: (inode 78880) not found on tape
./xobj/xserver/GL/mesa/main/mtypes.h: (inode 78881) not found on tape
./xobj/xserver/GL/mesa/main/occlude.h: (inode 78882) not found on tape
./xobj/xserver/GL/mesa/main/pixel.h: (inode 78883) not found on tape
./xobj/xserver/GL/mesa/swrast/s_blit.c: (inode 78944) not found on tape
./xobj/xserver/GL/mesa/swrast/s_buffers.c: (inode 78946) not found on tape


expected next file 108483, got 108482
expected next file 108485, got 108484
So yea I feel panic at this stage, the boot partition doesn't seem to be fully back up... as far as I recall though, /usr/xobj are there because I had recompiled Xorg in the past, it is just source code and since it is already compiled, those xobj errors can be safely ignore for now, for the purpose of being able to reboot into the Compact Flash anyway?

Regardless, I still proceed to install boot blocks in the new root:

Code:
# cd /mnt/root/                                                                
# /usr/mdec/installboot -v /mnt/root/boot /usr/mdec/biosboot sd1               
boot: /mnt/root/boot
proto: /usr/mdec/biosboot
device: /dev/rsd1c
/usr/mdec/biosboot: entry point 0
proto bootblock size 512
/mnt/root/boot is 3 blocks x 16384 bytes
fs block shift 2; part offset 63; inode block 24, offset 4904
using MBR partition 3: type 166 (0xa6) offset 63 (0x3f)
# umount /dev/sd1d                                                             
# umount /dev/sd1a
Can anyone see what might I have missed? Or if this new CompactFlash will be able to boot at all? (Assuming my computer's hardware/BIOS supports booting from USB Flash devices, I plan to attach the CompactFlash to a USB adapter.)

BTW sd0 is not the only disk I have on the computer, so it is not OpenBSD installed on just 1 GB of space... the full output of mount is as follows:

Code:
/dev/sd0a on / type ffs (local, noatime, softdep)
/dev/wd1h on /backup type ffs (local, nodev, noexec, nosuid, softdep)
/dev/wd0h on /home type ffs (local, nodev, nosuid, softdep)
/dev/wd2j on /img type ffs (local, nodev, noexec, nosuid, softdep)
/dev/wd2d on /tmp type ffs (local, noatime, nodev, noexec, nosuid, softdep)
/dev/sd0d on /usr type ffs (local, noatime, nodev, softdep)
/dev/wd2i on /usr/local type ffs (local, noatime, nodev, nosuid, softdep)
/dev/wd2f on /usr/ports type ffs (local, noatime, nodev, nosuid, softdep)
/dev/wd2h on /usr/src type ffs (local, noatime, nodev, nosuid, softdep)
/dev/wd2e on /var type ffs (local, nodev, nosuid, softdep)
/dev/wd4a on /usr/X11R6 type ffs (local, nodev)
/dev/wd5a on /var/www/htdocs type ffs (local, nodev, noexec, nosuid, synchronous, softdep)
/dev/wd3a on /usr/obj type ffs (asynchronous, local)
/dev/wd6a on /var/squid/logs type ffs (asynchronous, local, nodev, noexec, nosuid)
mfs:32150 on /tmp/you/ type mfs (asynchronous, local, size=1060227 512-blocks)
/dev/wd7a on /var/squid/cache type ffs (local, nodev, noexec, nosuid)
Reply With Quote
Reply

Thread Tools
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
hald(1) and nautilus(1) does not automount media vermaden FreeBSD Ports and Packages 3 2nd November 2009 06:17 PM
Popcorn Hour Media Box DraconianTimes Off-Topic 1 9th April 2009 06:18 PM
Mount removable Media Glitch shep FreeBSD General 3 14th February 2009 10:16 PM


All times are GMT. The time now is 08:38 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick