Using PSEXEC to run an application on a remote computer

Hello Experts,

Here is the situation.  We have switched from Norton Antivirus to Sophos Antivirus.  To make the switch, we had to uninstall Norton and then proceed with the Sophos install.  For the most part Sophos technicians were able to automate this process.  Every once in awhile we run across a PC (running XP Pro) where the uninstall of Norton was not as clean as we would have liked it to be and various Symantec windows pop up when the user logs on.  To take care of this, we run a utility called Nonav.  It finishes the uninstall very nicely.

Here is what I would like to do.  I would like to use psexec to run the Nonav utility on remote computers, but Im running into a few problems.  Please take a look at the following command:

Psexec \\ cmd.exe c nonav.exe

The psexec command above gets me to the remote PC and should copy the Nonav utility to the remote PC.  Here are my questions/problems:

1.      Were would the command copy the nonav.exe utility to on the remote PC?  Is there a way I can specify the location I want the file copied to on the remote PC
2.      When I launch Nonav.exe locally, a window comes up asking me to extract the application.  Once the application is extracted, it runs without any other user interaction.  Is there a way to force the application to run in a non-interactive mode via psexe?

Your help (as always) will be greatly appreciated.

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.


Read the comments from 'sirbounty' - he is the one who actually solved that one - not me.

If he checks in on this question - make sure you give him the points.

"Two seperate routes posted actually...

If you have a list of computers, then use:

for /f %a in (C:\Computers.txt) do psexec \\%a c:\pathtofile\file.exe

That's just a command-line command.
If you need to add it to a batch file, change %a to %%a (both instances).

Otherwise, just using psexec's builtin 'loop' method:
psexec @C:\computers.txt c:\pathtofile\file.exe

and both will use your current logged in credentials.
-u 'username' -p 'password'
(added to psexec parameters) allows you to change the user credentials)"

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Place nonav.exe into the directory you are running psexec from.....

Also, need to use the -c switch to copy the file to the destination....

TRy this....

psexec \\ -c nonav.exe /switches....

Try running Nonav.exe at a command line with "nonav.exe /?" and see if it lists silent switches...

Or look in the task manager to see what other processes are spawned....
Hey jb -
I was trying to find that post you made on PSEXEC a couple of weeks ago.
Have to figure out some way to save my favorites from you and sirbounty.

The Ultimate Tool Kit for Technolgy Solution Provi

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy for valuable how-to assets including sample agreements, checklists, flowcharts, and more!

No, they are copyrighted.....


Havent seen him around in forever....

Dont you use your Knowledge base?
<Dont you use your Knowledge base?>

Sure I do - on the rare occasions when my brain actually functions.

I started using it more and more,  kinda tired of typing the same things over and over....

> Is there a way to force the application to run in a non-interactive mode via psexe?

Good idea since those two programs are not that dependable. My preference is to dump unnecessary tasks, trim out all its files (clean disk), then trash all the registry entries. The process can be simplified of course through use of a command file that can be reused for each computer. Chances are that you have no idea at what point the application is currently installed to, how functional it might be, how many versions installed, how stable, functions & features etc.
We were able to use NoNav and PSEXEC to wipe out a wide variety of NAV/SAV versions from three different 2,000+ computer networks.

One of them was after a moron Second Lieutenant (redundant term) tried to 'hack' the SAV server password and locked up/crashed the server.

We were using NoNav 2.48, but there are newer versions out there now.

PSEXEC is a wonderfully stable little application and I've used it for many thousands of installs/uninstalls.

It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.