Difference between revisions of "User:Trogod/System0Maintai"

From MythTV Official Wiki
Jump to: navigation, search
(13 May 2011)
(13 May 2011)
Line 123: Line 123:
 
  Sector size (logical/physical): 512B/512B
 
  Sector size (logical/physical): 512B/512B
 
  Partition Table: msdos  
 
  Partition Table: msdos  
 
+
 
  Number  Start  End    Size    Type    File system    Flags
 
  Number  Start  End    Size    Type    File system    Flags
 
   1      32.3kB  1287MB  1287MB  primary  ext2            boot
 
   1      32.3kB  1287MB  1287MB  primary  ext2            boot
Line 135: Line 135:
 
  Sector size (logical/physical): 512B/512B
 
  Sector size (logical/physical): 512B/512B
 
  Partition Table: gpt  
 
  Partition Table: gpt  
 
+
 
  Number  Start  End    Size    File system  Name  Flags
 
  Number  Start  End    Size    File system  Name  Flags
 
   1      17.4kB  1000GB  1000GB  jfs
 
   1      17.4kB  1000GB  1000GB  jfs
 +
 
 
   
 
   
 
 
  Warning: Unable to open /dev/sr0 read-write (Read-only file system).  /dev/sr0
 
  Warning: Unable to open /dev/sr0 read-write (Read-only file system).  /dev/sr0
 
  vhas been opened read-only.
 
  vhas been opened read-only.

Revision as of 02:57, 13 May 2011

disk repair

3 May 2011

booted from live DVD for mythbuntu

ubuntu@ubuntu:~$ sudo parted -l
Model: ATA SAMSUNG SP0822N (scsi)
Disk /dev/sda: 80.1GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos  

Number  Start   End     Size    Type     File system     Flags
 1      32.3kB  1287MB  1287MB  primary  ext2            boot
 2      1287MB  10.3GB  9052MB  primary  linux-swap(v1)
 3      10.3GB  26.5GB  16.1GB  primary  ext3
 4      26.5GB  47.9GB  21.5GB  primary  ext3


Model: ATA Hitachi HDT72101 (scsi)
Disk /dev/sdb: 1000GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number  Start   End     Size    File system  Name  Flags
 1      17.4kB  1000GB  1000GB  jfs 
 

Warning: Unable to open /dev/sr0 read-write (Read-only file system).  /dev/sr0
has been opened read-only.
Error: /dev/sr0: unrecognised disk label  
 

and then I ran fsck:

ubuntu@ubuntu:~$ sudo fsck.jfs -n /dev/sdb1
fsck.jfs version 1.1.12, 24-Aug-2007
processing started: 5/4/2011 3.21.10
The current device is:  /dev/sdb1
Block size in bytes:  4096
Filesystem size in blocks:  244190429
**Phase 1 - Check Blocks, Files/Directories, and  Directory Entries
**Phase 2 - Count links
**Phase 3 - Duplicate Block Rescan and Directory Connectedness
**Phase 4 - Report Problems
**Phase 5 - Check Connectivity
**Phase 6 - Perform Approved Corrections
**Phase 7 - Verify File/Directory Allocation Maps
Errors detected in the Fileset File/Directory Allocation Map control information. (F)
Errors detected in the Fileset File/Directory Allocation Map. (F)
**Phase 8 - Verify Disk Allocation Maps
Incorrect data detected in disk allocation control structures.
976761716 kilobytes total disk space.
   146077 kilobytes in 66698 directories.
964783365 kilobytes in 413547 user files.
       20 kilobytes in extended attributes
   513312 kilobytes reserved for system use.
 11611096 kilobytes are available for use.
File system checked READ ONLY.
Filesystem is dirty.
Filesystem is dirty but is marked clean.  In its present state,
the results of accessing /dev/sdb1 (except by this utility) are undefined.
ubuntu@ubuntu:~$

and then I tried to fix it

