Effective December 3, NetApp adopts Microsoft’s Business-to-Customer (B2C) identity management to simplify and provide secure access to NetApp resources.
For accounts that did not pre-register (prior to Dec 3), access to your NetApp data may take up to 1 hour as your legacy NSS ID is synchronized to the new B2C identity.
To learn more, read the FAQ and watch the video.
Need assistance? Complete this form and select “Registration Issue” as the Feedback Category.

OpenStack Discussions

How can I attach a volume to VM using netapp volume driver?

JAESANGLEE

Hi, I set my openstack volume driver to NetAppISCSIDriver.

(nova version is essex milestone-1, I think it's too old, but It's not important)

I also configured some flags for driver.

This is my configuration.(nova.conf)

42 ### volume configuration

43 --volume_manager=nova.volume.manager.VolumeManager

45 --volume_driver=nova.volume.netapp.NetAppISCSIDriver

46 --netapp_login=administrator

47 --netapp_password=password

48 --netapp_server_hostname=10.4.1.252

49 --netapp_server_port=8088

50 --netapp_storage_service=Cloud

52 --netapp_wsdl_url=http://10.4.1.252/dfm.wsdl

53 --netapp_storage_service_prefix=cloud-

When I create volume It looks like normal.

~$ nova volume-create 5 --display_name jaesang3 --availability_zone b_zone

~$ nova volume-list

+----+-----------+-----------------+------+--------------------------------------+

| ID |   Status  |   Display Name  | Size |             Attached to              |

+----+-----------+-----------------+------+--------------------------------------+

| 35 | available | jaesang3        | 5    | None                                 |

+----+-----------+-----------------+------+--------------------------------------+

It's value of volumes table.

*************************** 10. row ***************************

         created_at: 2012-11-14 13:07:40

         updated_at: 2012-11-14 13:07:46

         deleted_at: NULL

            deleted: 0

                 id: 35

             ec2_id: NULL

            user_id: admin

         project_id: sds_netapp_test

               host: stest4.p18.poc

               size: 5

  availability_zone: b_zone

        instance_id: NULL

         mountpoint: NULL

        attach_time: NULL

             status: available

      attach_status: detached

       scheduled_at: 2012-11-14 13:07:40

        launched_at: 2012-11-14 13:07:46

      terminated_at: NULL

       display_name: jaesang3

display_description: NULL

  provider_location: 278

      provider_auth: NULL

        snapshot_id: NULL

     volume_type_id: NULL

But When I attach volume to VM, It looks like abnormal.

This is my block_device_mapping db table.

mysql> select id,instance_id,volume_id,connection_info from block_device_mapping where deleted=0\G;

*************************** 1. row ***************************

             id: 6

    instance_id: 5

      volume_id: 25

connection_info: {"driver_volume_type": "iscsi", "data": {"device_path": "/dev/disk/by-path/ip-10.245.34.51:3260-iscsi-iqn.1992-08.com.netapp:sn.1574419210-lun-0", "target_discovered": false, "target_iqn": "iqn.1992-08.com.netapp:sn.1574419210", "target_portal": "10.245.34.51:3260", "volume_id": 25, "target_lun": "0"}}

*************************** 2. row ***************************

             id: 8

    instance_id: 5

      volume_id: 26

connection_info: {"driver_volume_type": "iscsi", "data": {"device_path": "/dev/disk/by-path/ip-10.245.34.51:3260-iscsi-iqn.1992-08.com.netapp:sn.1574419210-lun-0", "target_discovered": false, "target_iqn": "iqn.1992-08.com.netapp:sn.1574419210", "target_portal": "10.245.34.51:3260", "volume_id": 26, "target_lun": "1"}}

*************************** 3. row ***************************

             id: 15

    instance_id: 5

      volume_id: 32

connection_info: {"driver_volume_type": "iscsi", "data": {"device_path": "/dev/disk/by-path/ip-10.245.34.51:3260-iscsi-iqn.1992-08.com.netapp:sn.1574419210-lun-0", "target_discovered": false, "target_iqn": "iqn.1992-08.com.netapp:sn.1574419210", "target_portal": "10.245.34.51:3260", "volume_id": 32, "target_lun": "2"}}

3 rows in set (0.00 sec)

You can see volume_id is different. BUT every device_path is same. So when I mount a volume in VM,  wrong volume mounted.

When I use HP san volume driver, every device_path is different. for example,

mysql> select id,instance_id,volume_id,connection_info from block_device_mapping where deleted=0 limit 3\G

*************************** 1. row ***************************

             id: 47

    instance_id: 49

      volume_id: 57

connection_info: {"driver_volume_type": "iscsi", "data": {"device_path": "/dev/disk/by-path/ip-10.113.1.1:3260-iscsi-iqn.2003-10.com.lefthandnetworks:c1-z1-pek:292:volume-00000039-lun-0", "target_discovered": false, "target_iqn": "iqn.2003-10.com.lefthandnetworks:c1-z1-pek:292:volume-00000039", "target_portal": "10.113.1.1:3260", "volume_id": 57, "auth_password": "project_secret_P20120816-004", "auth_username": "proj_P20120816-004", "auth_method": "CHAP"}}

*************************** 2. row ***************************

             id: 128

    instance_id: 93

      volume_id: 132

connection_info: {"driver_volume_type": "iscsi", "data": {"device_path": "/dev/disk/by-path/ip-10.113.1.1:3260-iscsi-iqn.2003-10.com.lefthandnetworks:c1-z1-pek:568:volume-00000084-lun-0", "target_discovered": false, "target_iqn": "iqn.2003-10.com.lefthandnetworks:c1-z1-pek:568:volume-00000084", "target_portal": "10.113.1.1:3260", "volume_id": 132, "auth_password": "project_secret_P20120821-002", "auth_username": "proj_P20120821-002", "auth_method": "CHAP"}}

*************************** 3. row ***************************

             id: 129

    instance_id: 94

      volume_id: 133

connection_info: {"driver_volume_type": "iscsi", "data": {"device_path": "/dev/disk/by-path/ip-10.113.1.1:3260-iscsi-iqn.2003-10.com.lefthandnetworks:c1-z1-pek:571:volume-00000085-lun-0", "target_discovered": false, "target_iqn": "iqn.2003-10.com.lefthandnetworks:c1-z1-pek:571:volume-00000085", "target_portal": "10.113.1.1:3260", "volume_id": 133, "auth_password": "project_secret_P20120821-002", "auth_username": "proj_P20120821-002", "auth_method": "CHAP"}}

Why Netapp driver set device_path is same? Is this normal situation?

Please help me in understanding setup using netapp driver.

Thanks in advance.

1 REPLY 1

esker

Hi Jay,

It actually is relevant that your Nova version is Essex-1.  There were a few fixes / enhancements that our driver required that came fairly late in the Essex development cycle.  Could you 1) retry with latest Essex-stable and 2) also make use of the most recent version of the driver intended to be used w/ Essex here:

https://github.com/rushiagr/nova/tree/essexport/nova/volume

Thanks!

Announcements
NetApp on Discord Image

We're on Discord, are you?

Live Chat, Watch Parties, and More!

Explore Banner

Meet Explore, NetApp’s digital sales platform

Engage digitally throughout the sales process, from product discovery to configuration, and handle all your post-purchase needs.

NetApp Insights to Action
I2A Banner
Public