Nfs сервер на windows server 2008 r2

Всем привет сегодня рассмотрим как установить NFS server в Windows Server 2008 R2. Эта тема в догонку к ранее уже описанной Как установить NFS server в Windows Server 2012 R2. Давайте попробуем сделать из нашего сервера под управлением Windows Server 2008 R2 хранилище виртуальных машин по протоколу NFS. Для этого мы с вами установим специальную роль через графические и консольные средства.

Обновлено 26.07.2016

Как установить NFS server в Windows Server 2008 R2

Как установить NFS server в Windows Server 2008 R2

Всем привет сегодня рассмотрим как установить NFS server в Windows Server 2008 R2. Эта тема в догонку к ранее уже описанной Как установить NFS server в Windows Server 2012 R2. Давайте попробуем сделать из нашего сервера под управлением Windows Server 2008 R2 хранилище виртуальных машин по протоколу NFS. Для этого мы с вами установим специальную роль через графические и консольные средства.

Как установить NFS роль через графический интерфейс

Для установки NFS server откройте Диспетчер сервера и нажимаем Добавить роли

Как установить NFS server в Windows Server 2008 R2-01

Как установить NFS server в Windows Server 2008 R2-01

Выбираем в мастере установки Файловые службы

Как установить NFS server в Windows Server 2008 R2-02

Как установить NFS server в Windows Server 2008 R2-02

Далее будет окно которое познакомит вас с данной ролью пропускаем его.

Как установить NFS server в Windows Server 2008 R2-03

Как установить NFS server в Windows Server 2008 R2-03

Выбираем компонент Службы для NFS

Как установить NFS server в Windows Server 2008 R2-04

Как установить NFS server в Windows Server 2008 R2-04

Установить.

Как установить NFS server в Windows Server 2008 R2-05

Как установить NFS server в Windows Server 2008 R2-05

Пройдет немного времени и роль установится.

Как установить NFS server в Windows Server 2008 R2-06

Как установить NFS server в Windows Server 2008 R2-06

Как установить NFS роль через консоль

Для решения данной задачи нам поможет команда servermanagercmd. Открывает командную строку и вводим

servermanagercmd -install FS-FileServer -FS-NFS-Services

Как установить NFS server в Windows Server 2008 R2-07

Как установить NFS server в Windows Server 2008 R2-07

Вот так вот просто установить NFS server в Windows Server 2008 R2.

Материал сайта pyatilistnik.org

Июл 26, 2016 23:31

We are currently working on a feature that will allow potential clients to download a trial of Atomia Cloud Hosting Platform and install it in their OpenStack cloud. This means we have to keep the size of the installation package as well as the footprint in their cloud (in terms of numbers of virtual machines) to a minimum. While a clustered productions environment may contain dozens of VMs we aim for a fully functional test environment with as few VMs as possible (currently 3, but we strive for 2).

Since we offer both Linux and Windows websites we need a storage solution that supports both SMB (Windows) and NFS (Linux). For production environments we recommend Nexenta ZFS, but for testing this is less suitable because it means that we would have to ship another image (and another VM is needed).

This can be avoided by exposing the NFS through Windows Server for NFS Services. While there are hundreds to tutorials regarding creating SMB shares, few are to be find about NFS Services. In Windows 2008 R2 there has been a number of changes and this blog post will guide you from start to finish on how to set it up.

Installing Server for NFS Services

To install Server for NFS Services simply execute this command:

ServerManagerCmd -install File-Services FS-NFS-Services

Setting up the User Mapping

This version of Server for NFS Services lacks the User Mapping server. The mapping is now done by Active Directory itself. But first a short explanation on what user mapping does: If you want to connect to the Windows NFS share from Linux, and you don’t use a common authentication scheme like Kerberos, Linux will identify the user to Windows using their user ID and group ID (which every user and group in Linux has). Run the following command in your Linux terminal to get the IDs:

less /etc/passwd

This is of course insecure because if an attacker controls a Linux machine of his own and connects to your NFS share he can simply pretend to be any user. Unlike among Windows machines it is not required for the Linux and the Windows user to share the same password. It is therefore important to control the access to the share via firewall or IP restrictions.

For the root you can choose for every share if it should be either considered anonymous or if it should be mapped to Administrator automatically. All unmapped users are covered by the entity Anonymous Logon in Windows. So you can save yourself the user mapping if you trust all users of the Linux machine, by granting rights to Anonymous Logon.

