Does 0.0.0.0/7 represent the same range as 1.0.0.0/8?
up vote
3
down vote
favorite
The range of 0.0.0.0/7
is 0.0.0.0 - 1.255.255.255
.
The range of 1.0.0.0/8
is 1.0.0.0 - 1.255.255.255
.
AFAIK, 0.0.0.0/8
(0.0.0.0 - 0.255.255.255
) is not usable. So, do these represent the same range practically?
ip route add 0.0.0.0/7 dev eth1 # 1
ip route add 1.0.0.0/8 dev eth1 # 2
Is the effect the same?
networking routing ip cidr
add a comment |
up vote
3
down vote
favorite
The range of 0.0.0.0/7
is 0.0.0.0 - 1.255.255.255
.
The range of 1.0.0.0/8
is 1.0.0.0 - 1.255.255.255
.
AFAIK, 0.0.0.0/8
(0.0.0.0 - 0.255.255.255
) is not usable. So, do these represent the same range practically?
ip route add 0.0.0.0/7 dev eth1 # 1
ip route add 1.0.0.0/8 dev eth1 # 2
Is the effect the same?
networking routing ip cidr
1
I get it now, but I suspect you should also read this.
– Michael Hampton♦
Nov 5 at 17:23
@MichaelHampton +1 for the link. Edited the post.
– Szymon Marczak
Nov 5 at 17:41
add a comment |
up vote
3
down vote
favorite
up vote
3
down vote
favorite
The range of 0.0.0.0/7
is 0.0.0.0 - 1.255.255.255
.
The range of 1.0.0.0/8
is 1.0.0.0 - 1.255.255.255
.
AFAIK, 0.0.0.0/8
(0.0.0.0 - 0.255.255.255
) is not usable. So, do these represent the same range practically?
ip route add 0.0.0.0/7 dev eth1 # 1
ip route add 1.0.0.0/8 dev eth1 # 2
Is the effect the same?
networking routing ip cidr
The range of 0.0.0.0/7
is 0.0.0.0 - 1.255.255.255
.
The range of 1.0.0.0/8
is 1.0.0.0 - 1.255.255.255
.
AFAIK, 0.0.0.0/8
(0.0.0.0 - 0.255.255.255
) is not usable. So, do these represent the same range practically?
ip route add 0.0.0.0/7 dev eth1 # 1
ip route add 1.0.0.0/8 dev eth1 # 2
Is the effect the same?
networking routing ip cidr
networking routing ip cidr
edited Nov 5 at 17:36
asked Nov 5 at 16:55
Szymon Marczak
1186
1186
1
I get it now, but I suspect you should also read this.
– Michael Hampton♦
Nov 5 at 17:23
@MichaelHampton +1 for the link. Edited the post.
– Szymon Marczak
Nov 5 at 17:41
add a comment |
1
I get it now, but I suspect you should also read this.
– Michael Hampton♦
Nov 5 at 17:23
@MichaelHampton +1 for the link. Edited the post.
– Szymon Marczak
Nov 5 at 17:41
1
1
I get it now, but I suspect you should also read this.
– Michael Hampton♦
Nov 5 at 17:23
I get it now, but I suspect you should also read this.
– Michael Hampton♦
Nov 5 at 17:23
@MichaelHampton +1 for the link. Edited the post.
– Szymon Marczak
Nov 5 at 17:41
@MichaelHampton +1 for the link. Edited the post.
– Szymon Marczak
Nov 5 at 17:41
add a comment |
1 Answer
1
active
oldest
votes
up vote
7
down vote
accepted
Clearly these are not the same.
However, nothing in 0.0.0.0/8 is a valid destination address, so the effect of each route would be the same. Attempts to connect to anything in 0.0.0.0/8 would just fail as always with an Invalid argument
error, while attempts to connect to 1.0.0.0/8 would be routed as specified.
Just to add to this, if you specify both routes,1.0.0.0/8
would always be used for1.*.*.*
, as it is more specific than0.0.0.0/7
. Hence,0.0.0.0/7
would be used (and fail as described) only for0.0.0.0/8
range (0.*.*.*
addresses).
– Matija Nalis
Nov 5 at 20:36
@MatijaNalis Connections to 0.0.0.0/8 fail regardless of whether a static route is defined for them or not.
– Michael Hampton♦
Nov 5 at 20:38
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
7
down vote
accepted
Clearly these are not the same.
However, nothing in 0.0.0.0/8 is a valid destination address, so the effect of each route would be the same. Attempts to connect to anything in 0.0.0.0/8 would just fail as always with an Invalid argument
error, while attempts to connect to 1.0.0.0/8 would be routed as specified.
Just to add to this, if you specify both routes,1.0.0.0/8
would always be used for1.*.*.*
, as it is more specific than0.0.0.0/7
. Hence,0.0.0.0/7
would be used (and fail as described) only for0.0.0.0/8
range (0.*.*.*
addresses).
– Matija Nalis
Nov 5 at 20:36
@MatijaNalis Connections to 0.0.0.0/8 fail regardless of whether a static route is defined for them or not.
– Michael Hampton♦
Nov 5 at 20:38
add a comment |
up vote
7
down vote
accepted
Clearly these are not the same.
However, nothing in 0.0.0.0/8 is a valid destination address, so the effect of each route would be the same. Attempts to connect to anything in 0.0.0.0/8 would just fail as always with an Invalid argument
error, while attempts to connect to 1.0.0.0/8 would be routed as specified.
Just to add to this, if you specify both routes,1.0.0.0/8
would always be used for1.*.*.*
, as it is more specific than0.0.0.0/7
. Hence,0.0.0.0/7
would be used (and fail as described) only for0.0.0.0/8
range (0.*.*.*
addresses).
– Matija Nalis
Nov 5 at 20:36
@MatijaNalis Connections to 0.0.0.0/8 fail regardless of whether a static route is defined for them or not.
– Michael Hampton♦
Nov 5 at 20:38
add a comment |
up vote
7
down vote
accepted
up vote
7
down vote
accepted
Clearly these are not the same.
However, nothing in 0.0.0.0/8 is a valid destination address, so the effect of each route would be the same. Attempts to connect to anything in 0.0.0.0/8 would just fail as always with an Invalid argument
error, while attempts to connect to 1.0.0.0/8 would be routed as specified.
Clearly these are not the same.
However, nothing in 0.0.0.0/8 is a valid destination address, so the effect of each route would be the same. Attempts to connect to anything in 0.0.0.0/8 would just fail as always with an Invalid argument
error, while attempts to connect to 1.0.0.0/8 would be routed as specified.
answered Nov 5 at 17:22
Michael Hampton♦
161k26297607
161k26297607
Just to add to this, if you specify both routes,1.0.0.0/8
would always be used for1.*.*.*
, as it is more specific than0.0.0.0/7
. Hence,0.0.0.0/7
would be used (and fail as described) only for0.0.0.0/8
range (0.*.*.*
addresses).
– Matija Nalis
Nov 5 at 20:36
@MatijaNalis Connections to 0.0.0.0/8 fail regardless of whether a static route is defined for them or not.
– Michael Hampton♦
Nov 5 at 20:38
add a comment |
Just to add to this, if you specify both routes,1.0.0.0/8
would always be used for1.*.*.*
, as it is more specific than0.0.0.0/7
. Hence,0.0.0.0/7
would be used (and fail as described) only for0.0.0.0/8
range (0.*.*.*
addresses).
– Matija Nalis
Nov 5 at 20:36
@MatijaNalis Connections to 0.0.0.0/8 fail regardless of whether a static route is defined for them or not.
– Michael Hampton♦
Nov 5 at 20:38
Just to add to this, if you specify both routes,
1.0.0.0/8
would always be used for 1.*.*.*
, as it is more specific than 0.0.0.0/7
. Hence, 0.0.0.0/7
would be used (and fail as described) only for 0.0.0.0/8
range (0.*.*.*
addresses).– Matija Nalis
Nov 5 at 20:36
Just to add to this, if you specify both routes,
1.0.0.0/8
would always be used for 1.*.*.*
, as it is more specific than 0.0.0.0/7
. Hence, 0.0.0.0/7
would be used (and fail as described) only for 0.0.0.0/8
range (0.*.*.*
addresses).– Matija Nalis
Nov 5 at 20:36
@MatijaNalis Connections to 0.0.0.0/8 fail regardless of whether a static route is defined for them or not.
– Michael Hampton♦
Nov 5 at 20:38
@MatijaNalis Connections to 0.0.0.0/8 fail regardless of whether a static route is defined for them or not.
– Michael Hampton♦
Nov 5 at 20:38
add a comment |
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f938713%2fdoes-0-0-0-0-7-represent-the-same-range-as-1-0-0-0-8%23new-answer', 'question_page');
}
);
Post as a guest
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
1
I get it now, but I suspect you should also read this.
– Michael Hampton♦
Nov 5 at 17:23
@MichaelHampton +1 for the link. Edited the post.
– Szymon Marczak
Nov 5 at 17:41