Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.os.linux.misc > #66781 > unrolled thread

Here's One - NFS - Mounting Over Share = Nada

Started byc186282 <c186282@nnada.net>
First post2025-04-01 21:29 -0400
Last post2025-04-03 12:38 +0100
Articles 20 on this page of 32 — 6 participants

Back to article view | Back to comp.os.linux.misc


Contents

  Here's One - NFS - Mounting Over Share = Nada c186282 <c186282@nnada.net> - 2025-04-01 21:29 -0400
    Re: Here's One - NFS - Mounting Over Share = Nada "Carlos E.R." <robin_listas@es.invalid> - 2025-04-02 12:35 +0200
      Re: Here's One - NFS - Mounting Over Share = Nada The Natural Philosopher <tnp@invalid.invalid> - 2025-04-02 11:48 +0100
        Re: Here's One - NFS - Mounting Over Share = Nada "Carlos E.R." <robin_listas@es.invalid> - 2025-04-02 13:18 +0200
          Re: Here's One - NFS - Mounting Over Share = Nada The Natural Philosopher <tnp@invalid.invalid> - 2025-04-02 18:04 +0100
            Re: Here's One - NFS - Mounting Over Share = Nada c186282 <c186282@nnada.net> - 2025-04-03 05:51 -0400
              Re: Here's One - NFS - Mounting Over Share = Nada The Natural Philosopher <tnp@invalid.invalid> - 2025-04-03 11:08 +0100
              Re: Here's One - NFS - Mounting Over Share = Nada "Carlos E.R." <robin_listas@es.invalid> - 2025-04-03 14:07 +0200
                Re: Here's One - NFS - Mounting Over Share = Nada c186282 <c186282@nnada.net> - 2025-04-03 11:27 -0400
                  Re: Here's One - NFS - Mounting Over Share = Nada Ralf Fassel <ralfixx@gmx.de> - 2025-04-03 18:36 +0200
                    Re: Here's One - NFS - Mounting Over Share = Nada The Natural Philosopher <tnp@invalid.invalid> - 2025-04-03 18:09 +0100
                      Re: Here's One - NFS - Mounting Over Share = Nada c186282 <c186282@nnada.net> - 2025-04-03 16:42 -0400
                    Re: Here's One - NFS - Mounting Over Share = Nada c186282 <c186282@nnada.net> - 2025-04-03 15:27 -0400
                  Re: Here's One - NFS - Mounting Over Share = Nada The Natural Philosopher <tnp@invalid.invalid> - 2025-04-03 18:08 +0100
                    Re: Here's One - NFS - Mounting Over Share = Nada "Carlos E.R." <robin_listas@es.invalid> - 2025-04-03 20:48 +0200
                      Re: Here's One - NFS - Mounting Over Share = Nada c186282 <c186282@nnada.net> - 2025-04-03 15:49 -0400
    Re: Here's One - NFS - Mounting Over Share = Nada vallor <vallor@cultnix.org> - 2025-04-02 10:49 +0000
      Re: Here's One - NFS - Mounting Over Share = Nada c186282 <c186282@nnada.net> - 2025-04-02 07:12 -0400
      Re: Here's One - NFS - Mounting Over Share = Nada "Carlos E.R." <robin_listas@es.invalid> - 2025-04-02 13:14 +0200
        Re: Here's One - NFS - Mounting Over Share = Nada c186282 <c186282@nnada.net> - 2025-04-02 07:39 -0400
          Re: Here's One - NFS - Mounting Over Share = Nada "Carlos E.R." <robin_listas@es.invalid> - 2025-04-02 14:19 +0200
            Re: Here's One - NFS - Mounting Over Share = Nada c186282 <c186282@nnada.net> - 2025-04-02 08:38 -0400
              Re: Here's One - NFS - Mounting Over Share = Nada "Carlos E.R." <robin_listas@es.invalid> - 2025-04-02 15:30 +0200
        Re: Here's One - NFS - Mounting Over Share = Nada vallor <vallor@cultnix.org> - 2025-04-02 11:40 +0000
          Re: Here's One - NFS - Mounting Over Share = Nada c186282 <c186282@nnada.net> - 2025-04-02 08:08 -0400
            Re: Here's One - NFS - Mounting Over Share = Nada "Carlos E.R." <robin_listas@es.invalid> - 2025-04-02 14:25 +0200
          Re: Here's One - NFS - Mounting Over Share = Nada "Carlos E.R." <robin_listas@es.invalid> - 2025-04-02 14:15 +0200
            Re: Here's One - NFS - Mounting Over Share = Nada Computer Nerd Kev <not@telling.you.invalid> - 2025-04-03 16:40 +1000
              Re: Here's One - NFS - Mounting Over Share = Nada c186282 <c186282@nnada.net> - 2025-04-03 06:19 -0400
                Re: Here's One - NFS - Mounting Over Share = Nada The Natural Philosopher <tnp@invalid.invalid> - 2025-04-03 12:03 +0100
                  Re: Here's One - NFS - Mounting Over Share = Nada c186282 <c186282@nnada.net> - 2025-04-03 07:27 -0400
                    Re: Here's One - NFS - Mounting Over Share = Nada The Natural Philosopher <tnp@invalid.invalid> - 2025-04-03 12:38 +0100

Page 1 of 2  [1] 2  Next page →


#66781 — Here's One - NFS - Mounting Over Share = Nada

Fromc186282 <c186282@nnada.net>
Date2025-04-01 21:29 -0400
SubjectHere's One - NFS - Mounting Over Share = Nada
Message-ID<UQ-dndQV6amaDnH6nZ2dnZfqnPednZ2d@giganews.com>
Here's an interesting problem ....

I re-mount USB drives onto NFS share points.
The problem is that NFS doesn't SEE that - it
only sees the previously empty dir instead.
Add a tag file to that dir and that's ALL you
will see in the share on another PC.

Tried variations of exportfs ... including the
'-r' and '-au' then '-a' AFTER doing the mount.
Sorry, the clients can't see the mount. The NFS
stuff seems to cut in very early - before the
USB re-mounts (done @reboot). If you look on the
host machine you DO see the USB drives, but
NEVER over the NFS share.

