JFSファイルシステムの修復
今日仕事から帰ってきたらここ数日また気になっていたCPUの熱のせいかPCがフリーズしていた。
なにも出来ないのでハードリセットかけると、データ保存用のHDDがmountできない。
ということでJFSファイルシステムの修復を行ったのでメモ。
とりあえずdmesgを見てみるがよく分からない。
# dmesg |tail [ 3047.460066] ata1.00: detaching (SCSI 0:0:0:0) [ 3047.460287] sd 0:0:0:0: [sda] Synchronizing SCSI cache [ 3047.460700] sd 0:0:0:0: [sda] Result: hostbyte=DID_BAD_TARGET driverbyte=DRIVER_OK,SUGGEST_OK [ 3047.460704] sd 0:0:0:0: [sda] Stopping disk [ 3047.460711] sd 0:0:0:0: [sda] START_STOP FAILED [ 3047.460712] sd 0:0:0:0: [sda] Result: hostbyte=DID_BAD_TARGET driverbyte=DRIVER_OK,SUGGEST_OK [ 3050.381083] ata1: exception Emask 0x10 SAct 0x0 SErr 0x4040000 action 0xe frozen [ 3050.381088] ata1: irq_stat 0x00000040, connection status changed [ 3050.381091] ata1: SError: { CommWake DevExch } [ 3050.381096] ata1: hard resetting link
パーティションは見えている。
# fdisk -l /dev/sda Disk /dev/sda: 1000.2 GB, 1000204886016 bytes 255 heads, 63 sectors/track, 121601 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0x6ac3085b Device Boot Start End Blocks Id System /dev/sda1 1 121601 976760001 83 Linux
jfs_fsckと言うコマンドで修復できるのだけどパッケージが良く分からない。
とりあえずJFS関係で必要そうなのをインストールしてみる
# aptitude install jfsutils
チェックをしてみると、あきらかにエラーが出ている。
# jfs_fsck -n /dev/sda1 jfs_fsck version 1.1.12, 24-Aug-2007 processing started: 8/20/2009 19.32.6 The current device is: /dev/sda1 Block size in bytes: 4096 Filesystem size in blocks: 244190000 **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. 976760000 kilobytes total disk space. 10091 kilobytes in 1015 directories. 974728464 kilobytes in 87633 user files. 0 kilobytes in extended attributes 208075 kilobytes reserved for system use. 1833552 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/sda1 (except by this utility) are undefined.
修復を試みる。
# jfs_fsck -v -f /dev/sda1 jfs_fsck version 1.1.12, 24-Aug-2007 processing started: 8/20/2009 19.34.17 The current device is: /dev/sda1 Open(...READ/WRITE EXCLUSIVE...) returned rc = 0 Primary superblock is valid. The type of file system for the device is JFS. Block size in bytes: 4096 Filesystem size in blocks: 244190000 **Phase 0 - Replay Journal Log LOGREDO: Allocating for ReDoPage: (d) 4096 bytes LOGREDO: Allocating for NoDoFile: (d) 4096 bytes LOGREDO: Allocating for BMap: (d) 502032 bytes LOGREDO: Allocating for IMap: (d) 18464 bytes LOGREDO: Allocating for IMap: (d) 2048 bytes LOGREDO: Allocating for IMap: (d) 2048 bytes LOGREDO: Allocating for IMap: (d) 2048 bytes LOGREDO: Allocating for IMap: (d) 2048 bytes LOGREDO: Allocating for IMap: (d) 2048 bytes LOGREDO: Allocating for IMap: (d) 2048 bytes LOGREDO: Allocating for IMap: (d) 2048 bytes LOGREDO: Allocating for IMap: (d) 2048 bytes LOGREDO: Allocating for IMap: (d) 2048 bytes LOGREDO: Allocating for IMap: (d) 2048 bytes 〜略〜 LOGREDO: Beginning to update the Inode Allocation Map. LOGREDO: Done updating the Inode Allocation Map. LOGREDO: Beginning to update the Block Map. LOGREDO: Done updating the Block Map. LOGREDO: End of log found at logend = 0x0164afe8 LOGREDO: Synch point record number: 0x01637898 LOGREDO: Synch point record address: 0x01622fc4 LOGREDO: Number of log records: (d) 1602 LOGREDO: Number of Do blocks: (d) 202 LOGREDO: Number of NoDo blocks: (d) 0 logredo returned rc = 0 **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 Filesystem Summary: Blocks in use for inodes: 12020 Inode count: 96160 File count: 87633 Directory count: 1015 Block count: 244190000 Free block count: 458736 976760000 kilobytes total disk space. 10091 kilobytes in 1015 directories. 974728464 kilobytes in 87633 user files. 0 kilobytes in extended attributes 0 kilobytes in access control lists 206683 kilobytes reserved for system use. 1834944 kilobytes are available for use. Filesystem is clean. All observed inconsistencies have been repaired. Filesystem has been marked clean. **** Filesystem was modified. **** processing terminated: 8/20/2009 19:35:15 with return code: 0 exit code: 0.
再度チェックすると問題無し。
# jfs_fsck -n /dev/sda1 jfs_fsck version 1.1.12, 24-Aug-2007 processing started: 8/20/2009 19.35.25 The current device is: /dev/sda1 Block size in bytes: 4096 Filesystem size in blocks: 244190000 **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 976760000 kilobytes total disk space. 10091 kilobytes in 1015 directories. 974728464 kilobytes in 87633 user files. 0 kilobytes in extended attributes 206683 kilobytes reserved for system use. 1834944 kilobytes are available for use. File system checked READ ONLY. Filesystem is clean.
マウントが成功してデータも無事。
よかった。
というわけで、金欠だけど急いでAmazonでCPUクーラを購入。
実は今月に片方のCPUクーラのファン部分が壊れたのでそっちはCPUクーラを買ったんだけど、こちらはなかなか優秀。
ただ、欠点としてスリムな奴を買ったので取り付けが非常にやりにくかった。
で今回は大きめのを買ってみた。
多分土日あたりにくるのでそれまで家のエアコンはつけっぱなしにしないと。
既に買ったクーラ
サイズ 【HASWELL対応】 手裏剣リビジョンB SYURIKEN Rev.B 全高64mm超ロープロファイルCPUクーラー
- 出版社/メーカー: サイズ
- メディア: 付属品
- クリック: 70回
- この商品を含むブログ (5件) を見る
今回注文したクーラ
サイズ トップフロー型CPUクーラー KABUTO 兜 12cmファン搭載 SCKBT-1000
- 出版社/メーカー: サイズ
- 発売日: 2009/04/22
- メディア: Personal Computers
- 購入: 7人 クリック: 50回
- この商品を含むブログ (19件) を見る
参考サイト:http://www.atmarkit.co.jp/flinux/rensai/fs06/fs06c.html