Import-PSSession

Import-PSSession brings commands from a remote computer into the current session. Microsoft Exchange uses this technique to provide remote access to the Exchange Management Shell.

The following example imports the NetAdapter module from a remote server into the current session:

$computerName = 'PSTest' 
$session = New-PSSession -ComputerName $computerName 
Import-PSSession -Session $session -Module NetAdapter 

Any commands used within this module are executed against the session target, not against the local computer.

If the session is removed, the imported module and its commands will be removed from the local session.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.144.98.13