LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   SSH /telnet setup (https://www.linuxquestions.org/questions/linux-newbie-8/ssh-telnet-setup-100611/)

zchoyt 10-05-2003 06:22 PM

SSH /telnet setup
 
Hello all. I am fairly new to redhad. I am trying to setup ssh so I can connect. When I try to connect I get "connection was rejected which I am not surprised about because it probably needs setting up but I don't know how. The only book I have tells me nothing. Can you help?

I have my IP and hostname setup already.
Any help or links would be great.
Thanks

damien 10-05-2003 07:00 PM

You need to give us a bit more info first. Are you trying to connect out from the RedHat box to another machine, or are you trying to connect in to your RedHat machine from outside?

SSH isn't too hard to set up. Post back and describe what you want to do.

Damien

guardian653 10-05-2003 08:54 PM

What version of RedHat are you running? If you happen to be running the latest (version 9) logged in as root you can open up redhat-config-services (need to be in X-windows, graphical screen aka Gnome :) or KDE or somethin)

Look down the list and check if you enabled the ssh or telnetd service. If their not enabled check either one (depending on your needs, ssh is more secure than telnet so I wouldn't enable (telnet) if I were you) and click the Start button. Then I would select the File>Save so that don't have to mess with it again.

If they are both checked and running it might be network problems. Say if your behind a router (running like Linksys) you'll need to open up a port. Now that is beyond this post so you'll have to check your manuals or ask your sysadmin to open up the port for ya. This can also be the case if your running some sort of firewall.

Telnet port is 25
SSH port is 22

If you need anymore help feel free to ask!

zchoyt 10-05-2003 11:31 PM

Hey thanks for the information guys. I apprecitated the help. I am running Red Hat 7.1. (because it is the same as school). I am trying to connect to the redhat box from other windows boxes. I do know how to set up my router with port forwarding, and also I have setup redhat with a static IP. The problem is that ssh is not enabled on my redhat box, and my book is kinka lacking in that department. So what I need is to know what files to edit to enabled ssh. I would be glad to tell you more if this is not enough info.
thx
zchoyt

joseph 10-06-2003 02:22 AM

as far as i know RH 7.1 already anable the SSH when you installed the SSH packages. Cos i used this distribution too.

td_miles 10-06-2003 03:00 AM

please post output from commands:


chkconfig --list sshd

ps ax | grep ssh

praveenk 10-06-2003 03:40 AM

In RedHat telnet service runs as part of xinetd service and not as a separate service. For enabling telnet, you have to edit the configuration of telnet. This is found in the file

/etc/xinetd/telnet

Replace the line 'disable=yes' by 'disable=no'

Then restart xinetd by typing...

/etc/init.d/xinetd restart

Before that in your security settings, you should allow the telnet port connections as said in the previous suggestion.

BTW, why do you run telnet as well as ssh? My suggestion is that when you are planning to have SSH, stick with that since telnet is unencrypted transport, packets can be easily sniffed to get the usernames and passwords in your box.

zchoyt 10-06-2003 05:04 PM

Thanks for the help fellas. I am wanting to learn how to enable both just for learning experience. I will go with SSh though. I will try those commands when I am at home (I could try them now if ssh was already setup!)

damien 10-06-2003 11:14 PM

I second Praveenk's comments. Go with ssh, but by all means mess around with telnet, rsh and so on, though I suggest you keep your rsh "practice" very short-lived! It won't hurt to be familiar with the various remote shells.

Check these websites out if you haven't already:

www.ssh.com

www.openssh.com

Enjoy.

Damien

PS That's one of the things I love about this forum. We have half the planet represented here.

zchoyt 10-07-2003 09:24 AM

Thanks again fellas.
td_miles, you asked me for output from some commands:
chkconfig --list sshd
command not found (no matter what folder)
ps ax | grep ssh
1677 pts/0 S 0:00 grep ssh


Also I tried what praveenk said, and it appears that I have no etc/xinetd directory. I do have a xinetd.d dir but nothing about telnet in there.

I am really interested in starting ssh first. I can't connect from another PC on my lan (connection actively refused). If someone could show or link me to ssh setup and firewall config/setup that would probobly be great.

Thanks for all the help so far. I am an appricieative noob.

zchoyt

td_miles 10-07-2003 07:11 PM

For the people suggesting xinetd, in RH 7.x SSH was a seperate service and not one started by xinetd.

If "chkconfig --list sshd" doesn't show any output, then it would appear that you don't have the sshd server installed.

Try running the command "rpm -qa | grep ssh" to see if any of the SSH packages are installed. If not, then you will need to install the ssh RPM packages from CD (if in doubt, install all packages that start with "openssh").


All times are GMT -5. The time now is 09:25 AM.