rcbops / chef-cookbooks

RCB OPS - Chef Cookbooks
Other
118 stars 102 forks source link

Additional option needed for proper handling of NFS mounts. #970

Open sdeaton2 opened 10 years ago

sdeaton2 commented 10 years ago

When using NetApp, a configuration block is needed like this:

  cinder:
    storage:
      netapp:
        nfsdirect:
          export:          /vol/cinder_volume
          login:           ### netapp login ###
          password:        ### netapp password ###
          port:            443
          server_hostname: ### netapp IP ###
          transport_type:  https
          provider: netappnfsdirect

This is fine and all, except that this is additionally needed....

nfs_mount_point_base=/var/lib/cinder/mnt

That needs added to the [DEFAULT] section in the /etc/nova/nova.conf file.

When attaching or detaching a volume, cinder, nova, and mysql all get along just fine... however, libvirt doesn't play well with cinder --- it does things based off of the state_path_def that is set for nova, since it is a driver for nova... because of this, the path ends up being /var/lib/nova/mnt, which should instead be /var/lib/cinder/mnt. The above configuration option fixes this.

With that option in place, everything attaches and detaches fine.

sdeaton2 commented 10 years ago

git describe shows "v4.1.0-660-gbd8ca2a" Package versions are Havana Distro is Ubuntu 12.04

Also, it looks like this option is changed to be "libvirt/nfs_mount_point_base" in Icehouse, per here: http://docs.openstack.org/icehouse/config-reference/content/nova-conf-changes-icehouse.html

cfarquhar commented 10 years ago

This would also need to be updated in the docs: http://www.rackspace.com/knowledge_center/article/configuring-openstack-block-storage#cinder-netapp .

Also, it would help to have clarification on where the cinder-volume role is required (not on the compute hosts).

sdeaton2 commented 10 years ago

To clarify a little bit ... a symptom of this problem is the fact that the NFS mount for the directory of volume files is that it will be mounted twice - once for the Nova-based value of state_path_def and once for the Cinder-based value for the same variable:

Compute01:~# df -t nfs
Filesystem                      1K-blocks      Used Available Use% Mounted on
10.240.0.81:/vol/PDS_Cinder_NFS 524288000 110807168 413480832  22% /var/lib/cinder/mnt/9cabab237868acde06b653384fe82fba
10.240.0.81:/vol/PDS_Cinder_NFS 524288000 110807168 413480832  22% /var/lib/nova/mnt/9cabab237868acde06b653384fe82fba