0%

Ovirt-configuring-storage

Last time we talked about adding a host to oVirt engine, it looks like following:

configure storage

Setting up storage is a prerequisite for a new data center because a data center cannot be initialized unless storage domains are attached and activated.
A storage domain is a collection of images that have a common storage domain contains complete images of templates and virtual machots), ISO files, and metadata about themselves. A storage domain can be made of either block devices (SAN - iSCSI or FCP) or a file system (NAS - NFS, GlusterFS, or other POSIX compliant file systems).

configure NFS storage

First I use another centOS as a nfs server,then attached it to storage domain.

1
2
3
[root@cube4200 ~]# showmount -e
Export list for cube4200:
/export/hosted_vm 192.168.0.0/24

It is attached successfully.

configure iSCSI storage

First I am going to use targetcli to create an iSCSI on my centOS.

after that, I go back to engine to attach it, but it said it can’t find the lun.I tried several times but failed.
After searching online, I found there is a specical user named vdsm whose user id is 36, group idis 36. This is a special user who supports engine to mount iSCSI to storage domain.Without this user the iSCSI can’t be found.

1
2
[root@cube4200 ~]# id vdsm
uid=36(vdsm) gid=36(kvm) groups=36(kvm),179(sanlock),107(qemu)

after adding user vdsm on iSCSI server, engine can find the lun.