Tag: pvcreate

  • pvcreate Device /dev/sdb excluded by a filter

    pvcreate Device /dev/sdb excluded by a filter

    When creating LVM physical volume with the command “pvcreate”, I got the following error

    root@sok1 ~ # pvcreate /dev/sdb
      Device /dev/sdb excluded by a filter.
    root@sok1 ~ #
    

    This disk was previously used as a software raid.

    To fix the error message, run

    wipefs -a /dev/sdX
    

    Example

    root@sok1 ~ # pvcreate /dev/sdb
      Device /dev/sdb excluded by a filter.
    root@sok1 ~ # wipefs -a /dev/sdb
    /dev/sdb: 8 bytes were erased at offset 0x00000200 (gpt): 45 46 49 20 50 41 52 54
    /dev/sdb: 8 bytes were erased at offset 0xe8d7ffffe00 (gpt): 45 46 49 20 50 41 52 54
    /dev/sdb: 2 bytes were erased at offset 0x000001fe (PMBR): 55 aa
    /dev/sdb: calling ioctl to re-read partition table: Success
    root@sok1 ~ # pvcreate /dev/sdb
      Physical volume "/dev/sdb" successfully created.
    root@sok1 ~ # 
    

    pvcreate mdadm error

    See HDD, pvcreate