microsoft_windows:nfs_client
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
microsoft_windows:nfs_client [2025/03/26 23:58] – created rodolico | microsoft_windows:nfs_client [2025/03/27 00:45] (current) – rodolico | ||
---|---|---|---|
Line 3: | Line 3: | ||
Microsoft Windows can attach to NFS Shares with no problem, though you must use the command line to do it. You also need to install the NFS Client Role (Server) or package (Workstation) as it is not normally turned on. | Microsoft Windows can attach to NFS Shares with no problem, though you must use the command line to do it. You also need to install the NFS Client Role (Server) or package (Workstation) as it is not normally turned on. | ||
**Note**: everything other than the basic read-only mount requires rebooting the server. This **must** be done for it to work (because it is Microsoft, and . . . ) | **Note**: everything other than the basic read-only mount requires rebooting the server. This **must** be done for it to work (because it is Microsoft, and . . . ) | ||
+ | |||
===== Read-only access ===== | ===== Read-only access ===== | ||
Line 10: | Line 11: | ||
</ | </ | ||
- | ===== Read/Write Access as anon ===== | + | ===== Read/Write Access as anon (anonymous user) ===== |
To get read/write access, you will need to go a step further. If you do not care about mapping Windows users to users on your NFS server, you can just go in as the anonymous user (anon). Note that this will kill all restrictions. Anyone who can connect can read/ | To get read/write access, you will need to go a step further. If you do not care about mapping Windows users to users on your NFS server, you can just go in as the anonymous user (anon). Note that this will kill all restrictions. Anyone who can connect can read/ | ||
Line 23: | Line 24: | ||
After reboot, you can mount the share as the anonymous user with full read/write access. However, remember, everyone can access it the same way. | After reboot, you can mount the share as the anonymous user with full read/write access. However, remember, everyone can access it the same way. | ||
+ | |||
+ | The **nolock** is very important. Did not research too much, but during testing, ended up with corrupted files when I did not mount using that. | ||
+ | |||
<code powershell> | <code powershell> | ||
# mount drive | # mount drive | ||
Line 44: | Line 48: | ||
Create two files, passwd and group, in c: | Create two files, passwd and group, in c: | ||
- | This file maps a remote Unix user to the a local Windows user. | + | ==== passwd file ==== |
+ | |||
+ | This file maps a remote Unix user to the a local Windows user. **Note**: I have not done this yet, so not 100% positive how it works. | ||
<code conf passwd> | <code conf passwd> | ||
# Place in c: | # Place in c: | ||
# domain\unixuser: | # domain\unixuser: | ||
- | rodolico: | + | john: |
- | cait: | + | mary: |
</ | </ | ||
+ | |||
+ | The passwd file maps the Unix username, UID and GID to a Unix path on this machine. Fields are separated by colons (:). So, the first non-comment line is: | ||
+ | |||
+ | - **john** - username on the Unix machine | ||
+ | - **x** - placeholder for password, not used (**x** is placeholder on modern Unix machines stating the password is actually in a file called shadow) | ||
+ | - **1000** - the UID of john on the NFS server | ||
+ | - **100** - the GID of john (users) on the NFS server | ||
+ | - **Rod,,,** - a comment, you can leave this empty with no problem (::) | ||
+ | - **c: | ||
+ | |||
+ | ==== Group File ==== | ||
+ | |||
+ | Again, have not tested yet, but this is a group file which maps the local user to a group on the NFS server. In the above case, we are mapping john and mary to group 100, commonly the ' | ||
+ | |||
+ | Just like the passwords, this is a colon separated file. The second field is **x** indicating that the password is stored in a shadow file format. | ||
<code conf group> | <code conf group> | ||
# place in c: | # place in c: | ||
- | # | + | # |
wheel:x:0:0 | wheel:x:0:0 | ||
users: | users: | ||
</ | </ | ||
+ | |||
+ | ===== General Notes ===== | ||
+ | |||
+ | I do not go over them below, but everything is mounted with file access of 755 (read/write owner, read only for everyone else) and case insensitive (standard Windows). The mount is not persistent and will not survive a logout/ | ||
+ | |||
+ | The default behavior can be modified with some additional flags to the mount command | ||
+ | * -o fileaccess=777 # gives full read/write to anyone who can get to this | ||
+ | * -o fileaccess=700 # owner can do everything, everyone else can not even read it | ||
+ | * -o casesensitive=yes # makes file access case sensitive, standard Unix | ||
+ | |||
+ | You can also create a startup script to auto-mount the volume when you log in. See the article [[microsoft_windows: | ||
+ | |||
+ | To make the mapping persistent, there are hints at https:// | ||
+ | |||
+ | Finally, the mount command is your friend. **mount** just by itself will show all mounts with all parameters | ||
+ | |||
+ | ===== Thank you ===== | ||
+ | |||
+ | Want to thank Michael Edie for the clearest description of this I found. See the block post at | ||
+ | |||
+ | https:// | ||
+ | |||
+ | Everyone else that I found was just "oh, install NFS Client, then do a mount," | ||
===== Links ===== | ===== Links ===== | ||
* https:// | * https:// | ||
+ | * https:// | ||
* https:// | * https:// | ||
* https:// | * https:// | ||
microsoft_windows/nfs_client.1743051501.txt.gz · Last modified: 2025/03/26 23:58 by rodolico