Run the following command on your Windows server to enable user mapping:

nfsadmin mapping localhost config adlookup=yes addomain=<yourdomain>
sc.exe stop NfsService
sc.exe start NfsService

Where the domain is given in its full DNS name.

To set up the mapping, let assume you found the line

ubuntu:x:1000:1000:Ubuntu,,,:/home/ubuntu:/bin/bash

in the passwd file. That means ubuntu is member of Ubuntu group and both have the ID 1000. To replicate that in windows you need to create a user ubuntu and a group we call g-ubuntu, but the name won’t matter.

MSDN has an excelent blog post with scripts on how to set the user and group ID
here.

Unfortunately it does not cover how to set the default group. In Windows a user can be member of several groups, but in Linux it can be only one. To set the default group, you open Active Directory Users and Computers, navigate to the users account, right click, select Properties, select the Member of tab and then select the group and click on Set Primary Group.

The User properties dialog

Creating the share

To create an NFS share simply right-click on folder and select the NFS Sharing tab. You can activate NFS sharing there. The defaults are usually ok.

The NFS sharing dialog in Windows explorerThe NFS sharing dialog in Windows explorer

Then click on the Permissions button. By default all machines have read access. You should limit access to those machines that really need it. If you need that you can allow root access which means that the root user is given Administrative privileges.

The permissions dialog for an NFS shareThe permissions dialog for an NFS share

The NTFS permissions

The trickiest part are the NTFS permissions. Let’s say you want to give the user ubuntu access to a file. In that case you will probably add ubuntu to the users of that file and add permissions. But on the linux side this will change nothing. This is because Linux is only aware of three entities, the owner, the owner’s group and all. So when you give permissions this applies:

Use the Everyone entity in Windows to give permissions to all. To give permissions to a specific user or group you must first change the ownership of the folder to that group and then give explicitly permissions to that user or group.

To give ownership to a certain user/group it is best to use SetACL:

SetACL -on c:Storageb -ot file -actn setowner -ownr "n:ubuntu" -actn setgroup -grp "n:g-ubuntu" -rec cont_obj

To give the user and group explicit read and execute access use:

SetACL -on c:Storage -ot file -actn ace -ace "n:ubuntu;p:read_ex" -ace "n:g-ubuntu;p:read_ex" -actn rstchldrn -rst dacl

On the Linux side

On the Linux side you simply mount the NFS share

mount <IP>:/<name_of_the_share> /<mountpoint>

When the Server for NFS Services role service is installed it automatically opens the right ports in the Windows firewall.

When connecting to NFS shared folder the windows credentials needs to be mapped to a equivalent unix account+ group. 

In Windows Server 2008 R2 the support for User Mapping is dropped and the same functionality can only be achived using Identity Management for Unix Components (extension schema for Active Directory).

Below describes on how you can connect to a NFS folder without using User Mapping Server.

A. Install NFS Client

Step 1. Enable File Services Role. Go to Server Management – > Add Roles -> File Services

Step 2. Install Services for Network File System. Go to File Services – > Add Role Services

 

B. Update NFS Client Registry

In this step, we are going to map the anonymous user credential to the unix account credential that you’ll be using to connect to NFS share. First you need to get the User Id and Group Id of the unix account from the unix administrator. It should be of decimal value like: UserId= 6500000 GroupId=4200. Once you have it, we can proceed.

1. Open Regedit.

2. Go to HKEY_LOCAL_MACHINESOFTWAREMicrosoftClientForNFSCurrentVersionDefault.

3. Create 2 DWORD value, one for AnonymousUid with decimal value=<User Id> and another for AnonymousGid with decimal value=<GroupId>.

It should look like this:

4.  Restart the NFS Client. Go to Administrative Tools -> Services for Network File System (NFS) ->

C. Test NFS Connection

1. Open command prompt.

2. Type:  mount -u:<UserName and not UserId> -p:<Password> <SharedNFSFolder> <drive letter to mount, Ex: J:>

3. dir <drive letter:>

Copy file to this NFS folder. This is only way to confirm that the registry hacking is successfully. Because by default if the anonymous access is turned on in NFS side, you can see the files without having to supply user/password.

Note: Limitation is that, you can only connect to a single NFS share because it would use the same UserId and Group Id everytime you connect.

