LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 04-20-2006, 11:51 PM   #1
vishivishi
LQ Newbie
 
Registered: Apr 2006
Location: New York
Distribution: Mandriva 2006
Posts: 10

Rep: Reputation: 0
network setup: connect to another computer through the router


HI there,

I have a general, even conceptual network setup question.

my apartment has 3 computers, C1, C2, C3.

C1 is XP station that connects to the internet thru the router
C2 is a linux machine that has 2 NICs. Thru one it connects to the internet thru the same router and thru the other one it connects to C3, another XP machine, ie C2 is a linux server and internet gateway for C3.

Now, is it possible for me to access C1 from my C3? If yes, how it should be set up?


Thanks,
Vishi
 
Old 04-21-2006, 03:09 AM   #2
TigerOC
Senior Member
 
Registered: Jan 2003
Location: Devon, UK
Distribution: Debian Etc/kernel 2.6.18-4K7
Posts: 2,380

Rep: Reputation: 49
Yes. All you have to do is use the ip address of C1 or if you have dhcp you need to use name resolution.
 
Old 04-21-2006, 03:10 AM   #3
Emmanuel_uk
Senior Member
 
Registered: Nov 2004
Distribution: Mandriva mostly, vector 5.1, tried many.Suse gone from HD because bad Novell/Zinblows agreement
Posts: 1,606

Rep: Reputation: 53
net -> router -> C1_XP <router> <--> eth0 C2_linux eth1 <---> C3_XP

>>access C1 from my C3
I suppose you want to share files only

Conceptually:
samba on C2 to see C1
nfs to then share files from C2 to C3

That is my guess (but little knowledge on this)

Must be more than 1 solution (and yes dnat as well)

I assume you do not want / cannot change cabling, NIC, router,
if not please let people know.

Internet connection sharing is another story (see post that
came at same time as mine, I suppose)

Last edited by Emmanuel_uk; 04-21-2006 at 03:13 AM.
 
Old 04-21-2006, 03:11 AM   #4
TigerOC
Senior Member
 
Registered: Jan 2003
Location: Devon, UK
Distribution: Debian Etc/kernel 2.6.18-4K7
Posts: 2,380

Rep: Reputation: 49
Duplicate posting - damn login problems!

Last edited by TigerOC; 04-21-2006 at 03:12 AM.
 
Old 04-21-2006, 09:47 AM   #5
elfy
LQ Newbie
 
Registered: Mar 2006
Location: Sevastopol, Ukraine
Distribution: CRUX/From Scratch
Posts: 12

Rep: Reputation: 0
The most preffered way(Ethernet bridge):
Step one - IP's
choose 3 ip adresses for your c1 c2 c3 network. You must only use adresses of this range not to conflict with internet:
10.0.0.1 to 10.255.255.254
192.168.0.1 to 192.168.255.254
172.12.0.1 to 172.17.255.254 (I'm likely lying about first 2 digits - see "LAN IP's" in some manual)
You may but this in dhcp but I recommend using static IP's for this case
Step two - bridging
An ethernet bridge is somewhat an ARP/Ethernet router wich makes your PC act like a network hub. When you bridge two ethernet cards together C1 and C3 will think they are connected directly.
To bridge you must compile an "ethernet bridge" kernel module or buildin this feature into kernel.
Then you must bring up the bridge via ifconfing(see man ifconfig for details) or via some graphical configuratir if you have one, but ifconfig is versalite.
Step three - having fun
You can also make some other configurations: from 2 subnets to NATing C3 but it's stupid when having only 3 computers so I wont write 'em until you ask me

Last edited by elfy; 04-21-2006 at 10:01 AM.
 
Old 04-22-2006, 02:42 PM   #6
scheidel21
Senior Member
 
Registered: Feb 2003
Location: CT
Distribution: Debian 6+, CentOS 5+
Posts: 1,323

Rep: Reputation: 100Reputation: 100
it should be real simple to access C1 from C3 share what you want to access on c1 then open ie on c3 and access it by typing \\ipaddressofc1\sharename so if the ip address was 192.168.0.2 on c1 and you shared a folder called music access it with the address \\192.168.0.1\music\ if you are running nat on the linux box it shouldnt make a difference C1 will just think the the linux box is requesting it, and if there is no nat it should work just as well.

Alex
 
Old 04-23-2006, 07:05 AM   #7
vishivishi
LQ Newbie
 
Registered: Apr 2006
Location: New York
Distribution: Mandriva 2006
Posts: 10

Original Poster
Rep: Reputation: 0
Thanks guys, reading your replies, I came to realize that what I really want to do is to have access from both C3 and C1 to the shared folder on the C2 (linux machine). I have already set it up for C3 to access C2 (working fine) but could not make it work for C1 --> C2 (can't figure out what i am doing wrong).

I use

router's IP 192.168.1.1
C3 10.0.0.253 (XP goes on Linux)
C2 192.168.1.105 to connect to the router, 10.0.0.1 as a gateway for C3
C1 (the one that directly connects to the router) That's where I have problems now: I am not sure what to use as IP and gateway.

Thanks
Vishi

Last edited by vishivishi; 04-23-2006 at 07:21 AM.
 
  


Reply



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
IS that computer connect to network so hard zhangweiwei Linux - Networking 9 07-27-2005 12:44 PM
How to setup computer a switch/router? jimdaworm Linux - Networking 11 02-27-2005 11:45 PM
Need help with how to setup a 4-5 computer wireless network... SonoranFun Linux - Wireless Networking 4 01-18-2005 08:58 PM
Home network setup with network firewall/router Gates1026 Linux - Networking 4 01-17-2005 08:26 PM
HELP! My Computer can't connect to my network Scorlibrian Linux - Wireless Networking 2 01-08-2005 05:09 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 01:09 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
Open Source Consulting | Domain Registration