This is a static archive of the old Zorin Forum.

The information below may be outdated. Visit the new Zorin Forum here ›

If you have registered on the old forum, you will need to create an account on the new forum.

(SOLVED) Auto remove packages via Terminal

Uzi

Tue Jul 02, 2013 6:26:20 am

While installing drivers for my Scanner via Terminal, it said

The following packages were automatically installed and are no longer required:
gir1.2-timezonemap-1.0 linux-headers-3.2.0-37 gir1.2-json-1.0
linux-headers-3.2.0-37-generic language-pack-kde-en kde-l10n-engb
language-pack-kde-en-base gir1.2-xkl-1.0
Use 'apt-get autoremove' to remove them.


So I ran apt-get autoremove

Terminal then said

E: Could not open lock file /var/lib/dpkg/lock - open (13: Permission denied)
E: Unable to lock the administration directory (/var/lib/dpkg/), are you root?


What do I need to do?

Cheers

Uzi

madvinegar

Tue Jul 02, 2013 7:04:07 am

try:

sudo apt-get autoremove

Uzi

Tue Jul 02, 2013 7:53:09 am

madvinegar wrote:try:

sudo apt-get autoremove


Yup - that did it 8-)

Mark as Solved

Cheers

Uzi.

Wolfman

Tue Jul 02, 2013 8:01:52 am

Hi Uzi,

whenever you do anything with the terminal related to "apt", you must put "sudo" in front of the command as it requires you to be root when doing such things.

Here is a how-to but it doesn't show the "sudo" part of the command, you just add it in front of the command you are using:

https://help.ubuntu.com/community/AptGet/Howto

Example:

Code:
apt-get dist-upgrade


won't work but the following will:

Code:
sudo apt-get dist-upgrade


I will mark this as solved.

Regards Wolfman :D