LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-12-2006, 12:42 PM   #1
robingazi
Member
 
Registered: Jul 2006
Location: Bangladesh
Distribution: Ubuntu
Posts: 93

Rep: Reputation: 15
connection between two platforms


Hi
I have debian Etch (kernels 2.6.17-1 em64t smp from sid/unstable) installed in my home pc. I have an ip that starts with 172. i have a DNS which start with 203 and a default gateway starting with 172. I dont have access to the DNS servers.

On the other hand at work i have windows XP. My work has a ip that starts with 192 and the DNS starts with 202 and the default gateway starts with 192.

Both the pc's have 255.255.255.0 as subnet mask.

Now to my question. How do I connect to my home pc using putty or any other client you might suggest? What are the software i need to install on my debian and how do i configure that software and putty?

Thank you in advance.
 
Old 08-13-2006, 05:01 AM   #2
ichrispa
Member
 
Registered: Mar 2005
Location: Dresden, Germany
Distribution: OpenSuse 11.2/3, Debian 5.0 , Debian 1.3.1, OpenBSD
Posts: 277

Rep: Reputation: 32
you will need a ssh-server installed and running on your home pc. I suggest openssh. From putty, you will need to enter your home-pcs complete IP. If your are using DSL with a modem/router/switch, that might be a problem, because the internal home-network will automaically be using NAT (Name Adress Translation), meaning you can only adress your router, not the pc's behind that router. How to solve this problem depends on the capabilities of your routers hardware.
 
Old 08-13-2006, 09:16 AM   #3
lotusjps46
Member
 
Registered: Apr 2003
Location: Dallas
Distribution: Vector Linux, Suse 10.1
Posts: 186

Rep: Reputation: 30
I believe Debian installs the SSH server daemon by default. Look up how to start the SSH server.

Set up your router to forwared port 22 to the Debian box. I do not know what kind of router you have, but somewhere the interface should have a section for Virtual Server, or Port Forarding. In it you put the IP address of the Debian machine on your local LAN. That is, use the IP address you get on the Debian machine using "ipconfig" in a terminal as root. You will probably have to reboot the router to have it take effect. When it has rebooted, copy down the IP address of the router on the internet (the WAN address). You can confirm that you have the right address by opening a browser and typing in "www.whatismyip.com". That will give you your Internet IP.

On the Windows box, open PuTTy and put in the IP address you copied down at home in the Host Name box, and select "SSH". Give this connection a name, and hit Save, then Open. It should ask for a name (your log on name at the Debian box, NOT root) and password (what you use on the Debian box). Look here for more information about PuTTy:

http://www.jfitz.com/tips/putty_config.html

It should connect. If it gives you a warning about not knowing who you are just accept it and go on. If it does not connect you will have to configure the SSH server to let you use a password. I have to go look that one up.

Good luck

C

Last edited by lotusjps46; 08-13-2006 at 09:19 AM.
 
Old 08-13-2006, 12:29 PM   #4
JimBass
Senior Member
 
Registered: Oct 2003
Location: New York City
Distribution: Debian Sid 2.6.32
Posts: 2,100

Rep: Reputation: 49
Minor nitpick, but it isn't "ipconfig" in the *nix world, it is "ifconfig". Also, just to find out the IP info you already have, you don't need to be root. Any user on a debian (and most other distros I assume) will tell you your IP address by asking for it correctly. The way to do that is /sbin/ifconfig

Code:
jim@worklap:~$ /sbin/ifconfig
eth0      Link encap:Ethernet  HWaddr 00:D0:59:D7:5B:4B
          inet addr:192.168.68.102  Bcast:192.168.68.255  Mask:255.255.255.0
          inet6 addr: fe80::2d0:59ff:fed7:4b3b/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:490599 errors:0 dropped:0 overruns:0 frame:0
          TX packets:420875 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:297050939 (283.2 MiB)  TX bytes:240680551 (229.5 MiB)
Peace, JimBass
 
Old 08-13-2006, 02:40 PM   #5
robingazi
Member
 
Registered: Jul 2006
Location: Bangladesh
Distribution: Ubuntu
Posts: 93

Original Poster
Rep: Reputation: 15
This is what i get when i do ifconfig.

