Jump to content
  • 0

MYSQL PORT CHANGE


Question

Posted

Hi,

IM trying to change the port that connects trow mysql and navicat, and i succefuly did it.

But when i try to start Loginserver.bat and gameserver.bat they give me a error saying there isnt a connection trow java to mysql.

 

Could anyone help me solve this problem?

 

The only missing thing is connect the new port from login/gameserver.bat to mysql/navicat.

 

Notes:

L2j Rev 7571 EP

I search the forum and there isnt a tutorial about this.....(Could anyone do it,very hellpful)

4 answers to this question

Recommended Posts

  • 0
Posted

so you installed backup the back into navicat ? ? ?

check  your server.properties

# Database Driver

 

Driver = com.mysql.jdbc.Driver
# Databese URL
DataBeseUrl = jdbc:mysql://localhost/your database name
# Databese User name
Login = root
# The Mighty password
Password = your mysql password

  • 0
Posted

make sure you have right confings

 

# ---------------------------------------------------------------------------

# Database

# ---------------------------------------------------------------------------

# Specify the appropriate driver and url for the database you're using.

# Examples:

# Driver = com.mysql.jdbc.Driver (default)

# Driver = org.hsqldb.jdbcDriver

# Driver = com.microsoft.sqlserver.jdbc.SQLServerDriver

Driver = com.mysql.jdbc.Driver

# Database URL

# URL = jdbc:mysql://localhost/l2jdb (default)

# URL = jdbc:hsqldb:hsql://localhost/l2jdb

# URL = jdbc:sqlserver://localhost/database = l2jdb/user = sa/password =

URL = jdbc:mysql://localhost/l2jdb (host name:localhost,db name: l2jdb)

# Database user info (default is "root" but it's not recommended)

Login = root

# Database connection password

Password = (put your db pass,if you dont have let it blank)

 

# Default: 100

MaximumDbConnections = 100

 

# Default: 0

MaximumDbIdleTime = 0

 

 

  • 0
Posted

so you installed backup the back into navicat ? ? ?

check  your server.properties

# Database Driver

 

Driver = com.mysql.jdbc.Driver
# Databese URL
DataBeseUrl = jdbc:mysql://localhost/your database name
# Databese User name
Login = root
# The Mighty password
Password = your mysql password

 

Thanks so much i figurid it out googling,

thanks for your fast replys

 

The fix is:

URL = jdbc:mysql://localhost/l2jdb

Instead of localhost

URL = jdbc:mysql://yourip:mysqlport/l2jdb

Example: URL = jdbc:mysql://174.120.165.10:3778/l2jdb

  • 0
Posted

Full fix for the Port edit is: (Someone might need this)

Go to Mysql Comand line Client and use this to create a username

 

CREATE USER 'Your Username'@'%' IDENTIFIED BY 'Your Password';

GRANT ALL PRIVILEGES ON *.* TO 'Your Username'@'%'  WITH GRANT OPTION;

 

CREATE USER 'Your Username'@'localhost' IDENTIFIED BY 'Your Password';

GRANT ALL PRIVILEGES ON *.* TO 'Your Username'@'%'  WITH GRANT OPTION;

 

Example:

Go to Mysql Comand line Client and use this to create a username

CREATE USER 'Dreamsonline'@'%' IDENTIFIED BY '12345';

GRANT ALL PRIVILEGES ON *.* TO 'Dreamsonline'@'%'  WITH GRANT OPTION;

 

CREATE USER 'dreamsonline'@'localhost' IDENTIFIED BY '12345';

GRANT ALL PRIVILEGES ON *.* TO 'Dreamsonline'@'%'  WITH GRANT OPTION;

This is to create a new Username in Mysql

 

You can drop username root

DROP USER 'root'@'%';

 

Reconfigure your mysql password to the password you defined in comand line.

 

Go to my.ini and change port number

Usually C:\Program Files\MySQL\MySQL Server 5.1\my.ini

# CLIENT SECTION

# ----------------------------------------------------------------------

port=3306 <----- Edit this port to the one you want

 

# SERVER SECTION

# ----------------------------------------------------------------------

# The TCP/IP Port the MySQL Server will listen on

port=3306  <----- Edit this port to the one you want

 

We are finished with Mysql

 

Now lets go to database ; for example i use Navicat

New Conection

Conection properties: fill in your information that you created in mysql comand line and port number that you edited in my.ini

 

OK now the finall part

Go to Server.properties and login.properties and change this line:

URL = jdbc:mysql://localhost/l2jdb

Change to

URL = jdbc:mysql://localhost:port ip/l2jdb

Example:

URL = jdbc:mysql://192.168.1.2:6877 /l2jdb

The 192.168.1.2 is your internal IP

The :6877 is the mysql port of server/login will listen to

 

 

Ok this might be helpfull for others,

Good luck have fun

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Posts

    • 🔥 L2Pride Interlude by DVP is NOW LIVE! 🔥 📅 Opened on June 10, 2026 at 21:00 GMT+2 ⚔️ The server is currently in the Tier 1 stage, giving everyone a fair chance to gear up and compete. 🔓 Tier 2 Items will be unlocked on June 27, 2026! ✅ Active players ✅ Stable server ✅ Competitive PvP ✅ Growing community Whether you're a solo player, clan leader, or PvP enthusiast, now is the perfect time to join and prepare for the next stage of progression. See you in-game, warriors! ⚔️ WEB: www.l2pride.ddns.net DISCORD: https://discord.gg/JVdpESC5Ry
    • Stock updates constantly. Only top items are posted on the forum. For current availability and ordering, message us on Telegram.   G2G Business 🇪🇺 EU Fully verified seller's account.   Revolut Business 🇪🇺 EU | Multi-currency IBAN, Virtual & physical cards, Instant SEPA transfers, ₿ Crypto exchange & settlements.   SumUp Business 🇬🇧 GB | POS, 1 physical card, 2 virtual cards. Payouts time: 1 day even on weekends and bank holidays, Multi-user access.   Vivid Business | Merchant POS, DE IBAN, up to 50 IBANs, SEPA Instant, unlimited transfers, up to 25 virtual and 3 physical cards.
    • 🔎 Find us: 👉🏼 Website: L2Dexter.eu 👉🏼 Discord: discord.gg/dttX9FE23W 👉🏼 Facebook: facebook.com/L2Dexter
    • G Support: https://t.me/buyingproxysup | Channel: https://t.me/buyingproxycom Discord support: #buyingproxy | Server: Join the BuyingProxy Discord Server!  Create your free account here
    • REAL PHOTOS ALWAYS «BREAK» ▪ Think a high-quality photo should be perfect? Think again. In real shots, something is almost always “off”: ▪ Noise in the shadows — especially noticeable in low light ▪ Local overexposures on highlights and glossy surfaces ▪ Loss of fine details in the brightest and darkest areas ▪ Overall “dirt” and unevenness that no editor can fully remove ▪  It’s exactly these imperfections that make the frame look alive. Algorithms already know well: a sterile clean image without these “flaws” is almost always a fake. Reality is never perfect. A fake tries to be.  Want photos that look genuinely “broken,” like they were taken on a real phone? Write to us — we’ll make even the flaws work in your favor. › TG: @mustang_service_ms ( https:// t.me/ mustang_service_ms ) › Channel: Mustang Service ( https:// t.me/ +JPpJCETg-xM1NjNl ) #documents #drawing #photoshop #verication #fake
  • Topics

×
×
  • Create New...

Important Information

This community uses essential cookies to function properly. Non-essential cookies and third-party services are used only with your consent. Read our Privacy Policy and We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue..