FreeIPA Automounting NFS
-
Ok sorry for the long delay. I had to spin up a new IPA server since I don't have one running at home any more. Here's how the configs will work.
Initial indirect mount set up:
List of mounts:
Under auto.home, here is the key setup:
The * and & are wildcards and it will search the NFS export for the username you are logged in with and replace the & with it.
The home directory for the user needs to be set to use the automount:
-
Since I'm using Puppet/Ansible, I don't really rely on the autofs setup from LDAP any longer. They don't change that often, so I just use the files. Puppet sticks all of my configs in the dump directory (auto.master.d) and adds the auto.whatever files in /etc for me. If there is a change, it will restart the autofs service automatically. The files seem to be more reliable than pulling from LDAP, but that's just anecdotal.
-
@stacksofplates said in FreeIPA Automounting NFS:
Ok sorry for the long delay. I had to spin up a new IPA server since I don't have one running at home any more. Here's how the configs will work.
Initial indirect mount set up:
List of mounts:
Under auto.home, here is the key setup:
The * and & are wildcards and it will search the NFS export for the username you are logged in with and replace the & with it.
The home directory for the user needs to be set to use the automount:
Thank you so much , i have configured the IPA Server as you did , but in the Ubuntu client when i run the command
ipa-client-automount
i have the below error :
root@cs1:~# ipa-client-automount Searching for IPA server... IPA server: [u'ipa.server.local'] Location: default Continue to configure the system with these values? [no]: yes Configured /etc/nsswitch.conf Configured /etc/default/nfs-common Configured /etc/idmapd.conf rpcidmapd failed to restart: Command '/usr/sbin/service rpcidmapd restart ' returned non-zero exit status 1 rpcgssd failed to restart: Command '/usr/sbin/service rpcgssd restart ' returned non-zero exit status 1 Restarting sssd, waiting for it to become available. Started autofs
-
@AlyRagab i also edited the /etc/nsswitch as " automount: files sss "
but the same problem , even i use the normal autofs configuration in ubuntu i could not automount the home directory. -
@AlyRagab said in FreeIPA Automounting NFS:
@AlyRagab i also edited the /etc/nsswitch as " automount: files sss "
but the same problem , even i use the normal autofs configuration in ubuntu i could not automount the home directory.After setting the local files did you restart rpcidmapd and rpcgssd?
You might have to set the automount to mount NFS version 3. I set up authentication once for an Ubuntu machine but not automounting. Everything I have is RHEL.
If you can't get the files working either I'd suspect it's something to do with Ubuntu.
If you're not using krb5p or krb5i you could just tell it to use NFS version 3 by default.
-
@stacksofplates said in FreeIPA Automounting NFS:
@AlyRagab said in FreeIPA Automounting NFS:
@AlyRagab i also edited the /etc/nsswitch as " automount: files sss "
but the same problem , even i use the normal autofs configuration in ubuntu i could not automount the home directory.After setting the local files did you restart rpcidmapd and rpcgssd?
You might have to set the automount to mount NFS version 3. I set up authentication once for an Ubuntu machine but not automounting. Everything I have is RHEL.
If you can't get the files working either I'd suspect it's something to do with Ubuntu.
If you're not using krb5p or krb5i you could just tell it to use NFS version 3 by default.
i could not find the rpcidmapd and rpcgssd services
also i can mount the NFS share manually without any problem! -
@AlyRagab said in FreeIPA Automounting NFS:
@stacksofplates said in FreeIPA Automounting NFS:
@AlyRagab said in FreeIPA Automounting NFS:
@AlyRagab i also edited the /etc/nsswitch as " automount: files sss "
but the same problem , even i use the normal autofs configuration in ubuntu i could not automount the home directory.After setting the local files did you restart rpcidmapd and rpcgssd?
You might have to set the automount to mount NFS version 3. I set up authentication once for an Ubuntu machine but not automounting. Everything I have is RHEL.
If you can't get the files working either I'd suspect it's something to do with Ubuntu.
If you're not using krb5p or krb5i you could just tell it to use NFS version 3 by default.
i could not find the rpcidmapd and rpcgssd services
also i can mount the NFS share manually without any problem!On my way home. I'llbe able to reply when I'm not driving.
-
So first I'd run
ipa-client-automount --uninstall
Then I'd set the configs like this:
auto.master
/home/ipa /etc/auto.home
auto.home
* nfsserver:/<path-for-user-dir>/&
Then restart autofs
systemctl restart autofs
-
i have tested it using Fedora and everything is working fine without any kind of troubleshooting , so why ubuntu is not simple as Fedora ?!!
-
@AlyRagab said in FreeIPA Automounting NFS:
i have tested it using Fedora and everything is working fine without any kind of troubleshooting , so why ubuntu is not simple as Fedora ?!!
Ha that's a good question. I stick with RHEL based products when I can.
-
@stacksofplates said in FreeIPA Automounting NFS:
@AlyRagab said in FreeIPA Automounting NFS:
i have tested it using Fedora and everything is working fine without any kind of troubleshooting , so why ubuntu is not simple as Fedora ?!!
Ha that's a good question. I stick with RHEL based products when I can.
i am planning from now to get rid of Ubuntu and use Fedora for Hosts and i am already work with CentOS
-
@AlyRagab said in FreeIPA Automounting NFS:
@stacksofplates said in FreeIPA Automounting NFS:
@AlyRagab said in FreeIPA Automounting NFS:
i have tested it using Fedora and everything is working fine without any kind of troubleshooting , so why ubuntu is not simple as Fedora ?!!
Ha that's a good question. I stick with RHEL based products when I can.
i am planning from now to get rid of Ubuntu and use Fedora for Hosts and i am already work with CentOS
CentOS / RHEL user here too.
-
The only Ubuntu system I have is my UniFi controller