Согласитесь, и у Вас когда-либо возникала проблема с нехваткой дискового пространства на ESX. И само-собой встает вопрос, а что делать??? Конечно самое простое это добавить хардов и проблема решена, но не всегда это возможно, к примеру, нет денег на HDD или же еще хуже, закончились свободные отсеки для HDD. И опять же что делать?
Если у Вас к примеру есть сервер, работающий на Windows 2008 R2, и на нем есть достаточно свободного места, то его можно прекрасно использовать для наших целей.

Итак переходим от прелюдий к практике:
1. Заходим Start > Administrative Tools > Server Manager

Выбираем Roles и нажимаем Add Roles:

Далее выбираем Роль File Services

В следующем меню нас интересует только  Services for Network File System:

Нажимаем Далее и устанавливает данную Роль.

Если данный Windows 2008 Server не является контроллер AD, то устанавливаем Роль Active Directory Domain Services, иначе пропускаем этот пункт и делаем все дальше.

P.S. Как устанавливать AD думаю описывать не стоит…

В окне Server Manager в категории Active Directory жмем Add Roles Services 

Устанавливаем Роль маппинг в AD для UNIX-систем.

 После установки перегружаем сервер.

После перезагрузки сервера запускаем Active Directory Users and Computers из меню Administrative Tools. Раскрываем дерево домена и выбираем OU Users:

Добавляем новую группу:

Нажимаем ОК и открываем группу еще раз, переходим на закладку UNIX Attributes, тут в качестве NIS Domain выбираем имя домена и устанавливаем GID (Group ID) в 0

С группами покончили, создаем User и добавляем его в нашу созданную группу UnixGroup. Далее перейдите на вкладку UNIX Attributes. Там в качестве NIS Domain выбираем имя домена и устанавливаем GID (Group ID) в 0. Это позволит серверу VMware ESX получить доступ к NFS-ресурсу для пользователя.

Теперь в Administrative Tools открываем Service for Network File System (NFS). Нажимаем правой кнопкой на Services for NFS и выбираем Properties:

На вкладке General Settings в поле Identity mapping source вводим имя домена:

Теперь создаем папку, где будут храниться виртуальные машины на хранилище NFS. Заходим в ее свойства и переходим на вкладку NFS Sharing, жмем Manage NFS Sharing.

Далее попадаем в окно, где ставил галочку Share this folder и вводим Share name (!без пробела!), а также ставим как изображено на картинке Allow anonymous access:

Нажимаем кнопку Permissions и меняем тип доступа на Read-Write, так же ставим галку: Allow root access checkbox.

Если все получилось, то в поле Network Path в свойствах NFS-шары будет отображен путь к этому ресурсу. 

С виндой закончили, теперь заходим в наш родной vSphere Client, жмем Add Storage, указываем Network File System указываем FQDN-имя сервера Windows 2008 Server R2, в поле Folder указываем имя папки на Windows Server, а в поле Datastore Name указываем имя нового виртуального хранилища NFS.

Теперь хранилище доступно, можно указывать при создании новой машины или перераспределении места существующей.

Всем удачи, с Вами был valhome ;)

Назад    Главная
 

Автор: Александр Самойленко
Дата: 02/07/2010

Реклама:

Статья:

Многие пользователи, применяющие платформу виртуализации VMware vSphere в своей виртуальной инфраструктуре, ищут возможности использования недорогого хранилища для виртуальных машин. Особенно эта проблема актуальна для небольших компаний, пользующихся бесплатным гипервизором VMware ESXi. В качестве одного из вариантов, для тестового или некритичного производственного окружения, можно рассмотреть организацию NFS-хранилища на базе Windows 2008 Server R2, у которого есть встроенные возможности по созданию общих ресурсов NFS.

Безусловно, этот вариант не рекомендуется использовать для полноценных производственных окружений, где в качестве дешевого варианта хранилища можно предложить коммерческие продукты StarWind, позволяющие создать общие отказоустойчивые хранилища на базе Software iSCSI.

Итак, чтобы приступить к созданию хранилища NFS для VMware vSphere на базе Windows 2008 Server, нужно запустить Server Manager:

Start -> Administrative Tools -> Server Manager

Читать дальше

I’ve had a requirement recently to create a small XenServer 6.2 test/demo environment. I decided to use a Windows 2008 R2 host as an NFS server to provide shared storage to the XenServer hosts as it is quick and easy to set up.

