• Welcome to Hurricane Electric's IPv6 Tunnel Broker Forums.

Very confused about /##, also, how do I bind addresses?

Started by r000t, January 16, 2011, 02:53:39 PM

Previous topic - Next topic

r000t

I've heard talk about /48 /64 /56 and others.... what does it all mean? Why do people need a /48 when they have a /64, which to me seems like it has more addresses?

I also am wondering how a friend of mine (who referred me here for tunneling) mapped a few addresses to a VPS. He assigned me a "jail" on the VPS and within 30 seconds had three custom IPv6 addresses assigned to it... How did he do that, and how can I do the same thing? How would I do this on a VPS? A home modem?

I'm sorry if it seems like I'm asking a lot of questions but this whole IPv6 thing is new to me....

cholzhauer

A /64 is 16 quintillion addresses.

A /56 is 256 /64's

A /48 is 64k of /64's

You get the idea.


jimb

"/48 /56" etc are prefix lengths.  They have the same meaning that they have under IPv4.  It's a way of dividing address space into "network" and "host" portions, or subnetting.  

The "standard" IPv6 LAN is a /64.  It basically means that the first 64 of the 128 bit address is a "set" and assigned network portion, and the remaining bits are host portion.  If one is assigned a /48, it generally means you have 64 - 48 = 16 bits of subnet space to work with, yielding 65,636 /64 networks.

The VPS is likely just living on the same IPv6 subnet as the host, and has virtual NICs in bridged mode.  So it's simply like tossing another box on the /64 LAN and throwing a few IPv6 addresses on it.  /64 provide ~ 18.4 billion billion (quintillion) IPv6 host addresses per LAN.

r000t

So I have this enormous block of IPs.... how do I take just one and assign it to a VPS I have hosted elsewhere?

jimb

Quote from: r000t on January 16, 2011, 06:12:49 PM
So I have this enormous block of IPs.... how do I take just one and assign it to a VPS I have hosted elsewhere?
You can't.  You need another /64, or a /48.  If it's at a totally different location you need another tunnel, or native IPv6 connectivity with totally difference space.  Just like IPv4.

sput

Hi there


Some networking related arithmetic basics;
http://en.wikipedia.org/wiki/Binary_numeral_system
http://en.wikipedia.org/wiki/Hexadecimal

Netmasks;
http://en.wikipedia.org/wiki/Bitwise_operation
http://www.sput.nl/software/cidr-routing.html#ipv6
This page has lots of large numbers. Some so large that they cannot be named (like kilo, Mega Giga, etc).

Speaking of which, there are more IPv6 addresses then there are;
- Grains of sand in our galaxy.
- Subatomic particles in our planet.
- Aliens in the universe.
- Seconds since the big bang.
So don't worry about requesting lots of /48s.


Regards,
Rob

r000t

Quote from: jimb on January 16, 2011, 07:06:21 PM
Quote from: r000t on January 16, 2011, 06:12:49 PM
So I have this enormous block of IPs.... how do I take just one and assign it to a VPS I have hosted elsewhere?
You can't.  You need another /64, or a /48.  If it's at a totally different location you need another tunnel, or native IPv6 connectivity with totally difference space.  Just like IPv4.

So if I request a /64 (which still seems like a big waste...) how do I assign it and bind it to a server?

jrocha

Quote from: r000t on January 17, 2011, 10:42:47 AM
So if I request a /64 (which still seems like a big waste...) how do I assign it and bind it to a server?

Once you have a tunnel assigned, you set it up on your server using the example configuration commands (ip tunnel add, ip link set, etc). Then you just pick one or more IPs out of your assigned /64 and assign them to one of your ethernet interfaces, just the same as an IPv4 address.

r000t

I'm confused.... it still tunnels (that's OK), but how do I tell HE that it's OK for that IP to use the tunnel?

jrocha

Quote from: r000t on January 17, 2011, 12:21:31 PM
I'm confused.... it still tunnels (that's OK), but how do I tell HE that it's OK for that IP to use the tunnel?

You don't have to. The entire /64 block assigned to you is automatically routed through the tunnel for you to use in any way you want.

r000t

OK.... So I can assign any v6 in my block to a computer.

So I did that, and when I went to whatismyipv6.com it gave me the address of the tunnel. I assumed this is how it would work, but someone who is using tunnelbroker was able to connect to IRC and the /whois came back with his custom IP... So how does this all work?

Thanks for helping me understand btw.

jrocha

Quote from: r000t on January 17, 2011, 12:30:27 PM
OK.... So I can assign any v6 in my block to a computer.

So I did that, and when I went to whatismyipv6.com it gave me the address of the tunnel. I assumed this is how it would work, but someone who is using tunnelbroker was able to connect to IRC and the /whois came back with his custom IP... So how does this all work?

Thanks for helping me understand btw.

This is due to the way your computer chooses which IP to use as the source IP when it sends out IP packets.

What the other person is likely doing is terminating his tunnel on a router. Then his router hands out IPs in his /64 (or the computers behind the router use SLAAC, either way). As long as the router will correctly route the IPv6 packets through the tunnel, then his computer will choose his custom IP as the source IP because it is not directly attached to the tunnel.