-   Linux - Networking (
-   -   ssh hostname (

d-x-4 04-30-2010 03:31 PM

ssh hostname
I've setup openssh in my ubuntu.

I've also enabled it by

sudo /etc/init.d/ssh start
How can I learn what's my hostname so the others can login to my pc?

rweaver 04-30-2010 03:48 PM

Unless you have dns setup for your host name they still wont be able to, nor will they be able to if you're behind a nat'd connection (private address ranges unless you forward the ports.

The easiest thing to give is an ipaddress which you can get by typing:


ifconfig | grep "inet addr" | awk '{print $2}' | cut -f2 -d: | grep -v
Again if it starts with 172.16-31.x.x, 192.168.x.x, or 10.x.x.x you need your external address and need to setup port forwarding on your firewall/router.

d-x-4 04-30-2010 03:59 PM

That revealed my ip address (I think).

Can you tell me step by step how the others can login like

ssh username@pcname.cs.etc
and not like

I need a hostname to do that. Can I get one? How?

rweaver 04-30-2010 04:08 PM

You could use a dynamic dns service ( they have instructions for setup and updating records.

All times are GMT -5. The time now is 12:07 AM.