I am using postgres 7.3 at this moment.

I want to build a database to store all the IP address information.

We have Public IP and internal IP. Internal IP was created from the router. Each customer will have their own VLAN.

Some of the customers are using our firewall. Since we are using NAT, we need to keep track which internal IP map to which public ip.

IP are also related to the servers and network equipment hosted in our datacenter.

I was wondering what is the best design to overcome my requirement.
1. One Public IP can map to one or many Internal IP.
2. One Internal IP can be map to one or many Public IP.
3. Customers can have one/many/none servers or network equipment.
3. If the customer do not host the server or network equipment in our datacenter, then at least the range of IP must be keep track and can be assigned to customer.
4. If the customer has the server and network equipment, then we should know exactly which server or network equipment own the IP address.
5. We need to keep track the NAT mapping of those IP Address.