Наши проекты:
Журнал · Discuz!ML · Wiki · DRKB · Помощь проекту |
||
ПРАВИЛА | FAQ | Помощь | Поиск | Участники | Календарь | Избранное | RSS |
[3.236.234.62] |
|
Сообщ.
#1
,
|
|
|
Дано, qemu+kvm+libvirt, на хосте есть lvm том
test@ololo:~# lvs LV VG Attr LSize Pool Origin Data% Move Log Copy% Convert ftp virts -wi-a--- 10.00g примонтированный в качестве харда в виртуалке <disk type='block' device='disk'> <driver name='qemu' type='raw' cache='none' io='native'/> <source dev='/dev/virts/ftp'/> <target dev='sda' bus='scsi'/> <address type='drive' controller='0' bus='0' target='0' unit='0'/> </disk Интересует такой вопрос, когда виртуалка погашена, можно ли примонтировать этот том к хосту с возможностью записи? пробовал так: mount /dev/virts/ftp test/ mount: you must specify the filesystem type |
Сообщ.
#2
,
|
|
|
А если все же указать тип файловой системы при монтировании?
|
Сообщ.
#3
,
|
|
|
В том то и дело, что там не просто файловая система, а сначала раздел и на нём уже ext4
mount -t ext4 /dev/virts/ftp test/ mount: wrong fs type, bad option, bad superblock on /dev/mapper/virts-ftp, missing codepage or helper program, or other error In some cases useful info is found in syslog - try dmesg | tail or so НА хосте fdisk -l /dev/virts/ftp Disk /dev/virts/ftp: 10.7 GB, 10737418240 bytes 255 heads, 63 sectors/track, 1305 cylinders, total 20971520 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 4096 bytes Disk identifier: 0x00000000 Disk /dev/virts/ftp doesn't contain a valid partition table Внутри виртуалки fdisk -l Disk /dev/sda: 10.7 GB, 10737418240 bytes 255 heads, 63 sectors/track, 1305 cylinders, total 20971520 sectors Units = sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00011f73 Device Boot Start End Blocks Id System /dev/sda1 * 2048 20013055 10005504 83 Linux |
Сообщ.
#4
,
|
|
|
Если кто будет гуглить и ненагулит, помогло
qemu-nbd -c /dev/nbd0 /dev/virts/ftp -P 1 Затем обычное монтирование /dev/nbd0 |
Сообщ.
#5
,
|
|
|
M Gonarh, кросава!!! Вот эталон общения в "тематике". |