Hack 25 Connect to Multiple Servers


single IRC client. With an ever-increasing
number of IRC servers and networks, the chances are that
you're going to want to connect to more than one at
a time at some point. Most IRC clients these days have the ability to
handle connections to multiple servers at the same time. This hack
explains how to do it in some of the more popular clients.
4.10.1 mIRC
To connect to an additional server in
mIRC, bring up the server-selection
dialog by clicking File
you want to connect to from the IRC Network and
IRC Server drop-down boxes. Ensure that the
New Server Window checkbox is checked, and then
click Connect to Server, as shown in Figure 4-22.
Figure 4-22. Connecting to multiple servers in mIRC

can type /join commands and so on as necessary.
Figure 4-23 shows mIRC connected to two IRC servers:
freenode and MAGnet. The client has joined the #irchacks channel on
the freenode server.
Figure 4-23. A mIRC client connected to multiple servers

new_server for a quicker method of adding
a new server in mIRC. The -m flag tells mIRC to
create a new connection rather than to nuke the existing one. So to
create another connection to the freenode IRC network, you would
type:
/server -m irc.freenode.netYou can also use the -j flag to get mIRC to
automatically join a channel when it has connected to the server:
/server -m irc.freenode.net -j #irchacksTo join more than one channel, you must specify their names as a
comma-separated list, for example:
/server -m irc.freenode.net -j #irchacks,#java,#jibble
4.10.2 XChat
To open a connection to another server in XChat, bring up the Server
List dialog by clicking X-Chat
Choose the new server or network you want to connect to from the
Networks list, and then click Connect
in a New Tab, as shown in Figure 4-24.
Figure 4-24. Server List dialog in XChat

all the necessary /join commands again, as shown
in Figure 4-25.
Figure 4-25. XChat connected to two servers

4.10.3 irssi
To connect to a new server in
irssi, simply enter the command
/server servername,
where servername is the domain name of the new
server.
Steve Jolly