Subject RE: [firebird-support] Re: Port number via isql
Author Nigel Weeks
> isql hostname/port:alias .....
>
Brilliant! Guess what I've done!

Get a copy of 'balance' (balance.sourceforge.net), slap it on your *nix box,
and run it like so:
`balance -df 3060 host1:3050 host2:3050`

Connect to the '3060' port, and viola, a load balanced database cluster
(Replication is outside the scope of this article)

Here's my commands:

On the load balancer:
`balance -df 3060 203.26.213.14:3050 203.26.213.181:3050`

Gives the output:
argv[0]=balance
bindhost=NULL
source port 3060
file /var/run/balance/balance.3060.0.0.0.0 already exists
bindhost_adress=[0.0.0.0]
the following channels are active:
0 0 203.26.213.14:3050:0
0 1 203.26.213.181:3050:0


On the client, doing the following:
isql -u blah -p blah 203.26.213.14/3060:/u1/db/oa.fdb
Database: 203.26.213.14/3060:/u1/db/oa.fdb, User: blah
SQL> exit;

(connecting, and exitting)

Did the following on the load balancer:
connect from 203.26.213.181
trying group 0 channel 0 ... connect to channel 0 successful
connect from 203.26.213.181
trying group 0 channel 1 ... connect to channel 1 successful
connect from 203.26.213.181
trying group 0 channel 0 ... connect to channel 0 successful

And yes, it did swap DB servers - the schema's were very different!

Sorry if everyone knows about this, but I just wondered if it was possible,
and it works amazingly well...

N

Nigel Weeks
Tech Support & Systems Developer
nweeks@...
www.examiner.com.au
71 - 75 Paterson Street
Launceston
Tasmania 7250
Australia
Phone: 03 6336 7234