VisualSVN Server includes a set of Windows PowerShell cmdlets which allow administrators to manage the server locally or remotely. To issue the cmdlet against a remote server, use the CimSession parameter. For example, the following cmdlet returns the list of repositories hosted on server1.contoso.com which is a remote VisualSVN Server instance:

PS C:\> Get-SvnRepository -CimSession server1.contoso.com

For more information about the PowerShell cmdlets included with VisualSVN Server and examples, read the article KB88: VisualSVN Server PowerShell Cmdlet Reference

The remote server administration with VisualSVN Server PowerShell uses Windows Management Instrumentation (WMI) over WinRM. It is required to complete the following three steps in order to enable remote administration with VisualSVN Server PowerShell cmdlets:

  • Ensure that Windows Management Framework 3.0 or newer is installed on the server and the administrator’s computer.
  • Enable WinRM remote management on the server computer.
  • Grant appropriate access permissions to administer VisualSVN Server through WinRM.

Below you can find more detailed description of each step required to enable the remote administration with PowerShell cmdlets.

Ensure that Windows Management Framework 3.0 or newer is installed

Windows Management Framework 3.0 or newer must be installed on the server computer. The computer of VisualSVN Server administrator issuing the cmdlets must have Windows Management Framework 3.0 or newer installed too.

You can ensure that the minimum Windows Management Framework version requirement is met by starting PowerShell console on the computer and running the following command:

PS C:\> $PSVersionTable.WSManStackVersion.Major

The resultant number corresponds to the Windows Management Framework version number and must be "3" or higher. If the result is "2" or lower, you should upgrade Windows Management Framework on the computer.

Enable WinRM remote management on the server computer

In order to allow remote management through WinRM, you need to run the Set-WSManQuickConfig cmdlet on the server computer. Running the cmdlet enables and starts the WinRM service and enables the Windows Remote Management (HTTP-In) Windows Firewall inbound rule. For more information about the cmdlet, read the Set-WSManQuickConfig cmdlet reference at Microsoft TechNet.

Run the Set-WSManQuickConfig cmdlet at the PowerShell command prompt:

  1. Start Windows PowerShell command prompt as administrator on the server computer.
  2. Issue the following cmdlet:
    PS C:\> Set-WSManQuickConfig
Note
Note

When performing the steps on a client Windows operating system such as Windows 7 or Windows 10, it is possible that it will be required to manually enable the inbound Windows Firewall rule. In addition to the steps described above run the Enable-NetFirewallRule cmdlet at the PowerShell command prompt:

  1. Start Windows PowerShell command prompt as administrator on the server computer.
  2. Issue the following cmdlet:
    PS C:\> Enable-NetFirewallRule -Name WINRM-HTTP-In-TCP

For more information, read the Enable-NetFirewallRule cmdlet reference at Microsoft TechNet.

Grant appropriate access permissions to administer VisualSVN Server through WinRM

The following permissions are required to use VisualSVN Server PowerShell for the remote administration of VisualSVN Server:

  • Permissions to access WinRM and WMI remotely.
  • Special permissions to manage resources related to VisualSVN Server.

To grant all the required permissions to a non-administrative user, you should include the user in the following local groups on the computer where VisualSVN Server is installed:

  • WinRMRemoteWMIUsers__.
  • VisualSVN Server Admins.
Note
Note Users who are local administrators of the remote VisualSVN Server computer, have all the required permissions to administer the server and the repositories.

See also

KB88: VisualSVN Server PowerShell Cmdlet Reference
KB25: Configuring Remote Administration
Last Modified: