LinuxQuestions.org
Help answer threads with 0 replies.
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 06-14-2005, 12:12 AM   #1
frankjp
LQ Newbie
 
Registered: Jun 2005
Location: Around the world
Distribution: Fedora Core 2 3 4 and Freebsd 5
Posts: 10

Rep: Reputation: 0
Red face Connect Failed: not route to host


Hi, I am Frankjp

I am new is the area of routing using Linux and I need someone to tell me what is wrong with my constructed network (OS fedora core 3 with the most recent kernel).
My network is design as follow:

192.168.9.0 network 192.168.7.0 network
PC1<================>PC_Router<==================>PC2
||
( Internet 192.168.0.0 network)
PC1 IP 192.168.9.2 netmask 255.255.255.0 gw 192.168.9.1
PC1 IP 192.168.7.2 netmask 255.255.255.0 gw 192.168.7.1
PC_router
NIC2 IP 192.168.9.1
NIC1 IP 192.168.7.1
NIC0 IP dhcp (192.168.0.8)

I can ping all PC of my subnet and from everywhere. But I cannot ping outside the network. Beside that when I run a client socket program on PC_router and the server of one of PC1 and PC2 , I obtain Connect failed: no route host. However running the Socket server on PC_router and client on PC1 or PC2 d't cause any error. PC1 and PC2 cannot also connect to Internet while PC_router can. I read some answer talking about routing but it could change anything
Could anyone help me?

Thank !

Frank

I also set this
echo 1 > /proc/sys/net/ipv4/ip_forward
and turned in /etc/sysconfig/network
FORWARD_IPV4 =true
other settings are below.

In PC_router

#ip show neigh
shows both PC1 and PC2
#route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.7.0 0.0.0.0 255.255.255.0 U 0 0 0 eth1
192.168.0.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
192.168.9.0 0.0.0.0 255.255.255.0 U 0 0 0 eth2
169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth2
0.0.0.0 192.168.0.1 0.0.0.0 UG 0 0 0 eth0

#ip route show table main
192.168.7.0/24 dev eth1 proto kernel scope link src 192.168.7.1
192.168.0.0/24 dev eth0 proto kernel scope link src 192.168.0.8
192.168.9.0/24 dev eth2 proto kernel scope link src 192.168.9.1
169.254.0.0/16 dev eth2 scope link
default via 192.168.0.1 dev eth0

#ifconfig
eth0 Link encap:Ethernet HWaddr 00:118:6A:36:1A
inet addr:192.168.0.8 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::211:d8ff:fe6a:361a/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:2510 errors:0 dropped:0 overruns:0 frame:0
TX packets:2181 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:1113199 (1.0 MiB) TX bytes:416573 (406.8 KiB)
Interrupt:177 Base address:0xd800

eth1 Link encap:Ethernet HWaddr 00:0E:0C:6E:A5:79
inet addr:192.168.7.1 Bcast:192.168.7.255 Mask:255.255.255.0
inet6 addr: fe80::20e:cff:fe6e:a579/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:245 errors:0 dropped:0 overruns:0 frame:0
TX packets:712 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:36967 (36.1 KiB) TX bytes:115574 (112.8 KiB)
Base address:0xdf00 Memory:fe5e0000-fe600000

eth2 Link encap:Ethernet HWaddr 00:0E:0C:6E:A7:F9
inet addr:192.168.9.1 Bcast:192.168.9.255 Mask:255.255.255.0
inet6 addr: fe80::20e:cff:fe6e:a7f9/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:297 errors:0 dropped:0 overruns:0 frame:0
TX packets:291 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:43383 (42.3 KiB) TX bytes:34885 (34.0 KiB)
Base address:0xde80 Memory:fe580000-fe5a0000

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:4876 errors:0 dropped:0 overruns:0 frame:0
TX packets:4876 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:6805928 (6.4 MiB) TX bytes:6805928 (6.4 MiB)

Last edited by frankjp; 06-14-2005 at 12:15 AM.
 
Old 06-14-2005, 02:11 AM   #2
ilnli
Member
 
Registered: Jul 2004
Location: Pakistan
Distribution: Slackware 10.0, SUSE 9.1, RH 7, 7.3, 8, 9, FC2
Posts: 413

Rep: Reputation: 32
have you enabled NAT on your PC_router?
 
Old 06-15-2005, 06:38 AM   #3
frankjp
LQ Newbie
 
Registered: Jun 2005
Location: Around the world
Distribution: Fedora Core 2 3 4 and Freebsd 5
Posts: 10

Original Poster
Rep: Reputation: 0
Dear ilnli,

Thank you for your answer. I am really new in this system.
Could you please tell me how to?
All what I did is to set the routes and gateways.

Frank
 
Old 06-15-2005, 11:20 AM   #4
javaroast
Member
 
Registered: Apr 2005
Posts: 130

Rep: Reputation: 18
Connect Failed

What are the routes on the client PC's? Each client PC will need a route to the Subnet of the other set of client pc's.
 
Old 06-15-2005, 11:09 PM   #5
frankjp
LQ Newbie
 
Registered: Jun 2005
Location: Around the world
Distribution: Fedora Core 2 3 4 and Freebsd 5
Posts: 10

Original Poster
Rep: Reputation: 0
Hello javaroast,

Thank you for your answer, I think that I set averything in the client PC. I think that the main PC (PC_router) is the one to redirect the income connection to other subnet.
This is the #route -n for both PC client
PC: 192.168.9.2
===========================================================================

Interface List

0x1 ........................... MS TCP Loopback interface
0x2 ...00 0c f1 b9 93 f1 ...... Intel(R) PRO/100 VE Network Connection -
===========================================================================

===========================================================================

Active Routes:

Network Destination Netmask Gateway Interface Metric

0.0.0.0 0.0.0.0 192.168.9.1 192.168.9.2 20

127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1

192.168.9.0 255.255.255.0 192.168.9.2 192.168.9.2 20

192.168.9.2 255.255.255.255 127.0.0.1 127.0.0.1 20

192.168.9.255 255.255.255.255 192.168.9.2 192.168.9.2 20

224.0.0.0 240.0.0.0 192.168.9.2 192.168.9.2 20

255.255.255.255 255.255.255.255 192.168.9.2 192.168.9.2 1

Default Gateway: 192.168.9.1

===========================================================================

Persistent Routes:

None

PC 192.168.7.2
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.7.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth0
0.0.0.0 192.168.7.1 0.0.0.0 UG 0 0 0 eth0

Do I need something else to set up? Please let me know.

Thank you

Frank
 
  


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
ftp: connect: No route to host dwarf007 Linux - Networking 15 03-22-2013 02:55 PM
Resolving <www.some remote host>.... failed: Host not found. koodoo Linux - Newbie 2 06-27-2005 08:48 AM
ftp: connect: No route to host agki Linux - Networking 2 03-09-2005 04:25 PM
online_update failed - ERROR(Media:connection failed)[Connect failed] rover Suse/Novell 8 02-22-2005 07:57 AM
ftp connect: no route to host dominant Linux - Networking 4 09-07-2004 04:29 AM


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

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration