Pages

Tuesday, 31 March 2015

Using WinRM to query remote computers

Firstly we must configure WinRM on the remote server with:
winrm quickconfig

We can then initiate a test connection too the server:
winrm get winrm/config/client -r:remote-host -u:[email protected] -p:password

** Note: If you attempt to connect via WinRM you must make sure that your user account (on the remote computer) is a member of the machine you are connecting to's Local Administrators group otherwise you will get an Access Denied message returned. **

We can then use winrm to query information from the remote computer e.g. services:
winrm get wmicimv2/Win32_Service?Name=spooler

No comments:

Post a Comment