First of all you have to install NFS services. This is done by running the following command:

ServerManagerCmd -install File-Services FS-NFS-Services


nfs_feature_install

Once the installation is complete, the next step is to create a share. First of all, create a folder, then right click on it and select the NFS Sharing tab:

nfs_share

Click the Manage NFS Sharing button:

nfs_settings

For our purposes, it’s fine to leave the defaults, but we will need to change a setting in the permissions options:

nfs_permissions

We need to ensure that ‘Allow root access’ is enabled, and that the share is set to Read-Write. By default it will be set as read only. If required, you can set it so that only certain IP address are able to connect to the share, however in this example I will leave it as allow all.

Now the share has been set up it can be added to the XenServer hosts as a Storage Repository. In XenCenter, right click a XenServer host and select ‘New SR’:

new-sr

Next, choose NFS VHD as the virtual disk storage type:

nfs-type

On the next screen, give the SR a name:

sr-name

Finally, enter the path to the NFS share created earlier:

sr-server

After clicking finish the new SR should be available.

If you wanted to use this NFS share with an ESXi environment rather than XenServer, the setup is identical on the NFS server. To connect an ESXi host to it, use the Add Storage wizard in the vSphere client:

esxi-nfs

Используя сетевую файловую систему NFS можно предоставить доступ серверам ESXi к файловым ресурсам или дисковой емкости другого оборудования, работающего под различными ОС. Например, удобно сделать доступными iso-образы, чтобы проще было их подключать к CD-ROM накопителям виртуальных машин.

Рассмотрим порядок установки и настройки связки NFS сервиса и VMware ESXi на примере сервера под Windows 2008 в самом простом варианте, без использования Active Directory:

1. Устанавливаем необходимые роли, а именно «Файловые службы» и ниже по иерархии «Служба для NFS».

2. После того как установка закончится, рекомендуется проверить, работает ли сервис «Служба для NFS» и открыт ли порт 111.

Иногда установке NFS сервиса может помешать уже работающая программа или служба, использующая тот же 111 порт. Например, так себя может вести «ONC/RPC Portmapper». В таком случае придется решить конфликт, отключив данный сервис.

3. Далее заходим в свойства той папки, которую будем расшаривать по NFS. Переключаемся на закладку «Совместный доступ NFS».

4. Нажимаем «Управление доступом NFS» и переходим в новое окно. Устанавливаем следующие настройки:

5. Ставим галку «Открыть общий доступ к этой папке», именуем общий ресурс, хотя лучше оставить имя по-умолчанию. Далее снимаем две следующие галки, оставляя «Не использовать серверную проверку подлинности» и устанавливаем «Разрешить доступ несопоставленным пользователям», затем «Разрешить анонимный доступ» и в полях анонимных UID и GID пишем идентификатор встроенного пользователя ESXi для работы с NFS(

nfsnobody

): 65534.

6. Нажимаем «Разрешения»:

7. В данном окне нужно выбрать тип доступа и обязательно поставить галку «Разрешить доступ с правами root». Тут также можно более подробно настроить доступ хостов к серверу NFS. На картинке показана лишь одна группа по-умолчанию, но с помощью консольной утилиты «nfsadmin« можно создать свои группы(«nfsadmin server creategroup MyGroup») и добавить туда необходимые клиенты(«nfsadmin server addmembers MyGroup \MyESXiHost»).

8. Далее заходим в свойство расшариваемой директории в параметры безопасности и добавляем требуемые права для файловой системы NTFS локальной группе «АНОНИМНЫЙ ВХОД».

9.  Если нужен доступ не только на чтение, но и на запись, в настройках локальной политики безопасности нужно обязательно включить параметр «Сетевой доступ: разрешать применение разрешений «Для всех» к анонимным пользователям»(«Локальные политики -> Параметры безопасности»).

10. Продолжаем настройку на стороне ESXi. В vSphere Client выберите нужный сервер, затем переходим на

«Configuration»->»Storage»->»Add Storage»

. Выбираем «Network File System»:

 11. Заполняем параметры подключения(

имя сервера

,

название шары на сервере

,

название хранилища на ESXi

). Устанавливаем галочку «Mount NFS read only» если доступ должен быть только в режиме чтения.