Why re-mount the USBs ? Because you can't
always rely on Linux to mount them in the
same order, used to be even the same place.
'/media/<user>/whatever' seems hard-wired
these days, but with multiple USB drives
you still can't count on drive 1 being
the drive 1 in /media/<user>. Kinda
depends on which comes online first.
Naming the drives helps, but even then.

And no, symlinks to some other mount point
don't work ... NFS just shares a link to
nowhere on the clients. 'hard' links ???

Have ONE share that's not a re-mounted
anything - THAT always shows perfectly
on the clients. Weird thing, somehow, at
one point I DID get it to work - but not
sure HOW. Just commented-out the old NFS
and fstab stuff, so I've been able to
re-try, but now none work. Set everything
to 775 or 777 for development work, but
that doesn't help.

SAMBA - this sort of thing works fine, but
I've had horrible probs with SAMBA with the
latest distros, ALWAYS intractable permissions
issues no matter the tweaks, hence using NFS.

So ... any insights on how to get NFS to
"see" whatever IS mounted to the share point
AT THE MOMENT ???

Oh, latest MX Linux.

[toc] | [next] | [standalone]


#66787

From"Carlos E.R." <robin_listas@es.invalid>
Date2025-04-02 12:35 +0200
Message-ID<6ggvblxiu5.ln2@Telcontar.valinor>
In reply to#66781
On 2025-04-02 03:29, c186282 wrote:
> So ... any insights on how to get NFS to
> "see" whatever IS mounted to the share point
> AT THE MOMENT ???

Restart NFS manually after the manual mount of external media.

Or, define the usb mounts in fstab, and exports. But then, you can not 
boot without the usb media.

-- 
Cheers, Carlos.

[toc] | [prev] | [next] | [standalone]


#66790

FromThe Natural Philosopher <tnp@invalid.invalid>
Date2025-04-02 11:48 +0100
Message-ID<vsj4l2$1jt3k$4@dont-email.me>
In reply to#66787
On 02/04/2025 11:35, Carlos E.R. wrote:
> On 2025-04-02 03:29, c186282 wrote:
>> So ... any insights on how to get NFS to
>> "see" whatever IS mounted to the share point
>> AT THE MOMENT ???
> 
> Restart NFS manually after the manual mount of external media.
> 
> Or, define the usb mounts in fstab, and exports. But then, you can not 
> boot without the usb media.
> 
I missed the earlier part, but mount | grep nfs...shows what is mounted

or mount | grep mount-point...

-- 
For in reason, all government without the consent of the governed is the 
very definition of slavery.

Jonathan Swift

[toc] | [prev] | [next] | [standalone]


#66795

From"Carlos E.R." <robin_listas@es.invalid>
Date2025-04-02 13:18 +0200
Message-ID<61jvblx7ff.ln2@Telcontar.valinor>
In reply to#66790
On 2025-04-02 12:48, The Natural Philosopher wrote:
> On 02/04/2025 11:35, Carlos E.R. wrote:
>> On 2025-04-02 03:29, c186282 wrote:
>>> So ... any insights on how to get NFS to
>>> "see" whatever IS mounted to the share point
>>> AT THE MOMENT ???
>>
>> Restart NFS manually after the manual mount of external media.
>>
>> Or, define the usb mounts in fstab, and exports. But then, you can not 
>> boot without the usb media.
>>
> I missed the earlier part, but mount | grep nfs...shows what is mounted
> 
> or mount | grep mount-point...
> 

The point he syas is that when exporting "/media/<user>/usbsomething", 
the clients can not see the files, only the mount point.

-- 
Cheers, Carlos.

[toc] | [prev] | [next] | [standalone]


#66806

FromThe Natural Philosopher <tnp@invalid.invalid>
Date2025-04-02 18:04 +0100
Message-ID<vsjqni$2bgo0$1@dont-email.me>
In reply to#66795
On 02/04/2025 12:18, Carlos E.R. wrote:
> On 2025-04-02 12:48, The Natural Philosopher wrote:
>> On 02/04/2025 11:35, Carlos E.R. wrote:
>>> On 2025-04-02 03:29, c186282 wrote:
>>>> So ... any insights on how to get NFS to
>>>> "see" whatever IS mounted to the share point
>>>> AT THE MOMENT ???
>>>
>>> Restart NFS manually after the manual mount of external media.
>>>
>>> Or, define the usb mounts in fstab, and exports. But then, you can 
>>> not boot without the usb media.
>>>
>> I missed the earlier part, but mount | grep nfs...shows what is mounted
>>
>> or mount | grep mount-point...
>>
> 
> The point he syas is that when exporting "/media/<user>/usbsomething", 
> the clients can not see the files, only the mount point.
> 
So he is trying to export a mounted partition?

I always start with ...

*(ro,sync,no_root_squash,no_subtree_check)

In /etc/exports for the least restricted export

-- 
Climate is what you expect but weather is what you get.
Mark Twain

[toc] | [prev] | [next] | [standalone]


#66825

