0

I have gone through the Dist Usage Utility in Ubuntu and I deleted some folders here and there in my Desktop and also in my Downloads. These included some software packages I had installed earlier.......

I am not very sure whether all the installation points related to these softwares have been cleaned after I have deleted the folders in the Desktop.

Windows ofcourse we have an uninstall utility. But since I dint know a similar way in Ubuntu I just deleted the folders. Is here any command that I can run now to fully scan and remove softwares and packages that have not been properly installed or UNINSTALLED???

Shabirmean
  • 123
  • 6

2 Answers2

2

From what you write, I think you did not actually deinstall or break any installed packages.
in case you did indeed, sudo debsums -c will help you to find the changes - see What is the apt equivalent to "rpm -V" (Verify installed packages).


But it sounds like you may have installed programs by building it from source, maybe under your home directory?

If so, there may be an uninstall command provided, like make uninstall.

If you installed something with make install or similar, but there is no make uninstall available, you need to find out which files were installed, and into which directories they were installed.
In simple cases this can be seen from the Makefile. But if that does not help, you can just run make install again - only to see the log output of which files are installed to where.


For future use, take a look at checkinstall - it can track what was installed from source, and cleanly uninstall it.

Volker Siegel
  • 13,065
  • 5
  • 49
  • 65
  • Thanks Very Much for the reply. However since I have deleted the folder I have no Makefile... What can I do now??? – Shabirmean Aug 17 '14 at 10:41
  • Normally it's not hard to find at least most of what was installed using locate - can you give an example? Of course, you can download the sources again, so you can do make install again. – Volker Siegel Aug 17 '14 at 10:47
  • I had downloaded SU2 (a Computational Fluid Dynamics Software package).. It was around 2 GB with test cases and stuff... It was in my desktop and I went through the installation process by running ./configure, make and make install... and then to remove it I just deleted the folder... Now I am not sure whether it got fully removed!!!! – Shabirmean Aug 17 '14 at 13:44
  • What is the url of the package? What does command -v su2 or so say? – Volker Siegel Aug 17 '14 at 14:30
  • URL: http://su2.stanford.edu/download.html the command doesn't return anything!!! – Shabirmean Aug 17 '14 at 14:46
  • Ok, so the source is here: https://github.com/su2code/SU2 ; From looking at the Makefle.in, would expect there are just a few dirs containing all the files. Is there a `/usr/lib/su2' or similar? – Volker Siegel Aug 17 '14 at 14:54
  • If /usr/lib/su2 exists, run locate -r '.*/su2$' – Volker Siegel Aug 17 '14 at 14:57
  • returns nothing again – Shabirmean Aug 17 '14 at 17:18
  • I do not know whether that programm or package is called su2 actually, it's more a guess. If you have any other idea, just try. Did the command that you installed have the name su2? – Volker Siegel Aug 17 '14 at 17:22
  • Hmm, you did run locate -r '.*/su2$', so /usr/lib/su2 exists, is that right? – Volker Siegel Aug 17 '14 at 17:23
  • From the INSTALL file, it should be in /usr/local/ - and it may be named SU2 or similar instead. Look at ls -l /usr/local/ – Volker Siegel Aug 17 '14 at 17:29
  • /usr/local/bin has SU2, SU2_CFD, SU2_DDC and many other SU2_* – Shabirmean Aug 17 '14 at 18:21
  • locate -r '.*/su2$' returns nothing – Shabirmean Aug 17 '14 at 18:29
  • Ah, good! Now I hope locate -r '.*/SU2$' and locate -r '.*/SU2_[^/]+' will find all related directories, and which you can delete then. Could find things like man pages too, which are not in their separate directories. To find related fies, you could check files last changed in the same minute or so - use ls -ltr – Volker Siegel Aug 17 '14 at 18:33
  • thanks. So for other software also Ill have t do the same??? N besides this wont work if the installed files have some other names – Shabirmean Aug 17 '14 at 18:43
  • Usually it's much easier, the name is obvious normally. This was a complicated case - so you learned quite a lot on how to sort it out manually. I would mostly use the "make install" related methods instead. – Volker Siegel Aug 17 '14 at 18:46
  • By the way, you could accept the answer with the check mark, and maybe upvote it. – Volker Siegel Aug 17 '14 at 18:47
0

I have two options for you. Either Graphical or command-line Graphical Way: Install Synaptic manager and cleanup your System. to install it run

 sudo apt-get install synaptic 

or you could try this command from terminal

 sudo apt-get update && sudo apt-get -f install

to update and attempt to fix your packages. But i recommend you install synaptic and you can find more on this.. askubuntu post

Zuko
  • 1,267
  • 11
  • 12
  • I don't specifically know what are the softwares that are corrupted or incorrectly deleted by me. I am looking for some command or utility that can auto scan my files and remove unnecessary hanging files in the disk... Can I do it with synaptic?? I already have it installed and it seems like the Add/Remove Programs in control panel....

    Also the terminal command gives: 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

    – Shabirmean Aug 17 '14 at 08:44
  • Yes you can do that with synaptic. have you tried the apt-get autoremove or autoclean commands as well..? – Zuko Aug 18 '14 at 16:02
  • Yes I have!!! But I dont know whether it worked – Shabirmean Aug 19 '14 at 16:54