#CIFS Shares & Clients
1 messages · Page 1 of 1 (latest)
$Data= Get-NcCifsSession -Controller $SOM | Select-Object Address,shares,WindowsUser,ConnectionId,LifAddressmysq
then
if ((Get-NcCifsSessionFile | Where-Object ConnectionId -EQ $_.ConnectionId | select-object Share).count -gt 0 )
Setup stuffs in a lab:
$PSVersionTable
Set-PSRepository -Name PSGallery -InstallationPolicy Trusted
Find-Module NetApp.ONTAP | Install-Module -SkipPublisherCheck -AllowClobber
Get-module NetApp.ONTAP -ListAvailable | Import-Module
Connect-NcController -Name cluster2.demo.netapp.com
Some discovery
PS C:\Users\Administrator.DEMO> Get-NcCifsSession -Controller $Global:CurrentNcController
VVVVVVV <- This is the host
LifAddress SessionId ConnectionId ConnectedTime ProtocolVersion Address Vserver
---------- --------- ------------ ------------- --------------- ------- -------
192.168.0.141 …76798722049 1732011656 3m 32s smb3_1 192.168.0.5 svm21
PS C:\Users\Administrator.DEMO> Get-NcCifsSession -Controller $Global:CurrentNcController | ForEach-Object {
>> Resolve-DnsName $_.Address}
Name Type TTL Section NameHost
---- ---- --- ------- --------
5.0.168.192.in-addr.arpa. PTR 1200 Question JUMPHOST.demo.netapp.com
PS C:\Users\Administrator.DEMO>
Unless I'm misunderstanding, Get-NcCifsSession is already providing the host
hi @faint torrent Harvest added the collection of CIFS connection IDs recently https://github.com/NetApp/harvest/issues/1826
I'll check it out but the cluster in question is still at 9.7 and has FAS8040 nodes. We're moving volumes off this thing.