ubuntu@ubuntu:~$ sudo fsck.jfs -f /dev/sdb1
fsck.jfs version 1.1.12, 24-Aug-2007
processing started: 5/4/2011 3.29.15
The current device is:  /dev/sdb1
Block size in bytes:  4096
Filesystem size in blocks:  244190429
**Phase 0 - Replay Journal Log
**Phase 1 - Check Blocks, Files/Directories, and  Directory Entries
**Phase 2 - Count links
**Phase 3 - Duplicate Block Rescan and Directory Connectedness
**Phase 4 - Report Problems
**Phase 5 - Check Connectivity
**Phase 6 - Perform Approved Corrections
**Phase 7 - Rebuild File/Directory Allocation Maps
**Phase 8 - Rebuild Disk Allocation Maps
976761716 kilobytes total disk space.
   146077 kilobytes in 66698 directories.
964783365 kilobytes in 413547 user files.
       20 kilobytes in extended attributes
   506992 kilobytes reserved for system use.
 11617416 kilobytes are available for use.
Filesystem is clean.

and ran it again, just to check...

ubuntu@ubuntu:~$ sudo fsck.jfs -n /dev/sdb1
fsck.jfs version 1.1.12, 24-Aug-2007
processing started: 5/4/2011 3.32.51
The current device is:  /dev/sdb1
Block size in bytes:  4096
Filesystem size in blocks:  244190429
**Phase 1 - Check Blocks, Files/Directories, and  Directory Entries
**Phase 2 - Count links
**Phase 3 - Duplicate Block Rescan and Directory Connectedness
**Phase 4 - Report Problems
**Phase 5 - Check Connectivity
**Phase 6 - Perform Approved Corrections
**Phase 7 - Verify File/Directory Allocation Maps
**Phase 8 - Verify Disk Allocation Maps
976761716 kilobytes total disk space.
   146077 kilobytes in 66698 directories.
964783365 kilobytes in 413547 user files.
       20 kilobytes in extended attributes
   506992 kilobytes reserved for system use.
 11617416 kilobytes are available for use.
File system checked READ ONLY.
Filesystem is clean.
ubuntu@ubuntu:~$


13 May 2011

There was, apparently, a power failure, today. My wife booted up the System0, but it didn't boot properly. There was some text on the screen with some error messages about mounting filesystems. I should've paid closer attention to those messages. Instead, I went straight to trying to repair the filesystems. I booted from live DVD for mythbuntu

ubuntu@ubuntu:~$ sudo parted -l                                                        
Model: ATA SAMSUNG SP0822N (scsi)
Disk /dev/sda: 80.1GB
Sector size (logical/physical): 512B/512B
Partition Table: msdos 

Number  Start   End     Size    Type     File system     Flags
 1      32.3kB  1287MB  1287MB  primary  ext2            boot
 2      1287MB  10.3GB  9052MB  primary  linux-swap(v1)
 3      10.3GB  26.5GB  16.1GB  primary  ext3
 4      26.5GB  47.9GB  21.5GB  primary  ext3


Model: ATA Hitachi HDT72101 (scsi)
Disk /dev/sdb: 1000GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt 

Number  Start   End     Size    File system  Name  Flags
 1      17.4kB  1000GB  1000GB  jfs
 

Warning: Unable to open /dev/sr0 read-write (Read-only file system).  /dev/sr0
vhas been opened read-only.
vError: /dev/sr0: unrecognised disk label                                  

then I checked for errors

ubuntu@ubuntu:~$ sudo fsck.jfs -n /dev/sdb1
fsck.jfs version 1.1.12, 24-Aug-2007
processing started: 5/13/2011 2.43.16
The current device is:  /dev/sdb1
Block size in bytes:  4096
Filesystem size in blocks:  244190429
**Phase 1 - Check Blocks, Files/Directories, and  Directory Entries
**Phase 2 - Count links
**Phase 3 - Duplicate Block Rescan and Directory Connectedness
**Phase 4 - Report Problems
**Phase 5 - Check Connectivity
**Phase 6 - Perform Approved Corrections
**Phase 7 - Verify File/Directory Allocation Maps
Errors detected in the Fileset File/Directory Allocation Map control information. (F)
Errors detected in the Fileset File/Directory Allocation Map. (F)
**Phase 8 - Verify Disk Allocation Maps
Incorrect data detected in disk allocation control structures.
976761716 kilobytes total disk space.
   146089 kilobytes in 66698 directories.
