Well, my server has dummy interface and multiple /32 IP addresses.
They are announced via OSPF to IGP.

The idea is to anycast 2 IPs (HA solution) and when primary server
goes down, secondary will response to primary's IP address also.

Primary server has the following config:
interface ignore wildcard
interface listen 172.20.1.3
interface listen 172.20.2.3
interface listen 172.20.1.19

+ FRR: ip ospf cost 700 172.20.2.3

Secondary:
interface ignore wildcard
interface listen 172.20.1.3
interface listen 172.20.2.3
interface listen 172.20.2.19

+ FRR: ip ospf cost 700 172.20.1.3

The IPs 172.20.1.3 and 172.20.2.3 are "floating IPs". And I need from
ntpd to make outgoing connections from 172.20.1.19 and 172.20.2.19
respectively.

I did tests and now, ntpd is selecting "172.20.2.3" for outgoing
"connections" from primary server. And it fails, because 172.20.2.3 is
routed to secondary (server will never get the response).

št 29. 9. 2022 o 15:18 William Unruh <un...@physics.ubc.ca> napísal(a):
>
> In comp.protocols.time.ntp, you wrote:
> > Hi there,
> >
> > I read the documentation a few times but can not find if it's possible
> > to specify IP address for outgoing connections?
> >
> > I have server with multiple IP addresses and I need to specify the
> > concrete one to be used to sync with servers/peers. For now, ntpd
> > selects one of the listening interfaces (still the same one, but I can
> > not determine why this one).
>
> Does not route -n
> tell you which one? Remember it always used the most the specific
> interface.
> Ie, if you have say 0.0.0.0/0 and 128.0.0.0/8 on different interfaces,and 
> your address of your
> ntp server is 128.113.27.6 then it will use the second. If you have
> 128.113.27.0/24 on a third interface, it will use that third one. If
> there are two of equal depth covering the interface, then it will use
> the last on I believe.
>
> Ie, with a specific set of routes, it should always pick the same
> interface. The server uses the same address it received the query on, so
> it will depend on the incoming routing of the response.
> >
> >
> > Thanks,
> > Blažej
> > --
> > This is questions@lists.ntp.org
> > Subscribe: questions+subscr...@lists.ntp.org
> > Unsubscribe: questions+unsubscr...@lists.ntp.org
> >
> >
> >
> --
> This is questions@lists.ntp.org
> Subscribe: questions+subscr...@lists.ntp.org
> Unsubscribe: questions+unsubscr...@lists.ntp.org
>
>
>
-- 
This is questions@lists.ntp.org
Subscribe: questions+subscr...@lists.ntp.org
Unsubscribe: questions+unsubscr...@lists.ntp.org



Reply via email to