Post4VPS Forum | Free VPS Provider
Two IPs - can I use the same Netmask for both? - Printable Version

+- Post4VPS Forum | Free VPS Provider (https://post4vps.com)
+-- Forum: VPS Discussion (https://post4vps.com/Forum-VPS-Discussion)
+--- Forum: VPS Support (https://post4vps.com/Forum-VPS-Support)
+--- Thread: Two IPs - can I use the same Netmask for both? (/Thread-Two-IPs-can-I-use-the-same-Netmask-for-both)



Two IPs - can I use the same Netmask for both? - deanhills - 03-08-2019

VPS 15 comes with two IPs, so this is my first experience with trying to put more than one IP on VestaCP. A nice challenge.

Previously I never bothered with how VestaCP set up the IP as I always had one IP, but this time round I have to add the second IP manually. It asks for a submask, and I don't have the foggiest what it should be?

Can I use the same Netmask that VestaCP loaded for the installation IP? Like have two IPs with the same Netmask, or do I need to figure out a different Netmask for the second IP. If yes, if it has to be different, how does one do that?


RE: Two IPs - can I use the same Netmask for both? - Manal - 03-08-2019

Maybe I'm wrong but I guess I know what you're trying to say and my opinion MAY help you.

First of all, check if the default IP address you have is in the block ie x.x.0.81 and x.x.0.82. If this is it, netmask should be the same.
But if the block is different, the netmask may differ.

I had this issue with Hetzner too when I bought additional IP and a subnet. Both were different and I had to apply different netmask.

So all over, if the IP address co-relates with each other, you MAY use the same netmask(not sure but this worked for me).


RE: Two IPs - can I use the same Netmask for both? - deanhills - 03-08-2019

Thanks for the feedback @Manal. The second IP has 2 extra digits at the end.

IP #1: xxx.xx.xx.x
IP #2: xxx.xx.xx.xxx

The mask for IP #1 that was set by VestaCP is: 255.255.255.255

So do you think I can use the same mask for IP#2?


RE: Two IPs - can I use the same Netmask for both? - Mashiro - 03-08-2019

You most likely have 2x /32 (single IPs) in your VPS and these do have the 255.255.255.255 subnet mask. Before you can even use the IP in VestaCP make sure it is configured in your network adapters already.


RE: Two IPs - can I use the same Netmask for both? - rudra - 03-08-2019

I may be totally wrong.

Now with that bit of wisdom in mind, ;-)

you can always configure another ip using 255.255.255.255 in such cases. It will simply mean you will have a virtual fence there and it wont talk directly with another ip even if that came from the same block. So probably it will always work if you set that... /32

It is like grouping people around tables where tables are marked with subnet masks.