LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 10-20-2015, 12:14 AM   #1
david1982
LQ Newbie
 
Registered: Oct 2015
Posts: 4

Rep: Reputation: Disabled
Connect four PC'S without Router


Hi Guys, having some trouble in Networking.

Here is my network
PC1 : Window 7/ubuntu, IP: 192.168.8.2 gtwy: 192.168.8.1
PC2 (2 nic cards) using ubuntu : eth0 : 192.168.8.1
eth1: 192.168.9.1 gtwy: 192.168.9.2
PC3 (2 nic cards) using ubuntu : eth0 : 192.168.10.1
eth1: 192.168.9.2 gtwy: 192.168.9.1
PC4: Win/ubuntu, IP: 192.168.10.2 GTWY: 192.168.10.1

My problem is i cannot ping to the host systems i.e pc1 to pc4 and vice versa.

can someone please help me out !!
 
Old 10-20-2015, 12:21 AM   #2
berndbausch
Senior Member
 
Registered: Nov 2013
Location: Tokyo
Distribution: Redhat/Centos, Ubuntu, Raspbian, Fedora
Posts: 1,691

Rep: Reputation: 353Reputation: 353Reputation: 353Reputation: 353
Can you ping otherwise, i.e. pc2 to pc3, pc1 to pc3 etc? Has it ever worked? Have you enabled forwarding on pc2/3? How are routing tables and iptables set up?
I would trace packets along the chain between pc1 and 4 to see where the packets disappear.
 
Old 10-20-2015, 12:30 AM   #3
david1982
LQ Newbie
 
Registered: Oct 2015
Posts: 4

Original Poster
Rep: Reputation: Disabled
Yes, i enabled ip forwarding in pc2 and pc3, and ping each other to both NIC's. And i can ping PC2 & 3 from PC 1 & 4
I turned the firewall on PC1 and 4 off. When i ping PC4 from PC1, it says " Request timed out"
 
Old 10-20-2015, 12:39 AM   #4
berndbausch
Senior Member
 
Registered: Nov 2013
Location: Tokyo
Distribution: Redhat/Centos, Ubuntu, Raspbian, Fedora
Posts: 1,691

Rep: Reputation: 353Reputation: 353Reputation: 353Reputation: 353
Quote:
Originally Posted by david1982 View Post
Yes, i enabled ip forwarding in pc2 and pc3, and ping each other to both NIC's. And i can ping PC2 & 3 from PC 1 & 4
I turned the firewall on PC1 and 4 off. When i ping PC4 from PC1, it says " Request timed out"
Netmask correct everywhere?
Looking at your config again, I wonder how PC3 knows what to do with a packet with destination 10.2.

Other than that, I suggest tcpdump -i eth0 on PC3 and PC4.
 
Old 10-20-2015, 12:43 AM   #5
david1982
LQ Newbie
 
Registered: Oct 2015
Posts: 4

Original Poster
Rep: Reputation: Disabled
Netmask is all correct, I wanna know what I can do on PC3 & 4 to get the network working.
Do i manipuate the iptables or you have any other suggestions for me.
And what does tcpdump -i eth0 do ??
 
Old 10-20-2015, 12:57 AM   #6
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.9, Centos 7.3
Posts: 17,369

Rep: Reputation: 2379Reputation: 2379Reputation: 2379Reputation: 2379Reputation: 2379Reputation: 2379Reputation: 2379Reputation: 2379Reputation: 2379Reputation: 2379Reputation: 2379
You could try it
If you look at the man pages you'll see tcpdump reads the specified device and shows what's coming/going
http://www.rationallyparanoid.com/articles/tcpdump.html
http://www.thegeekstuff.com/2010/08/...mand-examples/
 
Old 10-20-2015, 01:20 AM   #7
david1982
LQ Newbie
 
Registered: Oct 2015
Posts: 4

Original Poster
Rep: Reputation: Disabled
thank you, i'll have a read and see how it goes.
 
Old 10-20-2015, 04:55 AM   #8
cynwulf
Senior Member
 
Registered: Apr 2005
Location: Walsall, England
Posts: 1,941
Blog Entries: 5

Rep: Reputation: 992Reputation: 992Reputation: 992Reputation: 992Reputation: 992Reputation: 992Reputation: 992Reputation: 992
You don't need a router, you just need one of those boxes set up as a router and a basic (and cheap - i.e. 5 - 10) unmanaged switch. Much easier and saves all the hassle.
 
Old 10-20-2015, 05:00 AM   #9
berndbausch
Senior Member
 
Registered: Nov 2013
Location: Tokyo
Distribution: Redhat/Centos, Ubuntu, Raspbian, Fedora
Posts: 1,691

Rep: Reputation: 353Reputation: 353Reputation: 353Reputation: 353
Quote:
Originally Posted by david1982 View Post
thank you, i'll have a read and see how it goes.
To limit data volume, use filters e.g. tcpdump -i eth0 icmp or tcpdump -i eth0 host <ip address>. Otherwise you will get a lot of traffic to analyze
 
  


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
Can't connect server to router via ethernet; router is not projecting signal. oldpilsbury Linux - Newbie 5 04-01-2013 01:56 PM
How do I set up a laptop as a router to connect wirelessly to my ADSL router hairysocks Linux - Networking 12 12-20-2009 06:51 AM
Intel 4965 AGN - can't connect to wireless 802.11b router, can connect to 11g siodine Linux - Wireless Networking 3 12-01-2007 07:36 AM
How do I connect to router behind router... glenn69 Linux - Networking 1 04-25-2007 11:34 AM
howto connect router to router? kvasarnomad Linux - Networking 4 09-04-2005 09:14 PM


All times are GMT -5. The time now is 10:24 PM.

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