Solved

Remote Desktop in Centos

Posted on 2014-11-02
13
368 Views
Last Modified: 2014-11-04
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 :
rdpVNC:
vncSSH:
ssh

Any help ?

Thanks
0
Comment
Question by:jskfan
  • 6
  • 5
  • 2
13 Comments
 
LVL 37

Expert Comment

by:Gerwin Jansen
ID: 40418561
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.
0
 
LVL 23

Expert Comment

by:savone
ID: 40418589
One the destination CentOS machine type the following command to flush iptables:

iptables -F

Then try it again.
0
 

Author Comment

by:jskfan
ID: 40419392
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.
firewall
0
 
LVL 23

Assisted Solution

by:savone
savone earned 334 total points
ID: 40419907
Ahh your using firewalld, which iptables will have no effect on.  

Firewalld is a little more complicated.  Just to test, let's stop firewalld.

Run the following command on the destination machine and test again:

systemctl stop firewalld

After the test, reactivate the firewall.

systemctl start firewalld
0
 
LVL 37

Assisted Solution

by:Gerwin Jansen
Gerwin Jansen earned 166 total points
ID: 40420069
@savone - As I was suggesting already, disable firewall for testing first ;)
0
 
LVL 23

Expert Comment

by:savone
ID: 40420315
@Gerwin Jansen, I agree, I just thought it would be helpful to explain how to do it and why iptables wasn't working.
0
Superior storage. Superior surveillance.

WD Purple drives are built for 24/7, always-on, high-definition security systems. With support for up to 8 hard drives and 32 cameras, WD Purple drives are optimized for surveillance.

 

Author Comment

by:jskfan
ID: 40420886
[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
0
 
LVL 23

Expert Comment

by:savone
ID: 40420892
You need to stop it on the machine you are trying to connect to (192.168.80.139).
0
 

Author Comment

by:jskfan
ID: 40420895
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
0
 
LVL 23

Expert Comment

by:savone
ID: 40420913
Is sshd started on server1?

Post the output of the following command on server:

systemctl status sshd.service
0
 

Author Comment

by:jskfan
ID: 40423034
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 /]#
0
 
LVL 23

Accepted Solution

by:
savone earned 334 total points
ID: 40423104
No that means it is not started.

Start the sshd service, keep the firewall off and try again.  Here is the command to start the service.

systemctl start sshd.service
0
 

Author Closing Comment

by:jskfan
ID: 40423162
systemctl start sshd.service
Thanks it worked for SSH...

I will post a separate question for RDP and VNC connection
0

Featured Post

Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Squid Connection Pools 3 43
AWS RDS 3 64
Debug VNC connection on CentOS7 server 22 64
High Available Storage based on linux 6 67
The purpose of this article is to demonstrate how we can use conditional statements using Python.
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…

929 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now