Fromc186282 <c186282@nnada.net>
Date2025-04-03 05:51 -0400
Message-ID<FLadnWvzcO68x3P6nZ2dnZfqnPidnZ2d@giganews.com>
In reply to#66806
On 4/2/25 1:04 PM, The Natural Philosopher wrote:
> On 02/04/2025 12:18, Carlos E.R. wrote:
>> On 2025-04-02 12:48, The Natural Philosopher wrote:
>>> On 02/04/2025 11:35, Carlos E.R. wrote:
>>>> On 2025-04-02 03:29, c186282 wrote:
>>>>> So ... any insights on how to get NFS to
>>>>> "see" whatever IS mounted to the share point
>>>>> AT THE MOMENT ???
>>>>
>>>> Restart NFS manually after the manual mount of external media.
>>>>
>>>> Or, define the usb mounts in fstab, and exports. But then, you can 
>>>> not boot without the usb media.
>>>>
>>> I missed the earlier part, but mount | grep nfs...shows what is mounted
>>>
>>> or mount | grep mount-point...
>>>
>>
>> The point he syas is that when exporting "/media/<user>/usbsomething", 
>> the clients can not see the files, only the mount point.
>>
> So he is trying to export a mounted partition?
> 
> I always start with ...
> 
> *(ro,sync,no_root_squash,no_subtree_check)
> 
> In /etc/exports for the least restricted export

   Ok, tried your param list ... but still nada on
   the later-login mounts. Exportfs adds a bunch of
   other defaults to etab.

   It's VERY annoying.

   As best I can tell, NFS cuts in VERY early and there
   is no sane way to stop/delay it. As such it ONLY sees
   the original, empty, folder we are later gonna
   remount the USBs to.

   Have a 4-drive external USB fixture. The drives USUALLY
   come up in order, but experience sez they won't ALWAYS
   do that. Depends on how quick the drives initialize,
   and there's one magnetic in the mix. sda/sdb/etc may
   not ALWAYS, reliably, be the same physical drives.
   A Python script can more easily probe/parse info that
   can individually identify, that's the next stage.

   Anyway, the drives (sometimes) come up in /media/<user>
   and I have a mount statement that mounts them in my
   NFS share dir, under the appropriate sub-folder.

   BUT, NFS just doesn't SEE that - only what was there
   (nothing) a microsec after the system boots. Have NOT
   been able to use exportfs to change that no matter
   the params.

   It's vexing - I want to use the USB cluster as NAS
   yet this behavior is in the way. BTW there can also
   be other, more interesting, uses to being able to
   mount/umount/remount different USB drives and such
   in a dynamic manner ... maybe soon.

   Have a crontab now that tries to remount the USBs
   to the NAS folders every 5 minutes. Doesn't help.

   Anyway, not sure NFS can *do* what I need it to do.
   It's great at sharing pre-existing pre-stuffed
   subdirs - have security cam backups going there -
   but so far just WON'T handle later mount statements.

   As said somewhere, have had horrible probs with SAMBA
   in the latest distros - all the online advice and past
   experience do NOT get around permissions issues. You
   can see the SAMBA share is *there*, just not log on.
   They CHANGED something recently and it's ill-documented.
   SAMBA *can* cope with the to-the-second mounts, have
   used it that way before, even INTERNALLY on a NAS
   box so backup pgms would work easily.

   As for whomever bitched about '/var/libs' vs '/var/lib',
   QUIT NIT-PICKING ... typos happen ALL the time. Sorry,
   not everyone is 'Vulcan' or 'AI' or whatever ......

[toc] | [prev] | [next] | [standalone]


#66829

FromThe Natural Philosopher <tnp@invalid.invalid>
Date2025-04-03 11:08 +0100
Message-ID<vslmnj$bemd$3@dont-email.me>
In reply to#66825
On 03/04/2025 10:51, c186282 wrote:
> On 4/2/25 1:04 PM, The Natural Philosopher wrote:
>> On 02/04/2025 12:18, Carlos E.R. wrote:
>>> On 2025-04-02 12:48, The Natural Philosopher wrote:
>>>> On 02/04/2025 11:35, Carlos E.R. wrote:
>>>>> On 2025-04-02 03:29, c186282 wrote:
>>>>>> So ... any insights on how to get NFS to
>>>>>> "see" whatever IS mounted to the share point
>>>>>> AT THE MOMENT ???
>>>>>
>>>>> Restart NFS manually after the manual mount of external media.
>>>>>
>>>>> Or, define the usb mounts in fstab, and exports. But then, you can 
>>>>> not boot without the usb media.
>>>>>
>>>> I missed the earlier part, but mount | grep nfs...shows what is mounted
>>>>
>>>> or mount | grep mount-point...
>>>>
>>>
>>> The point he syas is that when exporting 
>>> "/media/<user>/usbsomething", the clients can not see the files, only 
>>> the mount point.
>>>
>> So he is trying to export a mounted partition?
>>
>> I always start with ...
>>
>> *(ro,sync,no_root_squash,no_subtree_check)
>>
>> In /etc/exports for the least restricted export
> 
>    Ok, tried your param list ... but still nada on
>    the later-login mounts. Exportfs adds a bunch of
>    other defaults to etab.
> 
>    It's VERY annoying.
> 
>    As best I can tell, NFS cuts in VERY early and there
>    is no sane way to stop/delay it. As such it ONLY sees
>    the original, empty, folder we are later gonna
>    remount the USBs to.
> 
There is an insane way, using systemd to delay it.
Or you could try automounting

Or write an explicit script and run it a minute after booting

Occasionally my Laptop doesn't mount my server because the Wifi tokk too 
long to connect.


>    Have a 4-drive external USB fixture. The drives USUALLY
>    come up in order, but experience sez they won't ALWAYS
>    do that. Depends on how quick the drives initialize,
>    and there's one magnetic in the mix. sda/sdb/etc may
>    not ALWAYS, reliably, be the same physical drives.
>    A Python script can more easily probe/parse info that
>    can individually identify, that's the next stage.
> 
>    Anyway, the drives (sometimes) come up in /media/<user>
>    and I have a mount statement that mounts them in my
>    NFS share dir, under the appropriate sub-folder.
> 
Why not put them in your fstab and explicitly mount them at boot time?

>    BUT, NFS just doesn't SEE that - only what was there
>    (nothing) a microsec after the system boots. Have NOT
>    been able to use exportfs to change that no matter
>    the params.
> 
NFS comes up after the system scans fstab

>    It's vexing - I want to use the USB cluster as NAS
>    yet this behavior is in the way. BTW there can also
>    be other, more interesting, uses to being able to
>    mount/umount/remount different USB drives and such
>    in a dynamic manner ... maybe soon.
> 
>    Have a crontab now that tries to remount the USBs
>    to the NAS folders every 5 minutes. Doesn't help.
> 
>    Anyway, not sure NFS can *do* what I need it to do.
>    It's great at sharing pre-existing pre-stuffed
>    subdirs - have security cam backups going there -
>    but so far just WON'T handle later mount statements.
> 
Sure did with me. I used to export a CD ROM drive

