Fedora Linux Support Community & Resources Center
  #1  
Old 6th June 2011, 04:00 AM
graciemax Offline
Registered User
 
Join Date: Jun 2011
Posts: 4
linuxchrome
automount question

Hello Fedoraforum!

I've been using autofs forever on my home network: I have a Linux server exporting directories to the network (comprised of Linux & Mac boxes). I recently switched one of my machines to Fedora 15. All is good (after disabling SELinux; don't need it behind my firewall), except for automounting said exported directories. Yes, I can mount them as NFS mounts/root, but that defeats the purpose.

I don't need to have them mounted at boot (that's not really automounting, is it?), but I would very much like to have the configured automounts behave as they have historically.

Any insights would be deeply appreciated; thanks in advance!
Reply With Quote
  #2  
Old 6th June 2011, 05:51 AM
bodhi.zazen Offline
Registered User
 
Join Date: Jul 2006
Location: Montana
Posts: 731
linuxfirefox
Re: automount question

autofs works the same in Fedora 15 as it did in Fedora 14.

As an alternate, you can automount with systemd

http://www.happyassassin.net/2011/05...remote-shares/

If it is not working as you expect, you need to provide more details.


Also, you should not need to disable selinux for either autofs or systemd to work.
__________________
If it is not broken, tweak it... If you break Fedora you get to keep both pieces :p
Reply With Quote
  #3  
Old 6th June 2011, 04:27 PM
graciemax Offline
Registered User
 
Join Date: Jun 2011
Posts: 4
linuxchrome
Re: automount question

Quote:
Originally Posted by bodhi.zazen View Post
autofs works the same in Fedora 15 as it did in Fedora 14.

As an alternate, you can automount with systemd

http://www.happyassassin.net/2011/05...remote-shares/

If it is not working as you expect, you need to provide more details.

Also, you should not need to disable selinux for either autofs or systemd to work.
Hello! Thanks for the reply. I have not used Fedora 14, so I am not familiar with how its flavor of autofs is rolled.

Here is a line from /etc/exports on my main server:

Code:
/av  192.168.1.0/255.255.255.0(async,insecure,rw,no_root_squash,no_subtree_check)
Here is the salient line from the auto.misc file as configured on this (Fedora 15) box, and my Mac Pro:

Code:
av              -fstype=nfs             pyrrho:/av
This configuration has worked fine & dandy for years. What I'm trying to figure out is if there is something
a.) proprietary going on w/Fedora or
b.) I fat-fingered.

Here is the status of the autofs daemon:

Code:
autofs.service - LSB: Automounts filesystems on demand
	  Loaded: loaded (/etc/rc.d/init.d/autofs)
	  Active: active (running) since Sun, 05 Jun 2011 21:37:18 -0700; 10h ago
	 Process: 5801 ExecReload=/etc/rc.d/init.d/autofs reload (code=exited, status=0/SUCCESS)
	 Process: 1029 ExecStart=/etc/rc.d/init.d/autofs start (code=exited, status=0/SUCCESS)
	Main PID: 1214 (automount)
	  CGroup: name=systemd:/system/autofs.service
		  └ 1214 automount --pid-file /var/run/autofs.pid
It seems overkill to add a line to /etc/fstab as the post you mentioned here suggests, though I will try it.

Thanks again!
Reply With Quote
  #4  
Old 6th June 2011, 04:55 PM
bodhi.zazen Offline
Registered User
 
Join Date: Jul 2006
Location: Montana
Posts: 731
unknownunknown
Re: automount question

Well, you have to decide if you are going to use autofs or systemd

If you use autofs, you do NOT add an entry to fstab.

The fedora autofs documentation is here:

http://docs.fedoraproject.org/en-US/...ig-autofs.html
__________________
If it is not broken, tweak it... If you break Fedora you get to keep both pieces :p

Last edited by bodhi.zazen; 6th June 2011 at 04:58 PM.
Reply With Quote
  #5  
Old 6th June 2011, 07:15 PM
graciemax Offline
Registered User
 
Join Date: Jun 2011
Posts: 4
linuxchrome
Re: automount question

It was a newbie to Fedora issue: Fedora comes with a firewall; reconfiguring that solved my NFS problem (and a couple of others).

