Services Spotlight:

Setup Ventrilo Server 3.0.3 On 32bit or 64bit Ubuntu (Any Version)

Written By Corlew Solutions
Updated September 6, 2016
Published January 16, 2014
Why Corlew Solutions?

We write great software and provide amazing technical support. Contact us today if you need help with a software project:

  • Website: Send an inquiry
  • Email:
  • Phone: (703) 688-3058

Article Technology Info

This article discusses the following technologies:

  • Ubuntu 13.04 - A Debian-based Linux operating system that is a popular server choice.
    (website | download | wiki)
  • Ventrilo Server 3.0.3 - Popular VoIP software for group chatting
    (website | download | docs)

Ventrilo is a popular VoIP technology frequently used for group communication.  Clients are available for Windows and Mac and server code exists for the most popular operating systems. This tutorial will guide you through the process of installing a dedicated Ventrilo server on Ubuntu.

Install Ventrilo

Step 1: Download the Linux i386 version of Ventrilo. 64bit Ubuntu users will need to install 32 bit Ventrilo as well since this is only version available.
Step 2: Copy the file to your server using your preferred FTP/SFTP client. The location where you choose to copy the file will depend on your server privileges and preferences. Some options include:

  • ~ (your home directory)
  • /srv
  • /usr/bin

Step 3: Extract the contents of the tarball and delete it since it is no longer needed:

1
2
sudo tar -xzf ventrilo_srv-3.0.3-Linux-i386.tar.gz
sudo rm ventrilo_srv-3.0.3-Linux-i386.tar.gz

Step 4: The command on line 1 above will create a directory called ventsrv.

Step 5: The rest of this tutorial will assume Ventrilo has been installed to /srv/ventsrv.

Step 6: If you’re running 64bit Ubuntu you will need to install some other packages which help 32bit applications like Ventrilo server run:

Ubuntu 15.10 or Newer

1
2
sudo apt-get update
sudo apt-get install lib32z1 lib32ncurses5 lib32stdc++6

If you run into problems getting Ventrilo to run later in the article, you might try installing libbz2-1.0:i386. Don’t install it now, because it probably isn’t needed, but according to this thread, it’s likely a substitute package for the lib32bs2-1.0 package that was needed in earlier versions of Ubuntu.

Ubuntu 13.10 to 15.04

1
2
sudo apt-get update
sudo apt-get install lib32z1 lib32ncurses5 lib32bz2-1.0 lib32stdc++6

Ubuntu 13.04 or Older

1
2
sudo apt-get update
sudo apt-get install ia32-libs

Configure Ventrilo

Ventrilo is configured by changing settings in the ventrilo_srv.ini file. Using your favorite editor, open ventrilo_srv.ini. We will use nano and open the file by executing:

1
sudo nano /srv/ventsrv/ventrilo_srv.ini

The only lines you really need to change in here are, Name, Phonetic, Auth, AdminPassword and Password. The Auth line tells Ventrilo to use the Password for connection verification, otherwise, anyone will be able to connect to the server. More information on the options in the config file can be found in the /srv/ventsrv/ventrilo_srv.htm file or viewed online.

Start Ventrilo

The Ventrilo server can be started in a number of ways. At the very least, try Method 1 below to make sure you can manually start the server on demand.

Method 1 - Manual Command (Ventrilo WILL Takeover the Terminal)

To manually start the server from the shell, execute the ventrilo_srv command:

1
2
cd /srv/ventsrv
sudo ./ventrilo_srv

You must be in the ventsrv folder before starting the server. Using a full path won’t work (likely because the ventrilo_srv isn’t smart enough to find other files that it needs when executed from another folder)

You can press Ctrl-C at any time to terminate the server.

NOTE: If you get an error in the terminal saying: -bash: /srv/ventsrv/ventrilo_srv: No such file or directory or -bash: ./ventrilo_srv: No such file or directory first check that /srv/ventsrv/ventrilo_srv is executable. If that doesn’t work, you may be on 64bit Ubuntu and require 32bit libraries to run Ventrilo server (which is 32bit software); see Step 6 in the installation instructions above.

There are two big downsides to this method. First, Ventrilo will take over and direct all output to the shell. Second, when you close the shell, the server will stop. Method 2 below fixes both of these issues.

Method 2 - Manual Command (Ventrilo WILL NOT Takeover the Terminal - a.k.a Daemon Mode)

Simply add a -d to the end of the server startup command ./ventrilo_srv -d and this will launch the Ventrilo server in Daemon mode. Once the server starts, the console will return to your control and Ventrilo will continue to run on the server even if you close the shell.

To stop the Ventrilo server in Daemon mode, you will have to open the ventrilo_srv.pid file and find the PID of the server. Once you know the PID you can kill the server.

1
2
sudo cat /srv/ventsrv/ventrilo_srv.pid   # Writes the PID in the file to the terminal.  You can also open the file with nano and have a look.
sudo kill {pid}

Method 3 - Startup Script

If you have root access on the server, you can install a startup script that will start the Ventrilo server every time the machine is rebooted. It’s a good idea to run Ventrilo under an account other than root so let’s create a system user with no home directory or login capabilities to do just that:

1
sudo adduser --system --no-create-home --disabled-login --disabled-password --group ventrilo

