From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Message-ID: <42B95BFE.1010403@stc.donpac.ru> Date: Wed, 22 Jun 2005 16:39:26 +0400 From: Eugene Prokopiev User-Agent: Mozilla/5.0 (X11; U; Linux i686; ru-RU; rv:1.7.2) Gecko/20040808 X-Accept-Language: ru-ru, ru MIME-Version: 1.0 To: Community@altlinux.ru Content-Type: text/plain; charset=KOI8-R; format=flowed Content-Transfer-Encoding: 8bit Cc: Subject: [Comm] softraid + lvm X-BeenThere: community@altlinux.ru X-Mailman-Version: 2.1.5 Precedence: list Reply-To: community@altlinux.ru List-Id: Mailing list for ALT Linux users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 22 Jun 2005 12:39:15 -0000 Archived-At: List-Archive: List-Post: Здравствуйте! Имею образ уже настроенной системы (ALM 2.4) в виде cpio, который необходимо развернуть на softraid1 + lvm, причем все, кроме /boot, должно лежать именно в lvm. Имею машину, на которой планируется все описанное разворачивать, машина загружена с Кноппикса. Делаю следующее: root@0[root]# cfdisk /dev/sda ... root@0[root]# sfdisk -d /dev/sda | sfdisk /dev/sdb Checking that no-one is using this disk right now ... OK Disk /dev/sdb: 1115 cylinders, 255 heads, 63 sectors/track Old situation: Units = cylinders of 8225280 bytes, blocks of 1024 bytes, counting from 0 Device Boot Start End #cyls #blocks Id System /dev/sdb1 0 - 0 0 0 Empty /dev/sdb2 0 - 0 0 0 Empty /dev/sdb3 0 - 0 0 0 Empty /dev/sdb4 0 - 0 0 0 Empty New situation: Units = sectors of 512 bytes, counting from 0 Device Boot Start End #sectors Id System /dev/sdb1 * 63 96389 96327 fd Linux raid autodetect /dev/sdb2 96390 2056319 1959930 82 Linux swap /dev/sdb3 2056320 17912474 15856155 fd Linux raid autodetect /dev/sdb4 0 - 0 0 Empty Successfully wrote the new partition table Re-reading the partition table ... If you created or changed a DOS partition, /dev/foo7, say, then use dd(1) to zero the first 512 bytes: dd if=/dev/zero of=/dev/foo7 bs=512 count=1 (See fdisk(8).) root@0[root]# mkswap /dev/sda2 Setting up swapspace version 1, size = 1003479 kB root@0[root]# mkswap /dev/sdb2 Setting up swapspace version 1, size = 1003479 kB root@0[root]# cat /etc/raidtab raiddev /dev/md0 raid-level 1 nr-raid-disks 2 chunk-size 32 nr-spare-disks 0 persistent-superblock 1 device /dev/sda1 raid-disk 0 device /dev/sdb1 raid-disk 1 raiddev /dev/md1 raid-level 1 nr-raid-disks 2 chunk-size 32 nr-spare-disks 0 persistent-superblock 1 device /dev/sda3 raid-disk 0 device /dev/sdb3 raid-disk 1 root@0[root]# mkraid -R /dev/md0 DESTROYING the contents of /dev/md0 in 5 seconds, Ctrl-C if unsure! handling MD device /dev/md0 analyzing super-block disk 0: /dev/sda1, 48163kB, raid superblock at 48064kB disk 1: /dev/sdb1, 48163kB, raid superblock at 48064kB root@0[root]# mkraid -R /dev/md1 DESTROYING the contents of /dev/md1 in 5 seconds, Ctrl-C if unsure! handling MD device /dev/md1 analyzing super-block disk 0: /dev/sda3, 7928077kB, raid superblock at 7928000kB disk 1: /dev/sdb3, 7928077kB, raid superblock at 7928000kB root@0[root]# cat /proc/mdstat Personalities : [raid1] read_ahead 1024 sectors md1 : active raid1 sdb3[1] sda3[0] 7928000 blocks [2/2] [UU] md0 : active raid1 sdb1[1] sda1[0] 48064 blocks [2/2] [UU] unused devices: root@0[root]# mkfs.ext2 /dev/md0 mke2fs 1.35 (28-Feb-2004) Filesystem label= OS type: Linux Block size=1024 (log=0) Fragment size=1024 (log=0) 12048 inodes, 48064 blocks 2403 blocks (5.00%) reserved for the super user First data block=1 6 block groups 8192 blocks per group, 8192 fragments per group 2008 inodes per group Superblock backups stored on blocks: 8193, 24577, 40961 Writing inode tables: done Writing superblocks and filesystem accounting information: done This filesystem will be automatically checked every 29 mounts or 180 days, whichever comes first. Use tune2fs -c or -i to override. root@0[root]# pvcreate /dev/md1 lvmiopversion -- Exec of pvcreate failed lvmiopversion: Input/output error При этом создать файловую систему я могу: root@0[root]# mkfs.ext2 /dev/md1 mke2fs 1.35 (28-Feb-2004) Filesystem label= OS type: Linux Block size=4096 (log=2) Fragment size=4096 (log=2) 991616 inodes, 1982000 blocks 99100 blocks (5.00%) reserved for the super user First data block=0 61 block groups 32768 blocks per group, 32768 fragments per group 16256 inodes per group Superblock backups stored on blocks: 32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632 Writing inode tables: done Writing superblocks and filesystem accounting information: done This filesystem will be automatically checked every 31 mounts or 180 days, whichever comes first. Use tune2fs -c or -i to override. Почему я не могу создать физический том LVM? -- С уважением, Прокопьев Евгений