FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > CentOS > CentOS

 
 
LinkBack Thread Tools
 
Old 05-08-2010, 02:16 PM
 
Default disable autofs timeout

Hi,

Does setting the autofs timeout=0 create a permanent mount?

What I'm trying to do is get the best of both world;

1) Have a persistent mount so that users can use autocompletion.
2) utilize the benefits of autofs so that when an NFS resource becomes
unavailable, the system doesn't hang.

I've tried a timeout of 0 but it doesn't seem to work.


_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
 
Old 05-08-2010, 03:12 PM
Brian Mathis
 
Default disable autofs timeout

On Sat, May 8, 2010 at 10:16 AM, <aurfalien@gmail.com> wrote:
> Hi,
>
> Does setting the autofs timeout=0 create a permanent mount?
>
> What I'm trying to do is get the best of both world;
>
> 1) Have a persistent mount so that users can use autocompletion.
> 2) utilize the benefits of autofs so that when an NFS resource becomes
> unavailable, the system doesn't hang.
>
> I've tried a timeout of 0 but it doesn't seem to work.


A simple solution would be to setup a cron job that runs every 5
minutes and does
ls /mount/point > /dev/null
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
 
Old 05-09-2010, 01:49 PM
James Pearson
 
Default disable autofs timeout

aurfalien@gmail.com wrote:
> Hi,
>
> Does setting the autofs timeout=0 create a permanent mount?
>
> What I'm trying to do is get the best of both world;
>
> 1) Have a persistent mount so that users can use autocompletion.
> 2) utilize the benefits of autofs so that when an NFS resource becomes
> unavailable, the system doesn't hang.
>
> I've tried a timeout of 0 but it doesn't seem to work.

I can't see that making an autofs mount permanent will help ...

If the NFS server goes away and it is mounted on your client (via the
automounter or statically), the client will still hang on accessing the
mount point.

If you want to 'see' all the automount mount points, then start the
automounter with BROWSE_MODE="yes" (in /etc/sysconfig/autofs)

James Pearson
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
 
Old 05-09-2010, 02:22 PM
 
Default disable autofs timeout

On May 9, 2010, at 9:49 AM, James Pearson wrote:

> aurfalien@gmail.com wrote:
>> Hi,
>>
>> Does setting the autofs timeout=0 create a permanent mount?
>>
>> What I'm trying to do is get the best of both world;
>>
>> 1) Have a persistent mount so that users can use autocompletion.
>> 2) utilize the benefits of autofs so that when an NFS resource
>> becomes
>> unavailable, the system doesn't hang.
>>
>> I've tried a timeout of 0 but it doesn't seem to work.
>
> I can't see that making an autofs mount permanent will help ...
>
> If the NFS server goes away and it is mounted on your client (via the
> automounter or statically), the client will still hang on accessing
> the
> mount point.

I see, I was hoping to test and find out exactly what would happen.

Brian Mathis had a great suggestion so I went with it (crontab ls).
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
 
Old 05-11-2010, 01:48 PM
Arun Khan
 
Default disable autofs timeout

On Sat, May 8, 2010 at 8:42 PM, Brian Mathis <brian.mathis@gmail.com> wrote:

>
> A simple solution would be to setup a cron job that runs every 5
> minutes and does
> * *ls /mount/point > /dev/null

I had to something on the same line at a client. On Mac OS X (10.5)
workstation, users were complaining that "network files" (NFS export
from Linux file server) were visible in the "finder" but on clicking
it would not open. I asked them to open a terminal with a couple of
tabs and showed them how to use "cd" to the paths that had the NFS
mounts. The problem went away.

-- Arun Khan
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
 
Old 05-11-2010, 02:01 PM
Rudi Ahlers
 
Default disable autofs timeout

On Sat, May 8, 2010 at 5:12 PM, Brian Mathis <brian.mathis@gmail.com> wrote:




*A simple solution would be to setup a cron job that runs every 5
minutes and does
* *ls /mount/point > /dev/null



_______________________________________________

*
*
How would this fix the problem though? I'm asking cause I sit with the same problem, and haven't figured out yet to tell a remote server what todo if the NFS server is unavailable (be it network problems, maintenance, incorrect password, etc)


*



--
Kind Regards
Rudi Ahlers
SoftDux

Website: http://www.SoftDux.com
Technical Blog: http://Blog.SoftDux.com


Office: 087 805 9573
Cell: 082 554 7532

_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
 
Old 05-11-2010, 02:35 PM
Brian Mathis
 
Default disable autofs timeout

On Tue, May 11, 2010 at 10:01 AM, Rudi Ahlers <rudiahlers@gmail.com> wrote:
> On Sat, May 8, 2010 at 5:12 PM, Brian Mathis <brian.mathis@gmail.com> wrote:
>>
>> A simple solution would be to setup a cron job that runs every 5
>> minutes and does
>> * *ls /mount/point > /dev/null
>
> How would this fix the problem though? I'm asking cause I sit with the same
> problem, and haven't figured out yet to tell a remote server what todo if
> the NFS server is unavailable (be it network problems, maintenance,
> incorrect password, etc)
>
> Rudi Ahlers

It doesn't fix it -- it's an ugly workaround -- but it works to keep
them mounted. I don't know of an elegant solution if the NFS server
goes away. I've seen it hang the clients until they timeout. Maybe
an NFS expert on the list will be able to provide a better solution.
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
 
Old 05-11-2010, 02:57 PM
 
Default disable autofs timeout

On May 11, 2010, at 10:35 AM, Brian Mathis wrote:

