How To Install Just Cause 2 (JC2-MP) Server on CentOS 7

In this tutorial we'll learn how to setup a Just Cause 2 multiplayer server.

Prerequisites

Please be sure the system is fully updated before we get started. Afterwards we'll be creating a new user for the server. Make sure to use a password that is tough!

yum update -y
adduser jcmp
passwd jcmp

Let us also open the necessary firewall ports.

firewall-cmd --zone=public --add-port=7777/udp --permanent
firewall-cmd --reload

Now we can install the required libs to run SteamCMD.

yum install glibc.i686 libstdc++.i686 -y

Switch to the user that we just created.

su jcmp
cd ~

Time to download SteamCMD.

wget https://steamcdn-a.akamaihd.net/client/installer/steamcmd_linux.tar.gz
tar xf steamcmd_linux.tar.gz

Run SteamCMD and install the server files.

./steamcmd.sh +login anonymous +force_install_dir ./jcmp +app_update 261140 validate +quit

Upon success, the screen will read Success! App '261140' fully installed..

Customizing The Server

Want to customize the name, description and also the slots of the server?

To change the name of your server, edit the file default_config.lua.

nano ~/jcmp/default_config.lua

To change the name of your server, go to line 28 and change JC2-MP Server to your liking. I suggest that you change the playercount and set an admin password also, to minimize the potential lag on your server, and to administrate it correctly.

When you're done editing the config, rename it to config.lua.

mv default_config.lua config.lua

Updating Your Server

When its time to update your server, because of Steam updates, there is an easy solution. First, create the file update_jcmp.txt.

nano /home/jcmp/update_jcmp.txt

Populate the following data.

login anonymous
force_install_dir ./jcmp
app_update 261140
quit

Now, to update your server, simply run the following command:

cd ~
./steamcmd.sh +runscript update_jcmp.txt

Running Your Server

Navigate to the following folder and run your server.

cd /home/jcmp/jcmp
screen -dmS jcmp ./Jcmp-Server

The server is now running in the background. To shut down the server, use the following command:

screen -S jcmp -X quit

And that's it! Enjoy your server!

  • Linux Guides, Game Servers, CentOS
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Setup Ragnarok Online Server on Ubuntu 14.04 x64

In this article, we are going to setup a Ragnarok Online Server on Ubuntu 14.04 x64. You can be...

Setting up a Name Server for IPv6 rDNS in CentOS

Managing your own IPv6 rDNS is a fairly simple task. After setting up the name server, please...

Reset the Root Password in CentOS

If you have forgotten the root password it is possible to set a new one by interrupting the boot...

How to Install and Configure vsftpd on CentOS 7

FTP (File Transfer Protocol) is one of the most popular methods to upload files to a server....

How to enable EPEL repository?

The EPEL repository is an additional package repository that provides easy access to install...