0

After I removed an app with purge, I cannot use sudo or apt-get any more and get this error.

-bash: /usr/bin/sudo: No such file or directory

Do you have any suggestions?

version: Ubuntu 16.04

Zanna
  • 70,465

1 Answers1

2

Be careful when you remove system's software. I can think 2 solutions:

  1. Use the command pkexec apt install sudo in order to install sudo.
  2. Reboot and choose "Advanced Options" in the grub menu in order to boot in a root shell and run apt install sudo command in order to install sudo.

After you install sudo look at the apt logs in order to see what other packages which depended on sudo package got removed and install them again.