Quantcast
Viewing all articles
Browse latest Browse all 10

Run batch files as administrator user

Image may be NSFW.
Clik here to view.
Question

I have a segment with 100 computers.

I am booting each machne from WinPE OS located on a CD. After the OS has finished loading, I want to automatically run a batch file that will copy the CD to the C: drive.

My questions:

  1. How can I edit the WinPe ISO to run the batch file automatically after booting?
  2. Copy to C: drive required an admin privilages, how can I write it to run as admin? (I can’t use “Run As” command since I dont know what the name and the password of admin on each computer are).
Asked by rrr

Image may be NSFW.
Clik here to view.
Answer

I don’t know how you’ve created the WinPE ISO, I presume it’s with the WAIK?

When you’re building the image, create a new text file in notepad called Winpeshl.ini and store it in the build_directorymountWindowsSystem32. In that file, call the batch file.

To make it a bit easier and quicker, see if this link will help. I used it to see when I was trying to auto-launch RDP from a WinPE enviroment as asked in this question

Answered by tombull89

Viewing all articles
Browse latest Browse all 10

Trending Articles