Linux Server. Very easy guide

Verno

New member
Messages
8
Points
0
This guide may not look very nice. Without git. Just for quick testing. Very small and easy quide. For those who will do this for the first time.

========SERVER==================================
1. Install Ubuntu Server (on virtual machine or whatever you want)
1.1 sudo apt-get update && dist-upgrade (updates for server)
1.2 apt-get install libmysqlclient-dev zlib1g-dev libpcre3-dev build-essential unzip (libraries for comliping and other)
1.3 sudo apt-get install mysql-server mysql-client (MYSQL)
    CREATE USERNAME AND PASSWORD FOR MYSQL
1.4 username password

(You can use "hercules hercules")

========CONFIGURE NETWORK=======================
sudo nano /etc/network/interfaces

    ADD OR CHANGE (example)
dhcp -> static
address 192.168.1.254
netmask 255.255.255.0
gateway 192.168.1.1
dns-nameservers 192.168.1.1

save end exit from "nano" editor:
Ctrl + X than Y
Ctrl + X will quit the editor and you will be asked if you want to save your changes. If you do, press Y for "Yes".

reboot

========== clean & reinstall mysql==============
    in case of unforeseen situations with mysql. If all is OK, just leave this part.
sudo apt-get remove --purge mysql-\*
sudo apt-get install mysql-server mysql-client

========CONFIGURE SAMBA TO SHARE FOLDER=========
    Just for easy operation from Windows. Copy files, edit or something else. If somebody need this.

sudo apt-get install samba
sudo nano /etc/samba/smb.conf

In the end of file add this:

[share]

comment = Hercules
path = /home/username/hercules
browsable = yes
guest ok = yes
read only = no
create mask = 0755

save end exit -> Ctrl + X -> Y

In Windows type this in the address bar:
\\192.168.1.254\share\
================================================

Copy and extract your Hercules-master.zip file to /home/username/

You will get something like this:
/home/username/hercules

================================================
    CONFIGURE MYSQL (The symbol ' not the same as " )
2. mysql -u root -p
    enter username and password (from part 1.4)

2.1 CREATE DATABASE hercules;
    Define the username. "hercules" is an example. Same with "password"
2.1 CREATE USER 'hercules'@'%' IDENTIFIED BY 'password';
2.3 GRANT ALL PRIVILEGES ON hercules.* TO 'hercules'@'%';
2.3.1 quit
    ADD SQL files to Hercules base
2.4 mysql --user=root -p hercules < hercules/sql-files/main.sql
(and others, I usually add only main files that are - main.sql and logs.sql (this is minimum that required))
2.5 sudo service mysql restart
    GIVE PERMISSIONS TO HERCULES FOLDER
2.5.1 chown -R username hercules/
2.5.2 chmod -R 777 hercules/
2.5.2 ls -l (look permissions)
2.6 ./configure

    COMPILE HERCULES SERVER
2.7 make clean && make sql (for hercules)
make clean && make server (for rathena)
    FROM "hercules" folder
2.8 ./athena-start start (stop, restart) ONLY AFTER CONFIGURING:

EXAMPLE:
hercules\conf\char\char-server.conf
login_ip: "192.168.1.254"
char_ip: "192.168.1.254"

hercules\conf\map\map-server.conf
char_ip: "192.168.1.254"
map_ip: "192.168.1.254"

hercules\conf\global\sql_connection.conf
db_hostname: "192.168.1.254"
db_port: 3306
db_username: "hercules"
db_password: "hercules"
db_database: "hercules"

================================================
    MAPCACHE
make plugin.mapcache

    make .MCACHE files
./map-server --load-plugin mapcache --map mapname
(with full path to map or add map files to "hercules\data")

expample:
./map-server --load-plugin mapcache --map 1@air1
.mcache files will automatically add to hercules\maps\re

    HELP
./map-server --load-plugin mapcache --help

BR :innocent:

 
Last edited by a moderator:
Back
Top