> On Tue, May 11, 2010 at 10:01 AM, Rudi Ahlers <rudiahlers@gmail.com>
> wrote:
>> On Sat, May 8, 2010 at 5:12 PM, Brian Mathis
>> <brian.mathis@gmail.com> wrote:
>>>
>>> A simple solution would be to setup a cron job that runs every 5
>>> minutes and does
>>> ls /mount/point > /dev/null
>>
>> How would this fix the problem though? I'm asking cause I sit with
>> the same
>> problem, and haven't figured out yet to tell a remote server what
>> todo if
>> the NFS server is unavailable (be it network problems, maintenance,
>> incorrect password, etc)
>>
>> Rudi Ahlers
>
> It doesn't fix it -- it's an ugly workaround -- but it works to keep
> them mounted. I don't know of an elegant solution if the NFS server
> goes away. I've seen it hang the clients until they timeout. Maybe
> an NFS expert on the list will be able to provide a better solution.

I did a cron on a client who is also an OSX 10.5 server and then
killed the NFS server that it had automounted.

No hangs on the client but I haven't tested this on my Centos clients
yet which is actually my main concern.

I was actually surprised that OSX behaved for once.

_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
 
Old 05-11-2010, 10:49 PM
Todd Denniston
 
Default disable autofs timeout

Brian Mathis wrote, On 05/11/2010 10:35 AM:
> On Tue, May 11, 2010 at 10:01 AM, Rudi Ahlers <rudiahlers@gmail.com> wrote:
>> On Sat, May 8, 2010 at 5:12 PM, Brian Mathis <brian.mathis@gmail.com> wrote:
>>> A simple solution would be to setup a cron job that runs every 5
>>> minutes and does
>>> ls /mount/point > /dev/null
>> How would this fix the problem though? I'm asking cause I sit with the same
>> problem, and haven't figured out yet to tell a remote server what todo if
>> the NFS server is unavailable (be it network problems, maintenance,
>> incorrect password, etc)
>>
>> Rudi Ahlers
>
> It doesn't fix it -- it's an ugly workaround -- but it works to keep
> them mounted. I don't know of an elegant solution if the NFS server
> goes away. I've seen it hang the clients until they timeout. Maybe
> an NFS expert on the list will be able to provide a better solution.

not an expert, only a user who has been singed a few times.
in the options for the mount I suggest: hard,intr

hard because soft has had some data loss issues for me.
intr because sometimes you need to be able to interrupt a process while a server is down (say to be
able to reboot the client box).

<near rant mode>
BTW, keeping the mount point busy pretty much invalidates the use of autofs IAW the OP, i.e., the
only benefit that you get from autofs at this point is that if the server is down at client boot
then the client will be able to finish booting (which could have been accomplished by using the bg
flag in the fstab (man 5 nfs)).
The OP wrote:
"2) utilize the benefits of autofs so that when an NFS resource becomes
unavailable, the system doesn't hang."


If the file system IS mounted, then the system will hang until you can interrupt processes (why you
need the intr option).
If the file system is not needed then it should be unmounted so it can't hang the client.

A less drastic option for autocompletion issues would be to set a longer timeout, i.e., in
auto.master change the line
from:
/misc /etc/auto.misc
to:
/misc /etc/auto.misc --timeout=3600
to get an hour between disuse and unmount (the default is 600 (man auto.master)).



If you really want permanent mounts, then I suggest going back to using fstab with the bg & intr
options and ignore autofs, because it appears autofs only causes trouble for you.

If you want the benefits of autofs (no hung mounts if not mounted during server interruptions, less
net traffic/connections when clients don't need remote file systems), you might be better served by
using a longer timeout and re-reading James Pearson's email.
</near rant mode>

BTW what applications are you having autocompletion issues with? I have been using autofs for ~15
years and have only had issues with soft mounting causing data corruption.

--
Todd Denniston
Crane Division, Naval Surface Warfare Center (NSWC Crane)
Harnessing the Power of Technology for the Warfighter
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
 
Old 05-11-2010, 11:26 PM
 
Default disable autofs timeout

On May 11, 2010, at 6:49 PM, Todd Denniston wrote:

> Brian Mathis wrote, On 05/11/2010 10:35 AM:
>> On Tue, May 11, 2010 at 10:01 AM, Rudi Ahlers
>> <rudiahlers@gmail.com> wrote:
>>> On Sat, May 8, 2010 at 5:12 PM, Brian Mathis
>>> <brian.mathis@gmail.com> wrote:
>>>> A simple solution would be to setup a cron job that runs every 5
>>>> minutes and does
>>>> ls /mount/point > /dev/null
>>> How would this fix the problem though? I'm asking cause I sit with
>>> the same
>>> problem, and haven't figured out yet to tell a remote server what
>>> todo if
>>> the NFS server is unavailable (be it network problems, maintenance,
>>> incorrect password, etc)
>>>
>>> Rudi Ahlers
>>
>> It doesn't fix it -- it's an ugly workaround -- but it works to keep
>> them mounted. I don't know of an elegant solution if the NFS server
>> goes away. I've seen it hang the clients until they timeout. Maybe
>> an NFS expert on the list will be able to provide a better solution.
>
> BTW, keeping the mount point busy pretty much invalidates the use of
> autofs

My critical servers are autofs and don't slam the nfs server.

However my clients do peg it so you are right.

> If you really want permanent mounts, then I suggest going back to
> using fstab with the bg & intr
> options and ignore autofs, because it appears autofs only causes
> trouble for you.
>

Already do.

> BTW what applications are you having autocompletion issues with? I
> have been using autofs for ~15
> years and have only had issues with soft mounting causing data
> corruption.
>

Command line tab completion and a custom 3D script.

I think I'll do KISS on this one and just use fstab was I've been
doing with bg, hard, intr.
_______________________________________________
CentOS mailing list
CentOS@centos.org
http://lists.centos.org/mailman/listinfo/centos
 

Thread Tools




All times are GMT. The time now is 04:52 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org