2015-12-26 11:59:35

by dE

[permalink] [raw]
Subject: How do you get /proc/fs/nfs/exports to populate?

Hi!
I'm running nfs-utils without init script or systemd unit assistance.

Since I'm using nfsv4, I'm eliminating the need to start mountd.

Now if mountd is gone, who populates /proc/fs/nfs/exports?

But even after running mountd (after an exportfs -a), this file still
does not have any entries.

Running rpc.nfsd with --

rpc.nfsd -d --syslog --port 10000

rpc.mountd runs without any arguments.


2015-12-28 09:40:57

by dE

[permalink] [raw]
Subject: Re: How do you get /proc/fs/nfs/exports to populate?

Ok, got it.

It happens that those are made after a mount request.

On 12/26/15 17:29, dE wrote:
> Hi!
> I'm running nfs-utils without init script or systemd unit assistance.
>
> Since I'm using nfsv4, I'm eliminating the need to start mountd.
>
> Now if mountd is gone, who populates /proc/fs/nfs/exports?
>
> But even after running mountd (after an exportfs -a), this file still
> does not have any entries.
>
> Running rpc.nfsd with --
>
> rpc.nfsd -d --syslog --port 10000
>
> rpc.mountd runs without any arguments.


2015-12-28 15:21:20

by Jeff Layton

[permalink] [raw]
Subject: Re: How do you get /proc/fs/nfs/exports to populate?

On Mon, 28 Dec 2015 15:11:03 +0530
dE <[email protected]> wrote:

> Ok, got it.
>
> It happens that those are made after a mount request.
>

Well, there is no such thing as a mount request, per-se in NFSv4. What
happens is that you try to walk down to the point where you're mounting
and access that inode, and nfsd upcalls to mountd to see whether that's
allowed. That populates the cache.

You can't really run nfsd without mountd (or something equivalent)
since something needs to populate the exports table. If you're running
a v4-only server though, then mountd doesn't need to be network-facing
however.

> On 12/26/15 17:29, dE wrote:
> > Hi!
> > I'm running nfs-utils without init script or systemd unit assistance.
> >
> > Since I'm using nfsv4, I'm eliminating the need to start mountd.
> >
> > Now if mountd is gone, who populates /proc/fs/nfs/exports?
> >
> > But even after running mountd (after an exportfs -a), this file still
> > does not have any entries.
> >
> > Running rpc.nfsd with --
> >
> > rpc.nfsd -d --syslog --port 10000
> >
> > rpc.mountd runs without any arguments.
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
> the body of a message to [email protected]
> More majordomo info at http://vger.kernel.org/majordomo-info.html


--
Jeff Layton <[email protected]>

2015-12-29 03:17:16

by dE

[permalink] [raw]
Subject: Re: How do you get /proc/fs/nfs/exports to populate?

Thanks for clearing that up. Explains the erratic behavior without mountd.

On 12/28/15 20:51, Jeff Layton wrote:
> On Mon, 28 Dec 2015 15:11:03 +0530
> dE <[email protected]> wrote:
>
>> Ok, got it.
>>
>> It happens that those are made after a mount request.
>>
> Well, there is no such thing as a mount request, per-se in NFSv4. What
> happens is that you try to walk down to the point where you're mounting
> and access that inode, and nfsd upcalls to mountd to see whether that's
> allowed. That populates the cache.
>
> You can't really run nfsd without mountd (or something equivalent)
> since something needs to populate the exports table. If you're running
> a v4-only server though, then mountd doesn't need to be network-facing
> however.
>
>> On 12/26/15 17:29, dE wrote:
>>> Hi!
>>> I'm running nfs-utils without init script or systemd unit assistance.
>>>
>>> Since I'm using nfsv4, I'm eliminating the need to start mountd.
>>>
>>> Now if mountd is gone, who populates /proc/fs/nfs/exports?
>>>
>>> But even after running mountd (after an exportfs -a), this file still
>>> does not have any entries.
>>>
>>> Running rpc.nfsd with --
>>>
>>> rpc.nfsd -d --syslog --port 10000
>>>
>>> rpc.mountd runs without any arguments.
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
>> the body of a message to [email protected]
>> More majordomo info at http://vger.kernel.org/majordomo-info.html
>