BOINC / boinc

Open-source software for volunteer computing and grid computing.
https://boinc.berkeley.edu
GNU Lesser General Public License v3.0
2.02k stars 446 forks source link

Use Windows (un)installer to fully uninstall WCG/BOINC #675

Open romw opened 9 years ago

romw commented 9 years ago

Reported by Ageless on 23 Mar 38539966 15:33 UTC Is it possible that the Windows installer/uninstaller asks to remove all traces of BOINC? Now when uninstalling BOINC through Add/Remove programs, the BOINC directory and entries in the registry stay in place.

What I would like is the option that some programs (games mostly) use, which ask you after you uninstalled the program if you want to delete the registry entries and 'saved files' as well. Of course this option should only be used when BOINC is uninstalled from the Add/Remove Programs program, not when upgrading it.

It gives that extra bit of finesse and service to the program

Migrated-From: http://boinc.berkeley.edu/trac/ticket/698

romw commented 9 years ago

Commented by romw on 9 May 39159109 21:46 UTC Punting setup bugs to 6.10.

romw commented 9 years ago

Commented by Ageless on 26 Jan 39946058 23:06 UTC I have written a batch file that does the following:

  1. Uninstall the BOINC user accounts and groups. [Use the Windows 2003 Server Tool NTRights.exe to delete the User Rights Assignments.[br]
  2. Kills boinctray.exe if it is still running.[Read the BOINC Install directory and Data directory paths from the registry and subsequently delete both directories and all files and sub-directories included.[br]
  3. Finds and deletes the BOINC_Master directory or directories in the Documents and Settings directory (works on foreign language Windows as well, where the "Documents and Settings" directory is set in that language)[[br]]
  4. Delete all BOINC related keys from the registry.

It will assume that the user uninstalled BOINC through Add/Remove Programs first. The computer needs to be rebooted at the end to finalize cleaning.

romw commented 9 years ago

Commented by romw on 25 May 40859068 13:46 UTC Setup bugs are being punted to a future release. This work item should be completed with the new open source installer.

romw commented 9 years ago

Commented by Ageless on 16 Oct 40964527 21:20 UTC Changing priority to Critical after the first Sony pre-installed complaint came in.

It's time the BOINC uninstaller came with the options of:

  1. Leave the data directory, user accounts and registry settings alone. or
  2. Remove any and all entries that were made by the software. Program and data directory, registry entries, Boinc limited user accounts, etc.

At least make these happen for the Sony installed World Community Grid installer.

Ageless93 commented 7 years ago

David, what do you think? Is this an option in InstallShield?

davidpanderson commented 7 years ago

Don't know.

Ageless93 commented 7 years ago

http://helpnet.flexerasoftware.com/installshield23helplib/helplibrary/RemoveFileTableSprt.htm shows how to do that (with InstallShield 2016)

We probably just want to test such an option, see how well it is warned that this will get rid of all of BOINC's files and folders. Or that there's extra warning text that can be added.

Ageless93 commented 7 years ago

Scratch that. Richard had a good idea: offer a separate removal tool. Something like the script I had a couple of years ago that would remove all traces of BOINC from drives and registry. I'll look around if I still have that.

Ageless93 commented 7 years ago

I still do. It runs from a batch file. This is just an idea. I think it misses one or two registry entries.

@ECHO OFF
Set CD=%CD%
Set SCRIPTDIR=%~dp0
Rem Removing of groups and accounts
ECHO Removing Groups and Accounts
net localgroup boinc_admins boinc_master /delete
net localgroup boinc_projects boinc_project /delete
net localgroup boinc_admins /delete
net localgroup boinc_users /delete
net localgroup boinc_projects /delete

Rem removing User Rights Assignments
ECHO Removing User Rights Assignments
%CD%:\ntrights -r SeNetworkLogonRight -u boinc_master
%CD%:\ntrights -r SeNetworkLogonRight -u boinc_project
%CD%:\ntrights -r SeDenyInteractiveLogonRight -u boinc_project
%CD%:\ntrights -r SeDenyInteractiveLogonRight -u boinc_master
%CD%:\ntrights -r SeServiceLogonRight -u boinc_master
%CD%:\ntrights -r SeServiceLogonRight -u boinc_project
%CD%:\ntrights -r SeDenyNetworkLogonRight -u boinc_project
%CD%:\ntrights -r SeDebugPrivilege -u 
%CD%:\ntrights -r SeIncreaseQuotaPrivilege -u boinc_users
%CD%:\ntrights -r SeIncreaseQuotaPrivilege -u boinc_admins
%CD%:\ntrights -r SeAssignPrimaryTokenPrivilege -u boinc_users
%CD%:\ntrights -r SeAssignPrimaryTokenPrivilege -u boinc_admins

Rem killing Boinctray.exe if that's still running
ECHO Killing Boinctray.exe if that's still running, else throw a message about that. 
tskill boinctray /A

Rem Removing left-over directories
ECHO Removing Left-Over Directories
FOR /F "tokens=2* delims=    " %%A IN ('REG QUERY "HKEY_LOCAL_MACHINE\SOFTWARE\Space Sciences Laboratory, U.C. Berkeley\BOINC Setup" /v INSTALLDIR') DO SET ID=%%B
RMDIR /S /Q %ID%

FOR /F "tokens=2* delims=    " %%A IN ('REG QUERY "HKEY_LOCAL_MACHINE\SOFTWARE\Space Sciences Laboratory, U.C. Berkeley\BOINC Setup" /v DATADIR') DO SET DD=%%B
RMDIR /S /Q %DD%

cd %homepath%
cd..
RMDIR /S /Q boinc_maste*
chdir /d %SCRIPTDIR%

Rem removing registry entries
ECHO Removing Registry Entries 
regedit /s cleaner.reg

:DONE
ECHO All done. Now all you need to do is remove this temporary directory and all files therein.

ECHO Thank you for using BOINC. We're sorry to see you go.