Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I am interested in hosting multiple services on a single host. Each service (which will all be HTTP for the sake of example) currently uses a private IPv4 address and different ports (e.g. there might be a service at 10.0.0.1:8000, :8001, :8002...) This works just fine, except that it's somewhat inconvenient that I cannot use the well known port.

I'm imagining it would be cool to give each service a unique site-local address and the default port. Then I could dynamically add DNS entries, and suddenly have useful / memorable names (service-1.mydomain.com:80, service-2.mydomain.com:80, ...).

Unfortunately, I'm not able to find much information on how to add additional automatically configured IPv6 addresses. The manpage for the Linux (CentOS 6) ip tool requires you to specify the address you'd like to add. I'd prefer it to just be automatically selected such as with stateless auto configuration. Is this possible? If not I suppose I can try to implement RFC4319 myself, but this sounds very much like the type of thing that should already exist.

share|improve this question
    
You forgot the OS. –  Ignacio Vazquez-Abrams Jul 16 '12 at 21:49
add comment

2 Answers

Two comments:

  1. Site-Local addresses have been deprecated for quite some time. You should use Unique-Local-Addresses (ULA, RFC 4193). You can generate those yourself, but the SixXS site has a nice generator.

  2. If you want to run services on IP addresses that means that you will at least have to put those addresses in configurations when configuring the services, put those addresses in DNS, etc. If you then let the system auto-configure the addresses on the system you run the risk that the addresses change unexpectedly.

    I have seen this happen. A server had a hardware failure so some hardware was replaced, including the network adapters. Because auto-configuration depends on the MAC addresses of the network adapters the IPv6 addresses suddenly changed as well. The sysadmin didn't realise that he had to reconfigure the services, update the DNS records, etc. So the services got broken...

So: the best thing to do is to use ULA addresses and configure them statically on the servers.

share|improve this answer
    
Nice point on the hardware failure. –  ekaj Jul 17 '12 at 1:26
add comment

There's an online tool that will generate the Global ID and Subnet ID for you already. Just pop the result into your /etc/radvd.conf and you're ready to go.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.