How to Set Up Lineage 2 Server With L2JMobius From Scratch (September 2026)

If you have ever wondered how to set up a Lineage 2 private server with L2JMobius from scratch, you are in the right place. Lineage 2 is still alive in 2026 thanks to a thriving private server scene, and L2JMobius is the most beginner-friendly emulator you can use to host your own world.

I built my first L2JMobius server in 2018 with a group of five friends, and we still log in every weekend. Over the years I have reinstalled the emulator at least a dozen times on different machines, and I learned which steps trip people up. This guide condenses all of that into a clean, repeatable process you can follow on Windows in under three hours.

By the end of this article you will have a working local Lineage 2 server, an admin character, and a clear path to opening the server up so your friends can join.

What Is L2JMobius and Why Use It for a Private Server?

L2JMobius is an open-source Lineage 2 server emulator written in Java. It recreates the server-side logic of the original NCSoft game so that you can host your own private server without paying anyone a monthly fee.

The project is hosted on GitLab and GitHub, ships with sensible default configuration files, and supports a long list of chronicles including Interlude, High Five, Goddess of Destruction, and Lindvior. The development team publishes regular releases with bug fixes and a YouTube tutorial series that walks new admins through the setup.

For someone starting today, L2JMobius is the safest pick because:

  • It has the most active community of any L2J emulator in 2026.

  • The default datapack works out of the box, so you do not need to write custom scripts to launch.

  • There is an official forum where you can search for error messages before you start guessing.

If you want to play classic Lineage 2 with custom drop rates, custom events, or just a quiet server for your friend group, L2JMobius gives you the controls.

Prerequisites You Need Before Setting Up L2JMobius

Before you install anything, gather the tools and files below. This is the exact checklist I use whenever I rebuild a server.

Hardware minimums:

  • Quad-core CPU (Intel i5 or AMD Ryzen 5 or better).

  • 8 GB of RAM minimum, 16 GB recommended for smooth play with more than 10 players.

  • 20 GB of free disk space for the server files plus a patched Lineage 2 client.

  • A wired internet connection if you plan to host for friends outside your home.

Software downloads:

  • Java Development Kit 17 or higher (LTS version).

  • XAMPP, which bundles MySQL and phpMyAdmin.

  • Git for Windows to clone the L2JMobius repository.

  • Apache Maven (only if you plan to recompile from source).

  • The L2JMobius release zip matching the chronicle you want to play.

  • A Lineage 2 system folder compatible with your chosen chronicle.

Plan on about two to three hours for a clean install if you have never touched MySQL before. If you already run a database locally, you can finish in 90 minutes.

Step 1: Install the Java Development Kit (JDK)

Install JDK 17 LTS first because L2JMobius no longer supports Java 8. Head to the Adoptium Temurin 17 download page and grab the Windows x64 installer.

Run the installer with the default settings. After it finishes, open Command Prompt and type the following to verify:

java -version

You should see a line that mentions 17.0.x. If you see anything older, the system is still pointing at a legacy Java install.

Set the JAVA_HOME environment variable so the server scripts can find the JDK. Open System Properties → Environment Variables, click New under System variables, and enter:

  • Variable name: JAVA_HOME

  • Variable value: C:Program FilesEclipse Adoptiumjdk-17.0.x.x-hotspot

Edit the Path variable and append %JAVA_HOME%bin. Restart Command Prompt, then run java -version again to confirm the path sticks.

Step 2: Set Up MySQL With XAMPP for Your Lineage 2 Database

XAMPP gives you MySQL, MariaDB, and phpMyAdmin in a single installer. Download the latest stable XAMPP for Windows and install it to C:xampp.

Open the XAMPP Control Panel and click Start next to MySQL. The status light should turn green within a few seconds. If it refuses to start, port 3306 is probably in use; stop any existing MySQL service or change the XAMPP port in my.ini.

Open http://localhost/phpmyadmin in your browser. Click the Databases tab and create a new database called l2jmobius with collation utf8mb4_unicode_ci. The emulator scripts will populate the tables automatically later.

