Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
What is the best API to find the NFS server address of the cluster?
2016-09-28
02:30 PM
2,379 Views
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In order to let a client mount a NFS volume on the cluster, we need to find out the IP address of the NFS server.
Currently we call the "net-interface-get-iter" API to list all interfaces on the cluster, and then find the interface with a "nfs" substring in its name. Then we can use this interface's IP address to mount the NFS volume. For example, the NFS interface in our cluster has this name: "TME_BENCH_nfs_lif1"
However, this looks very hacky to me... So I was just wondering, what would be the best API call to directly find out the IP address of the NFS server for a client to mount to?
Regards
1 REPLY 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I think network interface object has a "data-protocols" array that you can iterate to find nfs.
