Page MenuHomeFreeBSD

rmacklem (Rick Macklem)
User

Projects

User Details

User Since
Jan 13 2015, 10:58 PM (222 w, 4 d)

Recent Activity

Today

rmacklem committed rS346468: MFC: r345995.
MFC: r345995
Sun, Apr 21, 1:33 AM
rmacklem committed rS346467: MFC: r345994.
MFC: r345994
Sun, Apr 21, 1:25 AM
rmacklem committed rS346466: MFC: r345992, r346087.
MFC: r345992, r346087
Sun, Apr 21, 1:16 AM
rmacklem committed rS346465: MFC: r345995.
MFC: r345995
Sun, Apr 21, 12:59 AM
rmacklem committed rS346464: MFC: r345994.
MFC: r345994
Sun, Apr 21, 12:51 AM
rmacklem committed rS346463: MFC: r345992, r346087.
MFC: r345992, r346087
Sun, Apr 21, 12:41 AM
rmacklem committed rS346462: MFC: r345995.
MFC: r345995
Sun, Apr 21, 12:12 AM
rmacklem committed rS346461: MFC: r345994.
MFC: r345994
Sun, Apr 21, 12:05 AM

Yesterday

rmacklem committed rS346460: MFC: r345992, r346087.
MFC: r345992, r346087
Sat, Apr 20, 11:46 PM

Fri, Apr 19

rmacklem committed rS346424: Add support for the ModeSetMasked attribute to the NFSv4.1 server..
Add support for the ModeSetMasked attribute to the NFSv4.1 server.
Fri, Apr 19, 11:35 PM
rmacklem committed rS346423: Replace "vp" with NULL to make the code more readable..
Replace "vp" with NULL to make the code more readable.
Fri, Apr 19, 11:27 PM
rmacklem committed rS346365: Fix the NFSv4.0 server so that it does not support NFSv4.1 attributes..
Fix the NFSv4.0 server so that it does not support NFSv4.1 attributes.
Fri, Apr 19, 3:36 AM

Thu, Apr 18

rmacklem committed rS346344: MFC: r345866.
MFC: r345866
Thu, Apr 18, 2:54 AM
rmacklem committed rS346343: MFC: r345866.
MFC: r345866
Thu, Apr 18, 2:48 AM
rmacklem committed rS346342: MFC: r345866.
MFC: r345866
Thu, Apr 18, 2:32 AM

Tue, Apr 16

rmacklem committed rS346262: MFC: r345818, r345828.
MFC: r345818, r345828
Tue, Apr 16, 2:48 AM
rmacklem committed rS346260: MFC: r345818, r345828.
MFC: r345818, r345828
Tue, Apr 16, 2:38 AM
rmacklem committed rS346258: MFC: r345818, r345828.
MFC: r345818, r345828
Tue, Apr 16, 2:12 AM

Mon, Apr 15

rmacklem committed rS346217: Fix the NFSv4 client to safely find processes..
Fix the NFSv4 client to safely find processes.
Mon, Apr 15, 1:27 AM
rmacklem closed D19887: fix the NFSv4 client so that it doesn't call pfind() with a mutex held.
Mon, Apr 15, 1:27 AM

Sun, Apr 14

rmacklem added a comment to D19887: fix the NFSv4 client so that it doesn't call pfind() with a mutex held.

Updated patch renames pfind_locked() to pfind_any_locked(), per mjg@'s request.

Sun, Apr 14, 8:43 PM
rmacklem updated the diff for D19887: fix the NFSv4 client so that it doesn't call pfind() with a mutex held.

pfind_locked() has been renamed pfind_any_locked() and a comment
indicating that it finds zombies has been added, per mjg@'s request.

Sun, Apr 14, 8:41 PM

Sat, Apr 13

rmacklem committed rS346192: Fix printing of the line that starts with "LocalOpen..."..
Fix printing of the line that starts with "LocalOpen...".
Sat, Apr 13, 11:26 PM
rmacklem added a comment to D19887: fix the NFSv4 client so that it doesn't call pfind() with a mutex held.

Replied to inline comment.

