Header Image - Quake On LAN

Build your OWN Quake On LAN

Build your OWN Quake On LAN

We regularly get asked for the login to Quake On LAN so people can make their own changes or just for curiosity. It’s not ideal for us to be giving out these details, mainly for security reasons (we are giving away the details to hundreds of installs out in the wild). However, we have decided to go one better – we will give the instructions to to build your own Quake On LAN!

The setup for Quake On LAN is actually relatively simple. It involves 5 elements

  1. A server binary that works on ARM
  2. GPL’d versions of all the Quake Deathmatch maps
  3. A script to launch the server
  4. A cron job to keep the server up and talk to the web server
  5. PHP script on the server side to log and report user IP addresses

The following steps allow you to install/configure the first 4 elements yourself, and add any customization you require to your particular instance.

You will need an SD card of at least 2GB in size on hand.

Step 1

Download a the minimal Debian image for Raspberry Pi based on Debian Jessie, from here. Write the image to an SD card in the usual manner. For example:

dd if=raspbian-jessie-lite.img of=/dev/sdb

Step 2

Insert the card into a Raspberry Pi and connect to a monitor and keyboard. Don’t forget to connect to your LAN via ethernet too. Boot it up and get the IP address from the command line using the ifconfig command (the default login password in “raspberry”.

raspberry-pi-b-connected-photo-100409822-orig

Step 3

As root (sudo -i to change user) make sure the following directory exists: /usr/local/games/quake. Navigate to that directory using the cd command.

Step 4

Download the tarball file we have put together for you. It contain the Quake directory structure (excluding proprietary content) plus the pre-compiled Quakeworld binary for the server (courtesy of FTE QuakeWorld). The command to use is as follows:

wget http://www.quakeonlan.net/files/quakeonlan.tar.gz .

Step 5

Now extract the file

tar -xvzf quakeonlan.tar.gz

Step 6

We also need to create a launch script at /usr/local/bin/quake. You can use any editor you want, we prefer nano

nano /usr/local/bin/quake

Make the contents look like this:

#!/bin/bash
cd /usr/local/games/quake/

# Forces a check-in with the server at http://www.quakeonlan.net
# This is how clients know the IP of the Raspberry Pi on their LAN
# This will need modification for wlan adapters
# These 2 lines CAN be commented out if you assign a static IP address

ip=$(ip addr show eth0 | grep -o 'inet [0-9]\+\.[0-9]\+\.[0-9]\+\.[0-9]\+' | grep -o [0-9].*)
curl --silent http://www.quakeonlan.net/register.php?ip=$ip

# Don't remove this bit though, it ensures the server stays up
if [[ ! `pidof -s fteqw.sv` ]]; then

# Restart Server
exec ./fteqw.sv > /dev/null &2>&1

fi

and press CTRL + x to save/close the file.

Step 7

Make the new file executable

chmod +x /usr/local/bin/quake

and double check the server binary is executable, just in case it lost this flag along the way somewhere (less troubleshooting later on)

chmod +x /usr/local/games/quake/fteqw.sv

Step 8

now we need to make sure the script is called every minute. Execute crontab -e and add a line

* * * * * /usr/local/bin/quake

at the end of the file. CTRL + x to save/close.

Step 9

Reboot. Your Quake On LAN box is now ready to go, and no longer needs screen keyboard etc. All it needs is power and an ethernet cable into your router LAN port! Ideally, you should change the default password on the RPi and you should ONLY boot up your RPi or a private network, as we always intended for this project.

P1010299

If you need to customise your install in some way, now you can. Just ssh to the IP address of the RPi (as reported on this site) and execute whatever command you need, anytime you want!

$ ssh pi@192.168.1.100      <-- type this command in Linux Shell or else use PuTTY on Windows
pi@192.168.1.100's password:      <-- default password is "raspberry"

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Thu Jul 21 10:15:42 2016 from 192.168.1.198
pi@raspberrypi:~ $ sudo -i      <-- type this to gain root access
root@raspberrypi:~#      <-- you can now make changes to the system

Now that you are logged in to the RPi, you could for example configure it to use wireless rather than wired networking (assuming you have a wireless adapter).

nano /etc/wpa_supplicant/wpa_supplicant.conf

In this example you would want the file to look like the screenshot below. You’ll need to swap “YOUR_SSID” and “YOUR_PASSWORD” for your WIFI name and password. Once done, save & close down nano in the normal manner.

blog_pi_wifi_commands

Reboot the RPi and unplug the wired ethernet cable. Your Quakeworld server should still be available on the LAN. I haven’t tested this method, I’m just giving it as an example of how you now have full control over your Quakeworld server.

RawShark has been dabbling in all things Quake since day one. He has reviewed maps, written mods, hosted servers, hacked code and even played a few games. These days he comes up with solutions for people sitting at home yearning for a blast from the past...

Leave a reply

Your email address will not be published.

Time limit is exhausted. Please reload CAPTCHA.



Quake On LAN is in no way affiliated with id Software.