2

Setting-up DRBD on CentOS 7 now.

The configuration is:

resource testdata1 {
    protocol C;
    on node1 {
            device /dev/drbd0;
            disk /dev/sdb;
            address 198.19.0.1:7788;
            meta-disk internal;
    }
    on node2 {
            device /dev/drbd0;
            disk /dev/sdb;
            address 198.10.0.2:7788;
            meta-disk internal;
    }
}

I have create the path with:

# mkdir -p /dev/sdb

When I run the initialize meta data command:

# drbdadm create-md testdata1

Got this message:

open(/dev/sdb) failed: Is a directory
open(/dev/sdb) failed: Is a directory
Command 'drbdmeta 0 v08 /dev/sdb internal create-md' terminated with exit code 20

Why?

cloud_cloud
  • 189
  • 1
  • 3
  • 8

1 Answers1

1

Because /dev/sdb is a directory and isn't device. sda means scsi disk a, sdb - scsi disk b and etc. There are devices block special files for input and output operations witch are created by system automatically. You must have real hard disk or partition on it to create DRBD device.

Khirgiy Mikhail
  • 332
  • 1
  • 5