You are not logged in.

#1 2023-06-26 11:09:27

gabtram
Member
Registered: 2023-04-11
Posts: 64

[Solved] Bring mount command to fstab without using user and pass

Hi to all,

i managed to mount some of my qnap folders in arch.
I installed nfs-utils to work with nfs version 3 and 4 and it worked like a charm,

sudo mount -t nfs 192.168.xxx.xxx:/media /mnt/media

so i will to add this iine

192.168.xxx.xxx:/media /mnt/media nfs defaults 0 0

Now i i'dl ike to add user and password in fstab line to configure the login but from an external file not diretly inserting the user and pass in fstab. Like .htaccess and .htpasswd, just to understand.
Is it possible?

Last edited by gabtram (2023-06-26 17:35:09)

Offline

#2 2023-06-26 13:23:36

seth
Member
Registered: 2012-09-03
Posts: 60,792

Re: [Solved] Bring mount command to fstab without using user and pass

What "user and password"? This isn't CIFS.
For NFSv4 there's https://wiki.archlinux.org/title/NFS#En … _idmapping

Also 192.168.0.0/16 is a private range - the numbers there are completely meaningless outside your LAN and you can happily post them.

Offline

#3 2023-06-26 15:31:38

gabtram
Member
Registered: 2023-04-11
Posts: 64

Re: [Solved] Bring mount command to fstab without using user and pass

Hi,

thanks always Seth for your competence.
In my case, after reading what do you suggest i find this link: https://docs.qnap.com/operating-system/ … 84BFC.html
So my qnap Nas have an option to manage nfs parameters and the add the chance to have the option Sqash all users. With this i can write from my arch schred folder directly in the qnap folder, the file have a group:user nobody and i can see and open the file also with my win pc.
It could be better to have the map id's with a gid an uid equals to both client and server but i'd like to avoid modification inside qnap, if 'i'm doing something wrong smile

Bye

Offline

#4 2023-06-26 16:32:39

seth
Member
Registered: 2012-09-03
Posts: 60,792

Re: [Solved] Bring mount command to fstab without using user and pass

Please always remember to mark resolved threads by editing your initial posts subject - so others will know that there's no task left, but maybe a solution to find.
Thanks.

Offline

Board footer

Powered by FluxBB