cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1097
Views
0
Helpful
5
Replies

CPO issue - Copying a file from local machine to remote shared location

Prashant Raghav
Cisco Employee
Cisco Employee

 

Hello All,

 

I am trying to copy a file from local server to remote shared location by using the below command - 

 

Copy-Item -Path E:\praghav\latest_log.txt -Destination \\CPO-PRD-04\Shared_Directory\Cognos_Logs_DEV\latest_log.txt

ErrorCopy-Item : Access to the path '\\CPO-PRD-04\Shared_Directory\Cognos_Logs_DEV\latest_log.txt' is denied.At C:\Windows\Temp\PO_WorkingDir_d3387d74-c99c-4f00-9008-a4a4adaa9f82\PO_PSScript_d3387d74-c99c-4f00-9008-a4a4adaa9f82.ps1:1 char:10+ Copy-Item <<<<  -Path E:\praghav\latest_log.txt -Destination \\CPO-PRD-04\Shared_Directory\Cognos_Logs_DEV\latest_log.txt    + CategoryInfo          : PermissionDenied: (E:\praghav\latest_log.txt:Fil    eInfo) [Copy-Item], UnauthorizedAccessException    + FullyQualifiedErrorId : CopyFileInfoItemUnauthorizedAccessError,Microsof    t.PowerShell.Commands.CopyItemCommand 

Directory already has full access. The command is working fine when i am using it in powershell command prompt.

But it's not working fine in CPO Process.

Any idea?

 

Thanks,

Prashant
 

5 Replies 5

Shaun Roberts
Cisco Employee
Cisco Employee

Who has full access to it? anyone? Both read/write?

 

Can you tried standard "copy" from a windows execute function?

--Shaun Roberts
Principal Engineer, CX
shaurobe@cisco.com

Yes. Anyone can access it.

I am able to copy the file by using the same command via powershell command prompt but it's not working when i am using CPO activity.

Is the PowerShell activity configured to run on the local PO server machine or a remote machine?

Did you check the "Select this checkbox if this activity uses remote resources" ? I'm not sure if that will help here, but I normally check it for remote access stuff. (Worth a shot if you have not)

 

If that does not help, I'd suggest a TAC case.

--Shaun Roberts
Principal Engineer, CX
shaurobe@cisco.com

 

Awesome Shaun!!

It's working for me.

 

Thankyou so much.

Review Cisco Networking for a $25 gift card