This is a tutorial explains how to install a Multi Theft Auto server on Debian. It was last updated for Debian 7 and MTA 1.5.4.
Any VPS from AKLWEB Host is great for an MTA server, whether it’s just a private server for friends or development, to a server that will host lots of people 24/7.
For a development server or a server for your friends, I would recommend the lowest-end VPS (768 MB ram). The more people you are hosting, the bigger the server you would get (obviously).
Lets get started!
Credit goes to jhxp on the Multi Theft Auto forums for the majority of the steps in this tutorial. I have just added the links for 1.4.0 and changed a few things to make it shorter.
These packages must be installed before the MTA server.
For 32-bit Debian:
apt-get update; apt-get upgrade; apt-get -y install zip unzip libreadline5 screen
For 64-bit Debian:
apt-get update; apt-get upgrade; dpkg --add-architecture i386; #add the i386 architecture so the ia32-libs package can be installed apt-get update; #update the list of packages so the ia32-libs package is included in the list apt-get -y install zip unzip ia32-libs lib32ncursesw5 lib32readline5 screen
- We have installed the appropriate packages needed.
- We have added support for the i386 architecture on 64-bit systems.
Installing Multi Theft Auto
Do the steps listed below, one at a time:
cd ~; mkdir mtasa; cd mtasa; wget -O mtasa-linux-server.tar.gz http://linux.mtasa.com/dl/154/multitheftauto_linux_x64-1.5.4.tar.gz; wget -O baseconfig.tar.gz http://linux.mtasa.com/dl/154/baseconfig-1.5.4.tar.gz; wget -O mtasa-resources.zip https://mirror.mtasa.com/mtasa/resources/mtasa-resources-latest.zip; tar -zxf mtasa-linux-server.tar.gz; mv multitheftauto_linux_x64-1.5.4 mtasa-server; unzip -q mtasa-resources.zip -d mtasa-server/mods/deathmatch/resources/; tar -zxf baseconfig.tar.gz; #uncompress default server configuration files mv baseconfig/* mtasa-server/mods/deathmatch; rmdir baseconfig; rm mtasa-linux-server.tar.gz baseconfig.tar.gz mtasa-resources.zip;
- We have made a directory called
- Then, we have downloaded everything that we need.
- Then, we have unzipped and uncompressed all of the downloaded files and put them where they needed to go.
- And finally, we have deleted the old downloaded files since we don’t need them anymore.
Configuring the Server
Run the following commands:
cd ~; cd mtasa/mtasa-server/mods/deathmatch; nano mtaserver.conf;
- We have gone back to the main directory, then gone to the directory where the config file is located.
- Then, we have opened up the config file in nano.
Now, we can configure our server. All that you really need to configure in this step is the server name, the amount of slots the server can have (default is 32), and what resources it will run upon start-up. To configure your server, make any changes to the
mtaserver.conf file in
nano that you deem necessary. Once you have finished, hold CTRL and press O, then type y to save.
Running the Server
Run the following commands:
cd ~; cd mtasa/mtasa-server/; ./mta-server;
- Basically, go to your main directory, then go to
- Then, do
./mta-serverto start your server.
If everything is working, the MTA console should be displayed. The server will print a message stating that it is ready to accept connections.
There you go – you now have a fully working Multi Theft Auto 1.4.0 server that is ready for players!
At this point, the server is running. Once you exit the shell though, the server will stop. To keep it running when you have exited the shell, run the following commands:
cd ~; cd mtasa/mtasa-server/; screen -dmS mtasa ./mta-server;
- We have gone to the
- This time, we have started the server with screen and called it
mtasa(This can be whatever you want).
To view your server, run screen with the process ID of the server:
screen -r PROCESS_ID
You can find the process ID of your server by running this command:
Your server will appear with the ID being the first number next to what you called the screen (Example: 1231.mtasa).
To exit the screen, hold down CTRL, then press A and D at the same time to exit. If you are using a shell program, such as PuTTY, then you can just close PuTTY.
To stop the server, go into the screen and type
quit in the server console.
If the server has crashed, then get the screen ID and run:
kill <id> or
kill -9 <id>.
Enjoy your new MTA server!