-----Original Message-----
From: [email protected]
[mailto:[email protected]] On Behalf Of [email protected]
Sent: Friday, June 10, 2011 9:42 AM
To: [email protected]
Subject: Re: [Samba] Shutdown hangs since setting up Samba

Am 04.06.2011 16:40, schrieb Harry Jede:
> On 16:30:33 wrote [email protected]:
>> Am 03.06.2011 23:50, schrieb Chris Weiss:
>>> On Fri, Jun 3, 2011 at 4:11 PM,  <[email protected]> wrote:
>>>> I get this error messages on boot:
>>>>
>>>> CIFS VFS: Error connecting to socket. Aborting operation
>>>> CIFS VFS: cifs_mount failed w/return code = -101
>>>
>>> I have seen these before.
>>
>> OK, I'm not the only one.
>>
>>> as I recall, it's trying to mount before the network comes fully
>>> up, and downing the network before unmounting the cifs.
>>
>> I have the same suspicion, but don't know how to fix it.
>>
>>> I do not recall the solution, and I don't use cifs in fstab anymore.
>>
>> What are you using instead of CIFS?
> Use the pam mount helper. They run, when a user is logging in.
> 
> man pam_mount
> man pam_mount.conf

I followed this step-by-step guide [1], but it doesn't work.

The error messages in /var/log/auth.log look quite familiar to me:

pam_mount(mount.c:72): mount error(101): Network is unreachable
pam_mount(mount.c:72): Refer to the mount.cifs(8) manual page (e.g. man
mount.cifs)
pam_mount(pam_mount.c:521): mount of ben failed

---------------------------------

In my experience the switch to udev or some other parallel booting
process (not sure what did it) in more recent linux distros has caused
the init sequence to be violated.  So no longer can you count on S1
being finished before S99 starts.  I have had to do one of two things to
resolve this

RHEL: all mounting commands are put into /etc/rc.d/rc.local, because
that file is explicitely called after all other startup scripts have
completed.  (although on Fedora 14 this doesn't even seem to be the case
anymore...?)

SLES: Create a startup script that waits for your network interface to
come up before executing mounting commands.  Here's a simple, non-robust
one (where "do_network_mounts" actually does the mounting commands):

#!/bin/bash

# wait for a network interface to come up if we're running scripts in
parallel mode
while [ `ifconfig | grep 192.168 | wc -l` -eq 0 ]; do
  sleep 5
done

/mnt/do_network_mounts

-=Andrew
-- 
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba

Reply via email to