>    As said somewhere, have had horrible probs with SAMBA
>    in the latest distros - all the online advice and past
>    experience do NOT get around permissions issues. You
>    can see the SAMBA share is *there*, just not log on.
>    They CHANGED something recently and it's ill-documented.
>    SAMBA *can* cope with the to-the-second mounts, have
>    used it that way before, even INTERNALLY on a NAS
>    box so backup pgms would work easily.
> 
Samba is for people who run M£ or Appleshit.

Look just put them in fstab if they are permanently mounted and 
necessary for the computer to operate.

/media/bollocksface/myUSB is a temporary mount point for *removable* 
devices.

Dont fight the system. Use it the way K & R and Sun intended.

-- 
If you tell a lie big enough and keep repeating it, people will 
eventually come to believe it. The lie can be maintained only for such 
time as the State can shield the people from the political, economic 
and/or military consequences of the lie. It thus becomes vitally 
important for the State to use all of its powers to repress dissent, for 
the truth is the mortal enemy of the lie, and thus by extension, the 
truth is the greatest enemy of the State.

Joseph Goebbels



[toc] | [prev] | [next] | [standalone]


#66841

From"Carlos E.R." <robin_listas@es.invalid>
Date2025-04-03 14:07 +0200
Message-ID<68a2clxf62.ln2@Telcontar.valinor>
In reply to#66825
On 2025-04-03 11:51, c186282 wrote:
> On 4/2/25 1:04 PM, The Natural Philosopher wrote:
>> On 02/04/2025 12:18, Carlos E.R. wrote:
>>> On 2025-04-02 12:48, The Natural Philosopher wrote:


>> I always start with ...
>>
>> *(ro,sync,no_root_squash,no_subtree_check)
>>
>> In /etc/exports for the least restricted export
> 
>    Ok, tried your param list ... but still nada on
>    the later-login mounts. Exportfs adds a bunch of
>    other defaults to etab.
> 
>    It's VERY annoying.
> 
>    As best I can tell, NFS cuts in VERY early and there
>    is no sane way to stop/delay it. As such it ONLY sees
>    the original, empty, folder we are later gonna
>    remount the USBs to.

It is working fine for me. You need "nohide" or version 4.

> 
>    Have a 4-drive external USB fixture. The drives USUALLY
>    come up in order, but experience sez they won't ALWAYS
>    do that. Depends on how quick the drives initialize,
>    and there's one magnetic in the mix. sda/sdb/etc may
>    not ALWAYS, reliably, be the same physical drives.
>    A Python script can more easily probe/parse info that
>    can individually identify, that's the next stage.

So, do not use sda/sdb. Use persistent naming.


>    Anyway, the drives (sometimes) come up in /media/<user>
>    and I have a mount statement that mounts them in my
>    NFS share dir, under the appropriate sub-folder.

Define them in fstab.



-- 
Cheers, Carlos.

[toc] | [prev] | [next] | [standalone]


#66844

Fromc186282 <c186282@nnada.net>
Date2025-04-03 11:27 -0400
Message-ID<pImdnVzSPJVPNXP6nZ2dnZfqn_GdnZ2d@giganews.com>
In reply to#66841
On 4/3/25 8:07 AM, Carlos E.R. wrote:
> On 2025-04-03 11:51, c186282 wrote:
>> On 4/2/25 1:04 PM, The Natural Philosopher wrote:
>>> On 02/04/2025 12:18, Carlos E.R. wrote:
>>>> On 2025-04-02 12:48, The Natural Philosopher wrote:
> 
> 
>>> I always start with ...
>>>
>>> *(ro,sync,no_root_squash,no_subtree_check)
>>>
>>> In /etc/exports for the least restricted export
>>
>>    Ok, tried your param list ... but still nada on
>>    the later-login mounts. Exportfs adds a bunch of
>>    other defaults to etab.
>>
>>    It's VERY annoying.
>>
>>    As best I can tell, NFS cuts in VERY early and there
>>    is no sane way to stop/delay it. As such it ONLY sees
>>    the original, empty, folder we are later gonna
>>    remount the USBs to.
> 
> It is working fine for me. You need "nohide" or version 4.
> 
>>
>>    Have a 4-drive external USB fixture. The drives USUALLY
>>    come up in order, but experience sez they won't ALWAYS
>>    do that. Depends on how quick the drives initialize,
>>    and there's one magnetic in the mix. sda/sdb/etc may
>>    not ALWAYS, reliably, be the same physical drives.
>>    A Python script can more easily probe/parse info that
>>    can individually identify, that's the next stage.
> 
> So, do not use sda/sdb. Use persistent naming.
> 
> 
>>    Anyway, the drives (sometimes) come up in /media/<user>
>>    and I have a mount statement that mounts them in my
>>    NFS share dir, under the appropriate sub-folder.
> 
> Define them in fstab.

   For you and rbowman ...

   Here's what my boxes look like now :

. . . . .

server

/etc/exports :

/home/nas/shar 192.168.0.0/24(rw,sync,no_root_squash,no_subtree_check)

/etc/fstab :

LABEL=ustor1 /home/nas/shar/qshar1 ext4 defaults,_netdev 0 0
LABEL=ustor2 /home/nas/shar/qshar2 ext4 defaults,_netdev 0 0


client

/etc/fstab :

192.168.0.121:/home/nas/shar /mnt/shar nfs defaults, 
timeo=900,retrans=5,_netdev 0 0

. . . . .

   Results - ON the server you can see both of the USB drives,
   so they ARE mounting where instructed. There is also a
   third subfolder under /shar that's directly written to by
   a script on the server box.

   On the CLIENT ... you can read/write to that third folder
   just fine. However the other two, the shares of the USB
   drives mounted on the server to, /home/nas/shar/qshar1 and
   /home/nas/shar/qshar2, are just BLANK.

   All permissions, server and client, are very generous
   for testing purposes - could restrict a bit later.

   MAY try sharing each folder under /shar individually
   rather that trying to share just /shar and hoping
   everything under it gets carried over - which it doesn't.

[toc] | [prev] | [next] | [standalone]


#66846