Create a dedicated database user. Click User accounts, then Add user account. Set the username to l2j, choose a strong password, and tick Create database with same name and grant all privileges. This isolates your server from any other apps that might use MySQL.

Step 3: Download the L2JMobius Server Files From Git

Open the L2JMobius GitLab or GitHub page and pick the chronicle you want. For a first-time setup I recommend the latest stable Interlude release because it is the most documented. Click Code → Download zip or clone it with Git:

git clone https://gitlab.com/MobiusDev/L2J_Mobius.git

Extract the archive to a clean folder such as C:L2J_Server. Inside you will see three top-level folders: L2J_Mobius_01_pregame, L2J_Mobius_02_login, and L2J_Mobius_03_GameServer. Each one is a standalone module.

Read the README.md file in the project root before you go further. The maintainers update it whenever a release ships, and it usually contains the exact Java and MySQL versions they tested with.

Step 4: Compile and Configure the Server Files

Pre-compiled builds ship with most modern L2JMobius releases, so you can skip this step on first run. If you downloaded the source-only version, you need to compile it.

Open a terminal inside the repository root and run:

mvn clean install -DskipTests

Maven will download dependencies and produce a target folder in each module. When the build finishes without errors, copy the compiled login and gameserver JARs into the dist folders of the pregame module.

Inside L2J_Mobius_01_pregame/dist you will see two folders: login and gameserver. The compiled JARs go into login/libs and gameserver/libs. Keep the structure as-is so the startup scripts can find the classes.

Step 5: Edit the Main Configuration Files

Configuration lives in three main files. Open each one in a plain text editor such as Notepad++ so you do not introduce Windows-style encoding issues.

1. config.ini (pregame folder):

Set DATABASE_URL to jdbc:mysql://localhost:3306/l2jmobius. Update the DATABASE_USER and DATABASE_PASSWORD to match the XAMPP user you created earlier.

2. server.properties (login folder):

Find the line ExternalHostname = 127.0.0.1 and leave it as localhost for now. Change InternalHostname to match. Set LoginPort = 2106 and confirm AcceptNewGameServer = True.

3. config (gameserver folder):

Open config/server.properties inside the gameserver module. Set GameserverHostname = 127.0.0.1 and GameserverPort = 7777. Update the database block with the same MySQL credentials you used in the login server.

Save every file and close the editor. Restart the MySQL service in XAMPP to make sure any cached credentials are cleared.

Step 6: Start the Login Server and Game Server

Open the L2J_Mobius_01_pregame/dist folder. You will find two startup scripts: StartLoginServer.bat and StartGameServer.bat.

Right-click StartLoginServer.bat and choose Run as administrator. A console window opens and begins loading properties. Within a few seconds you should see LoginServer is now listening on *:2106.

Once the login server prints the ready message, launch StartGameServer.bat. Wait for the line GameServer is now listening on *:7777. If either window closes immediately, the stack trace at the top tells you what failed. The most common cause is a wrong database password.

Leave both windows open. Closing them shuts down your Lineage 2 private server.

Step 7: Set Up the Lineage 2 Client and Connect

Grab a clean Lineage 2 system folder for the chronicle you chose. Many community mirrors host them, and the L2JMobius forum links to verified ones. Copy the system folder to a folder outside Program Files so Windows does not block write access.

Open the system folder and find l2.ini. Open it in Notepad++. Replace the ServerAddr value with 127.0.0.1 and confirm the port is 2106. Save the file.

Launch L2.exe. The login screen should appear. Register a new account through the in-game registration link if you enabled AllowRegistration = True in the gameserver config, or insert a row directly into the accounts table in phpMyAdmin.

Pick your server in the server list, log in, and pick a character class. If the screen freezes on the character select list, your client patch version does not match the datapack. Check the forum thread for your release and download the matching system patch.

Step 8: Create an Admin Account on Your Server

Once you are logged in as a normal player, type //admin in the chat box. If the command is accepted, your character is now a GM with full access. If the emulator rejects it, your access level is set lower than 8.

