# FreeBSD network problem



## strCoder (May 4, 2010)

Hi guys.

I have a strange problem. I have a 'global ip' package from my ISP, it gives me 4 ip-addresses, where 1 of the ip adresses is available for a server, and the rest is for the router and broadcast.

The ISP rouder has been configured as a modem, no firewall, no NAT, no nothing, just one big open hole in the wall

ISP router / modem ip: XX.XX.236.73 / 255.255.255.252
Available ip: XX.XX.236.74 / 255.255.255.252

Problem:

When I put a router between the ISP modem and the server, and nat an address to the server 192.168.0.200, and route the ip XX.XX.236.74 to 192.168.0.200, everything is fine.

But I need to set the global-ip up directly on the network interface, so I cant use NAT.

When I remove my router, and connect the server directly to the dsl-modem, then it doesen't work.

The setup is:

rc.conf

```
ifconfig_re0="inet XX.Xx.236.74 netmask 255.255.255.252"
defaultrouter="XX.XX.236.73"
hostname="web01.mydomainishere.com"
```

FYI:
There is no blocking of ports in the ISP router / modem, all is open, I can get it to work when I use a NAT address, so: No problems with the router! Everyone asks this, and it's just waisting time.

Question:

Can anyone show me how I set up my FreeBSD 7.4 to have a global-ip set up directly on my network interface?

I have tried tons of different configurations, and forums for the past 7 days, please crack this one guys


----------



## SirDice (May 4, 2010)

You need to setup the NAT on your ISP router. You cannot have the global IP on your server. There's no need for it either.

The only way to get your global IP on your server would be to remove the ISP router and connect the server directly on your connection.


----------



## strCoder (May 4, 2010)

*DirectAdmin requirements*

Sounds logic.

The reason that I try to do this is because of the requirements of the system I'm trying to install. Below is the requirements from DirectAdmin.

--------
Your server IP must be an external IP address. Local IP addresses (192.168.x.x or 10.0.x.x) will not work. The IP in your network device must be the same IP in your license file, as well as the public IP that connects to our system to download the license and binaries. This means that LANs will not work. More info on IP requirements
--------

--------
In order for DirectAdmin to be able to run on your system, 3 things must be true:

1) The licensed IP must exists on the box. Type /sbin/ifconfig, and you must see the licensed IP in the output.

2) The licensed IP must function and be able to be bound to, eg:

wget --bind-address=1.2.3.4 http://www.directadmin.com/index.html

3) the IP that connects to our server must be the licensed IP.


If you only have a LAN with 192.168.x.x IPs on it, they would not satisfy rule number 1 and 2.
--------


----------



## strCoder (May 4, 2010)

Maybe I wrote it wrong btw. The router/modem XX.XX.236.73 gives one ip-address XX.XX.236.74.


----------



## SirDice (May 4, 2010)

strCoder said:
			
		

> Maybe I wrote it wrong btw. The router/modem XX.XX.236.73 gives one ip-address XX.XX.236.74.


Which is the other side of your point-to-point connection?

http://en.wikipedia.org/wiki/Network_topology#Point-to-point

Or do you get a real /28? If that's the case you need to configure your ISP router to forward that other address to the inside.


----------



## strCoder (May 4, 2010)

The ISP Router forwards one ip address 'XX.XX.236.74' to the inside, and when I set the ip in the tcp/ip configuration of my laptop (XP) and starts a webserver on it, it works fine, I can see the webserver from the internet.

But when I set up the ip on the FreeBSD, I can't see it from the internet (unless i use a router between the isp modem and the server, using nat)


----------



## SirDice (May 4, 2010)

It should just work. There's no reason why you should need NAT. All you need to do is configure the fbsd box exactly the same as you did the windows box.


----------

