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, or any name already showing up in a node's virsh pool-list. The provisioner will refuse with a friendly 409 if you do.
Quick steps¶
- Settings → Datastores → + Add Datastore.
- Choose NFS as the backend.
- Fill in:
- Name — operator-friendly label.
- Server IP — the NAS / file-server IP.
- Remote Path — the exported path (e.g.
/exports/mfcloud-vms). - Local Mount — defaults to
/mnt/<name>; change if you have a convention. - Save. MFCloud runs an idempotent script on each 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:
If mountpoint says it's not mounted, check journalctl -u mfcloud-agent -n 50 — the install script logs each step.
Removing a datastore¶
Storage → 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.