Jump to content

Question

Good afternoon friends, I need to configure the login table and loginlog in a different database, for example:

Myserver_login: login, loginlo
Myserver_1: char, storage ..... etc
Myserver_2: char, storage ..... etc

I did this with rAthena using the "inter_athena.conf"
// MySQL Login server
Login_server_ip: 127.0.0.1
Login_server_port: 3306
Login_server_id: ***
Login_server_pw: ***
Login_server_db: ***

// MySQL Character server
Char_server_ip: 127.0.0.1
Char_server_port: 3306
Char_server_id: ***
Char_server_pw: ***
Char_server_db: ***

Etc ... I can do the same in Hercules? Thank you : )

Share this post


Link to post
Share on other sites

9 answers to this question

Recommended Posts

  • 1

I suggest using import folder:

conf/import/char-server.conf:

char_configuration: {
	sql_connection: {
		db_hostname: "127.0.0.1"
		db_port: 3306
		db_username: "username"
		db_password: "password"
		db_database: "database"
	}
}

^ equivalent to Char_server_ip/char_server_port/etc.. in rA

conf/import/login-server.conf:

login_configuration: {
	account: {
		sql_connection: { // equivalent to login_server_ip/login_server_port/etc.
			db_hostname: "127.0.0.1"
			db_port: 3306
			db_username: "username"
			db_password: "password"
			db_database: "database"
		}
		ipban: {
			sql_connection: { // equivalent to ipban_db_ip/ipban_db_port/etc.
				db_hostname: "127.0.0.1"
				db_port: 3306
				db_username: "username"
				db_password: "password"
				db_database: "database"
			}
		}
	}
}

conf/import/inter-server.conf:

 

inter_configuration: {
	log: {
		sql_connection: { // equivalent to log_db_ip/log_db_port/etc.
			db_hostname: "127.0.0.1"
			db_port: 3306
			db_username: "username"
			db_password: "password"
			db_database: "database"
		}
	}
}

conf/import/map-server.conf

map_configuration: {
	sql_connection: { //equivalent to map_server_ip/map_server_port/etc.
		db_hostname: "127.0.0.1"
		db_port: 3306
		db_username: "username"
		db_password: "password"
		db_database: "database"
	}
}

 

 

If you want all servers to use same db username/pass/database, you can instead edit conf/global/sql_connection.conf

sql_connection: {
	db_hostname: "127.0.0.1"
	db_port: 3306
	db_username: "ragnarok"
	db_password: "ragnarok"
	db_database: "ragnarok"
	//codepage:""
}

sql_connection.conf affects all server, and avoids mentioning each credentials seperately.

 

I hope it helped you and this is what you were asking for.

Share this post


Link to post
Share on other sites
  • 0
  On 6/19/2017 at 5:01 PM, meko said:

Yes, I have already looked, but I do not know how to do so that only the login is done on another server.

Database_names: {
Account_db: "login"
Login_db: "loginlog"

These need to connect to a different database from the other tables.

Because? I want to migrate my accounts from rAthena to start using Hercules, but in rAthena I used 1 account for all the servers, you know?

Share this post


Link to post
Share on other sites
  • 0

rAthena tables are not compatible with Hercules table

If what you meant is running a rAthena login server with a Hercules char + map servers that isn't compatible either

 

If you want to migrate data you will have to export to a .sql file, change the structure to match Hercules's then import in the Herc db

Share this post


Link to post
Share on other sites
  • 0
  On 6/19/2017 at 5:21 PM, meko said:

rAthena tables are not compatible with Hercules table

Only the accounts, the rest will not be migrated, and let's say I start the servers from scratch, I get all the servers log in the same database, but load the characters and all other rest?

To facilitate what I need to do ....

Server 1
Login: 172.21.0.1
Char, map, etc: 192.168.0.1

Server 2
Login: 172.21.0.1
Char, map, etc: 201.168.0.1

Is that what I need to do at Hercules too, with you? And thanks for your support so far ^^

Share this post


Link to post
Share on other sites
  • 0

Are you talking about having 2 set of server? Or using multiple database for login/char/map?

From the first post , it seems you were talking about database, but from last post, it seems you want multi map server, however, multi map server is not possible with Hercules..

If you were asking of database, it's possible to segregate the database for login/char/map server, use import folders and import your own sql_connection setting(the format is same as that of map-server.conf/char-server.conf/login-server.conf)

Share this post


Link to post
Share on other sites
  • 0
  On 6/20/2017 at 6:18 AM, Dastgir said:

Are you talking about having 2 set of server? Or using multiple database for login/char/map?

From the first post , it seems you were talking about database, but from last post, it seems you want multi map server, however, multi map server is not possible with Hercules..

If you were asking of database, it's possible to segregate the database for login/char/map server, use import folders and import your own sql_connection setting(the format is same as that of map-server.conf/char-server.conf/login-server.conf)

Exactly, I need all servers to use the same database for login, just login.

Char / map each server will have your.

By doing this, I create only one account, and I use it for all servers, just like I already do on rAthena, and the same is done on the official one.

 

Share this post


Link to post
Share on other sites
  • 0

Thanks for the help @Dastgir, it worked for the login, but the error in the ma-server when connecting in char-server.

map-server

  Reveal hidden contents

Share this post


Link to post
Share on other sites
  • 0

Sorry for the friends error, I found that using userid and passwd in the same map-server.confi file in char-server.conf works.

I had disabled them, thinking it was communicating with the database.

map-server.conf

inter: {
  // Interserver communication passwords, set in the login server database
  userid: "user"
  passwd: "pass"

char-server.conf

inter: {
  // Server Communication username and password.
  userid: "user"
  passwd: "pass"

Thanks again @Dastgir, your response worked perfectly as desired!

 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.