標準ファームの HDD の中身(2)

LS-QVL

HDD の中身を見ようとしたが、
mount: unknown filesystem type 'linux_raid_member'
と言われて、マウント出来なかった。

楽し!

こういう新しいことがないとねぇ、、、(汗

LS-VL でも確認

念のため、LS-VL でも確認する。
まずはパーティション
root@vl:~# parted -s /dev/sdb print
-su: parted: command not found
root@vl:~# apt-get install parted
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
  parted-doc
The following NEW packages will be installed:
  parted
0 upgraded, 1 newly installed, 0 to remove and 3 not upgraded.
Need to get 157 kB of archives.
After this operation, 283 kB of additional disk space will be used.
Get:1 http://ftp.jp.debian.org/debian/ squeeze/main parted armel 2.3-5 [157 kB]
Fetched 157 kB in 0s (772 kB/s)
Selecting previously deselected package parted.
(Reading database ... 112788 files and directories currently installed.)
Unpacking parted (from .../parted_2.3-5_armel.deb) ...
Processing triggers for man-db ...
Setting up parted (2.3-5) ...
root@vl:~# parted -s /dev/sdb print
Model: ViPowER VP-89118(SD1) (scsi)
Disk /dev/sdb: 250GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number  Start   End     Size    File system  Name     Flags
 1      1049kB  1026MB  1024MB  ext3         primary
 2      1026MB  6146MB  5120MB               primary
 3      6146MB  6147MB  1049kB               primary
 4      6147MB  6148MB  1049kB               primary
 5      6148MB  7172MB  1024MB               primary
 6      7172MB  242GB   235GB                primary

root@vl:~#
マウントしてみる
root@vl:~# mkdir /tmp/root
root@vl:~# mount /dev/sdb2 !$
mount /dev/sdb2 /tmp/root
mount: unknown filesystem type 'linux_raid_member'
root@vl:~#
LS-QL で実行した時と同じくエラーでマウント出来ない。

手詰まり?

ピコーン!

RAID でマウントする

もともと RAID1 が組んである HDD なのだから、 そのとおりに RAID1 を組んでマウントすれば良いのでは?

RAID といえば、mdadm 。インストールする。

root@vl:~# apt-get install mdadm
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  exim4-base exim4-config exim4-daemon-light
Suggested packages:
  eximon4 exim4-doc-html exim4-doc-info spf-tools-perl swaks
Recommended packages:
  default-mta mail-transport-agent
The following NEW packages will be installed:
  exim4-base exim4-config exim4-daemon-light mdadm
0 upgraded, 4 newly installed, 0 to remove and 3 not upgraded.
Need to get 2512 kB of archives.
After this operation, 5214 kB of additional disk space will be used.
Do you want to continue [Y/n]? y
	:
	:
 lqqqqqqqqqqqqqqqqqqqqqqqqqqqu Configuring mdadm tqqqqqqqqqqqqqqqqqqqqqqqqqqqk
 x If the system's root file system is located on an MD array (RAID), it     x
 x needs to be started early during the boot sequence. If it is located on   x
 x a logical volume (LVM), which is on MD, all constituent arrays need to    x
 x be started.                                                               x
 x                                                                           x
 x If you know exactly which arrays are needed to bring up the root file     x
 x system, and you want to postpone starting all other arrays to a later     x
 x point in the boot sequence, enter the arrays to start here.               x
 x Alternatively, enter 'all' to simply start all available arrays.          x
 x                                                                           x
 x If you do not need or want to start any arrays for the root file system,  x
 x leave the answer blank (or enter 'none'). This may be the case if you     x
 x are using kernel autostart or do not need any arrays to boot.             x
 x                                                                           x
 x Please enter 'all', 'none', or a space-separated list of devices such as  x
 x 'md0 md1' or 'md/1 md/d0' (the leading '/dev/' can be omitted).           x
 x                                                                           x
 x MD arrays needed for the root file system:                                x
 x                                                                           x
 x none_____________________________________________________________________ x
 x                                                                           x
 x                                  <Ok>                                     x
 x                                                                           x
 mqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqj
起動時に RAID は必要無いので、none
 lqqqqqqqqqqqqqqqqqqqqqqqqqqqu Configuring mdadm tqqqqqqqqqqqqqqqqqqqqqqqqqqqk
 x                                                                           x
 x Once the base system has booted, mdadm can start all MD arrays (RAIDs)    x
 x specified in /etc/mdadm/mdadm.conf which have not yet been started. This  x
 x is recommended unless multiple device (MD) support is compiled into the   x
 x kernel and all partitions are marked as belonging to MD arrays, with      x
 x type 0xfd (as those and only those will be started automatically by the   x
 x kernel).                                                                  x
 x                                                                           x
 x Do you want to start MD arrays automatically?                             x
 x                                                                           x
 x                    <Yes>                       <No>                       x
 x                                                                           x
 mqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqj
自動的にやってくれるらしい。もちろん Yes を選択
	:
	:
Setting up mdadm (3.1.4-1+8efb9d1+squeeze1) ...
Generating array device nodes... done.
Generating mdadm.conf... done.
Starting MD monitoring service: mdadm --monitor.
Assembling MD array md0...done (degraded [1/4]).
Assembling MD array md1...done (degraded [1/4]).
Assembling MD array md10...done (degraded [1/4]).
Assembling MD array md22...done (degraded [1/2]).
Generating udev events for MD arrays...done.
!root@vl:~#
なんか、見たことのあるような array ができた。

見てみる

root@vl:~# cat /proc/mdstat
Personalities : [linear] [raid0] [raid1] [raid6] [raid5] [raid4]
md22 : active raid1 sdb6[0]
      229327736 blocks super 1.2 [2/1] [U_]

md10 : active raid1 sdb5[4]
      1000436 blocks super 1.2 [4/1] [_U__]

md1 : active raid1 sdb2[4]
      4999156 blocks super 1.2 [4/1] [_U__]

md0 : active raid1 sdb1[1]
      1000384 blocks [4/1] [_U__]

unused devices: <none>
root@vl:~#
できてる、できてる。

マウントしてみる

root@vl:~# mount /dev/md1 /tmp/root
root@vl:~#
マウントできた!

中身を見る

root@vl:~# ls /tmp/root
bin   dev  home    lib         mnt   root  sys  usr  www
boot  etc  initrd  lost+found  proc  sbin  tmp  var
root@vl:~#
アイゲティット!

LS-QVL
バッファローダイレクト
楽天市場
amazon
ドスパラ
livedoor デパート
Yahoo!ショッピング
バリューモア
ムラウチドットコム


デスクトップとして使う(9)新しいモジュールでXを起動
ハックの記録
LinkStation/玄箱 をハックしよう

デスクトップとして使う(10)もう一回カーネルのリコンフィグ

Copyright (C) 2003-2012 Yasunari Yamashita. All Rights Reserved.
yasunari @ yamasita.jp 山下康成@京都府向日市