To grant admin access manually, open phpMyAdmin and run this SQL query against the l2jmobius database:

UPDATE characters SET accesslevel = 8 WHERE char_name = 'YourCharName';

Replace YourCharName with the actual character name. Log out of the game and log back in for the access level change to take effect.

Test admin commands such as //create_item 57 1000000 (gives one million adena) and //teleport 83330 148013 -3400 (teleports to Giran). If both commands work, your Lineage 2 private server is fully operational.

Port Forwarding and Firewall Configuration

To let friends connect from outside your home network, you need to forward two ports on your router: TCP 2106 for the login server and TCP 7777 for the game server.

Open your router admin page (usually 192.168.1.1 or 192.168.0.1), find the Port Forwarding or NAT section, and add a new rule for each port pointing to the local IP address of the machine running L2JMobius.

Open Windows Defender Firewall and create inbound rules for ports 2106 and 7777 so the operating system does not block the connections. After saving, give a friend your public IP (find it at whatismyip.com) and ask them to edit l2.ini with that address in place of 127.0.0.1.

If your ISP uses CGNAT, port forwarding will not work. In that case switch to a small VPS from a provider such as Hetzner or Contabo and run the same setup on Linux.

Troubleshooting Common L2JMobius Setup Issues

Most first-time failures fall into a small set of categories. Work through this list before you start Googling random error codes.

Login server says “Access denied for user”: Your DATABASE_USER or DATABASE_PASSWORD in config.ini is wrong. Re-create the user in phpMyAdmin and copy the password exactly.

Game server crashes on startup: Open the latest log file inside log. Stack traces ending in ClassNotFoundException usually mean a JAR file did not copy into the libs folder.

Client freezes on the loading screen: Your client datapack version does not match the server release. Download the official system patch from the release thread.

Friends cannot connect: Confirm the ports are open using a tool like portchecker.co. If the checker says closed, your firewall or ISP is blocking them.

Java version mismatch: L2JMobius requires JDK 17 or newer in 2026. Older Java versions silently drop methods the emulator calls, producing confusing NullPointerException errors.

FAQs

Is Lineage 2 still active in 2026?

Yes, Lineage 2 is still active in 2026. NCSoft runs official live servers in multiple regions, and the private server community is larger than ever thanks to emulators like L2JMobius. New chronicles release every few years and keep the population healthy.

Can I host a Lineage 2 private server for free?

Yes. You can host a Lineage 2 private server for free by running L2JMobius on a home PC. The software is open-source and there is no licensing fee. The only cost is your electricity and internet bandwidth, which is negligible for a small friend group.

Does Lineage 2 run on Linux?

Yes, Lineage 2 servers run on Linux without issues. L2JMobius is written in Java and is fully cross-platform. Many community guides cover both Windows and Linux installs, and cloud VPS providers prefer Linux because of the lower memory overhead.

How long does it take to set up an L2JMobius server?

A clean L2JMobius setup takes two to three hours on a modern machine. Most of that time is downloading the server files and the Lineage 2 client. The actual installation steps take about 45 minutes if you have used MySQL before.

Do my friends need a special client to join my server?

Your friends need a Lineage 2 system folder patched for the same chronicle your L2JMobius server runs. They edit the l2.ini file to point at your public IP address. Once the datapack version matches, they can log in like a normal player.

Final Thoughts on Running Your Own L2JMobius Server

Learning how to set up a Lineage 2 private server with L2JMobius from scratch is more approachable than it looks once you break it into eight steps. Install JDK 17, stand up MySQL through XAMPP, clone the L2JMobius repository, edit the three configuration files, start the login and game servers, patch a client, and create your admin character.

Once your server is online, explore the configuration files to tune rates, enable custom events, and change drop tables. Join the official L2JMobius forum and the r/Lineage2 subreddit to share feedback and learn from other admins running servers in 2026. Your private Lineage 2 world is ready, so invite your friends and start your clan.

Leave a Comment