Link to home
Start Free TrialLog in
Avatar of jskfan
jskfanFlag for Cyprus

asked on

Remote Desktop in Centos

I am trying to connect from Centos server to another Centos Server using RDP, VNC,SSH but it does not seem to work as expected.
I can ping from /to both servers


RDP :
User generated imageVNC:
User generated imageSSH:
User generated image

Any help ?

Thanks
Avatar of Gerwin Jansen
Gerwin Jansen
Flag of Netherlands image

Try disabling the firewall on the destination CentOS server (for testing). Can you connect now? If so you need to change firewall settings on the destination CentOS server.
One the destination CentOS machine type the following command to flush iptables:

iptables -F

Then try it again.
Avatar of jskfan

ASKER

I have run this command but did not help.
iptables -F

I posted the Firewall Gui page, it does not look like ssh is blocked.
User generated image
SOLUTION
Avatar of Steven Vona
Steven Vona
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
@Gerwin Jansen, I agree, I just thought it would be helpful to explain how to do it and why iptables wasn't working.
Avatar of jskfan

ASKER

[root@localhost liveuser]#  systemctl stop firewalld
[root@localhost liveuser]# ssh root@192.168.80.139
ssh: connect to host 192.168.80.139 port 22: Connection refused
[root@localhost liveuser]#


AS you can see , I stopped Firewall but still cannot remote using ssh
You need to stop it on the machine you are trying to connect to (192.168.80.139).
Avatar of jskfan

ASKER

To explain what I have done:
I ran the below command in server1
[root@localhost liveuser]#  systemctl stop firewalld

I went to server2 and ran:
ssh root@192.168.80.139

I got the following message:
ssh: connect to host 192.168.80.139 port 22: Connection refused
Is sshd started on server1?

Post the output of the following command on server:

systemctl status sshd.service
Avatar of jskfan

ASKER

I wonder if it is not installed

[root@localhost /]# systemctl status sshd.service
sshd.service - OpenSSH server daemon
   Loaded: loaded (/usr/lib/systemd/system/sshd.service; disabled)
   Active: inactive (dead)

[root@localhost /]#
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of jskfan

ASKER

systemctl start sshd.service
Thanks it worked for SSH...

I will post a separate question for RDP and VNC connection