При успешном подключении и последующей проверке доступности хранилища можно считать задачу завершенной.

wikussmit

New here
Posts: 6
Joined: Tue Nov 09, 2010 5:04 pm

How do I mount a NFS folder to Windows Server 2008 R2

Hi,

Does anyone know how to mount a NFS share from a NAS (TS-809U-RP Turbo NAS) box on Microsoft 2008 R2 Server?

I need the drive to be seen as a local drive and not as a network mounted drive. The reason for this is that our backup software can only access local storage.


tmt

Experience counts
Posts: 1006
Joined: Mon Nov 16, 2009 11:02 am

Re: How do I mount a NFS folder to Windows Server 2008 R2

Post

by tmt » Wed Nov 10, 2010 12:31 am

Do you have the Windows Client for NFS component installed? (Control panel -> Programs and Features -> Turn Windows features on and off -> Services for NFS -> Client for NFS). If so, there’s a help file in it and you should be able to mount the NAS as you would any other NFS server. Whether your backup app runs properly on the share depends on the app, however, and not Windows or the NAS.

SS-439, Ubuntu Server 12.04.3 LTS, EXT4, RAID10, 4xHitachi 5K1000
TS-112, 4.1.x Beta, EXT4, 1xHitachi 7K1000


wikussmit

New here
Posts: 6
Joined: Tue Nov 09, 2010 5:04 pm

Re: How do I mount a NFS folder to Windows Server 2008 R2

Post

by wikussmit » Wed Nov 10, 2010 6:47 pm

I have done as you suggested and enabled the client for NFS on the 2008 Server. I have tried many different commands (below) from the command line but keep on getting a ‘Network Error 53’ error

mount -o mtype=hard anon fileaccess=7 \192.168.0.100NFS f:
mount \192.168.0.100:/NFS f:
mount \192.168.0.100NFS f:

Any idea why?


tmt

Experience counts
Posts: 1006
Joined: Mon Nov 16, 2009 11:02 am

Re: How do I mount a NFS folder to Windows Server 2008 R2

Post

by tmt » Wed Nov 10, 2010 9:12 pm

Have you verified that you can mount the NFS share from other clients, and enabled the share for NFS access in the QNAP gui with guest access rights (since you’re using «anon»)? Also, what QNAP firmware rev are you using btw?

Running Win7 and NFS-mounting my SS-439 running 3.3.5 works just fine with your first and last commandlines (using the dotted quad IP and share). The second one does fail with error 53, see below.

Code: Select all

Microsoft Windows [Version 6.1.7600]
Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

C:Userstmt>mount -o mtype=hard anon fileaccess=7 \192.168.0.100Public F:
F: is now successfully connected to \192.168.0.100Public

The command completed successfully.

C:Userstmt>dir f:
 Volume in drive F has no label.
 Volume Serial Number is 91D9-ED67

 Directory of F:

02/28/2010  11:30 PM    <DIR>          ...
(file listing follows)
              11 File(s)  2,215,804,300 bytes
               6 Dir(s)  600,150,368,256 bytes free

C:Userstmt>umount F:

Disconnecting           F:      \192.168.0.100Public
The command completed successfully.

C:Userstmt>mount \192.168.0.100:/Public F:
Network Error - 53

Type 'NET HELPMSG 53' for more information.


C:Userstmt>net helpmsg 53

The network path was not found.


C:Userstmt>mount \192.168.0.100Public F:
F: is now successfully connected to \192.168.0.100Public

The command completed successfully.

C:Userstmt>

SS-439, Ubuntu Server 12.04.3 LTS, EXT4, RAID10, 4xHitachi 5K1000
TS-112, 4.1.x Beta, EXT4, 1xHitachi 7K1000


wikussmit

New here
Posts: 6
Joined: Tue Nov 09, 2010 5:04 pm

Re: How do I mount a NFS folder to Windows Server 2008 R2

Post

by wikussmit » Wed Nov 10, 2010 10:57 pm

It’s working now. It turned out to be the access rights on the NFS Access Control which was set to ‘Deny Access’ rather than ‘No limit’ on the QNAP.

Our Current firmware version is 3.3.5 Build 1105T, the command worked as you suggested — mount -o mtype=hard anon fileaccess=7 \192.168.0.100NFS F:

Thank you!


tmt

Experience counts
Posts: 1006
Joined: Mon Nov 16, 2009 11:02 am