The above command will create a user and group named ventrilo. Next, let’s make the new ventrilo user the owner of all of the Ventrilo files.

1
sudo chown -R ventrilo:ventrilo /srv/ventsrv

Now we need a startup script that can be executed when the server starts. We will name the file ventrilo and it can be created by executing:

1
sudo nano /etc/init.d/ventrilo

Copy the script below and paste it into the ventrilo file you’re about to save.

NOTE: If you installed the server to somewhere other than /srv/ventsrv then you will need to edit the paths in the script below.  If you called your user something other than ventrilo you will need to edit the file as well.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
#!/bin/sh
#Init Script For Ventrilo Server

#Directory where Ventrilo config files will live.  
VENTCONFIG=/srv/ventsrv 
#Most files in the Ventrilo directory start with "ventrilo_srv" by default.
VENTPREFIX=ventrilo_srv
#Path to the Ventrilo executable
VENTBIN=/srv/ventsrv/ventrilo_srv
#Path to your ventstatus file
VENTSTATUS=/srv/ventsrv
#User name to run Ventrilo under
USERNAME=ventrilo
#If your user is system user, a shell needs to be specified.  Otherwise, set this to an empty string
USERSHELL="-s /bin/sh"

. /lib/lsb/init-functions

case $1 in
    start)
        log_daemon_msg "Starting VOIP server" "ventrilo"

        su $USERNAME -c "$VENTBIN -f$VENTCONFIG/$VENTPREFIX -d" $USERSHELL
        renice -5 `cat $VENTCONFIG/$VENTPREFIX.pid`

        log_end_msg 0
    ;;
    stop)
        log_daemon_msg "Stopping VOIP server" "ventrilo"

        kill `cat $VENTCONFIG/$VENTPREFIX.pid`

        log_end_msg 0
    ;;
    restart)
        log_daemon_msg "Restarting VOIP server" "ventrilo"

        #Stop
        kill `cat $VENTCONFIG/$VENTPREFIX.pid`

        #Start
        su $USERNAME -c "$VENTBIN -f$VENTCONFIG/$VENTPREFIX -d" $USERSHELL
        renice -5 `cat $VENTCONFIG/$VENTPREFIX.pid`

        log_end_msg 0
    ;;
    status)
        PID=`cat $VENTCONFIG/$VENTPREFIX.pid`
        if [ -n "$PID" ]; then
            log_success_msg "Vent is running (pid $PID)."
            ventStatus=`$VENTSTATUS/ventrilo_status -c1 -t127.0.0.1`
            log_success_msg "$ventStatus"
            exit 0
        else
            log_failure_msg "Vent is not running."
            exit 1
        fi
    ;;
    *)
        log_success_msg "Usage: $0 {start|stop|restart|status}"
        exit 1
    ;;
esac

Save the file and exit nano. Now execute the following commands to install the init script:

1
2
sudo chmod 755 /etc/init.d/ventrilo  # Changes the file permissions to make the script executable
sudo update-rc.d ventrilo defaults  # Adds the script to the server startup sequence so Ventrilo is loaded when the server restarts

Your Ventrilo server will now start automatically when the server restarts. You also have the following commands available for you to use as needed (note you must use the full paths when using these commands):

1
2
3
4
/etc/init.d/ventrilo start   # Starts the Ventrilo server
/etc/init.d/ventrilo stop   # Stops the Ventrilo server
/etc/init.d/ventrilo restart   # Restarts the Ventrilo server
/etc/init.d/ventrilo status    # Views the status of the Ventrilo server

You can also use these commands to start/stop the server if you prefer.

1
2
3
4
service ventrilo start   # Starts the Ventrilo server
service ventrilo stop   # Stops the Ventrilo server
service ventrilo restart   # Restarts the Ventrilo server
service ventrilo status    # Views the status of the Ventrilo server

If you run into the “/etc/init.d/rc: 121 /etc/init.d/rc: /etc/rc2.d/s20ventrilo: not found” error when trying to start the server for the first time, you may need to reboot Ubuntu and try again. We recently ran into this problem when trying to upgrade to Ubuntu 16.04 and after a reboot or two it went away.

Ventrilo Won’t Automatically Restart When Ubuntu 16.04 is Rebooted

A new issue has popped up after trying to get Ventrilo working on an Ubunut 16.04 box. If we reboot Ubuntu, the Ventrilo server doesn’t automatically restart like it did in earlier versions of Ubuntu. We can go in and manually start it using service ventrilo restart and it works fine until the next reboot. We’re not sure why it’s not starting correctly on a reboot. If anyone finds a solution, let us know and we’ll update the article. It might be related to the fact that we got an “/etc/init.d/rc: 121 /etc/init.d/rc: /etc/rc2.d/s20ventrilo: not found” error while installing the startup script.

We hope you found this article useful. If you see any mistakes, missing features or ways to improve it, please let us know in the comments below so we can update its contents. If you're willing to link to us, we would sincerely appreciate it!

Corlew Solutions is a Web Design and Web Application Development company based in Fairfax Virginia, minutes away Washington D.C. If you're looking for great web design from the Northern Virginia area or web design from the Washington D.C. area we can help. Contact Us today!

comments powered by Disqus