FromRalf Fassel <ralfixx@gmx.de>
Date2025-04-03 18:36 +0200
Message-ID<ygafriptd6v.fsf@akutech.de>
In reply to#66844
* c186282 <c186282@nnada.net>
|   Here's what my boxes look like now :
| server
>
| /etc/exports :
>
| /home/nas/shar 192.168.0.0/24(rw,sync,no_root_squash,no_subtree_check)
|

Haven't followed this thread from the beginning, so maybe you've been
there before:

  https://www.baeldung.com/linux/nfs-shares-export-import

basically says:
- you need to export both, the mount point /home/nas/shar
  *AND* the mounted USB-filesystems /home/nas/shar/qshar[12]

- use crossmnt on /home/nas/shar in /etc/exports to un-hide the
  USB-filesystems

HTH
R'

[toc] | [prev] | [next] | [standalone]


#66848

FromThe Natural Philosopher <tnp@invalid.invalid>
Date2025-04-03 18:09 +0100
Message-ID<vsmfbj$14dkr$3@dont-email.me>
In reply to#66846
On 03/04/2025 17:36, Ralf Fassel wrote:
> * c186282 <c186282@nnada.net>
> |   Here's what my boxes look like now :
> | server
>>
> | /etc/exports :
>>
> | /home/nas/shar 192.168.0.0/24(rw,sync,no_root_squash,no_subtree_check)
> |
> 
> Haven't followed this thread from the beginning, so maybe you've been
> there before:
> 
>    https://www.baeldung.com/linux/nfs-shares-export-import
> 
> basically says:
> - you need to export both, the mount point /home/nas/shar
>    *AND* the mounted USB-filesystems /home/nas/shar/qshar[12]
> 
> - use crossmnt on /home/nas/shar in /etc/exports to un-hide the
>    USB-filesystems
> 
> HTH
> R'

I think those are alternatives. Both are not needed

-- 
I would rather have questions that cannot be answered...
...than to have answers that cannot be questioned

Richard Feynman


[toc] | [prev] | [next] | [standalone]


#66861

Fromc186282 <c186282@nnada.net>
Date2025-04-03 16:42 -0400
Message-ID<bfmdnZcBgqwhb3P6nZ2dnZfqnPGdnZ2d@giganews.com>
In reply to#66848
On 4/3/25 1:09 PM, The Natural Philosopher wrote:
> On 03/04/2025 17:36, Ralf Fassel wrote:
>> * c186282 <c186282@nnada.net>
>> |   Here's what my boxes look like now :
>> | server
>>>
>> | /etc/exports :
>>>
>> | /home/nas/shar 192.168.0.0/24(rw,sync,no_root_squash,no_subtree_check)
>> |
>>
>> Haven't followed this thread from the beginning, so maybe you've been
>> there before:
>>
>>    https://www.baeldung.com/linux/nfs-shares-export-import
>>
>> basically says:
>> - you need to export both, the mount point /home/nas/shar
>>    *AND* the mounted USB-filesystems /home/nas/shar/qshar[12]
>>
>> - use crossmnt on /home/nas/shar in /etc/exports to un-hide the
>>    USB-filesystems
>>
>> HTH
>> R'
> 
> I think those are alternatives. Both are not needed

   I just added two extra lines in /etc/exports and
   everything Just Worked. WILL fool with crossmnt
   sometime however. Can fit two more drives in the
   USB fixture.

[toc] | [prev] | [next] | [standalone]


#66856

Fromc186282 <c186282@nnada.net>
Date2025-04-03 15:27 -0400
Message-ID<IKKcnZQe2Mi9fHP6nZ2dnZfqn_WdnZ2d@giganews.com>
In reply to#66846
On 4/3/25 12:36 PM, Ralf Fassel wrote:
> * c186282 <c186282@nnada.net>
> |   Here's what my boxes look like now :
> | server
>>
> | /etc/exports :
>>
> | /home/nas/shar 192.168.0.0/24(rw,sync,no_root_squash,no_subtree_check)
> |
> 
> Haven't followed this thread from the beginning, so maybe you've been
> there before:
> 
>    https://www.baeldung.com/linux/nfs-shares-export-import
> 
> basically says:
> - you need to export both, the mount point /home/nas/shar
>    *AND* the mounted USB-filesystems /home/nas/shar/qshar[12]
> 
> - use crossmnt on /home/nas/shar in /etc/exports to un-hide the
>    USB-filesystems


   BINGO !!! Also exporting the USB drive mount points
   explicitly worked ! On my client they still show up
   in /mnt/shar ... /mnt/shar/qshar1 and /mnt/shar/qshar2 ...
   as I wanted them to be while the native, non-usb,
   folder shows up too without needing its own explicit
   export line.

   This requirement was NOT anything I expected.

   NOW I can do some fun work with the system  :-)

[toc] | [prev] | [next] | [standalone]


#66847

