Bug 194084 - [PATCH] Add IPv6 support for quota(1)
Summary: [PATCH] Add IPv6 support for quota(1)
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: 10.1-STABLE
Hardware: Any Any
: --- Affects Some People
Assignee: Hiroki Sato
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-10-02 06:52 UTC by John Marshall
Modified: 2015-07-20 22:18 UTC (History)
3 users (show)

See Also:


Attachments
IPv6 support for quota(1) (1.88 KB, patch)
2014-10-02 06:52 UTC, John Marshall
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description John Marshall 2014-10-02 06:52:28 UTC
Created attachment 147899 [details]
IPv6 support for quota(1)

Bug 42004 included relevant patches for usr.bin/quota/quota.c and for usr.sbin/rpc.statd/procs.c. The rpc.statd patch was applied to CURRENT 7.5 years ago but the PR was closed without ever applying the quota.c patch. This means that quota(1) over IPv6 has still never worked.

I applied the quota.c patch from Bug 42004 to 10.1-BETA3 and, apart from an 8 line offset, it applied cleanly. I also patched inetd.conf to add a udp6 listener for rpc.quotad on the NFS server and now quota(1) works for me on 10.1-BETA3 (client and server) over IPv6.

Again, this is not MY patch: it was submitted by Jean-Luc Richier with PR 42004 back in 2002. All I did was find it, apply it and test it.
Comment 1 Hiroki Sato freebsd_committer freebsd_triage 2014-10-02 07:36:39 UTC
I will take a look into this.
Comment 2 Marcus von Appen freebsd_committer freebsd_triage 2015-02-18 11:54:20 UTC
Updated 10.1-BETA and 10.1-RC versioned bugs to 10.1-STABLE.
Comment 3 Glen Barber freebsd_committer freebsd_triage 2015-07-07 15:33:59 UTC
Hiroki, have you had a chance to look into this?
Comment 4 commit-hook freebsd_committer freebsd_triage 2015-07-07 20:15:27 UTC
A commit references this bug:

Author: hrs
Date: Tue Jul  7 20:15:10 UTC 2015
New revision: 285253
URL: https://svnweb.freebsd.org/changeset/base/285253

Log:
  - Add IPv6 support in quota(1).  While rpc.rquotad has supported PF_INET6
    for a long time, quota(1) utility supported only PF_INET.

  - Clean up confusing changes in f_mntfromname.

  - Add an entry for rquotad with rpc/udp6 to inetd.conf.

  PR:	194084

Changes:
  head/etc/inetd.conf
  head/usr.bin/quota/quota.c
Comment 5 John Marshall 2015-07-07 23:05:18 UTC
(In reply to commit-hook from comment #4)
Thank you Hiroki!

I merged your r285253 commit to stable/10@r284296 on a local IPv6 client, rebuilt and installed quota.c with good results - the client 'quota' command now returns quota results from an IPv6-mounted NFS filesystem instead of hanging.

Your commit log message does not mention MFC. Are there plans to MFC this commit to stable/10 before 10.2-RELEASE?

Thank you so much Glen and Hiroki for looking at this.
Comment 6 Hiroki Sato freebsd_committer freebsd_triage 2015-07-08 00:38:19 UTC
(In reply to John Marshall from comment #5)

Yes, I will MFC it after waiting for a couple of days to make sure there is no problem with this change, and hopefully to include it into 10.2.
Comment 7 John Marshall 2015-07-15 01:08:40 UTC
(In reply to Hiroki Sato from comment #6)
Thank you very much. It would be wonderful if the MFC could be done before BETA2 is built.
Comment 8 commit-hook freebsd_committer freebsd_triage 2015-07-20 21:52:47 UTC
A commit references this bug:

Author: gjb
Date: Mon Jul 20 21:52:07 UTC 2015
New revision: 285725
URL: https://svnweb.freebsd.org/changeset/base/285725

Log:
  MFC r285253 (hrs):
   - Add IPv6 support in quota(1).  While rpc.rquotad has supported
     PF_INET6 for a long time, quota(1) utility supported only PF_INET.
   - Clean up confusing changes in f_mntfromname.
   - Add an entry for rquotad with rpc/udp6 to inetd.conf.

  PR:		194084
  Approved by:	re (kib)
  Sponsored by:	The FreeBSD Foundation

Changes:
_U  stable/10/
  stable/10/etc/inetd.conf
  stable/10/usr.bin/quota/quota.c
Comment 9 commit-hook freebsd_committer freebsd_triage 2015-07-20 22:17:51 UTC
A commit references this bug:

Author: gjb
Date: Mon Jul 20 22:17:12 UTC 2015
New revision: 285727
URL: https://svnweb.freebsd.org/changeset/base/285727

Log:
  MFC r285253 (hrs):
   - Add IPv6 support in quota(1).  While rpc.rquotad has supported
     PF_INET6 for a long time, quota(1) utility supported only PF_INET.
   - Clean up confusing changes in f_mntfromname.
   - Add an entry for rquotad with rpc/udp6 to inetd.conf.

  PR:		194084
  Sponsored by:	The FreeBSD Foundation

Changes:
_U  stable/9/etc/
  stable/9/etc/inetd.conf
_U  stable/9/usr.bin/
  stable/9/usr.bin/quota/quota.c
Comment 10 Glen Barber freebsd_committer freebsd_triage 2015-07-20 22:18:44 UTC
Merges to stable/10 and stable/9 complete.
Thanks!