I am on Aix, and we have many IP adresses on the box, ipconfig -a gives
back:
en1 ........
IP1
IP2
IP3
I have been trying to use IP2 for Inst2 and IP3 for Inst3 with the same
port, but it seems that DB2 keeps listening to *.port on the first IP
address IP1 corresponding to the hostname.
Can I setup a different IP adress for each DB2 instance on the same machine
and how ? With Oracle, you would change the listener.ora to affect a
different IP address.
Thanks for your help,
Jean-Marc
Tee hee.
> I have been trying to use IP2 for Inst2 and IP3 for Inst3 with the same
> port, but it seems that DB2 keeps listening to *.port on the first IP
> address IP1 corresponding to the hostname.
>
> Can I setup a different IP adress for each DB2 instance on the same machine
> and how ? With Oracle, you would change the listener.ora to affect a
> different IP address.
I am not aware of any way to prevent DB2 from binding the TCP listener
to all interfaces.
Try modifying db2nodes.cfg for each instance.
Hi Mark,
Thanks for your suggestion but this does not work (this is not taken only
into consideration for db2 dpf).
I did not find any registry that would allow me to configure the IP address.
Regards,
JM
On 2 Mar, 23:10, "Jean-Marc Blaise" <jmbla...@hotmail.com> wrote:
> "Mark A" <some...@someone.com> wrote in message
>
> news:V7Zql.10809$b9....@bignews6.bellsouth.net...
>
>
>
> > "Jean-Marc Blaise" <jmbla...@hotmail.com> wrote in message
Alright, I'm utterly confused by this.
> Also , any specific reason for using different IP address ?
Yes. One machine, multiple networks, different "personalities" on each.
> db2 uses "ip address" in a different way.
> mainly the CLIENT uses the IP Address to recognize the SERVER than the
> Server uses to listen.
No, DB2 uses IP addresses in exactly the same way every other server does:
for binding to so that DB2 can listen for incoming connections. By allowing
users to bind to localhost, that can limit connections to applications
running on the local machine only, which can be a Good Thing, for example,
in web applications where the web server is on the same machine.
Further along that idea is a machine that both runs a web database and other
production databases where there is a private network set up between all the
web servers (load balancing) and the database server, and so you want to
bind the web instance to only the private network, and the other instance(s)
to the intranet (to reduce exposure to, say, hacking the apache server).
> so
> I think you can give a try by configuring CLIENT instances with
> different IP Address in their node directory.
I don't see how this addresses the original question from JM.
> On 2 Mar, 23:31, Sivaswami Jeganathan <sivaswamim...@gmail.com> wrote:
>> try setting different instance path for instances and place the
>> db2nodes.cfg in seperate directories.
This confused me, too, as I have absolutely no idea what this says.
Generally, when you have multiple instances, you can't do anything but have
a different instance path for each instance, and db2nodes.cfg only does
something for clustered DB2, which JM never indicated he was using, and even
if he were using it, I would be interested to know how this would apply.
Having gone up and down that file every which way, I'm at a loss to
understand what you would want JM to do with this file.
>> On 2 Mar, 23:10, "Jean-Marc Blaise" <jmbla...@hotmail.com> wrote:
>>
>> > "Mark A" <some...@someone.com> wrote in message
>>
>> >news:V7Zql.10809$b9....@bignews6.bellsouth.net...
>>
>> > > "Jean-Marc Blaise" <jmbla...@hotmail.com> wrote in message
>> > >news:49ac3f4c$0$2673$426a...@news.free.fr...
>> > >> Hello,
JM, I'm pretty sure this has been asked many times, and the answer each time
has been "no." As in, no, you can't tell DB2 to bind only to a specific
port. The best answer was to use something like iptables to prevent
incoming connections from interfaces that you didn't want to receive
connections on (which helps with the webserver exposure, for example), but
that still doesn't allow two instances to use the same port.
Thanks Darin for your comments, so let's continue ask for it :-)
Regards,
JM
Hi,
You can use iptables in order to configure you communications. With
iptables you can permit that external communication get into your
server only with a given ip:port
There is no way to configure DB2 to listen by a given ip, you can only
configure that a given instance listen a given port (port number or
service name). Then, you have to configure how your server is accessed
(configuring routers, firewalls)