Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

psexec copying files

Posted on 2014-04-25
2
534 Views
Last Modified: 2014-04-25
HI: stergium,qlemo and gurutc very kindly helped me set up a remote execution of a batch file. I This is great and I was wondering if psexec does more:
I am wanting to copy a file now, to the local directory of the server.
Does psexec allow me to copy a file from r:\data\deliveries\mapper.csv to c:\mapsuploader\mapper.csv, if the R drive is the same for pc and server, and a file of that name already exists (ie overwrite)?
Thanks!
0
Comment
Question by:ClaytonGlass
2 Comments
 
LVL 84

Accepted Solution

by:
oBdA earned 200 total points
ID: 40022250
No; psexec will only copy the program to be executed to the remote machine.
But nothing keeps you from using a batch script to first copy the file from your client and then run psexec:
@echo off
setlocal
copy R:\data\deliveries\mapper.csv \\Server\C$\mapsuploader\mapper.csv
psexec \\Server -h C:\mapsuploader\mapsuploader.exe C:\mapsuploader\mapper.csv

Open in new window

0
 

Author Closing Comment

by:ClaytonGlass
ID: 40022259
Thank you!
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

One of my most closely kept secrets is revealed in this discussion How to output text on the same line This question was recently posted in EE by Simon336697 (http://www.experts-exchange.com/Programming/Languages/Scripting/Shell/Batch/Q_2459…
VALIDATING DATES One method of validating dates is to jam the date into the DATE command and see if it accepts it by examining the system's errorlevel value. A non-zero result indicates failure. A typical example might look something like the fol…
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

809 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