FromThe Natural Philosopher <tnp@invalid.invalid>
Date2025-04-03 18:08 +0100
Message-ID<vsmf9o$14dkr$2@dont-email.me>
In reply to#66844
On 03/04/2025 16:27, c186282 wrote:
> On 4/3/25 8:07 AM, Carlos E.R. wrote:
>> On 2025-04-03 11:51, c186282 wrote:
>>> On 4/2/25 1:04 PM, The Natural Philosopher wrote:
>>>> On 02/04/2025 12:18, Carlos E.R. wrote:
>>>>> On 2025-04-02 12:48, The Natural Philosopher wrote:
>>
>>
>>>> I always start with ...
>>>>
>>>> *(ro,sync,no_root_squash,no_subtree_check)
>>>>
>>>> In /etc/exports for the least restricted export
>>>
>>>    Ok, tried your param list ... but still nada on
>>>    the later-login mounts. Exportfs adds a bunch of
>>>    other defaults to etab.
>>>
>>>    It's VERY annoying.
>>>
>>>    As best I can tell, NFS cuts in VERY early and there
>>>    is no sane way to stop/delay it. As such it ONLY sees
>>>    the original, empty, folder we are later gonna
>>>    remount the USBs to.
>>
>> It is working fine for me. You need "nohide" or version 4.
>>
>>>
>>>    Have a 4-drive external USB fixture. The drives USUALLY
>>>    come up in order, but experience sez they won't ALWAYS
>>>    do that. Depends on how quick the drives initialize,
>>>    and there's one magnetic in the mix. sda/sdb/etc may
>>>    not ALWAYS, reliably, be the same physical drives.
>>>    A Python script can more easily probe/parse info that
>>>    can individually identify, that's the next stage.
>>
>> So, do not use sda/sdb. Use persistent naming.
>>
>>
>>>    Anyway, the drives (sometimes) come up in /media/<user>
>>>    and I have a mount statement that mounts them in my
>>>    NFS share dir, under the appropriate sub-folder.
>>
>> Define them in fstab.
> 
>    For you and rbowman ...
> 
>    Here's what my boxes look like now :
> 
> . . . . .
> 
> server
> 
> /etc/exports :
> 
> /home/nas/shar 192.168.0.0/24(rw,sync,no_root_squash,no_subtree_check)
> 
> /etc/fstab :
> 
> LABEL=ustor1 /home/nas/shar/qshar1 ext4 defaults,_netdev 0 0
> LABEL=ustor2 /home/nas/shar/qshar2 ext4 defaults,_netdev 0 0
> 
> 
> client
> 
> /etc/fstab :
> 
> 192.168.0.121:/home/nas/shar /mnt/shar nfs defaults, 
> timeo=900,retrans=5,_netdev 0 0
> 
> . . . . .
> 
>    Results - ON the server you can see both of the USB drives,
>    so they ARE mounting where instructed. There is also a
>    third subfolder under /shar that's directly written to by
>    a script on the server box.
> 
>    On the CLIENT ... you can read/write to that third folder
>    just fine. However the other two, the shares of the USB
>    drives mounted on the server to, /home/nas/shar/qshar1 and
>    /home/nas/shar/qshar2, are just BLANK.
> 
>    All permissions, server and client, are very generous
>    for testing purposes - could restrict a bit later.
> 
>    MAY try sharing each folder under /shar individually
>    rather that trying to share just /shar and hoping
>    everything under it gets carried over - which it doesn't.

That would be the easier way of doing it. I cant remember if NFS 
automatically exports mounts

Ahh. You need to add the 'crossmnt' directive to the servers 
/etc/exports file for the whatever it is you are mounting


Then it will work the way you want it to

-- 
“Ideas are inherently conservative. They yield not to the attack of 
other ideas but to the massive onslaught of circumstance"

    -  John K Galbraith

[toc] | [prev] | [next] | [standalone]


#66854

From"Carlos E.R." <robin_listas@es.invalid>
Date2025-04-03 20:48 +0200
Message-ID<qp13clxirc.ln2@Telcontar.valinor>
In reply to#66847
On 2025-04-03 19:08, The Natural Philosopher wrote:
> On 03/04/2025 16:27, c186282 wrote:
>> On 4/3/25 8:07 AM, Carlos E.R. wrote:
>>> On 2025-04-03 11:51, c186282 wrote:



> Ahh. You need to add the 'crossmnt' directive to the servers /etc/ 
> exports file for the whatever it is you are mounting
> 
> 
> Then it will work the way you want it to

Right, because he is trying to export the parent directory. I export the 
mount points directly.

        crossmnt
               This option is similar to nohide but  it
               makes  it possible for clients to access
               all filesystems mounted on a  filesystem
               marked with crossmnt.  Thus when a child
               filesystem "B" is mounted  on  a  parent
               "A", setting crossmnt on "A" has a simi-
               lar effect to setting "nohide" on B.

               With nohide the child  filesystem  needs
               to   be   explicitly   exported.    With
               crossmnt it need not.  If a child  of  a
               crossmnt  file  is  not  explicitly  ex-
               ported, then it will be  implicitly  ex-
               ported  with  the same export options as
               the  parent,  except  for  fsid=.   This
               makes  it  impossible  to  not  export a
               child of a crossmnt filesystem.  If some
               but not all subordinate filesystems of a
               parent are to  be  exported,  then  they
               must be explicitly exported and the par-
               ent should not have crossmnt set.

               The nocrossmnt option can explictly dis-
               able  crossmnt if it was previously set.
               This is rarely useful.


-- 
Cheers, Carlos.

[toc] | [prev] | [next] | [standalone]


#66857

Fromc186282 <c186282@nnada.net>
Date2025-04-03 15:49 -0400
Message-ID<2kudnYbC9p3Le3P6nZ2dnZfqn_udnZ2d@giganews.com>
In reply to#66854
On 4/3/25 2:48 PM, Carlos E.R. wrote:
> On 2025-04-03 19:08, The Natural Philosopher wrote:
>> On 03/04/2025 16:27, c186282 wrote:
>>> On 4/3/25 8:07 AM, Carlos E.R. wrote:
>>>> On 2025-04-03 11:51, c186282 wrote:
> 
> 
> 
>> Ahh. You need to add the 'crossmnt' directive to the servers /etc/ 
>> exports file for the whatever it is you are mounting
>>
>>
>> Then it will work the way you want it to
> 
> Right, because he is trying to export the parent directory. I export the 
> mount points directly.
> 
>         crossmnt
>                This option is similar to nohide but  it
>                makes  it possible for clients to access
>                all filesystems mounted on a  filesystem
>                marked with crossmnt.  Thus when a child
>                filesystem "B" is mounted  on  a  parent
>                "A", setting crossmnt on "A" has a simi-
>                lar effect to setting "nohide" on B.
> 
>                With nohide the child  filesystem  needs
>                to   be   explicitly   exported.    With
>                crossmnt it need not.  If a child  of  a
>                crossmnt  file  is  not  explicitly  ex-
>                ported, then it will be  implicitly  ex-
>                ported  with  the same export options as
>                the  parent,  except  for  fsid=.   This
>                makes  it  impossible  to  not  export a
>                child of a crossmnt filesystem.  If some
>                but not all subordinate filesystems of a
>                parent are to  be  exported,  then  they
>                must be explicitly exported and the par-
>                ent should not have crossmnt set.
> 
>                The nocrossmnt option can explictly dis-
>                able  crossmnt if it was previously set.
>                This is rarely useful.

   Ralf's fix DID fix it all.

   Just two more near-duplicate /etc/export lines - but
   explicitly pointing where the USBs are mounted - did
   the trick neatly. On client it all still shows up
   under the blanket /mnt/shar

   I'll fool with crossmnt and nohide too, but for the moment
   I'm happy and can get on with more uses of this mini-NAS.
   Still room for two more USB drives in the Sabrient fixture.

   This is the BeeLink Mini-S with the N150 I recently bought,
   replacing two BMax N95 boxes with CPU to spare. DO note
   that the Mini-S does NOT have room/connectors for an
   internal SATA drive ... so I bought the one with 1tb
   nv ram so there'd still be plenty of onboard storage.

   Still under $200us (a few weeks ago anyhow, after
   tariff plans who the hell knows ?). Our Euro/UK people
   here can likely still get one cheap. Also note that
   'regular' MX won't boot properly on it - gotta use
   the MX-AHS version that's got more/newer drivers
   and kernel. Considered Fedora, but I know Debs
   a bit better.

   Figured there HAD to be a solution to this NFS thing,
   though didn't expect this one.