Re: How do I mount a NFS folder to Windows Server 2008 R2

Post

by tmt » Thu Nov 11, 2010 12:00 am

Great! Glad it was so simple to fix. So, does your backup application work correctly now?

SS-439, Ubuntu Server 12.04.3 LTS, EXT4, RAID10, 4xHitachi 5K1000
TS-112, 4.1.x Beta, EXT4, 1xHitachi 7K1000


wikussmit

New here
Posts: 6
Joined: Tue Nov 09, 2010 5:04 pm

Re: How do I mount a NFS folder to Windows Server 2008 R2

Post

by wikussmit » Thu Nov 11, 2010 5:02 pm

The drive is mounted as F: on the system but it seems that the system can’t access the drive once logged out.

I really want to get this working with NFS because you have the option to synchronise you NFS share with an external USB drive. You can also browse your shares with the file manager and move data between them.

I really don’t want to go down the iSCSI route as you can’t synchronise or browse and Microsoft apparently don’t recommend using NIC teaming.

Is there a way to make the share persistent or accessible by the system once you logged off? I tried it with the –o mtype=hard with no avail.


tmt

Experience counts
Posts: 1006
Joined: Mon Nov 16, 2009 11:02 am

Re: How do I mount a NFS folder to Windows Server 2008 R2

Post

by tmt » Thu Nov 11, 2010 9:50 pm

Hard mounts have nothing to do with being persistent. You can use the standard «net use» command to do this. Details are in the NFS help file (just click start->run->nfsmgmt.msc).

You need to add the «persistent:yes» flag to the appropriate «net use» command. After you enter it once, it’s not necessary to enter it again, unless you want to delete it.

«net use F: nfsserver:/nfsshare /persistent:yes» plus any other options you prefer. You can use the «nfsadmin» command to set default, in fact. Hopefully these examples will get you started:

Code: Select all

C:Userstmt>nfsadmin
Invalid option argument.
Usage : nfsadmin [server | client | mapping ] [\host]

For detailed help type nfsadmin [server|client|mapping] /?

C:Userstmt>nfsadmin client /?

Usage: nfsadmin client [computer name] [common_options] start | stop | config config_options

common_options are:
    -u user              Identity of the user whose credentials are to be used
    -p password          Password of the user

config_options are:
    protocol = TCP|UDP|TCP+UDP Set the preferred transport protocol.
    mtype = hard|soft       Specify the type of mount.
    casesensitive = yes|no  Specify the default case sensitivity of mounted file shares.
    retry = <number>        Set the number of retries for a soft mount.
    timeout = <duration>    Set the timeout (in seconds) for an RPC call.
    perf = default          Reset performance parameters to default values.
    UseReservedPorts = yes|no Use ports less than 1024
    rsize = <size>          Set the read buffer size (in KB).
    wsize = <size>          Set the write buffer size (in KB).
    fileaccess = <mode>     Specify the permission mode of the file.
                            These are used for new files created on NFS
                            servers. Specified using UNIX style mode bits.
    SecFlavors = [+|-]sys [+|-]krb5 [+|-]krb5i
                            Specify permitted security flavors.

C:Userstmt>net help use
The syntax of this command is:

