Solved

Remotely un-install software on my domain

Posted on 2012-03-26
34
1,859 Views
Last Modified: 2012-03-29
is there a way or some soft of script to remotely un-install a software from all my PC's on my network?

i need to remove webroot spysweeper

Thanks
0
Comment
Question by:NxJNY
  • 11
  • 10
  • 5
  • +3
34 Comments
 
LVL 17

Expert Comment

by:Chris Millard
ID: 37765750
If you know what the command is to uninstall it locally from a PC, then you can do it over a network using the free PSEXEC utility (part of PSTOOLS):-

http://technet.microsoft.com/en-us/sysinternals/bb896649

It is very straight foward to use - you'd be better off creating a text file with all of the computer names.

OR you could automate the removal without using PSEXEC by using a login script on your domain.
0
 
LVL 38

Expert Comment

by:younghv
ID: 37765761
The best tool I've ever used for this kind of work is "PSEXEC" - free from MS.

Two of us teamed up on the EE question linked below - which you should be able to modify to do what you need:
http://www.experts-exchange.com/Q_22397407.html
0
 
LVL 29

Expert Comment

by:Sudeep Sharma
ID: 37765798
You could also try ssecleanup tool to remove it.

Download
http://resnet.bridgew.edu/files/SSECleanup.zip

Sudeep
0
 
LVL 2

Author Comment

by:NxJNY
ID: 37765864
thanks guys i am mostly interested on how to remove remotely; i am using pexec but i don't know the commands of how to go about the removal of the software remotely
0
 
LVL 14

Expert Comment

by:athomsfere
ID: 37765972
You can find the command by opeing the registry and finding the uninstall string (The same way add/ remove programs sees and uninstalls programs).

Go to HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall
And then the application name, you will see a subkey named UninstallString

If you run that from the command line it will uninstall, but first try it locally on a machine with it installed with a /? switch to see if you can uninstall it silently / quietly.

You can then run that new command with the quiet switch with PSExec on the machines.
0
 
LVL 2

Author Comment

by:NxJNY
ID: 37766168
@ athomsfere I have no un-install string for spysweeper

@younghv - i have read your link and it was very informative however i am a bit confused; do i need pexec to be installed on every PC for the command to work?
webroot.png
0
 
LVL 29

Expert Comment

by:Sudeep Sharma
ID: 37766263
No, you would only need psexec on your system however you would need administrator rights of the remote machine to uninstall the program.
0
 
LVL 17

Expert Comment

by:Chris Millard
ID: 37766295
Ok, there's a SpySweeper removal tool that you could download from here:-

http://resnet.bridgew.edu/files/SSECleanup.zip

You could unzip that archive and put the contents somewhere on a network share that EVERYONE has access to, then you can use PSXEC to run that tool remotely on all of the PCs
0
 
LVL 38

Assisted Solution

by:younghv
younghv earned 250 total points
ID: 37766300
NxJNY,
One of the many great things about PSEXEC is that you only need to install it on YOUR workstation.

As long as you are logged in with an account that has Domain Admin privs, you don't need to fool around with account names/passwords - the privs of the account typing the commands will execute them.
0
 
LVL 38

Expert Comment

by:younghv
ID: 37766310
"You could unzip that archive and put the contents somewhere on a network share that EVERYONE has access to, then you can use PSXEC to run that tool remotely on all of the PCs"

Not really.
You can have that file ANYWHERE that the account running PSEXEC can see. Ideally, it would be right on the logged-in workstation where you are doing the work.
0
 
LVL 17

Expert Comment

by:Chris Millard
ID: 37766317
Suppose you create a textfile called mycomps.txt and populate it with the list of PCs on your network (one per line), and then yuo put SSECleanup.exe on a server called MYSRV in a shared folder called SSE, the command for PSEXEC would then be:-

PSEXEC @mycomps.txt -u yourdomain\yourusername -p yourpassword \\MRSRV\SSE\SSECleanup.exe
0
 
LVL 17

Expert Comment

by:Chris Millard
ID: 37766323
Sorry - \\MYSRV\SSE\SSECleanup.exe - not \\MRSRV
0
 
LVL 38

Expert Comment

by:younghv
ID: 37766338
Please do NOT use the command that includes your username and password.
First of all, it is unnecessary (PSEXEC automatically uses your credentials), and
Second, PSEXEC is transmitting "in the clear" and your username/password can be read by anyone looking at network traffic.