[toc] | [prev] | [next] | [standalone]


#66791

Fromvallor <vallor@cultnix.org>
Date2025-04-02 10:49 +0000
Message-ID<m54j20Fhof8U3@mid.individual.net>
In reply to#66781
On Tue, 1 Apr 2025 21:29:48 -0400, c186282 <c186282@nnada.net> wrote in
<UQ-dndQV6amaDnH6nZ2dnZfqnPednZ2d@giganews.com>:

> Here's an interesting problem ....
> 
> I re-mount USB drives onto NFS share points. The problem is that NFS
> doesn't SEE that - it only sees the previously empty dir instead.
> Add a tag file to that dir and that's ALL you will see in the share on
> another PC.
> 
> Tried variations of exportfs ... including the '-r' and '-au' then '-a'
> AFTER doing the mount. Sorry, the clients can't see the mount. The NFS
> stuff seems to cut in very early - before the USB re-mounts (done
> @reboot). If you look on the host machine you DO see the USB drives, but
> NEVER over the NFS share.
> 
> Why re-mount the USBs ? Because you can't always rely on Linux to mount
> them in the same order, used to be even the same place.
> '/media/<user>/whatever' seems hard-wired these days, but with multiple
> USB drives you still can't count on drive 1 being the drive 1 in
> /media/<user>. Kinda depends on which comes online first.
> Naming the drives helps, but even then.
> 
> And no, symlinks to some other mount point don't work ... NFS just
> shares a link to nowhere on the clients. 'hard' links ???
> 
> Have ONE share that's not a re-mounted anything - THAT always shows
> perfectly on the clients. Weird thing, somehow, at one point I DID get
> it to work - but not sure HOW. Just commented-out the old NFS and fstab
> stuff, so I've been able to re-try, but now none work. Set everything to
> 775 or 777 for development work, but that doesn't help.
> 
> SAMBA - this sort of thing works fine, but I've had horrible probs with
> SAMBA with the latest distros, ALWAYS intractable permissions issues no
> matter the tweaks, hence using NFS.
> 
> So ... any insights on how to get NFS to "see" whatever IS mounted to
> the share point AT THE MOMENT ???
> 
> Oh, latest MX Linux.

Take a look at "man exports" under the "nohide" option.

-- 
-v System76 Thelio Mega v1.1 x86_64 NVIDIA RTX 3090 Ti
   OS: Linux 6.14.0 Release: Mint 22.1 Mem: 258G
   "Why can't we just spell it orderves?"

[toc] | [prev] | [next] | [standalone]


#66792

Fromc186282 <c186282@nnada.net>
Date2025-04-02 07:12 -0400
Message-ID<ukCdnQr9sv0uhnD6nZ2dnZfqnPWdnZ2d@giganews.com>
In reply to#66791
On 4/2/25 6:49 AM, vallor wrote:
> On Tue, 1 Apr 2025 21:29:48 -0400, c186282 <c186282@nnada.net> wrote in
> <UQ-dndQV6amaDnH6nZ2dnZfqnPednZ2d@giganews.com>:
> 
>> Here's an interesting problem ....
>>
>> I re-mount USB drives onto NFS share points. The problem is that NFS
>> doesn't SEE that - it only sees the previously empty dir instead.
>> Add a tag file to that dir and that's ALL you will see in the share on
>> another PC.
>>
>> Tried variations of exportfs ... including the '-r' and '-au' then '-a'
>> AFTER doing the mount. Sorry, the clients can't see the mount. The NFS
>> stuff seems to cut in very early - before the USB re-mounts (done
>> @reboot). If you look on the host machine you DO see the USB drives, but
>> NEVER over the NFS share.
>>
>> Why re-mount the USBs ? Because you can't always rely on Linux to mount
>> them in the same order, used to be even the same place.
>> '/media/<user>/whatever' seems hard-wired these days, but with multiple
>> USB drives you still can't count on drive 1 being the drive 1 in
>> /media/<user>. Kinda depends on which comes online first.
>> Naming the drives helps, but even then.
>>
>> And no, symlinks to some other mount point don't work ... NFS just
>> shares a link to nowhere on the clients. 'hard' links ???
>>
>> Have ONE share that's not a re-mounted anything - THAT always shows
>> perfectly on the clients. Weird thing, somehow, at one point I DID get
>> it to work - but not sure HOW. Just commented-out the old NFS and fstab
>> stuff, so I've been able to re-try, but now none work. Set everything to
>> 775 or 777 for development work, but that doesn't help.
>>
>> SAMBA - this sort of thing works fine, but I've had horrible probs with
>> SAMBA with the latest distros, ALWAYS intractable permissions issues no
>> matter the tweaks, hence using NFS.
>>
>> So ... any insights on how to get NFS to "see" whatever IS mounted to
>> the share point AT THE MOMENT ???
>>
>> Oh, latest MX Linux.
> 
> Take a look at "man exports" under the "nohide" option.

   Quick look, MAY be promising. No decent examples yet
   to be seen ... syntax can be very peculiar .....

   I'll look into it.

   STILL don't know what's wrong with SAMBA - used to
   use it all the damned time in a mixed environment.
   Now, suddenly ......

   Hmmm :
 
