Add an NFS Datastore¶
Wire an external NFS share into MFCloud so VMs and backups can use it as a storage backend.
Prerequisites¶
- An NFS server reachable from every compute node (port 2049/tcp + 111/tcp+udp open in both directions).
- An export path with
rw,no_root_squashso libvirt can write VM images as root. - A unique, lowercase pool name with no spaces — this becomes the libvirt storage pool name on each node.
Reserved pool names
Don't reuse default, images, iso, boot, tmp, var, or any name already showing up in a node's virsh pool-list. The provisioner will refuse with a 400 if you do.
Quick steps¶
- Storage → Manage Storage → Enterprise Pools tab → Attach New Storage Pool.
- Fill in:
- Pool Name — operator-friendly label; becomes the libvirt storage pool name on each node.
- Server IP — the NAS / file-server IP.
- Remote Path — the exported path (e.g.
/exports/mfcloud-vms). - Local Mount — defaults to
/var/lib/libvirt/pools/<pool-name>; change if you have a convention. - Cluster — which cluster's hosts get the mount; defaults to All clusters (fleet-wide).
- Mount on Cluster. MFCloud runs an idempotent script on each targeted Active node:
- Installs
nfs-utilsif missing. - Adds the mount to
/etc/fstab(dedup'd viaawkon the mountpoint). - Mounts the share.
- Registers a libvirt storage pool that points at the mount.
The datastore appears under Storage within ~30 s of the script finishing on the last node.
Verifying the mount¶
On any compute node:
mountpoint -q /var/lib/libvirt/pools/<pool-name> && echo OK
virsh pool-list --all | grep <pool-name>
If mountpoint says it's not mounted, check journalctl -u mfcloud-agent -n 50 — the install script logs each step.
Removing a datastore¶
Storage → Network Attached Storage (NFS) table → right-click the row → Remove. The agent will:
- Stop and undefine the libvirt pool on every node.
umountthe share (preceded by amountpoint -qgate to avoidumount: not mountednoise).- Strip the matching line from
/etc/fstab. - Delete the row.
VMs whose disks live on the datastore are not removed — the operator must reassign or delete those VMs first. Otherwise the unmount will fail with device is busy and the row stays in place.
See also¶
- Default Ports for the NFS-related firewall rules.
- Troubleshooting → NFS mount fails if a node won't pick up the share.