On 6/19/20 7:15 AM, Robert wrote:
> Hi,
> 
> I want to configure multiple alias IPs on the same interface and in the same 
> subnet.
> (reason: hosting services with dedicated DNS names and IPs)
> 
> inet 10.0.0.1 255.255.255.0
> inet alias 10.0.0.2 255.255.255.0
> inet alias 10.0.0.3 255.255.255.255
> ...
> 
> What is the correct subnet mask for those alias IPs?

If you have multiple IP's in the same subnet you enter then as /32

If you have two different subnet NOT in the same range, the first one of
the new subnet you enter it as it's full subnet and any additional one
in that second subnet you enter them as /32.

Example:

inet 10.0.0.1 255.255.255.0
inet alias 10.0.0.2 255.255.255.255
inet alias 10.0.0.3 255.255.255.255
inet 10.1.0.1 255.255.255.0
inet alias 10.1.0.2 255.255.255.255
inet alias 10.1.0.3 255.255.255.255
inet 10.2.0.1 255.255.255.0
inet alias 10.2.0.2 255.255.255.255
inet alias 10.2.0.3 255.255.255.255

It's always how I did it. If I am doing it wrong, then I never
understood it properly. May be the man page might benefit from
clarifying it.

Hope this help you.

Daniel

Reply via email to