< Back

Connect-FreeNasServer

Mon Jan 13, 2020 7:43 pm

NAME Connect-FreeNasServer



SYNOPSIS

Connect FreeNas Server it use to connect to your FreeNas Server or TrueNas





SYNTAX

Connect-FreeNasServer [-Server] <Object> [[-Username] <String>] [[-Password] <SecureString>] [[-Credentials]

<PSCredential>] [-httpOnly] [-SkipCertificateCheck] [[-port] <Int32>] [<CommonParameters>]





DESCRIPTION

Connect FreeNas Server it use to connect to your FreeNas Server or TrueNas

Support connection to HTTPS (default) or HTTP





PARAMETERS

-Server <Object>

Description d????????aide Freenas



Required? true

Position? 1

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Username <String>



Required? false

Position? 2

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Password <SecureString>



Required? false

Position? 3

Default value

Accept pipeline input? false

Accept wildcard characters? false



-Credentials <PSCredential>



Required? false

Position? 4

Default value

Accept pipeline input? false

Accept wildcard characters? false



-httpOnly [<SwitchParameter>]



Required? false

Position? named

Default value False

Accept pipeline input? false

Accept wildcard characters? false



-SkipCertificateCheck [<SwitchParameter>]



Required? false

Position? named

Default value False

Accept pipeline input? false

Accept wildcard characters? false



-port <Int32>



Required? false

Position? 5

Default value 0

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS



OUTPUTS

System.String





NOTES





By default the connection use the secure method to interact with FreeNas or TrueNas server



-------------------------- EXAMPLE 1 --------------------------



PS C:\\>Connect-FreeNasServer -Server 192.0.2.1



Connect to an FreeNas using HTTPS with IP 192.0.2.1 using (Get-)credential









-------------------------- EXAMPLE 2 --------------------------



PS C:\\>Connect-FreeNasServer -Server 192.0.2.1 -SkipCertificateCheck



Connect to an FreeNas using HTTPS (without check certificate validation) with IP 192.0.2.1 using (Get-)credential









-------------------------- EXAMPLE 3 --------------------------



PS C:\\>Connect-FreeNasServer -Server 192.0.2.1 -httpOnly



Connect to an FreeNas using HTTP (unsecure !) with IP 192.0.2.1 using (Get-)credential









-------------------------- EXAMPLE 4 --------------------------



PS C:\\>Connect-FreeNasServer -Server 192.0.2.1 -port 4443



Connect to an FreeNas using HTTPS (with port 4443) with IP 192.0.2.1 using (Get-)credential









-------------------------- EXAMPLE 5 --------------------------



PS C:\\>$cred = get-credential



PS > Connect-FreeNasServer -Server 192.0.2.1 -credential $cred



Connect to an FreeNas with IP 192.0.2.1 and passing (Get-)credential









-------------------------- EXAMPLE 6 --------------------------



PS C:\\>$mysecpassword = ConvertTo-SecureString mypassword -AsPlainText -Force



PS > Connect-FreeNasServer -Server 192.0.2.1 -Username root -Password $mysecpassword



Connect to an FreeNas with IP 192.0.2.1 using Username and Password











RELATED LINKS