Solved

Urgent : SSH Connection to Linux Server

Posted on 2004-04-09
8
285 Views
Last Modified: 2013-11-13

           Hi.

           I have just install Linux in a new pc and I use this pc as a development server.


           Then, I use any pc and open SSH in order to connect to my development server. I find that I am not able to connect to my development server.

            Do you have idea on what is going on? Do I need to do any setting in my Linux server? What is the setting? This is urgent and hope you can reply soon. Thank you.


Regards,
     Jocelyn
0
Comment
Question by:jocelynyip
8 Comments
 
LVL 17

Accepted Solution

by:
owensleftfoot earned 20 total points
ID: 10790121
What distro of linux are you using? Are you sure sshd is running on the development server? "service sshd status" (without the quotes) will tell you. If it isnt "service sshd start" will start it. "chconfig sshd on" will ensures it starts at boot time.
0
 
LVL 9

Assisted Solution

by:Alf666
Alf666 earned 20 total points
ID: 10790123
1) Check that ssh is installed
rpm -q -i ssh
or
rpm -q -i openssh

2) Check that sshd is running

ps awxu | grep sshd

3) Check that you can connect with a non-root user

4) If only root can not connect, change the following in your sshd_config :

PermitRootLogin yes

0
 
LVL 1

Assisted Solution

by:fyerk
fyerk earned 20 total points
ID: 10790846
In the event you're not using an RPM-based system, you can check if SSH is installed with:

whereis sshd
or
whereis sshd

Also, it's generally not good practice to ssh as root. You should ssh as a normal user and then use sudo or su to elevate your privileges as necessary.

Which errors are you getting when you try to connect to your server?
0
Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

 
LVL 12

Assisted Solution

by:mburdick
mburdick earned 20 total points
ID: 10790990
netstat -nap | grep ":22 " will tell you if anything is listening on the default ssh port (which is 22). If there's nothing listening, you need to be sure it's installed. You didn't specify which distribution you're using, so I can't give you a definite way to check, but    rpm -qa |grep ssh   will work on redhat, suse, and others. It's no good for distributions like slackware.

If it's installed but not running, you need to start it. This can often be done with    /etc/init.d/sshd start

If it's installed and running, but you don't get a prompt when you launch your SSH client, you need to check for firewall rules (which install by default on most systems now).   iptables -L -n    will usually show you what rules are loaded. If iptables comes back with information, paste the output back here so we can help you set the rules (or verify that they're already ok).
0
 
LVL 1

Assisted Solution

by:doushanes
doushanes earned 20 total points
ID: 10794741
Tip: not a good idea to have ssh allow root login if this machine is on the internet.  
If you need root. Login as user and su to root form there. Just my .02

doushanes
0
 
LVL 14

Expert Comment

by:isaman07
ID: 10797516
This depends on too many things, like the others pointed out, which distro of linux u r using? is openssh installed and running? and what are the machines that you are trying to connect from to your linux box?If this is one of the latest distros of linux and you are trying to connect from a windows xp or win2k machine, you must modify the sshd.conf file by turning on the PasswordAuthentication to yes.
Hope this will help.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

This article will explain how to establish a SSH connection to Ubuntu through the firewall and using a different port other then 22. I have set up a Ubuntu virtual machine in Virtualbox and I am running a Windows 7 workstation. From the Ubuntu vi…
It’s 2016. Password authentication should be dead — or at least close to dying. But, unfortunately, it has not traversed Quagga stage yet. Using password authentication is like laundering hotel guest linens with a washboard — it’s Passé.
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…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:

759 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

19 Experts available now in Live!

Get 1:1 Help Now