Robert Kulagowski wrote: > Jan Willamowius wrote: > > Thats pretty much what I roughly had in mind. > > > > But now for extra credit: ;-) > > Right now you only return the preferred gateway IP. You should modify > > your SQL to return the other gateway IPs in the next rows so the call > > will failover to those when the preferred gateway isn't available. > > Isn't it doing that already? Sorry, I didn't see that you had multiple entries for some prefixes. For those where you have multiple entries, GnuGk will of course do failover. > mysql> select * from routes; > +-------------+--------+-------+-------------+--------+---------+ > | gatewayip | prefix | route | destination | called | calling | > +-------------+--------+-------+-------------+--------+---------+ > | 10.244.22.5 | NULL | NULL | NULL | NULL | 21 | > | 10.244.22.5 | NULL | NULL | NULL | NULL | 22 | > | 10.244.2.5 | NULL | NULL | NULL | NULL | 31 | > | 10.244.22.5 | NULL | NULL | NULL | NULL | 31 | > +-------------+--------+-------+-------------+--------+---------+ > 4 rows in set (0.00 sec) > > mysql> select gatewayip from routes where calling="31"; > +-------------+ > | gatewayip | > +-------------+ > | 10.244.2.5 | > | 10.244.22.5 | > +-------------+ > 2 rows in set (0.00 sec) I didn't expect multiple entries from that query, because you don't have an 'order by' clause. If you don't have one, the order in which the entries are returned is not defined and may change over time. So you should add something like a priority column that you order by. Regards, Jan -- Jan Willamowius, jan@xxxxxxxxxxxxxx, http://www.gnugk.org/ ------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________________ Posting: mailto:Openh323gk-users@xxxxxxxxxxxxxxxxxxxxx Archive: http://sourceforge.net/mailarchive/forum.php?forum_name=openh323gk-users Unsubscribe: http://lists.sourceforge.net/lists/listinfo/openh323gk-users Homepage: http://www.gnugk.org/