The basic steps to setup an IrcD
are install, configure and run...
You will need to add a source for ircd-hybrid to your /etc/apt/sources.list and run "apt-get update; apt-get install ircd-hybrid". We recommend that you build a deb in any case, because irc.indy uses a longer NICKLEN and TOPICLEN than normal.
ircd-hybrid is in debian official (sarge and later), but not in woody. For woody, try http://www.apt-get.org
. If there are no stable/woody backports, then you will want to compile a .deb
Compiling a .deb
If you can't find an appropriate source for woody then add the following lines you your /etc/apt/sources.list. You will want to replace ftp.us.debian.org with your closest mirror.
deb-src ftp://ftp.us.debian.org/debian unstable main
deb http://www.backports.org/debian stable dpatch
Then run the following commands to get the packages required to build ircd-hybrid, and download the source code (inc debian patches).
apt-get install fakeroot
apt-get build-dep ircd-hybrid
apt-get source ircd-hybrid
The build-dep step will install debhelper, bison, libssl-dev, zlib1g-dev, dpatch (from backports.org), flex and docbook-to-man. You may want to edit debian/control & debian/control.in to remove docbook-to-man and use the stable version of debhelper. The package will still build no problems with the old debhelper and without dobook-to-man.
Then you will want to edit ./ircd-hybrid*/debian/rules, and change the parameters at the top to the following (to provide compatability with existing nodes):
NICKLEN = 45
TOPICLEN = 390
MAXCLIENTS = 2000
Then build and install the package (you will need sudo/root access for that):
sudo dpkg -i ../ircd-hybrid*.deb
After all that you will want to edit the configuration files for ircd-hybrid (see below). For debian these will be in /etc/ircd-hybrid/.
Direct from Source
You may want to install in a different location by changing the value of --prefix (including placing it in a stow
If openssl is not properly detected by configure, you will need to use '--enable-openssl=/path/to/openssl'
Use the following if you are running a 2.4 kernel in gnu/linux:
./configure --prefix=/usr/local/ircd-hybrid-7 \
--enable-openssl --with-maxclients=1000 \
--with-nicklen=25 --enable-rtsigio \
sudo make install
Create link to install path from /usr/local/ircd
Check ownership on ircd dir (irc.irc preferably - 'chown -R irc.irc ircd' if necessary). Make sure this is correct before starting the daemon.
When doing the configuring all the config files will be in /usr/local/ircd/etc/.
Acquire IMC template files/dirs from che.indymedia.org:/root/ircd_template. You can ask on the email list (ircd -at- lists.indymedia.org) or ask one of the ircd working group on irc.indymedia.org in the channel #ircd.
You will need to configure ircd.conf: customize IMC default ircd.conf for your node, set server autoconnect for proper hub, create/copy keys directory, generating local rsa.key and rsa.pub if necessary:
openssl genrsa -out rsa.key 2048
openssl rsa -in rsa.key -pubout -out rsa.pub
chown irc.irc rsa.key rsa.pub
chmod 0600 rsa.key
chmod 0644 rsa.pub
Create/copy ircd.motd. Touch optional logfiles if desired: logs/userlog, logs/operlog, logs/foperlog.
On debian, run '/etc/init.d/ircd-hybrid start'. On other platforms you will have to run the binary in another way.
Testing & troubleshooting
Check the output of 'ps aux' to make sure the ircd is running. Check the output of 'netstat -l' for an irc line to make sure the irc daemon is listening. Check the logs to find out what happened if the ircd is not running.
This should be run with these parameters:
stunnel -s irc -N ircs -d 994 -r 127.0.0.1:6667
for instructions on how to setup qwebirc in our environment.