https://unix.stackexchange.com/questions/42131/how-to-properly-export-and-import-nfs-shares-that-have-subdirectories-as-mount-p

   Apparently developers are not aware of the "Just Make It WORK"
   concept ......

[toc] | [prev] | [next] | [standalone]


#66794

From"Carlos E.R." <robin_listas@es.invalid>
Date2025-04-02 13:14 +0200
Message-ID<4qivblx7ff.ln2@Telcontar.valinor>
In reply to#66791
On 2025-04-02 12:49, vallor wrote:
> On Tue, 1 Apr 2025 21:29:48 -0400, c186282 <c186282@nnada.net> wrote in
> <UQ-dndQV6amaDnH6nZ2dnZfqnPednZ2d@giganews.com>:
> 
>> Here's an interesting problem ....
>>
>> I re-mount USB drives onto NFS share points. The problem is that NFS
>> doesn't SEE that - it only sees the previously empty dir instead.
>> Add a tag file to that dir and that's ALL you will see in the share on
>> another PC.
>>
>> Tried variations of exportfs ... including the '-r' and '-au' then '-a'
>> AFTER doing the mount. Sorry, the clients can't see the mount. The NFS
>> stuff seems to cut in very early - before the USB re-mounts (done
>> @reboot). If you look on the host machine you DO see the USB drives, but
>> NEVER over the NFS share.
>>
>> Why re-mount the USBs ? Because you can't always rely on Linux to mount
>> them in the same order, used to be even the same place.
>> '/media/<user>/whatever' seems hard-wired these days, but with multiple
>> USB drives you still can't count on drive 1 being the drive 1 in
>> /media/<user>. Kinda depends on which comes online first.
>> Naming the drives helps, but even then.
>>
>> And no, symlinks to some other mount point don't work ... NFS just
>> shares a link to nowhere on the clients. 'hard' links ???
>>
>> Have ONE share that's not a re-mounted anything - THAT always shows
>> perfectly on the clients. Weird thing, somehow, at one point I DID get
>> it to work - but not sure HOW. Just commented-out the old NFS and fstab
>> stuff, so I've been able to re-try, but now none work. Set everything to
>> 775 or 777 for development work, but that doesn't help.
>>
>> SAMBA - this sort of thing works fine, but I've had horrible probs with
>> SAMBA with the latest distros, ALWAYS intractable permissions issues no
>> matter the tweaks, hence using NFS.
>>
>> So ... any insights on how to get NFS to "see" whatever IS mounted to
>> the share point AT THE MOMENT ???
>>
>> Oh, latest MX Linux.
> 
> Take a look at "man exports" under the "nohide" option.

Ah, yes.

Last line says "not if you use NFSv4". The hiding doesn't happen with 
version 4.

Reminds me of something. How does one know what version is actually used?

-- 
Cheers, Carlos.

[toc] | [prev] | [next] | [standalone]


#66796

Fromc186282 <c186282@nnada.net>
Date2025-04-02 07:39 -0400
Message-ID<KSedndRn-_mCv3D6nZ2dnZfqn_qdnZ2d@giganews.com>
In reply to#66794
On 4/2/25 7:14 AM, Carlos E.R. wrote:
> On 2025-04-02 12:49, vallor wrote:
>> On Tue, 1 Apr 2025 21:29:48 -0400, c186282 <c186282@nnada.net> wrote in
>> <UQ-dndQV6amaDnH6nZ2dnZfqnPednZ2d@giganews.com>:
>>
>>> Here's an interesting problem ....
>>>
>>> I re-mount USB drives onto NFS share points. The problem is that NFS
>>> doesn't SEE that - it only sees the previously empty dir instead.
>>> Add a tag file to that dir and that's ALL you will see in the share on
>>> another PC.
>>>
>>> Tried variations of exportfs ... including the '-r' and '-au' then '-a'
>>> AFTER doing the mount. Sorry, the clients can't see the mount. The NFS
>>> stuff seems to cut in very early - before the USB re-mounts (done
>>> @reboot). If you look on the host machine you DO see the USB drives, but
>>> NEVER over the NFS share.
>>>
>>> Why re-mount the USBs ? Because you can't always rely on Linux to mount
>>> them in the same order, used to be even the same place.
>>> '/media/<user>/whatever' seems hard-wired these days, but with multiple
>>> USB drives you still can't count on drive 1 being the drive 1 in
>>> /media/<user>. Kinda depends on which comes online first.
>>> Naming the drives helps, but even then.
>>>
>>> And no, symlinks to some other mount point don't work ... NFS just
>>> shares a link to nowhere on the clients. 'hard' links ???
>>>
>>> Have ONE share that's not a re-mounted anything - THAT always shows
>>> perfectly on the clients. Weird thing, somehow, at one point I DID get
>>> it to work - but not sure HOW. Just commented-out the old NFS and fstab
>>> stuff, so I've been able to re-try, but now none work. Set everything to
>>> 775 or 777 for development work, but that doesn't help.
>>>
>>> SAMBA - this sort of thing works fine, but I've had horrible probs with
>>> SAMBA with the latest distros, ALWAYS intractable permissions issues no
>>> matter the tweaks, hence using NFS.
>>>
>>> So ... any insights on how to get NFS to "see" whatever IS mounted to
>>> the share point AT THE MOMENT ???
>>>
>>> Oh, latest MX Linux.
>>
>> Take a look at "man exports" under the "nohide" option.
> 
> Ah, yes.
> 
> Last line says "not if you use NFSv4". The hiding doesn't happen with 
> version 4.
> 
> Reminds me of something. How does one know what version is actually used?


   /var/libs/nfs/etab reads "NFS4"

   But remounts to the shared dir still do
   not register.

   I'd LIKE NFS to reflect WHATEVER THE HELL I currently
   have mounted to that share dir.

   Or maybe it just CAN'T ??? There ARE reasons I stuck
   with SAMBA so long ... it (used to) Just Work.

[toc] | [prev] | [next] | [standalone]


Page 1 of 2  [1] 2  Next page →

Back to top | Article view | comp.os.linux.misc


csiph-web