Project

General

Profile

Actions

Submit #2913

closed

sbin/mount_nfs: Add -o retrycnt= from FreeBSD

Added by tkusumi over 8 years ago. Updated over 8 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Start date:
05/12/2016
Due date:
% Done:

0%

Estimated time:

Description

Matt,

I'd like to bring in a /sbin/mount_nfs option "-o retrycnt=" from FreeBSD.

DragonFly's mount_nfs has -R which is the same as -o retrycount,
but automountd (userspace daemon of autofs port from FreeBSD) needs this.

Using non -o options requires userspace rewrite as the config file parser for automountd assumes mount options are passed via -o.

The parser part of automountd is 100% userspace stuff which means the code is basically 100% compatible with FreeBSD,
so adding this alias to mount_nfs makes more sense than touching the parser only to support non -o format.

https://leaf.dragonflybsd.org/~tkusumi/diff/0001-sbin-mount_nfs-Add-o-retrycnt-from-FreeBSD.patch

Actions #1

Updated by tkusumi over 8 years ago

It's not that automountd requires every single option to have -o alias,
but -o retrycnt is the mandatory one that is hard-coded in exec arguments.
Even if retrycnt option is not used, automountd still tries to mount NFS with retrycnt=1.

Both
fork()/exec("mount_nfs -o retrycnt=1") (default)
or
fork()/exec("mount_nfs -o retrycnt=10")
fails without mount_nfs supporting this format.

https://github.com/freebsd/freebsd/blob/master/usr.sbin/autofs/automountd.c#L331

Actions #2

Updated by tkusumi over 8 years ago

  • Status changed from New to Closed
Actions

Also available in: Atom PDF