You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by Roland Kool <Ro...@tomtom.com> on 2012/09/20 17:37:56 UTC
NFS mount options on primary storage
Hi all,
Hopefully this is the correct place to ask this, if not, my apologies.
On a CS 3.0.2 setup using KVM on RHEL6 and NFS as primary storage, we noted some strange behaviour when it comes down to the NFS mount options for the primary storage.
When a hypervisor is booted, the primary storage is mounted using the default mount options as configured in /etc/nfsmount.conf. However, when we shutdown the agent, manually unmount the primary storage and start the cloud agent again, the primary storage is mounted using some hardcoded values (in our case the NFS mount becomes a soft mount, in stead of hard and the timeo and retrans settings change).
After some digging, we found that the script /usr/lib64/cloud/agent/scripts/vm/hypervisor/kvm/kvmheartbeat.sh is responsible for that (the mountoptions are hardcoded there).
My question is: what's the reasoning behind this? Is this a bug or leftover? Or is this by design and if so, why are these settings now always enforced?
Thanks in advance for any insights and your time.
Best regards,
Roland Kool | Sr. Systems Engineer | TomTom TechOps |
RE: NFS mount options on primary storage
Posted by Edison Su <Ed...@citrix.com>.
> -----Original Message-----
> From: Wido den Hollander [mailto:wido@widodh.nl]
> Sent: Friday, September 21, 2012 3:03 AM
> To: cloudstack-dev@incubator.apache.org
> Subject: Re: NFS mount options on primary storage
>
> On 09/20/2012 05:37 PM, Roland Kool wrote:
> > Hi all,
> >
> > Hopefully this is the correct place to ask this, if not, my apologies.
> >
> > On a CS 3.0.2 setup using KVM on RHEL6 and NFS as primary storage, we
> noted some strange behaviour when it comes down to the NFS mount
> options for the primary storage.
> >
> > When a hypervisor is booted, the primary storage is mounted using the
> default mount options as configured in /etc/nfsmount.conf. However,
> when we shutdown the agent, manually unmount the primary storage and
> start the cloud agent again, the primary storage is mounted using some
> hardcoded values (in our case the NFS mount becomes a soft mount, in
> stead of hard and the timeo and retrans settings change).
> >
> > After some digging, we found that the script
> /usr/lib64/cloud/agent/scripts/vm/hypervisor/kvm/kvmheartbeat.sh is
> responsible for that (the mountoptions are hardcoded there).
> >
> > My question is: what's the reasoning behind this? Is this a bug or
> leftover? Or is this by design and if so, why are these settings now
> always enforced?
> >
>
> This is a leftover and legacy. You're right that you should be able to
> specify your own NFS mount options.
>
> As the number of storage pool options in CloudStack is expanding we are
> looking at a refactor of the storage code, one of the things is that
> these kind of options can be submitted by the admin.
>
> So yes, it's on our radar, we haven't been able to look at this yet
> though.
There is an option in agent.properties before: mount.path=, but seems it doesn't take effect for a while.
It's the code in LibvirtStorageAdaptor.java, hardcoded to "/mnt". It should read the agent.properties or /etc/nfsmount.conf.
Let me add a quick fix, to read mount point option from agent.properties.
>
> Wido
>
> > Thanks in advance for any insights and your time.
> >
> > Best regards,
> >
> > Roland Kool | Sr. Systems Engineer | TomTom TechOps |
> >
Re: NFS mount options on primary storage
Posted by Wido den Hollander <wi...@widodh.nl>.
On 09/20/2012 05:37 PM, Roland Kool wrote:
> Hi all,
>
> Hopefully this is the correct place to ask this, if not, my apologies.
>
> On a CS 3.0.2 setup using KVM on RHEL6 and NFS as primary storage, we noted some strange behaviour when it comes down to the NFS mount options for the primary storage.
>
> When a hypervisor is booted, the primary storage is mounted using the default mount options as configured in /etc/nfsmount.conf. However, when we shutdown the agent, manually unmount the primary storage and start the cloud agent again, the primary storage is mounted using some hardcoded values (in our case the NFS mount becomes a soft mount, in stead of hard and the timeo and retrans settings change).
>
> After some digging, we found that the script /usr/lib64/cloud/agent/scripts/vm/hypervisor/kvm/kvmheartbeat.sh is responsible for that (the mountoptions are hardcoded there).
>
> My question is: what's the reasoning behind this? Is this a bug or leftover? Or is this by design and if so, why are these settings now always enforced?
>
This is a leftover and legacy. You're right that you should be able to
specify your own NFS mount options.
As the number of storage pool options in CloudStack is expanding we are
looking at a refactor of the storage code, one of the things is that
these kind of options can be submitted by the admin.
So yes, it's on our radar, we haven't been able to look at this yet though.
Wido
> Thanks in advance for any insights and your time.
>
> Best regards,
>
> Roland Kool | Sr. Systems Engineer | TomTom TechOps |
>