Check_auth: username mismatch, have <one>, digest has <two>

I have three asterisk servers: one, two, and three. I have extensions assigned to each of the three servers: one (2XXX), two (4XXX), and three (6XXX). I had one and three servers working fine. I added server two and when I make a call from 4001 to 6001 or 2001 I get the error shown above. When I make the call from 4001 (on server two) somehow it thinks I am using the wrong username. Where does it get the username from when making a call?

thanks
Y-

The SIP username is derived from the caller ID, unless overridden.

This sounds like it may be the result of the common mistake of using type=friend when type=peer is adequate.

Thanks for reply. I have the servers as “type=friend” I have the phones as “type=peer”. should I switch these?

Set everything to type=peer. The only time you need type=friend is if two peers can have the same IP address.

That did it. Thanks!