Quote:
eth0 Link encap:Ethernet HWaddr 00:133:C9:67:6F
inet addr:172.16.5.75 Bcast:172.16.5.255 Mask:255.255.255.0
inet6 addr: fe80::213:d3ff:fec9:676f/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:9955 errors:0 dropped:0 overruns:0 frame:0
TX packets:3286 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:4454318 (4.2 MiB) TX bytes:389287 (380.1 KiB)
Interrupt:201 Base address:0x4800

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:121 errors:0 dropped:0 overruns:0 frame:0
TX packets:121 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:8140 (7.9 KiB) TX bytes:8140 (7.9 TiB)
The problem is I do not have a router. I get internet connection via lan. The isp [like most isps in Bangladesh] gave me an eathernet card and a cable. They provide me with internet via lan. I do have a D-link switch installed though since I have another pc at home. The problem is I do not have access to any routers of my ISP or the server my ISP uses.

Last edited by robingazi; 08-13-2006 at 02:51 PM.
 
Old 08-13-2006, 04:19 PM   #6
lotusjps46
Member
 
Registered: Apr 2003
Location: Dallas
Distribution: Vector Linux, Suse 10.1
Posts: 186

Rep: Reputation: 30
OOps, sorry about the "ipconfig" thing. I have been working on XP boxes and it has damaged my brain.

Not sure how you can connect to ssh if you are behind your ISP's router and cannot open port 22. You can try going to www.whatismyip.com to get the WAN IP of the ISP router, but unless they have port 22 open you will not be able to connect. You could contact the ISP and see if they would direct port 22 to your IP on the LAN (172.16.5.75) but failing that I am not sure what you can do. It might be possible to set the SSH server to work on port 80, then set PuTTy to use port 80 also (since port 80 is open by default on the router for web traffic) but I have no idea what the implications of that are. You can change the port for the ssh daemon in /etc/ssh/ssh-config.

Good luck.

C
 
Old 08-13-2006, 04:24 PM   #7
JimBass
Senior Member
 
Registered: Oct 2003
Location: New York City
Distribution: Debian Sid 2.6.32
Posts: 2,100

Rep: Reputation: 49
172.16.5 is a private IP. If that is the address that is you are getting from your ISP, then there is no way to connect to your box from outside their network unless they are willing to forward requests to your machine.

Peace,
JimBass
 
Old 08-13-2006, 08:17 PM   #8
robingazi
Member
 
Registered: Jul 2006
Location: Bangladesh
Distribution: Ubuntu
Posts: 93

Original Poster
Rep: Reputation: 15
This is what i get when i go to that webpage.
Quote:
Your IP Is
203.112.202.253
Are there any configureations I need to do before i call my ISP for port forwarding? BTW i have installed openssh-server and ssh. I dont know how to configure them. I tried dpkg-reconfigure openssh-server but that I think only restarts the programme.

This is my process list. I believe the second last one is openssh-server.

Quote:
1 ? Ss 0:01 init [2]
2 ? S 0:00 [migration/0]
3 ? SN 0:00 [ksoftirqd/0]
4 ? S 0:00 [watchdog/0]
5 ? S 0:00 [migration/1]
6 ? SN 0:00 [ksoftirqd/1]
7 ? S 0:00 [watchdog/1]
8 ? S< 0:00 [events/0]
9 ? S< 0:00 [events/1]
10 ? S< 0:00 [khelper]
11 ? S< 0:00 [kthread]
14 ? S< 0:00 [kblockd/0]
15 ? S< 0:00 [kblockd/1]
16 ? S< 0:00 [kacpid]
115 ? S< 0:00 [khubd]
117 ? S< 0:00 [kseriod]
162 ? S 0:00 [pdflush]
163 ? S 0:00 [pdflush]
164 ? S 0:00 [kswapd0]
165 ? S< 0:00 [aio/0]
166 ? S< 0:00 [aio/1]
1662 ? S< 0:00 [ata/0]
1663 ? S< 0:00 [ata/1]
1685 ? S< 0:00 [scsi_eh_0]
1686 ? S< 0:00 [scsi_eh_1]
2040 ? S< 0:00 [kjournald]
2211 ? S<s 0:00 udevd --daemon
3685 ? S< 0:00 [kpsmoused]
3688 ? S 0:00 [saa7134[0]]
3917 ? S< 0:00 [hda_codec]
5083 ? Ss 0:00 /sbin/syslogd
5089 ? Ss 0:00 /sbin/klogd -x
5154 ? Ss 0:00 /usr/sbin/acpid -c /etc/acpi/events -s /var/run/acpid
5165 ? S 0:00 hald-runner
5186 ? S 0:00 /usr/lib/hal/hald-addon-storage
5247 ? Ss 0:00 /usr/sbin/inetd
5317 ? Ss 0:00 /usr/sbin/cron
5332 ? Ss 0:00 /usr/sbin/gdm
5337 ? S 0:00 /usr/sbin/gdm
5338 tty7 Ss+ 0:22 /usr/X11R6/bin/X :0 -dpi 96 -audit 0 -auth /var/lib/g
5349 tty1 Ss+ 0:00 /sbin/getty 38400 tty1
5350 tty2 Ss+ 0:00 /sbin/getty 38400 tty2
5351 tty3 Ss+ 0:00 /sbin/getty 38400 tty3
5352 tty4 Ss+ 0:00 /sbin/getty 38400 tty4
5353 tty5 Ss+ 0:00 /sbin/getty 38400 tty5
5354 tty6 Ss+ 0:00 /sbin/getty 38400 tty6
6167 pts/0 S 0:00 su
6168 pts/0 S 0:00 bash
6225 ? Ss 0:00 /usr/sbin/sshd
6226 pts/0 R+ 0:00 ps x