Sat, Apr 13, 10:22 PM
rmacklem committed rS346191: Add support for INET6 addresses to the kernel code that dumps open/lock state..
Add support for INET6 addresses to the kernel code that dumps open/lock state.
Sat, Apr 13, 10:00 PM
rmacklem committed rS346190: Fix nfsdumpstate(8) so that it can print out INET6 callback addresses..
Fix nfsdumpstate(8) so that it can print out INET6 callback addresses.
Sat, Apr 13, 9:46 PM
rmacklem closed D19839: add INET6 support to nfsdumpstate for the client callback address.
Sat, Apr 13, 9:46 PM
rmacklem added a comment to D19887: fix the NFSv4 client so that it doesn't call pfind() with a mutex held.

I have included responses to the inline comments.

Sat, Apr 13, 9:29 PM
rmacklem updated the diff for D19887: fix the NFSv4 client so that it doesn't call pfind() with a mutex held.

This version of the patch uses SX_DUPOK instead of a separate name for each
lock. It also adds a couple of small functions to kern_proc.c to acquire/release
all the pid hash locks, so that the NFS code can call those instead of doing it directly.

Sat, Apr 13, 9:27 PM
rmacklem added a comment to D19887: fix the NFSv4 client so that it doesn't call pfind() with a mutex held.

I just read the man page (I know, never read the documentation;-) and it seems that
the recursion check is for exclusive locks, so adding SX_DUPOK would allow a process
to acquire a shared lock that it already has.
So, maybe, sticking with the current patch that applies a unique name to each element
is preferred?

Sat, Apr 13, 4:46 AM
rmacklem added a comment to D19887: fix the NFSv4 client so that it doesn't call pfind() with a mutex held.

Ok, the inline comments were still there, so I have just responded to them.

Sat, Apr 13, 4:36 AM
rmacklem updated the diff for D19887: fix the NFSv4 client so that it doesn't call pfind() with a mutex held.

This version of the patch brings in pfind_locked() from stable/12, but with the
sx_assert() changed.
Since the code the inline comments were applied to has been removed from this patch,
I'll try to address mjg@'s comments here:

  • Yes, the "optimization" I left in the code wouldn't have ever happened. I just left it in the code so that it looked more like _pfind(). Since that code isn't in pfind_locked(), it is gone.
  • The old pfind_locked() found zombie processes. I know that works ok and I'm not sure that the code would work correctly if zombie processes aren't found. Some of these open/lock_owners refer to opens, where a child of the zombie process might still have the file open. Delaying the cleanup of it until the children die only delays the garbage collection, so all that happens is a little malloc()d memory doesn't get released as soon. Since freeing the openowner prematurely would break things badly, I'd rather leave it finding zombie processes. (The code should delay the cleanup until all opens are closed, but...)
Sat, Apr 13, 4:29 AM

Fri, Apr 12

rmacklem created D19887: fix the NFSv4 client so that it doesn't call pfind() with a mutex held.
Fri, Apr 12, 3:00 AM

Sun, Apr 7

rmacklem added a comment to D19839: add INET6 support to nfsdumpstate for the client callback address.

Marked rgrimes@ inline comments as done, per his instructions.

Sun, Apr 7, 9:46 PM
rmacklem updated the diff for D19839: add INET6 support to nfsdumpstate for the client callback address.

This version of the patch has the changes mentioned in the inline comments.
A comment has been added explaining that INET[6]_ADDRSTRLEN includes
NULL termination and the length calculation has been changed to "-1 + 8"
from "+ 7" to make the calculation more understandable.

Sun, Apr 7, 8:34 PM
rmacklem added a comment to D19839: add INET6 support to nfsdumpstate for the client callback address.

Added replies to the inline comments. I will update the patch with the changes mentioned
in the replies later to-day.
Thanks for the review, rick

Sun, Apr 7, 3:21 PM
rmacklem updated the diff for D19839: add INET6 support to nfsdumpstate for the client callback address.

Fixed one place where I had typed AF_INET when it should have been AF_INET6.
This didn't seem to have caused problems during testing, so I don't think it actually mattered,
but it is now correct.

Sun, Apr 7, 1:31 AM
rmacklem created D19839: add INET6 support to nfsdumpstate for the client callback address.
Sun, Apr 7, 1:12 AM

Sat, Apr 6

rmacklem committed rS345995: Delete the BUGS entry related to failing when jails are enabled..
Delete the BUGS entry related to failing when jails are enabled.
Sat, Apr 6, 10:14 PM
rmacklem committed rS345994: Fix nfsuserd so that it handles the mapped localhost address when jails.
Fix nfsuserd so that it handles the mapped localhost address when jails
Sat, Apr 6, 10:06 PM
rmacklem committed rS345992: Add INET6 support for the upcalls to the nfsuserd daemon..
Add INET6 support for the upcalls to the nfsuserd daemon.
Sat, Apr 6, 9:53 PM
rmacklem closed D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.
Sat, Apr 6, 9:53 PM
rmacklem added a comment to D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.

