Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Help with SSH setup.
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
krunk
Guru
Guru


Joined: 27 Jul 2003
Posts: 316

PostPosted: Mon Nov 17, 2003 10:58 pm    Post subject: Help with SSH setup. Reply with quote

I've searched the forums and read the suggested docs, but I still need help in getting ssh working.

Objective: to be able to ssh into my desktop with my laptop remotely.

Accomplished: I have figured out that you have to specify what type of key you want when doing ssh-keygen with the -t option and am able to ssh into my desktop if I'm on my local network and use the local IP. Like ssh 192.168.1.34 or some such.

If I try to do it this way: ssh usre_name@localhost it doesn't work.

I need a simple 1, 2, 3, tutorial on how to get ssh up and running that doesn't assume I know anything about ssh.

I'm behind a linksys router....how do I go about logging in remotely....do I use my isp given IP...how do I designate which computer behind the linksys to log into?

I don't mind reading and a link to a tutorial that is aimed at ssh noobs is fine. I just can't find one.
_________________
G4 1ghz iBook
PowerMac G3 (B&W) [Powered by Gentoo and Gentoo alone :)]

Dual G5
iPod 3rd generation
Back to top
View user's profile Send private message
Zombie[BRAAAINS]
n00b
n00b


Joined: 19 Mar 2003
Posts: 62

PostPosted: Mon Nov 17, 2003 11:24 pm    Post subject: Reply with quote

If you're able to log in locally, you're almost done.

First, you need to set your router to forward TCP port 22 to the IP of the computer that is running sshd.

When you're outside your network, just connect to you external IP, and you should be good to go.

Oh, one last note. If you want to use a username other than the one you're currently logged in on the system you're connecting from, the format is ssh -l USERNAME instead of ssh USERNAME@example.com. scp on the other hand, is scp username@example.com:/file/to/copy (or file/to/copy if you want it to start from your home dir) local.filename
_________________
RAWR! Brains, BRAINS! BRAAAINS! MUST EAT BRAINS!
Back to top
View user's profile Send private message
kwiqsilver
Guru
Guru


Joined: 19 Mar 2003
Posts: 360

PostPosted: Mon Nov 17, 2003 11:39 pm    Post subject: Reply with quote

When you say remotely, do you mean from outside the router?
If so here's your step-by-step:

Set sshd up on the workstation. Make sure it works by connecting the notebook to the router (from the inside), pinging the workstation from the notebook, and ssh-ing in from the notebook.

Log into your router from inside and change its settings so port 22 is forwarded to your workstation's IP. (I'd suggest setting up 2222 as well*, since some ISPs block 22).

Go outside the network and ssh to the IP assigned by your ISP. Your router will forward this to your workstation and you'll get the login prompt.
I'd suggest using keys for this kind of connection. It's more secure.



* If you set up a second port, you'll need to edit /etc/ssh/sshd_config on the workstation and find the line "Listen 22" (or something like that). Uncomment it (if commented) and then add a second "Listen 2222" line. Restart ssh ("/etc/init.d/sshd restart").
Back to top
View user's profile Send private message
krunk
Guru
Guru


Joined: 27 Jul 2003
Posts: 316

PostPosted: Tue Nov 18, 2003 12:12 am    Post subject: Reply with quote

Thanks guys, I think this will get me under way.....I'll test as soon as I leave the house :)


Appreciated.
_________________
G4 1ghz iBook
PowerMac G3 (B&W) [Powered by Gentoo and Gentoo alone :)]

Dual G5
iPod 3rd generation
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum