Hot answers tagged

20

The IPv6 documentation prefix (2001:db8:::/32) must be used ONLY for documentation purposes. It means written examples, diagrams, PPT presentations, Textbook explanations, etc. This range shouldn't be used in practical networks. There is a "private IP range" of fc00::/7 which should be used for device testing, demos, courses, etc. as per RFC4193 Unicast ...


12

RFC950 states that Since the bits that identify the subnet are specified by a bitmask, they need not be adjacent in the address. However, we recommend that the subnet bits be contiguous and located as the most significant bits of the local address. Most devices follow this recommendation as far as to enforce it. I have only managed to use non-...


11

If your test environment is separated from your local network you hypothetically could use any IPv6 addresses which are not reserved for special uses. However, if you are looking for an equivalent of private IPv4 adresses you should take a look in RFC4193. There you can see that fc00::/7 is the suitable subnet for testing purposes. On the other hand you ...


8

Just from the RFC I can't see anything defining that documentation is strictly written text. Do you have any source for this interpretation? According to the IANA IPv6 Special-Purpose Address Registry, the 2001:db8::/32 Documentation address range cannot be used in source or destination addressing, is not forwardable (routable) nor globally reachable, and ...


8

Prefix delegation is a DHCPv6 option. You cannot do it without DHCP. Here is the RFC: https://tools.ietf.org/html/rfc3633


8

How do routing protocols carry the prefixes? Where is the "slash" part stored? I'll answer this as direct as possible with OSPF. Below is a Type 1 Hello packet sent out all interfaces to form an adjacency. 0 1 2 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-...


8

Classful networking died in 1993 and was replaced by CIDR. With CIDR, any subnet prefix length is possible. You can use 192.168.0.0/16 just as well as 10.0.0.1/31 (for private addresses). Nobody stops you from using 10.0.0.0/8 at home or elsewhere. Most often, IP address and prefix length aka network mask are assigned by a DHCP server. [edit] Who ...


7

The issue is that you end up comparing unequal things when you say "I would express the range as 121.34.56.64/24 in prefix notation" The range 121.34.56.64 to 121.34.56.128 is contained in 121.34.56.64/24 (which is actually the 256 IPs from 121.34.56.0 to .255), but the two are not equivalent. The reason that 121.34.56.64-128 cannot be expressed as a ...


6

If you are using prefixes and networks, then the answer is no, the bits need to be contiguous. There are cases where a wildcard mask (inverse of mask) can be used, e.g. Cisco ACLs, and those can be any bit pattern. For instance, you could block traffic from all the odd numbered hosts on a network. This seems to still be taught, but I have not seen it used ...


6

It depends on the routing protocol. Old protocols like RIP v1 assume a classful mask and do not advertise a mask, but newer ones like RIP v2, OSPF, ISIS, BGP, etc do. The answer to the second part of your question: To determine the network part of the address, or to test if a given address is part of a particular network, you perform a bitwise logical AND ...


5

When you lease an ipv4 block what do you actually get? The right to use those addresses on the Internet. How do you get access to the ip adresses? Is any special equipment required or is it as simple as renting a server? You have two options, if you have BGP sessions established you can advertise the addresses yourself. Alternatively you can get your ...


5

How can I convert that to a size in /30? This question does not actually make sense. How many /30 equals to one /64? Neither does this question make sense. I assume you mean IPv6 because there is no such thing as an IPv4 /64 network. Your last question could make sense if you reverse it to ask how many /64 networks can be made from a /30 prefix. The ...


4

No. A netmask is a continuous series of ones. (The others are "wildcard" patterns.)


4

I would assume /17 to /32 are the smaller prefixes. Prefix is used as a synonym (1) for network in this case. The prefixes are longer, thus the networks they describe are smaller. I can see this could indeed be considered confusing, smaller as the opposite of shorter, but that's natural languages for you. (1) It's probably a metonym, but that's a ...


4

So, according to longest prefix matching rule, we send this packet to net2. That is correct. Now I have a doubt that all the packets which match with both networks are sent only to net2, instead, it might be possible that some actually belong to net1. This isn't possible unless you have another, even more specific (longer) routing table entry. In any ...


4

There are generally two reasons to use BGP with your ISP: You have more than one connection to your ISP(s), and you want to influence which path your traffic takes. You have your own provider independent, registered block of IP addresses, which needs to be advertised. For most organizations with a single connection to the Internet, there is no reason or ...


3

If you want to limit your output to just the names of the routing-tables, then something like: show route 192.169.0.0/24 | match dest will do the trick


3

When TCP/IP first came out and got widespread, there were actually a lot of subnets with non-contiguous masks. But as addresses became scarce, the overhead to the rest of the net to allow global routing of these prefixes rather than forcing everything to be only prefix based; was too much and the global network changed to only supporting prefixes. There ...


3

I guess I should start by saying that IP prefixes are not technically bought. When an IP prefix is allocated to a provider from an RIR like ARIN, there is no transfer of ownership. The IP range is always allocated to the RIR, and the allocation to the provider is only valid so long as the original terms of the allocation are upheld. As for the routing ...


3

What determines the class of private ip addresses? Nothing because network classes are dead (please let them rest in peace), killed in 1993 (over 25 years ago, before the Internet went commercial!) by RFCs 1517, 1518, and 1519, which defined CIDR (Classless Inter-Domain Routing). Modern networking does not use network classes. If you want a history lesson, ...


3

RFC 6164, Using 127-Bit IPv6 Prefixes on Inter-Router Links explains that /127 networks are good for point-to-point links: Abstract On inter-router point-to-point links, it is useful, for security and other reasons, to use 127-bit IPv6 prefixes. Such a practice parallels the use of 31-bit prefixes in IPv4. This document specifies the motivation for, and ...


2

What does stop you from bridging these two interfaces? Simple transparent bridge. In this case you save 1 IP address. For all internal devices the GW is the IP of the router. For external devices, everything behind the router is visible, but you may adjust it with some filtering policy.


2

You can subnet the /27 into /30 for the WAN link. That will leave you with another /30, a /29, and a /28 for you to assign on your network. Like this: 90.10.200.32/30 for the WAN, use 90.10.200.33 for the ISP and 90.10.200.34 for your WAN interface 90.10.200.36/30 for a subnet with 2 hosts 90.10.200.40/29 for a subnet with 6 hosts 90.10.200.48/28 for a ...


2

A gateway is the host on a network that knows how to reach other networks. Your host would need a gateway just to reach a gateway on a network to which it is not directly connected. An IPv6 host will know how to reach other hosts on any networks to which it is directly attached, but it still needs a gateway in order to reach other networks. While IPv4 uses ...


2

In Junos you have the command: test policy <<POLICY-NAME>> <<Prefix>> however, it doesn't do quite what you are asking. Firstly, create your prefix-list and match it in a policy: policy-options { prefix-list SOME-PREFIXES { 172.16.10.1/32; 172.16.10.32/27; 172.16.10.50/32; 172.16.10.96/29; ...


2

No there isn't. For SMTP block lists people tend to use a /64.


2

Short answer: you can't. You are asking to route traffic not by the destination address, but by the source address. In other words, you want traffic to take a particular path based on its source address (i.e., sourced from obscure ISP). That's not how routing normally works. It would be technically possible to make this happen using policy-based routing, ...


1

Subnet routing is usually by destination address (as opposed to policy-based routing where other parameters can be used). The routing algorithm selects the most specific, longest subnet prefix from the routing table. Effectively, the routing table is sorted by prefix lengths and entries are tested from longest to shortest prefix until a match is found. If ...


1

Ok if you know how to calculate CIDR from NETMASK this will be easy... /30 = 4-2=2 hosts /29 = 8-2=6 hosts /28 = 16-2=14 hosts /27 = 32-2=30 hosts /26 = 64-2=62 hosts basically, /x is 2^(32-x)-2 hosts and if you have n hosts, you can use a /x with x=floor(32-LOG2(n+2)) you can remove one more host if you want an ip for the gateway So in your example,...


Only top voted, non community-wiki answers of a minimum length are eligible