VMware Cloud Community
MAHC
Enthusiast
Enthusiast
Jump to solution

Windows Services for Unix (NFS) and ESX

I have setup a hardware system with Windows Server 2003 standard and installed Microsoft Windows Services for Unix to use its NFS features for ESX. I am at the section for the User Name Mapping and I am not sure what ESX uses for NIS Domain names or what my NIS server name would be. We are a exclusively ESX and Windows shop so a lotof the Linux/Unix stuff I am not confident with because of my lack of use. I also have an option to use a password and group file. Is that what I would</span> need to make to use ESX with this NFS setup?

Any and all help would be greatly appreciated.

0 Kudos
1 Solution

Accepted Solutions
JoJoGabor
Expert
Expert
Jump to solution

I've used these NFS Services for Windows many times just for hosting templates where clients dont want to fork out for shared storage. You need to copy the /etc/passwd and /etc/group passwords onto your windows box. DO this using something like WinSCP or alternatively just copy it in linux to your datastore using cp /etc/passwd /vmfs/volumes/Datastore-name and then browse your datastore through the VI client and download those files.

Within the NFS for Windows console you need to setup user mappings, think about the security here. But you can map a ESX user such as root to a Windows user you have given sufficient rights to the share. YOu will need to point the NFS server to those files then setup the maps. Then (from memory) I think you need to share out the folder which will have an NFS SHaring tab.

View solution in original post

0 Kudos
19 Replies
vspheredoc
Contributor
Contributor
Jump to solution

MAHC,

You don't need to use NIS , NIS is for UNIX world. However to get NFS working using ESX and Windows you need to fix user mapping.Specially you are talking you need NFS working between Windows and ESX that straightforward. Taking NIS out of picture make your task much easier.

I worked on Windows services for UNIX sometime back for Single Sign-on solution for a mix environment (Solaris,HP-UX, Linux and Windows 2003 server ) later decided to use Centrify. But i remember you don't need NIS anywhere to get the NFS working.

Let me know if that helps ?

If you have any question then let me know.

MAHC
Enthusiast
Enthusiast
Jump to solution

So I am assuming I am going to have to use the Password and Group files option that it gives. With that now figured out I guess my next question is where would I find this file on my ESX servers? They are all setup basically the same.

0 Kudos
RParker
Immortal
Immortal
Jump to solution

So I am assuming I am going to have to use the Password and Group files option that it gives. With that now figured out I guess my next question is where would I find this file on my ESX servers

You don't. ESX is NOT linux. It has a Linux console. But you should not install ANY services on ESX, even if you can find a work around. You will compromise the integrity of VM hosting which is what ESX was designed to do, not host NFS.

You should install a VM with Linux and use that VM for NFS hosting on the host.

0 Kudos
vspheredoc
Contributor
Contributor
Jump to solution

MAHC,

Look into /etc/passwd and /etc/group on ESX host. You need to login to ESX host using ssh from command line.

0 Kudos
JoJoGabor
Expert
Expert
Jump to solution

I've used these NFS Services for Windows many times just for hosting templates where clients dont want to fork out for shared storage. You need to copy the /etc/passwd and /etc/group passwords onto your windows box. DO this using something like WinSCP or alternatively just copy it in linux to your datastore using cp /etc/passwd /vmfs/volumes/Datastore-name and then browse your datastore through the VI client and download those files.

Within the NFS for Windows console you need to setup user mappings, think about the security here. But you can map a ESX user such as root to a Windows user you have given sufficient rights to the share. YOu will need to point the NFS server to those files then setup the maps. Then (from memory) I think you need to share out the folder which will have an NFS SHaring tab.

0 Kudos
MAHC
Enthusiast
Enthusiast
Jump to solution

</span> RParker- I am not looking to have ESX HOST NFS I am looking for it to connect to a Windows Based NFS server so it has that storage available to it. I know that by installing extra stuff on the ESX server will compromise it and its not designed for that type of stuff. Thanks for looking out for me though

vspheredoc - I will check those locations and see what I can find..

JoJoGabor - Thanks for the command help. I didnt think to do it through the VI client storage like that.

0 Kudos
RParker
Immortal
Immortal
Jump to solution

I am not looking to have ESX HOST NFS I am looking for it to connect to a Windows Based NFS server so it has that storage available to it. I know that by installing extra stuff on the ESX server will compromise it and its not designed for that type of stuff.

