Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Static ipv4 and dynamic ipv6 address config: how to do it?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
nephros
Advocate
Advocate


Joined: 07 Feb 2003
Posts: 2139
Location: Graz, Austria (Europe - no kangaroos.)

PostPosted: Mon Apr 30, 2012 8:59 am    Post subject: Static ipv4 and dynamic ipv6 address config: how to do it? Reply with quote

Hi,

I am running a IP dual-stack LAN, set up like this:

Code:


   {cable uplink} --- [ OpenWRT router] ---- LAN --- [ box1 ]
                                   |
                                   ----------WLAN--- [laptop1]


Now, the machines do the following:

  • router: runs DHCP server, 6to4 tunnel, radvd
  • laptop1: connects via WLAN, get addresses via DHCP and radvd everything working OK
  • box1: connected via LAN, has a fixed ipv4 address and should also get a radvd-assigned ipv6 address but it doesn't.


I have been trying to figure out to get box1 to keep its static IPv4 connection, and get IPv6 address and routing information from radvd like dynamic clients.

Everything works on box1 if I set a static ip6 address (prefix + local prefix +MAC address) and route in conf.d/net but I don't want to do that because later I want to use privacy extensions which vary the MAC part.
_________________
Please put [SOLVED] in your topic if you are a moron.


Last edited by nephros on Mon Apr 30, 2012 9:01 am; edited 1 time in total
Back to top
View user's profile Send private message
truc
Advocate
Advocate


Joined: 25 Jul 2005
Posts: 3199

PostPosted: Mon Apr 30, 2012 12:51 pm    Post subject: Reply with quote

Are you hidding some informations about box1 by any chance? I ask, because, enabling IPv6 forwarding on box1 will usually disable IPv6 auto conf. That may be you problem?


Other than that, why not just keep everything dynamic on the client side and just configure the DHCPd on the openWRT router to always assign(and reserve) the same IP address for box1?
_________________
The End of the Internet!
Back to top
View user's profile Send private message
nephros
Advocate
Advocate


Joined: 07 Feb 2003
Posts: 2139
Location: Graz, Austria (Europe - no kangaroos.)

PostPosted: Mon Apr 30, 2012 1:20 pm    Post subject: Reply with quote

truc wrote:
Are you hidding some informations about box1 by any chance? I ask, because, enabling IPv6 forwarding on box1 will usually disable IPv6 auto conf. That may be you problem?


Good catch, yes, box1 has a rather more complex setup (connected to two other networks, and openvpn server), and I have ipv6 forwarding enabled.

I will experiment with ipv6 forwarding disabled, didn't know that. Is there a way to have both?
_________________
Please put [SOLVED] in your topic if you are a moron.
Back to top
View user's profile Send private message
truc
Advocate
Advocate


Joined: 25 Jul 2005
Posts: 3199

PostPosted: Mon Apr 30, 2012 4:51 pm    Post subject: Reply with quote

nephros wrote:
Good catch, yes, box1 has a rather more complex setup (connected to two other networks, and openvpn server), and I have ipv6 forwarding enabled.

I will experiment with ipv6 forwarding disabled, didn't know that. Is there a way to have both?


IIRC there is. I don't remember which of the sysctl key you have to play with but I do remember you have to set a boolean key to 2 (that's right, not 0, not 1, but 2 :lol: )

I have not tested it though, so keep us informed ;)
_________________
The End of the Internet!
Back to top
View user's profile Send private message
nephros
Advocate
Advocate


Joined: 07 Feb 2003
Posts: 2139
Location: Graz, Austria (Europe - no kangaroos.)

PostPosted: Mon Apr 30, 2012 7:48 pm    Post subject: Reply with quote

truc wrote:
nephros wrote:
Good catch, yes, box1 has a rather more complex setup (connected to two other networks, and openvpn server), and I have ipv6 forwarding enabled.

I will experiment with ipv6 forwarding disabled, didn't know that. Is there a way to have both?


IIRC there is. I don't remember which of the sysctl key you have to play with but I do remember you have to set a boolean key to 2 (that's right, not 0, not 1, but 2 :lol: )

I have not tested it though, so keep us informed ;)


Right, it's the 'accept_ra' sysctl.

I learned from here, and it's documented at http://www.kernel.org/doc/Documentation/networking/ip-sysctl.txt (or locally file:///usr/src/linux/Documentation/networking/ip-sysctl.txt)

This will require some more work for me to get it right for all the interfaces in my use case (esp routing is a mess on "box1") but thanks a lot for your help and pointing me in the right direction.

[PS: What is the right amount of slashes for the file: URI scheme? Three, four, what? Is it at all portable?]
[PPS: I have been absent from these forums for years now, seriously considering spending more time here again after this very positive experience]
_________________
Please put [SOLVED] in your topic if you are a moron.
Back to top
View user's profile Send private message
truc
Advocate
Advocate


Joined: 25 Jul 2005
Posts: 3199

PostPosted: Tue May 01, 2012 2:40 pm    Post subject: Reply with quote

nephros wrote:
This will require some more work for me to get it right for all the interfaces in my use case (esp routing is a mess on "box1") but thanks a lot for your help and pointing me in the right direction.
no problem, I was probably a bit lucky there :wink:

Quote:
[PS: What is the right amount of slashes for the file: URI scheme? Three, four, what? Is it at all portable?]

three, unless you want to specify the hostname which unsurprisingly goes between the second and the third in which case it looks like there is only two slashes :lol:
_________________
The End of the Internet!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum