Removing a software/package completely and reinstalling

Hi. I am new to Linux.

If I remove a software/package using pacman or pamac or yay, the package in question gets removed but leaves residues. Packages leave previous settings/files/configurations. If I reinstall that software/package after removing it, a weird thing happens. The new installation somehow loads settings or configs from previous installation.

Is this behavior normal?
How can I remove software completely with every file/folder/config it created?

1 Like

Yes this is normal behaviour. pacman never touches your home folder and as pamac and yay are more or less just pacman in the background so they won’t too. You have to manually remove those config files. Those files created by the application have no impact on a system after you remove the package so it won’t do any harm. That is just how it works.

3 Likes

There are some guides to help you to purge completely a package (it requires manual intervention for each package):

Links

https://gist.github.com/rumansaleem/083187292632f5a7cbb4beee82fa5031
How to clean Arch Linux | Average Linux User

2 Likes

While uninstalling use -Rns while removing which removes orphan and dependency along with…
and in Dolphin ( the file manager)you can go into root folder and search for the package
you will receive bunch of files and folders affiliated to that particular package
the configuration files generally reside in /etc folder or you can do

man <that particular package> 

to find the configuration files that it has or you can just google the default configuration files to copy and paste the default setting you are in need of
Hope that helps
Make sure to mark the solution box if you found any answer
Have a great day :slight_smile:

2 Likes

In this case it may be possible to not uninstall/reinstall the package, but only to remove the wrong configurations. :wink:
This depends on the package. But you did not name one :man_shrugging:

1 Like

@andreas85
I know you are reply this to @sajidanamifti
but since there are a lot of us here so mentioning makes things a bit easier
Have a great day :slight_smile:

Files in /etc will be purged along with an uninstall.
The point is the users configuration files in places like ~/.config … and it is true this can sometimes be ascertained by using the man page.
As noted in the first reply in this thread, pacman will not touch your $HOME by default, so those files and directories are your responsibility to augment or delete at will.

3 Likes

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.