If you simply store SSECleanup.exe in the root of your C:\ Drive, you can modify the above command to:


PSEXEC @mycomps.txt SSECleanup.exe
0
 
LVL 14

Expert Comment

by:athomsfere
ID: 37766411
Is the application in Add-remove programs?

If so the application might also be listed as a GUID in the uninstall.
0
 
LVL 2

Author Comment

by:NxJNY
ID: 37767646
what am i doing wrong here guys?
psexec-error.png
0
 
LVL 38

Expert Comment

by:younghv
ID: 37768120
What is wrong is that rubbish path you stuck the executable file in.

Please read my last comment and follow the directions.
0
 
LVL 2

Author Comment

by:NxJNY
ID: 37768171
when i try your suggestion "PSEXEC @mycomps.txt SSECleanup.exe" i get an error "PSEXEC could not start mycomps.txt SSECleanup.exe on nypc@domain.com
0
What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 
LVL 38

Expert Comment

by:younghv
ID: 37768201
Are PSEXEC, mycomps.txt, and SSECleanup.exe all in your root of C - and are you sure that your logged in account has Admin privs on all of the target computers?

You might want to test drive it by entering the UNC path of a computer near you - just to make sure the command will work, before trying the .txt file.

Does your .txt file show a UNC path for each of your systems?
0
 
LVL 2

Author Comment

by:NxJNY
ID: 37768299
yes i have PSEXEC; SSECleanup.exe; and mycomps.txt all in my C Drive; yes i am a network admin on all PC's and i am logged in as myself; i only add one pc on my network to mycomps.txt list as i am testing for now
0
 
LVL 2

Author Comment

by:NxJNY
ID: 37768351
yes it does and i even tried it with the ip address but still no luck
0
 
LVL 2

Author Comment

by:NxJNY
ID: 37768429
here is what the error currently looks like

Starting PsExec service on mypc@domain.com...


Connecting with PsExec service on mypc@domain.com...


Starting PSEXEC SSECleanup.exe on mypc@domain.com...



PsExec could not start PSEXEC SSECleanup.exe on mypc@domain.com:
0
 
LVL 38

Expert Comment

by:younghv
ID: 37768443
I just pinged "sirbounty" to take a look at this one - he is much more current on this than I.
0
 
LVL 2

Author Comment

by:NxJNY
ID: 37769279
i want to thank you guys for all your help; even though this issue is not solved as yet i appreciate all you guys helping
0
 
LVL 38

Expert Comment

by:younghv
ID: 37770622
Would you post an example (correct format, but fake) of an actual computer name on your domain?

For me one the biggest attractions of PSEXEC is its simplicity.

To run any command, you only need three things:

PSEXEC
\\UNC_Computer_Name
Whatever_Command
******************

In your example above, you use this: "mypc@domain.com..." and I don't know what that means.

In my experience, an actual UNC path would be something like:
\\Sales001 or \\BigBoss7

Since you are functioning within the domain, you do not need to use the FQDN.
(Sorry if I'm telling you how to suck eggs, but I've never seen this occur before with PSEXEC.)

Have you read through the actual link at MS with the list of commands?
http://technet.microsoft.com/en-us/sysinternals/bb897553

Finally, have you actually gone to another system and logged on with the account you are using to run PSEXEC? I can't begin to recall the number of times someone has mucked about with the local admin group on a system and managed to alter the membership.
0
 
LVL 67

Accepted Solution

by:
sirbounty earned 250 total points
ID: 37771141
Hi gang - just glossed over most of this.
If I recall, when using the psexec computer list loop, you have to specify a hard path.
Thus, instead of:

"PSEXEC @mycomps.txt SSECleanup.exe"

Try using:
"PSEXEC @C:\MyFolder\mycomps.txt C:\MyTools\SSECleanup.exe"
(obviously replacing MyFolder and MyTools as necessary).

However, I don't think that psexec will actually deploy ssecleanup.exe.  That file needs to be placed somewhere accessible from the target client.
Whether that's a network share or a temporary copy to each client, it needs to be accessible from the client.  Placing it on a network share somewhere, as previously mentioned, should suffice.  So that your command becomes:

