Deploying an IRC Server on Ubuntu

Posted on 09 Apr 2016

For fun, and mostly because I can, I deployed an IRC Network on my home server and I thought I’d write up the experience and steps of doing just that.

Screenshot of IRC Client

IRC Server with InspIRCd

Despite the punny name, InspIRCd appeared to be the simplest open source solution to deploying your own IRC server, since a package for it is in the Ubuntu repositories –you don’t have to faff around with compiling from source.

sudo apt-get install inspircd

Although if you are so compelled, you can compile the latest version from source by following their instructions.

Configuration

Almost all items in UPPERCASE, or things like addresses in the following you will need to update with your own.

The installation of InspIRCd creates a default configuration file in /etc/inspircd/inspircd.conf a lot of which you won’t have to touch but there are a some lines that you will need to update.

So nano it! (Or open it in any other editor)

sudo nano /etc/inspircd/inspircd.conf

Server details

You will need set the details for your server/network, specifically the name (which doesn’t have to exist, but has to be in abc.mno.xyz form), description and the Network name and ID.

<server name="irc.example.com" description="Example IRC Server" network="EXAMPLEIRC" id="26Z">

The id field is any random 2 numbers and 1 letter.

Admin details

Presumably the admin details would be yours, as you’re configuring this server, but you’ll need to set the name of the admin account and it’s nick and email address.

<admin name="ADMIN NAME" nick="ADMIN_NICK" email="admin@example.com">

Server address

Simply update the address field with the IP address of your server.

<bind address="111.111.111.111" port="6667" type="clients">

Kill & restart passwords

You have to set a the password that can be used by operators to shutdown & restart the server.

<power diepass="SERVER_KILL_PASSWORD" restartpass="SERVER_RESTART_PASSWORD" pause="2">

Configure Operator Accounts

Essentially for each operator account, add a nick and password and add the server IP and Hostname of your server to the host field.

<oper name="OPERATOR_NICK" password="OPERATOR_PASSWORD" host="@localhost, *@111.111.111.111, *@HOSTNAME" type="NetAdmin">

Write the Server MotD and Rules.

This line points to the plaintext files that will contain the Message of the Day and IRC network rules that users on your server will be able to see when they are online via the /rules and /motd commands.

<files motd="/etc/inspircd/inspircd.motd" rules="/etc/inspircd/inspircd.rules">

So, you’ll have to edit the contents of both /etc/inspircd/inspircd.motd and /etc/inspircd/inspircd.rules or point the values in above line to files you have pre-written.

That’s the minimum you should do for configuring your server. For the full detail and info on the other fields of the configuration file, you can visit the official documentation page.

InspIRCd Configuration

Starting Your Server & First Log On

Next, start your IRC server and attempt to login with your chosen client.

# start
sudo service inspircd start
# or with systemd:
sudo systemctl start inspircd.service

If all goes well you should see a message along the lines of Starting Inspircd... done. at which point you can attempt to logon to the server.

In case you didn’t know, you can use the irc:// URI to link directly to IRC networks/channels

irc://irc.example.com:port/#channel
Trying to leave a comment? Feel free to contact me directly instead.

Recent Posts

How to Run a Usability Test27 Aug 2019
Joining Purism!30 Jul 2019
Taking the "User" out of Design20 Feb 2019
Basic Linux Virtualization with KVM16 Feb 2019
Moving Beyond Themes05 Aug 2018