LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 09-07-2013, 09:23 AM   #1
dfclin073
LQ Newbie
 
Registered: Dec 2011
Posts: 10

Rep: Reputation: Disabled
Troubles setting up Linux router


All,
I am trying to setup my CentOS 6.4 as a router between a 2 local networks . This is a virtual machine Im using VMware Workstation. Here are my settings.
[root@Centos-FW ~]# ifconfig
eth0 Link encap:Ethernet HWaddr 00:0C:29:43:xx:xx
inet addr:192.168.1.92 Bcast:192.168.1.95 Mask:255.255.255.240
inet6 addr: fe80::20c:29ff:fe43:2cc6/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:46 errors:0 dropped:0 overruns:0 frame:0
TX packets:42 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:13854 (13.5 KiB) TX bytes:3076 (3.0 KiB)

eth1 Link encap:Ethernet HWaddr 00:0C:29:43:xx:xx
inet addr:192.168.0.15 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::20c:29ff:fe43:2cd0/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:7 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 b) TX bytes:553 (553.0 b)

[root@Centos-FW ~]# route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
192.168.1.80 0.0.0.0 255.255.255.240 U 1 0 0 eth0
192.168.0.0 0.0.0.0 255.255.255.0 U 1 0 0 eth1
0.0.0.0 192.168.1.81 0.0.0.0 UG 0 0 0 eth0

[root@Centos-FW ~]# iptables -L
Chain INPUT (policy ACCEPT)
target prot opt source destination

Chain FORWARD (policy ACCEPT)
target prot opt source destination

Chain OUTPUT (policy ACCEPT)
target prot opt source destination

eth0 is bridged to the host, eth1 is on a LAN segment and is the default gateway for the 192.168.0.0/24 network. All hosts on this network are a part of the same LAN segment. ip forwarding is set to 1.
I am don't using any dns or host names only IP addresses.
I can ping both interfaces from their respective networks but not through the box.
I have looked around on forums and youtube, all resources Ive used indicate this setup should work, any help would be appreciated
thanks
Dan

Last edited by dfclin073; 09-07-2013 at 09:33 AM.
 
Old 09-07-2013, 05:26 PM   #2
dfclin073
LQ Newbie
 
Registered: Dec 2011
Posts: 10

Original Poster
Rep: Reputation: Disabled
Fixed it, I think it was SELinux.
 
  


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
Having troubles to use linux as a router Mirihayami Linux - Networking 1 07-29-2011 02:54 PM
Setting up Linux box as IPv6 router to replace Netgear WNR1000 wireless router samcan Linux - Networking 1 06-19-2011 05:30 AM
setting up linux router rcmonroig Linux - Networking 2 01-27-2010 12:56 AM
Setting Up My Router In Linux! NeedsHelp Linux - Networking 2 08-28-2002 10:56 PM
Setting up Linux as a router planew Linux - Networking 1 02-07-2002 12:07 PM

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

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