"PSEXEC @C:\MyFolder\mycomps.txt \\MySrv\SSETool\SSECleanup.exe"
(where SSETool is a share on MySrv that your current admin credentials are able to connect to).

Let us know how you make out.
0
 
LVL 38

Expert Comment

by:younghv
ID: 37771169
"(where SSETool is a share on MySrv that your current admin credentials are able to connect to)."


Dang!

Thanks for checking in. I had forgotten that. We used to hang a "Shared Folder" off one of the File Servers that had "Everyone" with full permissions.

I'm going to go sit in the corner and try to remember where I left my memory.
0
 
LVL 67

Expert Comment

by:sirbounty
ID: 37771178
Nah, that's an easy one to overlook.  Though not 'Everyone' needs perms to that share - just the admin running the tool... ;^)
0
 
LVL 2

Author Comment

by:NxJNY
ID: 37771595
thanks Guys i got PSEC working now however i have a bit of issue now as the software does not seem to be uninstalling;i have rebooted the pc also. below is my psexec results

Connecting to mypc77...
\\mypc78:

Starting PsExec service on mypc77...

Connecting with PsExec service on mypc77...

Starting \\myserver\SS\MyTools\SSECleanup.exe on mypc77...

\\myserver\SS\MyTools\SSECleanup.exe started on mypc77 with process ID 4748.
Connecting to nypc47...

Starting PsExec service on mypc78...

Connecting with PsExec service on mypc78...

Starting \\myserver\SS\MyTools\SSECleanup.exe on mypc78...

\\mypc78\SS\MyTools\SSECleanup.exe started on mypc78 with process ID 4072.
0
 
LVL 67

Expert Comment

by:sirbounty
ID: 37771656
Is it possible that it's running when the uninstall is attempted?

Using the pstools link already provided, utilize pslist or psservice to see if it's in the process/service list (pslist \\mypc78|find /i "spysweeper").
If it's running, it may not allow an uninstall because the files are in use.

You might try this batch file combination to ensure it's not running: (using pskill from PSTools)

@echo off
for /f %%a in (C:\MyFolder\Computers.txt) do call :process %%a
goto :eof

:process
set PC=%1
pskill \\%PC% spysweeper.exe
psexec \\%PC% \\myserver\SS\MyTools\SSECleanup.exe

Open in new window

0
 
LVL 38

Expert Comment

by:younghv
ID: 37771699
Good thoughts from sirbounty.

You might also try a different SSECleanup.exe

If you have this path on one of your systems, it will insure that you are using the correct version:
C:\Program Files\Webroot\Enterprise\Server\Client

I was meandering around their web site and their "Help" pages aren't very helpful
0
 
LVL 67

Expert Comment

by:sirbounty
ID: 37771701
Sorry, obviously the above is depending on a list of computers in C:\MyFolder\Computers.txt
(Just the computer name only - no preceeding "\\")
0
 
LVL 67

Expert Comment

by:sirbounty
ID: 37771708
Yeah, from what I've found, the best option is to install the new trial version - it uninstalls the existing first... (great marketing scheme)
0
 
LVL 2

Author Comment

by:NxJNY
ID: 37784401
ok guys so here is the situation; we had webroot installed on all PC's on my domain; however the subscription got expired and the console did not give me the option to un-install; after trying to get the software un-install script to work with you guys my manager suggested i call webroot and explain to them and they helped; simple enough i just had to go to services>webroot Admin Console> enter admin credentials and that worked; from the console i can now uninstall webroot successfully.

Thank you guys both for following through with all your help
0
 
LVL 38

Expert Comment

by:younghv
ID: 37784584
Hard to believe that none of us thought to verify that you had already contacted WebRoot!
LOL (at us).

The right thing to do now is click on the "Accept as Solution" link right beneath your comment described how you solved this and it will start the "auto-close" and save your solution for future readers.

You can't earn any points for answering your own question, but you might help someone with the same problem in the future.
0

Featured Post

Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Let’s list some of the technologies that enable smooth teleworking. 
In our personal lives, we have well-designed consumer apps to delight us and make even the most complex transactions simple. Many enterprise applications, however, are a bit behind the times. For an enterprise app to be successful in today's tech wo…
Video by: Tony
This video teaches viewers how to export a project from Adobe Premiere Pro and the various file types involved.
An overview on how to enroll an hourly employee into the employee database and how to give them access into the clock in terminal.

746 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

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now