/exports/home (home directories) and
/exports/pkgsrc (NetBSD's pkgsrc repository) from an OpenBSD NFSv3 server running OpenBSD 6.0-release to an internal network of OpenBSD and Ubuntu 16.10 hosts, and one Solaris 11.3 host.
This works well for the home directories on Ubuntu and OpenBSD, because the UIDs and GIDs of the users happens to be the same on both system.
On Solaris, I had to manually change the UIDs since Solaris starts allocating UIDs at 100 rather than at 1000. I think it is manageable to do this manually for users that I've added, but not really for other default system UIDs/GIDs.
pkgsrc export, I'd like the mount to show up as
root:src on Ubuntu and
root:wsrc on OpenBSD, but the
src group is GID 40 on Ubuntu while the
wsrc group has GID 9 on OpenBSD (9 is
news on Ubuntu). On Solaris, GID 9 belongs to the
Is it possible to perform a remapping of (at least) the GID between the client and server when mounting an NFSv3 share? I don't really want to have to manually synchronize UIDs and GIDs that I didn't add myself across heterogeneous Unix systems... Is there an easier way to do this (keeping in mind that I can't just use NFSv4 on OpenBSD)?
The workaround will be to add a completely new
pkgsrc group with a GID that is unique on all systems, but I'll wait with that to see if there's a better solution.
/etc/exports on the
/exports/home -network=10.0.0 -mask=255.255.255.0 /exports/pkgsrc -network=10.0.0 -mask=255.255.255.0
This is the corresponding
fstab entries on an Ubuntu host:
omni:/exports/home /home nfs rsize=4096,wsize=4096,soft omni:/exports/pkgsrc /opt/pkgsrc nfs rsize=4096,wsize=4096,soft
pkgsrc directory, on the OpenBSD server:
$ ls -ld /exports/pkgsrc drwxrwxr-x 52 root wsrc 2048 Feb 18 20:07 /exports/pkgsrc
and on an Ubuntu host:
$ ls -ld /opt/pkgsrc drwxrwxr-x 52 root news 2048 Feb 18 20:07 /opt/pkgsrc
... and I'd like
news (GID 9) to be
src (GID 40).