Set-NfsClientConfiguration

Set-NfsClientConfiguration

Changes configuration settings for an NFS client.

Syntax

Parameter Set: InputObject (cdxml)
Set-NfsClientConfiguration [-AsJob] [-Authentication <String[]> ] [-CaseSensitiveLookup <Boolean> ] [-CimSession <CimSession[]> ] [-DefaultAccessMode <UInt32> ] [-InputObject <CimInstance[]> ] [-MountRetryAttempts <UInt32> ] [-MountType <String> ] [-PassThru] [-ReadBufferSize <UInt32> ] [-RpcTimeoutSec <UInt32> ] [-ThrottleLimit <Int32> ] [-TransportProtocol <String[]> ] [-UseReservedPorts <Boolean> ] [-WriteBufferSize <UInt32> ] [-Confirm] [-WhatIf] [ <CommonParameters>]

Detailed Description

The Set-NfsClientConfiguration cmdlet changes configuration settings for a Network File System (NFS) client. You can use the Get-NfsClientConfiguration cmdlet to get a configuration object for an NFS client.

Parameters

-AsJob

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Authentication<String[]>

Specifies one or more authentication types that an NFS client can use to access NFS shares.

Valid values are:
-- Sys (AUTH_SYS authentication)
-- Krb5 (Kerberos v5 authentication)
-- Krb5i (Kerberos v5 authentication with integrity checking)
-- Krb5p (Kerberos v5 authentication with privacy)
-- All
-- Default

If you specify All, Services for NFS configures Sys, Krb5, Krb5i, and Krb5p on the share. If you specify Default, Services for NFS configures Sys, Krb5, and Krb5i on the share.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-CaseSensitiveLookup<Boolean>

Specifies that the NFS client must perform case-sensitive lookups of file names for NFS shares that are mounted locally.

Aliases

none

Required?

false

Position?

named

Default Value

0

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-CimSession<CimSession[]>

Runs the cmdlet in a remote session or on a remote computer. Enter a computer name or a session object, such as the output of a New-CimSession or Get-CimSession cmdlet. The default is the current session on the local computer.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-DefaultAccessMode<UInt32>

Specifies the default permission mode that an NFS client assigns for newly created files, in UNIX-style mode bits. The permissions that this property specifies are set for all new files created on mounted shares.

With UNIX-style mode bits (also known as the three-digit octal notation), each numeral represents a different component of the permission set: user class, group class, and "others" class.

Each of these digits is the sum of its component bits. As a result, specific bits add to the sum:

The read bit adds 4 to its total (in binary 100).
The write bit adds 2 to its total (in binary 010).
The execute bit adds 1 to its total (in binary 001).

Individual octal digit values represent the following:
0 -- no permission
1 -- x     execute
2 -- w     write
3 -- wx   write and execute
4 -- r      read
5 -- r-x   read and execute
6 -- rw    read and write
7 – rwx   read, write, and execute

The following are examples of UNIX-style mode bits:

777 = "-rwxrwxrwx" = rwx for all

754 = "-rwxr-xr--" = rwx for owner, r-x for group, r-- for other

124 = "--x-w-r--" = x for owner, w for group, r for other

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-InputObject<CimInstance[]>

Specifies the input to this cmdlet. You can use this parameter, or you can pipe the input to this cmdlet.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByValue)

Accept Wildcard Characters?

false

-MountRetryAttempts<UInt32>

Specifies the number of retries that the NFS client performs when it is attempting a soft mount.

Aliases

none

Required?

false

Position?

named

Default Value

1

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-MountType<String>

Specifies the type of mount that the NFS client uses when it is mounting a share that an NFS server exported. Valid values are Hard and Soft.

Aliases

none

Required?

false

Position?

named

Default Value

1

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-PassThru

Returns an object representing the item with which you are working. By default, this cmdlet does not generate any output.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ReadBufferSize<UInt32>

Specifies the size of the read buffer (in kilobytes) that the NFS client uses.

Aliases

none

Required?

false

Position?

named

Default Value

32

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-RpcTimeoutSec<UInt32>

Specifies the time-out for a remote procedure call (RPC), in seconds, that the NFS client enforces for outstanding RPC calls.

Aliases

none

Required?

false

Position?

named

Default Value

8

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ThrottleLimit<Int32>

Specifies the maximum number of concurrent operations that can be established to run the cmdlet. If this parameter is omitted or a value of 0 is entered, then Windows PowerShell® calculates an optimum throttle limit for the cmdlet based on the number of CIM cmdlets that are running on the computer. The throttle limit applies only to the current cmdlet, not to the session or to the computer.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-TransportProtocol<String[]>

Specifies the transport protocol that the NFS client uses for NFS, Network Lock Manager (NLM), Port Mapper (PMAP), or MAPSVR protocols.

Valid values are:
-- TCP
-- UDP
-- TCP+UDP

Aliases

none

Required?

false

Position?

named

Default Value

3

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-UseReservedPorts<Boolean>

Specifies whether the NFS client uses network ports less than 1024.

Aliases

none

Required?

false

Position?

named

Default Value

1

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-WriteBufferSize<UInt32>

Specifies the size of the write buffer (in kilobytes) that the NFS client uses.

Aliases

none

Required?

false

Position?

named

Default Value

32

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Confirm

Prompts you for confirmation before running the cmdlet.

Required?

false

Position?

named

Default Value

false

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Required?

false

Position?

named

Default Value

false

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see    about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

Outputs

The output type is the type of the objects that the cmdlet emits.

  • Microsoft.Management.Infrastructure.CimInstance#root/Microsoft/Windows/NFS/MSFT_NfsClientConfig

Examples

Example 1: Modify configuration settings for an NFS client

This command modifies configuration settings for an NFS client on the local computer. This command sets the default permissions for newly created files to 755, and it sets the sizes of the read and write buffers to 64 kilobytes (KB).

The default permission of 755 sets read, write, and execute permissions (7 – rwx) for the owner, read and execute permissions (5 -- r-x) for the group, and read and execute permissions (5 -- r-x) for others.

PS C:\> Set-NfsClientConfig -DefaultAccessMode 755 -ReadBufferSize 64 -WriteBufferSize 64

Get-NfsClientConfiguration