Eu deletei todas as partições em dois discos locais e estou configurando o LVM nesses dois discos. Eu criei com sucesso um volume físico em /dev/sda
, mas fazê-lo em /dev/sdb
falha conforme descrito abaixo. Eu estou trabalhando de um instalador USB linux mint (por exemplo, nenhum disco está montado).
Tentativa de criar um volume físico:
mint ~ # pvcreate /dev/sdb
Device /dev/sdb not found (or ignored by filtering).
Verifique se não há partições
mint ~ # fdisk /dev/sdb
Welcome to fdisk (util-linux 2.27.1).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.
Command (m for help): p
Disk /dev/sdb: 931.5 GiB, 1000204886016 bytes, 1953525168 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
Disklabel type: gpt
Disk identifier: 785CAD57-8930-43D2-A61E-572453B74805
Command (m for help): q
Veja /proc/partitions
- isso foi solicitado em um guia de solução de problemas que tentei seguir.
mint ~ # cat /proc/partitions
major minor #blocks name
7 0 1799560 loop0
8 0 125034840 sda
8 16 976762584 sdb
8 32 1966080 sdc
8 33 1966030 sdc1
Adicionado detalhes dos comentários:
Nenhuma saída de:
grep -n '^[^#]*filter' /etc/lvm/lvm*.conf
Strace resulta perto da mensagem de erro (a saída foi muito longa):
strace pvcreate /dev/sdb
stat("/dev/sdb", {st_mode=S_IFBLK|0660, st_rdev=makedev(8, 16), ...}) = 0
open("/dev/sdb", O_RDONLY|O_DIRECT|O_NOATIME) = 4
fstat(4, {st_mode=S_IFBLK|0660, st_rdev=makedev(8, 16), ...}) = 0
ioctl(4, BLKBSZGET, [4096]) = 0
ioctl(4, BLKPBSZGET, [512]) = 0
lseek(4, 0, SEEK_SET) = 0
read(4, "mint ~ # pvcreate /dev/sdb
Device /dev/sdb not found (or ignored by filtering).
mint ~ # fdisk /dev/sdb
Welcome to fdisk (util-linux 2.27.1).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.
Command (m for help): p
Disk /dev/sdb: 931.5 GiB, 1000204886016 bytes, 1953525168 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
Disklabel type: gpt
Disk identifier: 785CAD57-8930-43D2-A61E-572453B74805
Command (m for help): q
mint ~ # cat /proc/partitions
major minor #blocks name
7 0 1799560 loop0
8 0 125034840 sda
8 16 976762584 sdb
8 32 1966080 sdc
8 33 1966030 sdc1
grep -n '^[^#]*filter' /etc/lvm/lvm*.conf
strace pvcreate /dev/sdb
stat("/dev/sdb", {st_mode=S_IFBLK|0660, st_rdev=makedev(8, 16), ...}) = 0
open("/dev/sdb", O_RDONLY|O_DIRECT|O_NOATIME) = 4
fstat(4, {st_mode=S_IFBLK|0660, st_rdev=makedev(8, 16), ...}) = 0
ioctl(4, BLKBSZGET, [4096]) = 0
ioctl(4, BLKPBSZGET, [512]) = 0
lseek(4, 0, SEEK_SET) = 0
read(4, "%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%"..., 4096) = 4096
close(4) = 0
write(2, " ", 2 ) = 2
write(2, "Device /dev/sdb not found (or ig"..., 52Device /dev/sdb not found (or ignored by filtering).) = 52
%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%%pre%"..., 4096) = 4096
close(4) = 0
write(2, " ", 2 ) = 2
write(2, "Device /dev/sdb not found (or ig"..., 52Device /dev/sdb not found (or ignored by filtering).) = 52