953111998 kilobytes in 413620 user files.
       20 kilobytes in extended attributes
   507043 kilobytes reserved for system use.
 23288744 kilobytes are available for use.
File system checked READ ONLY.
Filesystem is dirty.
Filesystem is dirty but is marked clean.  In its present state,
the results of accessing /dev/sdb1 (except by this utility) are undefined. 

then I attempted repair

ubuntu@ubuntu:~$ time sudo fsck.jfs -f /dev/sdb1
fsck.jfs version 1.1.12, 24-Aug-2007
processing started: 5/13/2011 2.45.33
The current device is:  /dev/sdb1
Block size in bytes:  4096
Filesystem size in blocks:  244190429
**Phase 0 - Replay Journal Log
**Phase 1 - Check Blocks, Files/Directories, and  Directory Entries
**Phase 2 - Count links
**Phase 3 - Duplicate Block Rescan and Directory Connectedness
**Phase 4 - Report Problems
**Phase 5 - Check Connectivity
**Phase 6 - Perform Approved Corrections
**Phase 7 - Rebuild File/Directory Allocation Maps
**Phase 8 - Rebuild Disk Allocation Maps
976761716 kilobytes total disk space.
   146089 kilobytes in 66698 directories.
953111998 kilobytes in 413620 user files.
       20 kilobytes in extended attributes
   506995 kilobytes reserved for system use.
 23288792 kilobytes are available for use.
Filesystem is clean.

real	1m51.009s
user	0m2.770s
sys	0m2.390s


ubuntu@ubuntu:~$ sudo fsck.jfs -n /dev/sdb1     
fsck.jfs version 1.1.12, 24-Aug-2007
processing started: 5/13/2011 2.48.53
The current device is:  /dev/sdb1
Block size in bytes:  4096
Filesystem size in blocks:  244190429
**Phase 1 - Check Blocks, Files/Directories, and  Directory Entries
**Phase 2 - Count links
**Phase 3 - Duplicate Block Rescan and Directory Connectedness
**Phase 4 - Report Problems
**Phase 5 - Check Connectivity
**Phase 6 - Perform Approved Corrections
**Phase 7 - Verify File/Directory Allocation Maps
**Phase 8 - Verify Disk Allocation Maps
976761716 kilobytes total disk space.
   146089 kilobytes in 66698 directories.
953111998 kilobytes in 413620 user files.
       20 kilobytes in extended attributes
   506995 kilobytes reserved for system use.
 23288792 kilobytes are available for use.
File system checked READ ONLY.
Filesystem is clean.
ubuntu@ubuntu:~$ sudo fsck.ext2 -p /dev/sda1
/dev/sda1 was not cleanly unmounted, check forced.
/dev/sda1: 216/628320 files (1.4% non-contiguous), 116856/1256416 blocks
ubuntu@ubuntu:~$ sudo fsck.ext2 -pv /dev/sda1
/dev/sda1: clean, 216/628320 files, 116856/1256416 blocks

ubuntu@ubuntu:~$ sudo fsck.ext2 -pv /dev/sda2
/dev/sda2 is mounted.  

WARNING!!!  The filesystem is mounted.   If you continue you ***WILL***
cause ***SEVERE*** filesystem damage.

Do you really want to continue (y/n)? no 

check aborted.

oh, yeah - that's the swap partititon. oops....

ubuntu@ubuntu:~$ sudo fsck.ext2 -pv /dev/sda3
/dev/sda3: clean, 131773/983488 files, 790678/3933916 blocks
ubuntu@ubuntu:~$ sudo fsck.ext2 -pv /dev/sda4
/dev/sda4: clean, 1801/1313280 files, 218299/5242880 blocks

So both my /storage drive and my boot partition needed repair...