Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

How to redirect script results to a computer name on the network.

Posted on 2008-06-26
6
Medium Priority
?
159 Views
Last Modified: 2010-04-21
Hello,

Situation:
I have a batch file I'm running on a lot of computers at times when no users are logged on to the machines.  The computers are on a Server2003 domain.  The batch file collects information from the machine that it's ran on and redirects or pipes the information to a Log file saved on the local C: drive.  I need the Log file to be more accessible so I don't have to go to each individual machine.

Here is my script:

*********below*************

REM Create a new log file
set logname=C:\log %date:/=-% %time::=-%.txt
echo Log of Results > "%logname%"
echo ------------------------- >> "%logname%"
echo.  >> "%logname%"

*********above*************

The problem I am working to resolve:
I can't figure out how to set the Logname to be redirected to my personal PC, that I work from, instead of being saved on the local HDD of every machine its ran on.

Thanks for comments and ideas,
zbox
0
Comment
Question by:zbox
  • 3
  • 2
6 Comments
 
LVL 15

Accepted Solution

by:
sr75 earned 2000 total points
ID: 21874358
send it to a share on your laptop.  


echo -------------------------->>  \\YourMachine\YourShare
0
 
LVL 25

Expert Comment

by:slam69
ID: 21874372
what happens if your machien is not on teh network when the script runs? it will bomb teh script out, far better to redircet to a network share
0
 

Author Comment

by:zbox
ID: 21874378
that's too funny.  i use that command all the time and didn't think of that.  let me see what happens, be right back.

zbox
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:zbox
ID: 21874912
man that worked! and as soon as you posted your comment I hit myself in the head.  well that was an easy 500 lol.  thanks a lot sr75 for quick response.  This stuff is real important to me.

Thanks EE,

zbox
0
 

Author Closing Comment

by:zbox
ID: 31470943
perfect and on time.
0
 
LVL 15

Expert Comment

by:sr75
ID: 21878562
No problem.   I have had many of those moments myself.  Thanks for the grade.
0

Featured Post

Ask an Anonymous Question!

Don't feel intimidated by what you don't know. Ask your question anonymously. It's easy! Learn more and upgrade.

Question has a verified solution.

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

For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
In threads here at EE, each comment has a unique Identifier (ID). It is easy to get the full path for an ID via the right-click context menu. However, we often want to post a short link within a thread rather than the full link. This article shows a…
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
Suggested Courses

926 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