Page 1 of 1

what happened to my apt command?

Posted: Wed Jul 22, 2020 4:09 pm
by hamilc
I am trying to do an update so I enter at the $ prompt, "sudo -get update" and I get the following
"unable to resolve host Rpi3" Rpi3 is my pi name.

So what gives?

Re: what happened to my apt command?

Posted: Wed Jul 22, 2020 4:18 pm
by DougieLawson
You have a syntax error.

The commands are
sudo apt update
sudo apt dist-upgrade -y


Copy'n'paste my blue text.

Re: what happened to my apt command?

Posted: Wed Jul 22, 2020 4:26 pm
by fruitoftheloom
hamilc wrote:
Wed Jul 22, 2020 4:09 pm
I am trying to do an update so I enter at the $ prompt, "sudo -get update" and I get the following
"unable to resolve host Rpi3" Rpi3 is my pi name.

So what gives?

https://www.raspberrypi.org/documentati ... are/apt.md

Re: what happened to my apt command?

Posted: Wed Jul 22, 2020 4:43 pm
by hippy
hamilc wrote:
Wed Jul 22, 2020 4:09 pm
I am trying to do an update so I enter at the $ prompt, "sudo -get update" and I get the following
"unable to resolve host Rpi3" Rpi3 is my pi name.
Assuming "apt -get update" is merely a typo; I've seen the same "unable to resolve host" error when I haven't set the hostname in all the right places.

Use 'raspi-config' to set the hostname, reboot, and it will hopefully fix itself, "sudo apt-get update" should then work.

Re: what happened to my apt command?

Posted: Wed Jul 22, 2020 4:53 pm
by B.Goode
hamilc wrote:
Wed Jul 22, 2020 4:09 pm
I am trying to do an update so I enter at the $ prompt, "sudo -get update" and I get the following
"unable to resolve host Rpi3" Rpi3 is my pi name.

So what gives?


Don't know. With my recent version of RasPiOS Buster I get this -

Code: Select all

pi@raspberrypi:~ $ sudo -get update
sudo: unknown group: et
sudo: unable to initialize policy plugin

Re: what happened to my apt command?

Posted: Wed Jul 22, 2020 5:03 pm
by HvdW
It's either
sudo apt update
or
sudo apt-get update

As mentioned before
sudo -get update
is a non existing command