Marked rgrimes inline comments done per his request.

Sat, Apr 6, 3:21 PM
rmacklem added a comment to D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.

Replied to the inline comments.

Sat, Apr 6, 5:24 AM
rmacklem updated the diff for D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.

Oops, I think I uploaded the wrong version of the diff. Here is
the correct one with updated kernel changes that include #ifdef INET and INET6.

Sat, Apr 6, 1:51 AM
rmacklem updated the diff for D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.

This version of the patch has an updated set of kernel changes
against head that include the #ifdef INET and INET6.

Sat, Apr 6, 1:34 AM

Thu, Apr 4

rmacklem committed rS345898: Add an entry to UPDATING for r345895, which affects the use of nfsuserd daemons.
Add an entry to UPDATING for r345895, which affects the use of nfsuserd daemons
Thu, Apr 4, 11:40 PM
rmacklem committed rS345895: Revert r320698, since the related userland changes were reverted by r338192..
Revert r320698, since the related userland changes were reverted by r338192.
Thu, Apr 4, 11:30 PM
rmacklem committed rS345866: Fix malloc stats for the RPCSEC_GSS server code when DEBUG is enabled..
Fix malloc stats for the RPCSEC_GSS server code when DEBUG is enabled.
Thu, Apr 4, 1:23 AM

Wed, Apr 3

rmacklem committed rS345828: Add a comment to the r345818 patch to explain why cl_refs is initialized to 2..
Add a comment to the r345818 patch to explain why cl_refs is initialized to 2.
Wed, Apr 3, 3:50 AM

Tue, Apr 2

rmacklem committed rS345818: Fix a race in the RPCSEC_GSS server code that caused crashes..
Fix a race in the RPCSEC_GSS server code that caused crashes.
Tue, Apr 2, 11:51 PM

Mar 11 2019

rmacklem accepted D19458: Drop unused 'p' argument to nfsvno_link();.

Looks ok, rick

Mar 11 2019, 11:02 PM
rmacklem accepted D19457: Drop unused 'p' argument to nfsvno_rmdirsub();.

Looks ok, rick

Mar 11 2019, 11:01 PM
rmacklem accepted D19456: Drop unused 'p' argument to nfsvno_readlink();.

Looks ok, rick

Mar 11 2019, 11:01 PM
rmacklem accepted D19455: Drop unused 'p' argument to nfsrv_getuser()..

Looks ok, rick

Mar 11 2019, 11:00 PM
rmacklem accepted D19454: Drop unused 'p' argument to nfsvno_getfh()..

Looks ok, rick

Mar 11 2019, 10:59 PM
rmacklem accepted D19453: Drop unused 'p' argument to nfsrv_findlayout()..

Looks ok, rick

Mar 11 2019, 10:57 PM
rmacklem accepted D19452: Drop unused 'p' argument to nfsrv_checksequence()..

Looks ok, rick

Mar 11 2019, 10:56 PM
rmacklem accepted D19451: Drop unused 'p' argument to nfsvno_symlink()..

Looks ok, rick

Mar 11 2019, 10:55 PM
rmacklem accepted D19450: Drop unused 'p' argument to nfsvno_mkdir()..

Looks ok, rick

Mar 11 2019, 10:54 PM
rmacklem accepted D19449: Drop unused 'p' argument to nfsvno_mknod()..

Looks ok, rick

Mar 11 2019, 10:53 PM
rmacklem accepted D19448: Don't pass td to nfsvno_fillattr()..

Looks ok, rick

Mar 11 2019, 10:53 PM
rmacklem accepted D19447: Don't pass td to nfsrv_checkgetattr()..

Looks ok, rick

Mar 11 2019, 10:52 PM
rmacklem accepted D19445: Don't pass td to nfsrvd_mkdirsub() and nfsrvd_symlinksub()..

Looks ok, rick

Mar 11 2019, 10:51 PM
rmacklem accepted D19444: Don't pass td to nfsrv_opencheck()..

Looks ok, rick

Mar 11 2019, 10:50 PM
rmacklem accepted D19443: Don't pass td to nfsrv_pnfscreate()..

Loos ok, rick