Thanks for the input!
Reply With Quote
  #6  
Old 9th June 2011, 12:17 AM
erikj123 Offline
Registered User
 
Join Date: Jun 2011
Posts: 2
linuxfirefox
Re: automount question

Can you please post what you did to reconfigure your firewall to make the nfsmounts work? I am struggling with the same problem and no amount of firewall reconfiguration seems to work, even trying many things in various posts (adding ports, etc).

Thanks!
Reply With Quote
  #7  
Old 9th June 2011, 07:12 AM
graciemax Offline
Registered User
 
Join Date: Jun 2011
Posts: 4
linuxchrome
Re: automount question

Quote:
Originally Posted by erikj123 View Post
Can you please post what you did to reconfigure your firewall to make the nfsmounts work? I am struggling with the same problem and no amount of firewall reconfiguration seems to work, even trying many things in various posts (adding ports, etc).

Thanks!
I took the easy way out: I simply disabled the Fedora firewall completely. Since I have a firewall set up on my router for my entire network I have no need for a personal one on a specific machine.

Probably not what you wanted to hear; sorry I can't give you anything more specific. Note the tool does warn any custom configurations you've made will be overwritten by using it; don't know if that's a factor in your case.

Good luck!
Reply With Quote
  #8  
Old 9th June 2011, 07:57 AM
bodhi.zazen Offline
Registered User
 
Join Date: Jul 2006
Location: Montana
Posts: 731
linuxfirefox
Re: automount question

Quote:
Originally Posted by erikj123 View Post
Can you please post what you did to reconfigure your firewall to make the nfsmounts work? I am struggling with the same problem and no amount of firewall reconfiguration seems to work, even trying many things in various posts (adding ports, etc).

Thanks!
auto mounting nfs works (with either of the two techniques I posted) on the clients without having to do anything to the firewall.

Server side, run
Code:
system-config-firewall
Alternately use iptables , for example,

Code:
iptables -A INPUT -p tcp -s 192.168.0.1/24 --dport 2049 -j ACCEPT
iptables -A INPUT -p tcp --dport 2049 -j DROP
Keep in mind, with iptables the order of your rules is critical

Also, with Fedora, after manually changing the iptables rules you need to save your changes

Code:
systemctl save iptables.service
Allow nfs4 (port 2049).

https://fedoraproject.org/w/index.ph...ch/HowTo/NFSv4
__________________
If it is not broken, tweak it... If you break Fedora you get to keep both pieces :p

Last edited by bodhi.zazen; 9th June 2011 at 08:02 AM.
Reply With Quote
  #9  
Old 9th June 2011, 05:34 PM
erikj123 Offline
Registered User
 
Join Date: Jun 2011
Posts: 2
linuxfirefox
Re: automount question

Thank you both for your replies, I appreciate your help. I was not very specific about my problems. If I turn my firewall off on the NFS server, then the automount on my client machine works fine. I am running F15 on my server and CentOS 5.6 on my client. I have carefully read the Fedora documentation on NFS (see Fedora F14 Stotage Administration Guide, Chapter 9, Network File System), in particular the section on running NFS behind a firewall (see the same doc, section 9.6.3). I have configured the firewall to allow NFS4 TCP access on port 2049. I have also uncommented the various ports listed in /etc/sysconfig/nfs and enabled the same port numbers in the firewall (I did not try to use custom port numbers). I have also made sure all the requisite services are up and running. But as soon as I enable the firewall, the automount fails. I have not tried using the IP tables method that Bohdi mentions. For now I am leaving the firewall off. I will return to this when I have more time.

Thanks!
Reply With Quote
Reply

Tags
automount, question

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Automount in KDE JClosed Hardware & Laptops 6 14th November 2010 04:32 PM
NFS,LDAP,AUTOMOUNT,AUTOFS Server (security question) gimli Servers & Networking 8 16th January 2007 09:42 PM
automount FC5 tho.mei Using Fedora 6 8th April 2006 07:18 PM
NTFS Automount question fryem720 Hardware & Laptops 4 16th May 2004 12:17 AM


Current GMT-time: 04:04 (Friday, 25-04-2014)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive
logo

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat