Remote powershell problems

My powershell-fu is weak, I work primarily with Linux but we took on an exchange project. I'm having issues connecting to a server over a vpn with powershell. My machine is a non-domain machine. The remote machine is running Windows Server 2012. I need to run a powershell script on a remote machine, RDP is not enabled, the client will not enable it, i cant copy and paste via the console on vmware so I'm left with powershell which the client assures me is what he uses to interface with the machine. i can get it to prompt me for a password for my user account but when i enter it i get:

Enter-PSSession : Connecting to remote server ***SERVERNAME*** failed with the following error message : The WinRM
client cannot process the request. If the authentication scheme is different from Kerberos, or if the client computer
is not joined to a domain, then HTTPS transport must be used or the destination machine must be added to the
TrustedHosts configuration setting. Use winrm.cmd to configure TrustedHosts. Note that computers in the TrustedHosts
list might not be authenticated. You can get more information about that by running the following command: winrm help
config. For more information, see the about_Remote_Troubleshooting Help topic.
At line:1 char:1
+ Enter-PSSession -ComputerName ***SERVERNAME*** -Credential abc.net ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (***SERVERNAME***:String) [Enter-PSSession], PSRemotingTransportExcep
   tion
    + FullyQualifiedErrorId : CreateRemoteRunspaceFailed

Open in new window


Can anyone give me any ideas what I'm doing wrong?
LVL 4
Jesse BruffettM&F-ing SorcererAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Martin MillerCTOCommented:
The output looks like a group policy for Active Directory needs to be enabled for you client to process. Do have access admin of AD, or someone that can assist ?
0
Jesse BruffettM&F-ing SorcererAuthor Commented:
I do not have access to the AD servers but I can have their sysadmin do it tomorrow. What needs to be enabled? I’m case he asks.
0
Martin MillerCTOCommented:
If the admin understands AD and x.500... the Kerberos in the note, "TrustedHosts" , they should be able to look at the policy and permissions on the remote machine and your client machine where the script is executed.
0
INTRODUCING: WatchGuard's New MFA Solution

WatchGuard is proud to announce the launch of AuthPoint, a powerful, yet simple, Cloud-based MFA service designed to eliminate the vulnerabilities that put your data, systems, and users at risk.

Jesse BruffettM&F-ing SorcererAuthor Commented:
But... which AD policy needs to be enabled on the domain? They don’t have access to my machine so what if anything do I need to do to my machine?
0
Martin MillerCTOCommented:
If you are on "the network", then you have an AD profile.

WRT to which policy, I suggest doing screen share session with your admin, and show them the error message. They may clueless but they should understand the "TrustedHosts" are part of a group, but what group ?  ... and your machine is not included...
0
Jesse BruffettM&F-ing SorcererAuthor Commented:
Just to make sure we are on the same page, the account I’m using is an AD account of course, my computer is NOT bound to to domain, or any domain. The account I’m using, I’m just using to log into the remote machine with.
0
Martin MillerCTOCommented:
The magic may be binding to the domain, think about the security risk of anyone attempting remote access.
0
footechCommented:
No need to do anything on the domain.  There's lots of good information in the error message.
"HTTPS transport must be used or the destination machine must be added to the TrustedHosts configuration setting"
And for more information, read the about_Remote_Troubleshooting help topic.  If you're not familiar with the built-in help for PS, you can see a help topic by running something like
help about_Remote_Troubleshooting

Open in new window

In PS 3.0+, you will first need to download the help files, by running Update-Help from an elevated (administrative) PS session.

There's some headings under the about_Remote_Troubleshooting topic which should stand out for you, "HOW TO CONNECT REMOTELY FROM A WORKGROUP-BASED COMPUTER", and "HOW TO ADD A COMPUTER TO THE TRUSTED HOSTS LIST".  Sounds about spot-on, right?  The client probably hasn't enabled HTTPS transport.

You can read the topic for more detail, but the quick answer for this one instance is run the following from an elevated PS session.
Set-Item wsman:\localhost\Client\TrustedHosts -Value <name or IP of remote machine>

Open in new window

1

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Jesse BruffettM&F-ing SorcererAuthor Commented:
Your last script was spot on what i needed. Thank you!
0
footechCommented:
Glad to help!

If you intend to become stronger with PowerShell, working towards understanding any error messages you come across and reading the built-in help will serve you well.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Powershell

From novice to tech pro — start learning today.