Mar 11 2019, 10:48 PM
rmacklem accepted D19442: Push td down nfsvno_accchk()..

Looks ok, rick

Mar 11 2019, 10:46 PM

Mar 2 2019

rmacklem accepted D19417: Push down td in nfsrvd_dorpc()..

Look ok to me.

Mar 2 2019, 8:32 PM
rmacklem accepted D19419: Push down td in the NFS server code..

Looks ok. I'm not sure I understand why having a lot of "struct thread *p = curthread;"s in
the local variables of the functions is an improvement over passing it as an argument,
but I see no harm in it?

Mar 2 2019, 8:31 PM
rmacklem accepted D19421: Don't pass td to nfsd_fhtovp()..

Looks ok to me.

Mar 2 2019, 8:26 PM
rmacklem accepted D19423: Push td down into nfssvc_srvcall()..

Looks ok to me.

Mar 2 2019, 8:25 PM

Mar 1 2019

rmacklem added a comment to D19153: Handle SIGPIPE in gssd, and limit kgssapi RPC retries.

My concern is that all sorts of signals get posted to processes and you don't want any old
signal to interrupt an attempt at an upcall. The failure of a gssd should be a rare occurrence
and so long as the upcall doesn't try "forever", I think that will be sufficient.

Mar 1 2019, 11:44 PM
rmacklem added a comment to D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.

Yes, sometime in April I will revert the AF_LOCAL patch from head and then create an updated (simpler)
kernel patch, including the #ifdef INET/INET6.

Mar 1 2019, 11:19 PM

Feb 24 2019

rmacklem updated the diff for D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.

This patch has the .include <src.opts.mk> added to the Makefile and has the kernel
patch, which I was going to leave until later, but bz@ wanted to compile the code,
so here it is.
(Note that the kernel patch mostly replaces the AF_LOCAL socket code that is unused,
because the patch to nfsuserd.c for this was reverted and never MFC'd. As such, the kernel
changes won't apply to a stable branch and is only for head. I am planning on first reverting
the kernel change for AF_LOCAL and then applying the changes, so the patch that will be
committed to head for the kernel changes won't look the same as this patch, although the
post-commit code should look the same.)

Feb 24 2019, 10:35 PM
rmacklem updated the diff for D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.

