Solved

Powershell remote file-out

Posted on 2013-12-05
1
1,515 Views
Last Modified: 2013-12-05
Setup:
I have a domain runing Server 2008 R2 and windows 7. I am starting to use powershell more and more. I have configued WinRM and used group policy to Allow Automatic configuration of listeners. I can now start a remote session and execute powershell commands on remote machines from Powershell ISE or Powershell on my machine (logged in as domain admin).

Problem:
After a few test commands I ran the following:
Get-ChildItem -Path C:\nso | Out-File -FilePath \\mymachine\c$\nso\test.txt
However I ran into the following error:
Access to the path '\\mymachine\c$\nso\test.txt' is denied.
    + CategoryInfo          : OpenError: (:) [Out-File], UnauthorizedAccessException
    + FullyQualifiedErrorId : FileOpenFailure,Microsoft.PowerShell.Commands.OutFileCommand

I can't understand why such a simple command fails I am a domain admin, I started the session using domain admin credentials and I can happly read/write to both locations if I browse to them.......what am I missing? thanks in advance
0
Comment
Question by:Dead_Eyes
1 Comment
 
LVL 39

Accepted Solution

by:
footech earned 250 total points
Comment Utility
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

"Migrate" an SMTP relay receive connector to a new server using info from an old server.
This article will help you understand what HashTables are and how to use them in PowerShell.
In this video, we discuss why the need for additional vertical screen space has become more important in recent years, namely, due to the transition in the marketplace of 4x3 computer screens to 16x9 and 16x10 screens (so-called widescreen format). …
This Micro Tutorial will give you a introduction in two parts how to utilize Windows Live Movie Maker to its maximum capability. This will be demonstrated using Windows Live Movie Maker on Windows 7 operating system.

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now