RE: howto set a source ip address?
Ronald Klop <[email protected]> Tue, 6 Feb 2007 17:03:07 +0100 (CET)
| Newsgroups | gmane.comp.db.mysql.java |
|---|---|
| Message-ID | <21218101.941170777787170.JavaMail.tomcat@localhost> |
On Tue Feb 06 02:21:50 CET 2007 Mark Matthews <[email protected]> wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > > > > -----Original Message----- > > From: Fabian Bieker [mailto:[email protected]] > > Sent: Friday, February 02, 2007 5:34 AM > > To: [email protected] > > Subject: howto set a source ip address? > > > > Hi, > > > > Is it possible to tell to connector/j to use a specific source address > > for its database conection? > > > > I googled and looked into the ml archive but was unable to find an > > answer... > > > > Thanks for your help, > > > > Fabian Bieker > > Fabian, > > At this time, Connector/J does not support this feature. The Java socket API > itself makes this rather cumbersome to do, in that one has to specify not > only the source address, but a source port at the same time, so of course > one would have collisions with other connections on the same local address. > > Is there a reason your routing doesn't take care of this for you? > > -Mark > You can possibly give a portnr of 0 (the ANY port). The socket wil get a random port. Ronald.