The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Special Forums > IP Networking
.
google unix.com



IP Networking Learn TCP/IP, Internet Protocol, Routing, Routers, Network protocols in this UNIX and Linux forum.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Assigning a static IP to NICs sunfan SUN Solaris 10 01-03-2008 01:28 AM
How many NICS do I have? bigapple100 SUN Solaris 2 10-29-2007 09:29 PM
changeing the MAC addresses on NICS BG_JrAdmin SUN Solaris 1 11-17-2006 05:35 AM
Merge NICs bong02 AIX 1 07-24-2006 08:35 AM
Mac addresses of NICs (why are they the same) hcclnoodles UNIX for Dummies Questions & Answers 1 05-28-2002 10:38 AM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 10-24-2006
ednix ednix is offline
Registered User
  
 

Join Date: Oct 2006
Posts: 7
FreeBSD and two NICs

FreeBSD 4.8, Apache 1.3.27 - two NICs, one with a real-world IP plugged into a switch outside the PIX firewall, the other with a private IP plugged into a switch inside the PIX firewall. Apache listens on both IPs. my domain is mydomain.org.

so in /etc/rc.conf i have something like this (these real-world IPs are not really real, just a spammer's IP borrowed for illustration):

#rc.conf
#
defaultrouter "68.208.213.123"
ifconfig_de0="inet 68.208.213.123 netmask 255.255.255.0"
ifconfig_de1="inet 10.10.10.45 netmask 255.255.0.0"

my ISP runs nameservers which point the outside world to mydomain.org at the real-world IP. i run a local nameserver which points users inside our firewall to the private IP. works great....on my LAN. outside my LAN (still behind the PIX) the users can't see/ping the private address.

question: is there a way to specify a different default gateway for each of the NICs? i did not see anything which would allow that in the man pages for ifconfig(8) or rc.conf(5).
  #2 (permalink)  
Old 10-27-2006
stdout stdout is offline
Registered User
  
 

Join Date: Feb 2006
Posts: 103
hello,

which side of the bsd router your LAN cant see?
RTO or unreachable?

try netstat -rn to see the route for the BSD

cheers
  #3 (permalink)  
Old 10-27-2006
ednix ednix is offline
Registered User
  
 

Join Date: Oct 2006
Posts: 7
It's not my LAN that can't see something. It's the LANs connected to me that can't see the BSD machine at the private address. I'm connected to these other LANs via older Cisco routers talking over T1s. Our ISP's Cisco guy said that the problem was probably the default gateway for the BSD machine at the private address. In rc.conf, sure enough, I don't have a default gateway for the machine's "inside-the-firewall" NIC. I only have a default gateway for the "outside-the-firewall" NIC. How do I set two default gateways, one for each address class I'm using?
  #4 (permalink)  
Old 10-27-2006
stdout stdout is offline
Registered User
  
 

Join Date: Feb 2006
Posts: 103
yes - i know that not your internal LAN cant see something,
but your intranet LAN cant see it right

post the route with netstat -rn,
yes - you can create as many route as you want with NIC(s)

cheers
  #5 (permalink)  
Old 10-30-2006
ednix ednix is offline
Registered User
  
 

Join Date: Oct 2006
Posts: 7
here's the netstat output. the default routers (ciscos) are in bold.
in my original post i said the gateway for the outside was 68.208.213.123
it should have been 68.208.213.1

Routing tables

Internet:
Destination Gateway Flags Refs Use Netif Expire
default 68.208.213.1 UGSc 36 27262 de0
10.10/16 link#2 UC 4 0 de1
10.10.10.1 00:e0:b0:63:da:e0 UHLW 0 2 de1 1196
10.10.10.18 00:04:75:83:e7:8c UHLW 0 1 de1 1046
10.10.10.19 00:c0:f0:32:02:40 UHLW 0 10 de1 831
10.10.10.45 00:c0:f0:31:55:b0 UHLW 0 54194 lo0
127.0.0.1 127.0.0.1 UH 0 2546 lo0
68.208.0/16 link#1 UC 13 0 de0
68.208.213.1 00:00:0c:75:dc:91 UHLW 37 0 de0 907
68.208.213.19 00:04:27:46:43:ea UHLW 0 2074 de0 68
68.208.213.152 00:04:27:46:43:ea UHLW 0 332 de0
68.208.213.221 00:04:27:46:43:ea UHLW 2 222693 de0 729
68.208.214.8 00:00:0c:75:dc:91 UHLW 4 667918 de0 713
68.208.214.16 00:00:0c:75:dc:91 UHLW 0 7 de0 625
68.208.214.51 00:00:0c:75:dc:91 UHLW 0 7 de0 792
68.208.214.54 00:00:0c:75:dc:91 UHLW 0 7 de0 61
68.208.214.57 00:00:0c:75:dc:91 UHLW 0 7 de0 653
68.208.214.60 00:00:0c:75:dc:91 UHLW 0 140 de0 912
68.208.214.116 00:00:0c:75:dc:91 UHLW 0 411 de0 387
68.208.214.182 00:00:0c:75:dc:91 UHLW 0 146 de0
68.208.214.254 00:00:0c:75:dc:91 UHLW 0 508 de0 1090
  #6 (permalink)  
Old 10-30-2006
stdout stdout is offline
Registered User
  
 

Join Date: Feb 2006
Posts: 103
hello,

and which LAN cant see your router?
have you try with pings/traceroute?
and what i the output? RTo or net unreachable?

cheers
  #7 (permalink)  
Old 10-31-2006
ednix ednix is offline
Registered User
  
 

Join Date: Oct 2006
Posts: 7
there's several networks connected to mine that can't see the FreeBSD server. for example, 10.1.1.0, 10.7.1.0, and others. They RTo on trying to ping the 10.10.10.45 address, the address on the second NIC in the FreeBSD machine. on my network (10.10.10.0) i can ping the IP and in fact pull up the webpage from Apache - no problem.

it's as if the router (10.10.10.1) isn't picking up the address as being on its network. would that be the case if the NIC doesn't have a default gateway?
Sponsored Links
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 09:16 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language translation by Google.
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0