Sign in to follow this  
Followers 0
Pumagaju

RunAsSet Help Needed

4 posts in this topic

I get the following error when running setup via RunAsSet:

System cannot find the path specified.

Here is my code:

DriveMapDel ("Y:")

DriveMapAdd ("Y:", "\\Server\ClearCase7.0.1", 0, "domain\InstallAcct", "@Password")

RunAsSet("InstallAcct", "domain", "@Password", 0)
Run ("Y:\setup.exe")

I can verify the mapped drive and acces to the correct files, but for some reason it doesnt seem to be passing the right privs.

Any help greatly appreciated. :D

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

I could be wrong but.... this can occur if the mapped drive is connected in the security context of the locally logged on user. Runas.exe cannot access resources that were authenticated in the security context of another user. (taken from Microsoft article 303308). Ive seen this before when we try to execute a runas for a patch/program/whatever on a mapped drive while logged in as a user who has no admin rights to the box they are using. Use a UNC path or copy it local then runas.

Edited by Legacy99

Share this post


Link to post
Share on other sites

I agree, I would try to copy the files to a local drive before installing.

FileCopy("\\Server\ClearCase7.0.1\setup.exe", @TempDir & "\temp-installer-dir\setup.exe"
; Alternatively you can DirCopy("\\Server\ClearCase7.0.1", @TempDir & "\temp-installer-dir\")

RunAsSet("InstallAcct", "domain", "@Password", 0)
Run (@TempDir & "\temp-installer-dir\setup.exe")

Share this post


Link to post
Share on other sites

Hey thanks for the responses. I read that KB, great info. So I tried it with the UNC path and all is working perfectly. Didnt want to use FileCopy since its 1.5GB install. :D

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0