https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=256592
Bug ID: 256592
Summary: autofs_trigger_one: request for /net/ completed with
error 60
Product: Base System
Version: 13.0-STABLE
Hardware: Any
OS: Any
Status: New
Severity: Affects Some People
Priority: ---
Component: bin
Assignee: [email protected]
Reporter: [email protected]
In a holdover from our days on Solaris, we use NFS automountd frequently.
However, browsing /net mountpoints with the following /etc/auto_master entry
generally causes a 5 second lag when visiting each directory before our bash
prompt returns:
/net -hosts -nosuid,intr
In /var/adm/messages, we typically see:
WARNING: autofs_task: request 94 for /net/ timed out after 30 seconds
WARNING: autofs_trigger_one: request for /net/ completed with error 60, pid
3311 (git)
WARNING: autofs_task: request 95 for /net/ timed out after 30 seconds
WARNING: autofs_trigger_one: request for /net/ completed with error 60, pid
3311 (git)
WARNING: autofs_task: request 96 for /net/ timed out after 30 seconds
WARNING: autofs_trigger_one: request for /net/ completed with error 60, pid
3311 (git)
WARNING: autofs_task: request 97 for /net/ timed out after 30 seconds
WARNING: autofs_trigger_one: request for /net/ completed with error 60, pid
3311 (git)
Seeing "git" there looks a bit odd. In our ~/.bashrc, we have this code to
automatically show the git branch of any directory we visit in case it's a git
repository:
===
parse_git_branch() {
git branch 2> /dev/null | sed -e '/^[^*]/d' -e 's/* \(.*\)/ (\1)/'
}
function bash_prompt {
if [[ "$(id -u)" == 0 ]]; then
return
fi
echo "\[\033[00;34m\]$(id -un)@\$(uname -n)\$(parse_git_branch)\[\033[00m\]
"
}
PS1=$(bash_prompt)
===
so that seems like it might have some relevance. Sure enough, when running
automountd with some debug flags, we see:
root@puroto:~/.ssh # automountd -d -v
automountd: waiting for request from the kernel
automountd: not forking due to -d flag; will exit after servicing a single
request
automountd: got request 91: from map -hosts, path /net/, prefix "/net", key
".git", options "nosuid,intr"
automountd: parsing map "-hosts"
automountd: executing "/etc/autofs/special_hosts .git" as pid 3319
RPC: Unknown host
showmount: can't do exports rpc
automountd: "/etc/autofs/special_hosts .git", pid 3319, terminated with exit
status 1
automountd: failed to handle special map "-hosts"
automountd: completing request 91 with error 5
So why does automountd think ".git" is a hostname we should be passing to the
special_hosts script, which otherwise ought to be just running 'showmount -e'
on the NFS server? Something must be passing ".git" as an argument to
/etc/autofs/special_hosts?
For now, we've hacked around the problem with this change to
/etc/autofs/special_hosts on the NFS client to see if we can resolve the host
at all. This isn't an ideal fix, but seems to work well enough for now.
===
13 getent hosts $1 > /dev/null
14 if [ $? -ne 0 ]; then
15 exit 0
16 fi
17
18 out=`showmount -E "$1"`
19 [ $? -eq 0 ] || exit 1
20 echo "$out" | awk -v host="$1" \
21 '{ printf "\"%s\"\t\"%s:%s\" ", $0, host, $0 } END { printf "\n" }'
22
===
There seems to be a similar instance of this sort of thing reported at
https://mail-index.netbsd.org/current-users/2019/11/28/msg037105.html
We're running:
FreeBSD puroto 13.0-RELEASE-p1 FreeBSD 13.0-RELEASE-p1 #0: Wed May 26 22:15:09
UTC 2021
[email protected]:/usr/obj/usr/src/amd64.amd64/sys/GENERIC
amd64
--
You are receiving this mail because:
You are the assignee for the bug.