I'm installing and configuring the ssh in CentOs 8 with a virtual box machine.
I installed both libraries with following command:
sudo yum install openssh-server openssh-clients
Then I started the service with:
sudo systemctl enable sshd
sudo systemctl start sshd
sudo systemctl status sshd
And it's running normally.
When I try to edit the sshd_config file with the command:
sudo gedit /etc/ssh/sshd_config
I get the following error:
No protocol specified
Unable to init server: Could not connect: Connection refused
(gedit:5680): Gtk-WARNING **: 21:59:00.071: cannot open display: :0
Could someone help me, please?
sudo
command. Tryxhost +127.0.0.1
to allow any user from the local host to access the display, then try the command again. – Fubar May 5 '20 at 1:29sudo gedit /etc/sudoers
I got the same error. – Henrique Branco May 5 '20 at 1:32xhost +127.0.0.1
with no success. – Henrique Branco May 5 '20 at 1:34xhost local:
instead – Fubar May 5 '20 at 1:40