linux commands

Linux: sudo: apt-get: command not found

This tutorial guides you on how to resolve linux error sudo: apt-get: command not found while running sudo apt-get commands in the terminal.

Linux: sudo apt-get: command not found

When I was trying sudo apt-get update command in the linux terminal, I got the following error message.

sudo: apt-get: command not found

And the same message I see whatever apt-get command that I try in the linux terminal.

The above problem you may be facing because of interrupted installation. The installation would have been corrupted due to power outage or bad drive or could be any other reason like incorrect file/folder permissions settings that you might have changed while you playground.

I would recommend you to do a fresh install of Linux OS again from a live CD or from USB.

Note, it is also possible that the apt-get package is missed in the installation. If you want to install apt-get package then follow the below section.

Installing apt-get

If the apt-get package is missed to get installed, its strange. Then you may need to install it manually by following the below steps.

1: First, search the apt version that you wanted to install from here: Download apt. For example, apt_2.0.5_amd64.deb.

2: Download the apt.deb version.

3: Finally, install the deb package.

sudo dpkg -i apt_2.0.5_amd64.deb

That’s all. Now you can start using sudo apt-get commands (sudo apt-get update) or install any other packages. And you should not see the error: sudo: apt-get: command not found any more.

Hope it helped 🙂


Inline Feedbacks
View all comments