NET USE
[devicename | *] [\computernamesharename[volume] [password | *]]
        [/USER:[domainname]username]
        [/USER:[dotted domain name]username]
        [/USER:[username@dotted domain name]
        [/SMARTCARD]
        [/SAVECRED]
        [[/DELETE] | [/PERSISTENT:{YES | NO}]]

NET USE {devicename | *} [password | *] /HOME

NET USE [/PERSISTENT:{YES | NO}]

NET USE connects a computer to a shared resource or disconnects a
computer from a shared resource. When used without options, it lists
the computer's connections.

devicename       Assigns a name to connect to the resource or specifies
                 the device to be disconnected. There are two kinds of
                 devicenames: disk drives (D: through Z:) and printers
                 (LPT1: through LPT3:). Type an asterisk instead of a
                 specific devicename to assign the next available
                 devicename.
\computername   Is the name of the computer controlling the shared
                 resource. If the computername contains blank characters,
                 enclose the double backslash (\) and the computername
                 in quotation marks (" "). The computername may be from
                 1 to 15 characters long.
sharename       Is the network name of the shared resource.
volume          Specifies a NetWare volume on the server. You must have
                 Client Services for Netware (Windows Workstations)
                 or Gateway Service for Netware (Windows Server)
                 installed and running to connect to NetWare servers.
password         Is the password needed to access the shared resource.
*                Produces a prompt for the password. The password is
                 not displayed when you type it at the password prompt.
/USER            Specifies a different username with which the connection
                 is made.
domainname       Specifies another domain. If domain is omitted,
                 the current logged on domain is used.
username         Specifies the username with which to logon.
/SMARTCARD       Specifies that the connection is to use credentials on
                 a smart card.
/SAVECRED        Specifies that the username and password are to be saved.
                 This switch is ignored unless the command prompts for username
                 and password.
/HOME            Connects a user to their home directory.
/DELETE          Cancels a network connection and removes the connection
                 from the list of persistent connections.
/PERSISTENT      Controls the use of persistent network connections.
                 The default is the setting used last.
YES              Saves connections as they are made, and restores
                 them at next logon.
NO               Does not save the connection being made or subsequent
                 connections; existing connections will be restored at
                 next logon. Use the /DELETE switch to remove
                 persistent connections.

NET HELP command | MORE displays Help one screen at a time.


C:Userstmt>net use f: 192.168.0.100:/Public /persistent:yes
The command completed successfully.


C:Userstmt>dir f:
 Volume in drive F has no label.
 Volume Serial Number is 91D9-ED67

 Directory of F:

02/28/2010  11:30 PM    <DIR>          ...
              11 File(s)  2,215,804,300 bytes
               6 Dir(s)  599,986,257,920 bytes free


C:Userstmt>net use
New connections will be remembered.


Status       Local     Remote                    Network

-------------------------------------------------------------------------------
             f:        \192.168.0.100Public    NFS Network

The command completed successfully.


C:Userstmt>

SS-439, Ubuntu Server 12.04.3 LTS, EXT4, RAID10, 4xHitachi 5K1000
TS-112, 4.1.x Beta, EXT4, 1xHitachi 7K1000


wikussmit

New here
Posts: 6
Joined: Tue Nov 09, 2010 5:04 pm

Re: How do I mount a NFS folder to Windows Server 2008 R2

Post

by wikussmit » Thu Nov 11, 2010 10:37 pm

I tried the command below and mounted the NFS share fine, when I log in with another admin account the network drive is missing. But when I log in again with domain admin (account used to add NFS share) the share is back.

F: 192.168.0.100:/Attixdata /persistent:yes»

I just want the system or Attix (backup software) to have access to this drive when nobody is logged in. The reason for using NFS is that the backup server is virtualized and not directly connected to the NAS storage. Also, I tried copying data with a batch file (using Task Scheduler) to the NFS share (f:) when everyone is logged out with no success.

Do you know if this is even possible — for the OS to have access to a NFS share when logged out?


tmt

Experience counts
Posts: 1006
Joined: Mon Nov 16, 2009 11:02 am

Re: How do I mount a NFS folder to Windows Server 2008 R2

Post

by tmt » Thu Nov 11, 2010 11:13 pm

Well, the problem with your plan is that you need user credentials, and without someone logged on, there aren’t any. Do you really want to do that? If so, I suggest you look into scripting the mount, using the user/password options provided by mount.exe or nfsadmin.exe. It’s not a very secure approach!

By the way, remember too that you don’t need to assign a drive letter unless your app requires it. You can use UNC paths just as easily, perhaps.

SS-439, Ubuntu Server 12.04.3 LTS, EXT4, RAID10, 4xHitachi 5K1000
TS-112, 4.1.x Beta, EXT4, 1xHitachi 7K1000


wikussmit

New here
Posts: 6
Joined: Tue Nov 09, 2010 5:04 pm

Re: How do I mount a NFS folder to Windows Server 2008 R2

Post

by wikussmit » Thu Nov 11, 2010 11:22 pm

The NAS sits on a private rage not accesble by anyone else . Also, only the backup server IP is allowed access to the NFS share. I just found out that the backup software does support backing up to an UNC path so will rather go that way. Thanks for all the help!


Понравилась статья? Поделить с друзьями:
  • Nfs протокол настроить в windows 10
  • Nfs клиент для windows server 2012
  • Nfs клиент для windows 10 скачать
  • Nfs для windows 10 64 bit
  • Nfs world системные требования windows 10