Microsoft Virtualization Discussions

vfiler creation



I am trying to script the creation of a new cifs vfiler.

This works:

$testfiler = Connect-NaController testfiler
New-NaVfiler vf1 -Addresses -Storage vf1vol -controller $testfiler
But how can I do setup of the ip address and CIFS equivalent of the "setup" and "cifs setup"
on the vfiler command line?

I have tried

$vf1 = Connect-NaController fas270a -Vfiler vf1

Set-NaCifs -CifsServer vf1 -AuthType ad -SecurityStyle ntfs -Domain test.local -Controller $vf1

but this doesnt seem to accept a vfiler as "-Controller"

Is this possible at all with PowerShell only? (it should be)




Re: vfiler creation


Yes, this should be possible and I managed to get it working here.  I did have to do a few things beyond what you listed.

First, make sure your vfiler network is fully configured with ip address, netmask and interface.  I did it like this from the pfiler context, per the Toolkit online help:

PS C:\> $b = New-Object NetApp.Ontapi.Filer.Vfiler73.IpbindingInfo
PS C:\> $b.Interface = "e0a"
PS C:\> $b.Ipaddress = ""
PS C:\> $b.Netmask = ""
PS C:\> Set-NaVfilerAddress vfiler1 -IpBindingInfo $b

Also make sure your vfiler DNS is configured so you can resolve the domain controller by name.

PS C:\> Ping-NaHost torres.rtprre.testdomain

Then try configuring CIFS from the vfiler context:

PS C:\> Connect-NaController dunn -Vfiler vfiler1

Name                 Address           Ontapi   Version
----                 -------           ------   -------
dunn             1.12     NetApp Release 7.3.3: Thu Mar 11 22:29:52 PST 2010

PS C:\> Set-NaCifs -CifsServer DUNNVF1 -AuthType ad -SecurityStyle ntfs -Domain rtprre.testdomain -User Administrator -Password ********
PS C:\> Get-NaCifs

ADSite            :
AuthType          : ad
DCConnection      : {NetApp.Ontapi.Filer.Cifs.ConnectionInfo}
DNSDomainname     : rtprre.testdomain
LDAPConnection    : {NetApp.Ontapi.Filer.Cifs.ConnectionInfo}
NetBIOSDomainname : RTPRRE
NetBIOSServername : DUNNVF1
SecurityStyle     : ntfs
WindowsType       : Windows 2003

PS C:\> Test-NaCifs

In my case I had to add the vfiler server name to the AD server manually; I'm not sure why, but ONTAP tried and failed to register the name:

Mon Dec  6 15:58:32 EST [vfiler1@dunn (takeover): cifs.ldap.processingFail:error]: LDAP: Could not create Active Directory account for the filer. Error 32: No such object

Earn Rewards for Your Review!
GPI Review Banner
All Community Forums