OK, that's good you understand the consequences, you still don't need the command line or modify files on ESX to do it. You use the vkernel, add storage via the VI Client, and point to the NFS server address. This is ALL done within the VI Client GUI, still don't need to touch those files and no need make changes at that level.

This functionality is already built into ESX via the VI client.

Click on the host, click on configuration -&gt; storage -&gt; add storage. You need vkernel on the host for this to work, and point it to the NFS server address. Make sure you enable r/w access for root, voila. Done.

0 Kudos
JoJoGabor
Expert
Expert
Jump to solution

Hi Rparker,

I dont think he's intending to change those files, but Windows Services for Unix needs to see a copy of them on the Windows box in order to create user mappings between ESX users and Windows Users.

0 Kudos
RParker
Immortal
Immortal
Jump to solution

I dont think he's intending to change those files, but Windows Services for Unix needs to see a copy of them on the Windows box in order to create user mappings between ESX users and Windows Users.

If all he wants is NFS for extra storage on ESX, you don't need to touch any of those files. You do it by adding storage. Provide the NFS IP, and that's it.

0 Kudos
MAHC
Enthusiast
Enthusiast
Jump to solution

After i add the files and right click on the User Name Mapping and tell it to start it gives me the error Service failed ot start and in the event viewer I see Event ID 1014 Could not connect to Mapping Server at host localhost:while connecting: RPC: Port Mapper failure - RPC: Unable to receive. What am I missing?

Message was edited by: MAHC

0 Kudos
vspheredoc
Contributor
Contributor
Jump to solution

MAHC,

For using NFS on ESX you don't need to touch anything on ESX. All you have to do is create NFS share on any Linux/UNIX machine and add it to ESX using VCenter.

0 Kudos
MAHC
Enthusiast
Enthusiast
Jump to solution

I am sure this would be ALOT easier to just use Linux but the organization i am with would like to keep as much stuff Windows as possible so we are trying this path first. Unfortunately I am getting errors just setting up the NFS server so I am confused if it is from the information I provided from ESX or if it is another setting.

0 Kudos
vspheredoc
Contributor
Contributor
Jump to solution

MAHC,

try this on ESX host :

esxcfg-firewall -e nfsClient

0 Kudos
JoJoGabor
Expert
Expert
Jump to solution

Hmmm, sounds strange. So you've copied over the group and passwd files and pointed NFS to them right?

Have you gone through these instructions...

Once it can read the files it should display a list of users from within the passwd file.

I remember it being a bit fiddly to setup but not too much of a drama. Go through the doc and see if you've missed anything

JoJoGabor
Expert
Expert
Jump to solution

One more thing it could be.. You cant map to the administrators group or the Domain users group, so make sure you are mapping your ESX user to a windows user (I usually use local windows users) You did install the names mapping component as well didnt you?

0 Kudos
MAHC
Enthusiast
Enthusiast
Jump to solution

I have attached a couple of screen shots of the setup. I have the User Name Mapping Installed but the error I get " Unable to access User Name Mapping server No maps could be obtained" is confusing me on what I am missing so it cant communicate. Any ideas. The link that was posted did have a lot of good information, Thanks.

I did forget to mention that when I right click on the User Name Mapping icon on the left and select start it gives me the error " The service failed to start."

0 Kudos
RParker
Immortal
Immortal
Jump to solution

I am sure this would be ALOT easier to just use Linux but the organization i am with would like to keep as much stuff Windows as possible

This isn't hard at all. Open VI Client on the host. You click on storage, you click ADD storage, it prompts for VMFS or NFS. You choose NFS. You provide the IP address for the NFS server, you provide the path to the NFS server that you set up.

That's it, it's that simple.

The problem is NFS needs security, and you have to tell it that root needs access to that file system. you allow root access for read and write, then that's it for NFS.

The problems you are experiencing are ALL 100% to do with NFS and how it was setup, from ESX is not difficult at all.

0 Kudos
MAHC
Enthusiast
Enthusiast
Jump to solution

Found the problem. The User Name Mapping Service was set to disable by default so that was my problem. I set the permissions and everything is running great. Thanks for the help everyone.

0 Kudos
dougdavis22
Hot Shot
Hot Shot
Jump to solution

Not sure if you are aware, but using Windows Services for Unix for NFS datastores is not supported by VMware for use with ESX. I only found this out when I logged a support call. Luckily we're not using it for VMs to run on.

Doug.

0 Kudos