Updated the patch with changes suggested by bz@. I did not change the usage
of INET6_LOOOPBACK_INIT, since I couldn't see an easy way to use it to initialize
a "struct sockaddr_storage". (There might be a C trick to using this initializer
that I don't know about.

Feb 24 2019, 2:35 AM

Feb 22 2019

rmacklem added a comment to D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.

Oops, my mistake. I didn't notice he had made multiple comments.
I see it now and will add the ifdefs.

Feb 22 2019, 10:45 PM
rmacklem added a comment to D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.

Whether or not "#ifdef INET6" and "#ifdef INET" should be in the code is still an open question.
I was hoping bz@ could answer this?
(I, personally, was of the understanding that this was no longer required/recommended for
FreeBSD sources. If bz@ does not know the correct answer for this, I will ask on freebsd-net@.)
At this point I have made no changes to the Makefile.
To build/run it, there is a small kernel change required, but I did not include that in this review.

Feb 22 2019, 12:44 AM

Feb 21 2019

rmacklem updated the diff for D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.

This version of the patch includes the changes that bz@ recommended.
I think he meant sockaddr_storage when he said sockaddr_union, so I
made "fromip" one of those instead of having both "fromip" and "fromip6"
plus "use_inet6" to decide which to use.
It uses INET6 if it can and uses the INADDR_LOOPBACK and IN6ADDR_LOOPBACK_INIT
macros.

Feb 21 2019, 3:06 AM

Feb 18 2019

rmacklem added a comment to D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.

W.r.t. the NFS root mount, you are sort of correct at this time.
What would happen for an NFSv4 root mount at this time is
that the NFS client code would have a miss on the "uid<->username"
cache and attempt an upcall to the nfsuserd, which would not
work. (I think it will eventually fail and use "nobody", but I'd have
to look at the code to be sure.
As such, NFSv4 root mounts are not currently recommended, but I
would like to resolve that someday.

Feb 18 2019, 3:39 PM
rmacklem updated the diff for D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.

Added a comment w.r.t. why "localhost" is hardcoded. I will also note that the kernel will
use these hardcoped values (I don't believe the kernel can do a name lookup and I wouldn't
want it to in this case), so the code doesn't want to use any other value, if a sysadmin were
to change the values for "localhost".

Feb 18 2019, 2:07 AM
rmacklem added a comment to D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.

The problem with doing a name lookup in this daemon is that it assumes/expects it
to work. Often (an NFS mounted root fs is one example and a system configured to
use DNS before the local /etc/hosts file) are not yet working and an NFS mount is
expected to work.
(ie. In general I'd agree with you, but for NFS not so much...)

Feb 18 2019, 1:22 AM

Feb 16 2019

rmacklem created D19218: fix nfsuserd to find a mapped "localhost" ip address and to use INET6 when INET isn't available.
Feb 16 2019, 10:50 PM

Feb 15 2019

rmacklem accepted D19191: Add support for a virtual hostname to nfsd.

Looks fine to me now. Thanks, rick

Feb 15 2019, 11:51 PM
rmacklem added a comment to D19191: Add support for a virtual hostname to nfsd.

Thanks for adding the strlen() check. I am going to be nitpicky and suggest an
error message be printed (not sure if the nfsd should fail or just log an error?),
since silently ignoring the "-V" argument could cause confusion too, I think?

Feb 15 2019, 2:54 PM
rmacklem accepted D19191: Add support for a virtual hostname to nfsd.

Looks ok to me. (I'll admit I don't understand when it is useful, but that's ok.;-)
The one change I might suggest is a sanity check for the strlen() of the "-V" optarg
being <= MAXHOSTNAMELEN.

Feb 15 2019, 12:02 AM

Feb 12 2019

rmacklem accepted D19153: Handle SIGPIPE in gssd, and limit kgssapi RPC retries.

This one looks fine to me, rick.

Feb 12 2019, 2:37 PM
rmacklem added a comment to D19153: Handle SIGPIPE in gssd, and limit kgssapi RPC retries.

First off, I should note that I am not the author of this code. If dfr@ could review this, that could be better.

Feb 12 2019, 1:41 AM

Dec 29 2018

rmacklem committed rS342582: Add an UPDATING entry for r342562..
Add an UPDATING entry for r342562.
Dec 29 2018, 12:06 AM
rmacklem committed rS342581: Add an UPDATING entry for r342561..
Add an UPDATING entry for r342561.
Dec 29 2018, 12:01 AM

Dec 28 2018

rmacklem committed rS342562: MFC: r342286.
MFC: r342286
Dec 28 2018, 12:26 AM
rmacklem committed rS342561: MFC: r342286.
MFC: r342286
Dec 28 2018, 12:10 AM

Dec 20 2018

rmacklem committed rS342287: Add an UPDATING message for r342286..
Add an UPDATING message for r342286.
Dec 20 2018, 10:27 PM
rmacklem committed rS342286: Fix the NFSv4 server to obey vfs.nfsd.nfs_privport..
Fix the NFSv4 server to obey vfs.nfsd.nfs_privport.
Dec 20 2018, 10:21 PM

Dec 18 2018

rmacklem committed rS342186: Delete an unneeded statement, since "tl" isn't used after this line..
Delete an unneeded statement, since "tl" isn't used after this line.
Dec 18 2018, 6:09 AM

Dec 17 2018

rmacklem committed rS342155: Merge in an up to date kernel from head..
Merge in an up to date kernel from head.
Dec 17 2018, 12:34 AM

Dec 1 2018

rmacklem accepted D18393: Add kern.rpc.gss.client_max.

Looks fine to me, although I'll admit I've never noticed there was a CLIENT_MAX in this code.
(I wasn't the author.)

Dec 1 2018, 1:09 AM

Nov 23 2018

rmacklem committed rS340787: Make sure the NFS readdir client fills in all "struct dirent" data..
Make sure the NFS readdir client fills in all "struct dirent" data.
Nov 23 2018, 12:17 AM

Nov 20 2018

rmacklem committed rS340663: Improve sanity checking for the dircount hint argument to.
Improve sanity checking for the dircount hint argument to
Nov 20 2018, 2:00 AM
rmacklem committed rS340662: nfsm_advance() would panic() when the offs argument was negative..
nfsm_advance() would panic() when the offs argument was negative.
Nov 20 2018, 1:56 AM
rmacklem committed rS340661: r304026 added code that started statistics gathering for an operation.
r304026 added code that started statistics gathering for an operation
Nov 20 2018, 1:52 AM