Last edited by robingazi; 08-13-2006 at 08:23 PM.
 
Old 08-14-2006, 10:24 PM   #9
lotusjps46
Member
 
Registered: Apr 2003
Location: Dallas
Distribution: Vector Linux, Suse 10.1
Posts: 186

Rep: Reputation: 30
Well, someone has an ssh server running at that IP address. In a shell, this is what I got when I tried it:

chuck@tbird:~> ssh 203.112.202.253
The authenticity of host '203.112.202.253 (203.112.202.253)' can't be established.
RSA key fingerprint is b8:cc:bd:62:17:eb:12:ff:3d:63:61:1a:06:9a:f3:f3.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '203.112.202.253' (RSA) to the list of known hosts.
chuck@203.112.202.253's password:
Permission denied, please try again.
chuck@203.112.202.253's password:


I do not know your password, or what your log-on name is, but it looks like you can start using ssh. Use

ssh yournamehere@203.112.202.253

Good luck.

C
 
Old 08-15-2006, 12:47 AM   #10
robingazi
Member
 
Registered: Jul 2006
Location: Bangladesh
Distribution: Ubuntu
Posts: 93

Original Poster
Rep: Reputation: 15
I had already tried that. It appears 203.112.202.253 is not my machine since it doesnt accept my username or passwd. Its probably a server of my isp. not too sure though.
 
Old 08-15-2006, 08:02 AM   #11
lotusjps46
Member
 
Registered: Apr 2003
Location: Dallas
Distribution: Vector Linux, Suse 10.1
Posts: 186

Rep: Reputation: 30
There is a way to have ssh listen to another port on your computer (not 22; see /etc/ssh/ssh-config). If you can get the ISP to point that port to your computer at your IP (not 203.112.202.253) then it would work, but you have to get them to do this. I do not know of any other way to resolve this.

Good luck.

C
 
Old 08-15-2006, 02:47 PM   #12
danga1993
LQ Newbie
 
Registered: Oct 2005
Location: In a house......
Distribution: Debian
Posts: 21

Rep: Reputation: 15
I seems higly unlikely that your isp can stretch a cat5 cable all the way from you to them. There must be some mechanism where it is converted to another system.

But I guess it's possible, I hear new stuff every day.

Cheers
 
Old 08-15-2006, 08:27 PM   #13
robingazi
Member
 
Registered: Jul 2006
Location: Bangladesh
Distribution: Ubuntu
Posts: 93

Original Poster
Rep: Reputation: 15
I believe they use UTP cables and there are switches installed every 100 metres or so. The provide internet almost to all homes in my neighbourhood and some other surrounding neighbourhoods.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Multiboot *nix platforms.... Basslord1124 Linux - General 9 12-10-2005 07:50 AM
Multiple Platforms insideout Linux - Hardware 1 10-24-2005 05:38 PM
C character sizes on different platforms.. f0rmula Programming 4 03-21-2005 04:18 PM
Platforms? nr5 Linux - Software 3 12-28-2004 06:43 PM
Different platforms? linuxpyro Linux - Hardware 1 04-09-2004 03:57 PM


All times are GMT -5. The time now is 02:34 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration