[Tutorial] Setting up your ASECO server (local database)

Answers to the most commonly asked questions with both user created and official tutorials

Moderator: TM-Patrol

Post Reply
Crusard

[Tutorial] Setting up your ASECO server (local database)

Post by Crusard » 13 Oct 2006 15:27

I've been through a lot of trouble to get my local database server running, and I would have loved to see a tutorial about this somewhere. This may or nor work, depending on your system configuration, but it will if you have a standard pc config.
Hopely someone can find this tutorial useful, it took a lot of time to figure everything out by myself without any knowledge of databases or anything :P
Ok enough chat, here goes.


1) Download ASECO, and install/unzip it to a folder of your choice (preferably in a new folder within your Trackmania directory)

2) Download Xampp and install it to the default folder (Program Files, unless you know what you're doing). Install all options (Apache, Mysql are the most important ones). Once the installation is finished, the Xampp Control Box should open, but close it for now.

3) Now we have to configure Aseco.
Go to your ASECO folder, and right-click on Aseco.bat, then click on Edit. The file should open in wordpad or notepad.
Where it says set INSTPHP=C:\Programme\Apache2\Php5 change the location to C:/Program Files/xampp/php (Unless you didn't install Xampp in the default directory). Now save and exit.

Now right-click on the file config.xml, and Edit. There's a lot of things you can change and customize here, but I'll only explain the ones necessary to get your aseco server running (for further information check the ReadMe.pdf file).
Find the <tmserver> part and set your login and password to the ones in your dedicated server's config. Also make sure your IP and port (usually 5000) are correct (Normally, you don't need to change this). Remember that 127.0.0.1 is the same as localhost (The dedicated server is hosted on your pc).
After you're happy with your config, save and exit.

Again, right-click and Edit the file plugins.xml. Right before the final line (</aseco_plugins>) enter a space and add the following line: <plugin>plugin.localdatabase.php</plugin>
Save and exit.

One last file to edit, open localdatabase.xml. Set your mysql login and password (We haven't really created our mysql "account" yet, but we will soon when we configure it). set your databasename (<mysql_database>) to aseco. Then change <display> from false to true.
The file should look like this
<?xml version="1.0" encoding="utf-8" ?>
<settings>
<!-- MySQL Server Settings -->
<mysql_server>localhost</mysql_server>
<mysql_login>MyCrazyLogin</mysql_login>
<mysql_password>MyCrazyPassword</mysql_password>
<mysql_database>aseco</mysql_database>
<!-- Do you want Aseco to display the records? -->
<display>true</display>
</settings>
(Remember that 127.0.0.1 = localhost)
Now save and exit.

4) And now the "complicated" part. Let's configure our local database.
First go to the following folder in your hard drive: C:/Program Files/Xampp/mysql/bin (Unless you installed Xampp in a different directory) and open winmysqladmin.exe. Set your login and password to the ones you selected when configuring localdatabase.xml (MyCrazyLogin, in the example).
Then once you created your mysql "account" you can just close the program.

Now open your Xampp Control Pannel to make sure all the necessary database applets are running (You can run it from your start menu).
Open a browser window (Internet Explorer, firefox, etc) and enter the address: http://localhost (Or just click here!)
You will have entered your Xampp control board. In the navigation menu on your left, click on the PHPmyadmin link.
When the page loads, notice there's a space below "Create new Database". Type aseco and click on Create.
Now find the button that says import (It's in the upper menu bar), then click on Browse.... There's a file in the /Aseco/localdb directory, called aseco.sql, select it. Ignore all the options you're given, and click on Continue.
If everything worked well, you should see a long paragraph of code, and a message confirming that the data was added successfully. If that doesn't happen and a line saying that there was an error, just go back and try again (Trying again worked for me, can't explain why exactly).


5) Now it's time to run aseco. First start your dedicated server (You can also use ServerMania if you want). Once it's ready, go to your ASECO directory and run Aseco.bat. Aseco should be able to find your server and "attach", unless you inserted the wrong IP or ports (I use 5225 instead of the default 5000, for example). If aseco can find your server, then you should see the line (ASECO) Connection established successfully!. Then aseco will try to connect to your local database (The one you created with Xampp). If everything goes well, aseco will be running on your server.

I hope this can be useful to somebody!
Last edited by Crusard on 13 Oct 2006 16:10, edited 1 time in total.

Zooz
TM-Patrol
TM-Patrol
Posts: 5326
Joined: 13 Aug 2005 08:58
Owned TM-games: TMO, TMS, TMNF, TMUF
Manialink(s): zooz
Location: The Netherlands

Post by Zooz » 13 Oct 2006 15:53

Thanks! So that means setting up a local database is not totally impossible? :P
I should try that soon, already have Xampp... Nice tutorial.

User avatar
RavenZero
swift roadking
swift roadking
Posts: 747
Joined: 08 Jul 2006 06:22
Owned TM-games: TMS, TMN & TMU
Location: Santa Catarina
Contact:

Post by RavenZero » 13 Oct 2006 15:53

Great! Finally a complete tutorial about setting up the ASECO into local dbase.

I would like to :award: it! :P

@Zooz: Geez, you're fast! :shock:

User avatar
robert1
speedy pilot
speedy pilot
Posts: 414
Joined: 13 Aug 2005 07:55
Owned TM-games: TMO TMS TMN TMU
Location: ashford/kent
Contact:

Post by robert1 » 24 Oct 2006 12:57

i get this

[Aseco] Load plugin [chat.admin.php]
[Aseco] Load plugin [chat.help.php]
[Aseco] Load plugin [chat.me.php]
[Aseco] Load plugin [chat.records.php]
[Aseco] Load plugin [chat.stats.php]
[Aseco] Load plugin [chat.vote.php]
[Aseco] Load plugin [plugin.localdatabase.php]
[Aseco] Try to connect to server on 127.0.0.1:5225
[Aseco] Authenticated with username 'Robert187' and password '*******'
[Aseco] Connection established successfully!
[Local DB] Load settings file ...
[Local DB] Try to connect to MySQL server
[PHP Warning] mysql_connect(): Access denied for user 'Robert'@'localhost' (using password: YES) on line 59 in file C:\Program Files\TmSunrise\aseco_061b\plugins\plugin.localdatabase.php
[ASECO Error] [Local DB] Could not authenticate at MySQL server! on line 60
CPU: Intel i7 3.40 GHz
Memory: 6GB DDR3
HDD: 500GB
Optical: Super Multi Double Layer DVD+RW drive
Grapichs: Asus GeForce GTX 580 1536MB GDDR5
OS: Microsoft Windows 7 Premium 64bit
Over Clockers UK: "Titan Goliath" Intel Core i7 920

User avatar
henrik180
pedestrian
pedestrian
Posts: 8
Joined: 09 Aug 2006 21:28
Contact:

Post by henrik180 » 27 Oct 2006 14:43

hi, i need alot of help...
anyone can help? add henriksive@hotmail.com to msn
thx

User avatar
henrik180
pedestrian
pedestrian
Posts: 8
Joined: 09 Aug 2006 21:28
Contact:

Post by henrik180 » 28 Oct 2006 09:44

got the same problem as robert.... plz..anyone can aswer??

Crusard

Post by Crusard » 28 Oct 2006 14:01

Looks like it has something to do with your mysql account. Make sure the password and username match the ones you created in your mysql thing. Try opening winmysqladmin.exe (The traffic lights on your taskbar) and go to the my.ini Setup tab. There should be something like this:

Code: Select all

#This File was made using the WinMySQLAdmin 1.4 Tool
#13/10/2006 09:19:59 a.m.

#Uncomment or Add only the keys that you know how works.
#Read the MySQL Manual for instructions

[mysqld]
basedir=C:/Archivos de programa/Xampp/mysql
#bind-address=111.222.333.444
datadir=C:/Archivos de programa/Xampp/mysql/data
#language=C:/Archivos de programa/Xampp/mysql/share/your language directory
#slow query log#=
#tmpdir#=
#port=3306
#set-variable=key_buffer=16M
[WinMySQLadmin]
Server=C:/Archivos de programa/Xampp/mysql/bin/mysqld-nt.exe
user=CrusardTestLogin
password=CrusardTestPassword
Make sure the last two lines show the username (login) and password you especified in localdatabase.sql.

MichaelMH
pedestrian
pedestrian
Posts: 7
Joined: 22 Oct 2006 10:54
Location: GBR
Contact:

Post by MichaelMH » 29 Oct 2006 15:18

Hi, Brilliant Tutorial but I too am having the same problems the other two people are. I've verified that my login settings match with the .ini file and it still dosnt work =/

I'm gonna trinker around with it for a while. I'll post back if I find a solution
MichaelMH :mrgreen:

Crusard

Post by Crusard » 31 Oct 2006 12:14

MichaelMH wrote:Hi, Brilliant Tutorial but I too am having the same problems the other two people are. I've verified that my login settings match with the .ini file and it still dosnt work =/

I'm gonna trinker around with it for a while. I'll post back if I find a solution
Please do :wink:

Brobak
wheelbarrow operator
wheelbarrow operator
Posts: 16
Joined: 02 Nov 2006 19:54
Contact:

Post by Brobak » 02 Nov 2006 20:02

If you guys find a solution then please let us know :) I have the same problem.

Brobak
wheelbarrow operator
wheelbarrow operator
Posts: 16
Joined: 02 Nov 2006 19:54
Contact:

Post by Brobak » 04 Nov 2006 16:03

looks like I got a bit further in the process

Didnt seem like that we created the login and password the correct way, because I could log in with user root without a password.

Now I seem to have a new error.

# initialize ASECO ############################################################
[Aseco] Load settings [config.xml]
[Aseco] Load plugin [chat.admin.php]
[Aseco] Load plugin [chat.help.php]
[Aseco] Load plugin [chat.me.php]
[Aseco] Load plugin [chat.records.php]
[Aseco] Load plugin [chat.stats.php]
[Aseco] Load plugin [chat.vote.php]
[Aseco] Load plugin [plugin.localdatabase.php]
[Aseco] Try to connect to server on 127.0.0.1:5000
[Aseco] Authenticated with username 'SuperAdmin' and password 'SuperAdmin'
[Aseco] Connection established successfully!
[Local DB] Load settings file ...
[Local DB] Try to connect to MySQL server
[Local DB] Synchronize players with database
###############################################################################
# Aseco v0.6.1b running on 127.0.0.1:5000
# Game : TmNationsESWC - TimeAttack
# Author: Florian Schnell
###############################################################################
[RPC Error -1000] Command reserved.
Array
(
[0] => AddChatCommand
[1] => Array
(
[0] => stats
)

)
[RPC Error -1000] Command reserved.
Array
(
[0] => AddChatCommand
[1] => Array
(
[0] => score
)

)
[11/04,16:24:31] map changed [none] >> [F-1]
[11/04,16:24:31] no votings available for this track
[11/04,16:24:31] currently no record on F-1

anyone who can help me with this?

Brobak
wheelbarrow operator
wheelbarrow operator
Posts: 16
Joined: 02 Nov 2006 19:54
Contact:

Post by Brobak » 11 Nov 2006 09:56

found my problem, it was just an old version of dedicated server that caused my problem.

User avatar
oliverde8
solid chaser
solid chaser
Posts: 1135
Joined: 07 Oct 2006 07:03
Owned TM-games: TMU
Manialink(s): oliverde8
Location: Turkey
Contact:

Post by oliverde8 » 13 Nov 2006 16:38

robert1 wrote:i get this

[Aseco] Load plugin [chat.admin.php]
[Aseco] Load plugin [chat.help.php]
[Aseco] Load plugin [chat.me.php]
[Aseco] Load plugin [chat.records.php]
[Aseco] Load plugin [chat.stats.php]
[Aseco] Load plugin [chat.vote.php]
[Aseco] Load plugin [plugin.localdatabase.php]
[Aseco] Try to connect to server on 127.0.0.1:5225
[Aseco] Authenticated with username 'Robert187' and password '*******'
[Aseco] Connection established successfully!
[Local DB] Load settings file ...
[Local DB] Try to connect to MySQL server
[PHP Warning] mysql_connect(): Access denied for user 'Robert'@'localhost' (using password: YES) on line 59 in file C:\Program Files\TmSunrise\aseco_061b\plugins\plugin.localdatabase.php
[ASECO Error] [Local DB] Could not authenticate at MySQL server! on line 60
I have exactly the same thing I check the log in is correct what do I Do
-I use servermania v086 :?:
ImageImage
Manialink : oliverde8color>
Servers : STATS <> United | VeryShort | Made In Turkey

Kopatch
cyclist
cyclist
Posts: 40
Joined: 21 Nov 2006 23:38
Contact:

Post by Kopatch » 21 Nov 2006 23:47

hey guys, i dont know if you solved yet or not.
but i digged into it abit and found something that helped me...
now im not a programmer in anyway, so if what im saying might risk ones computer please tell me and ill edit, cause i really have no idea whats the stuff i changed actually made :| i just know it made mine work...

so basicly after brobak said he could log in with "root" user without password i also tryed.
i change the Username in my.ini and in localdatabase.xml to "root" (without the " ) and deleted the password i put in, and it worked.
but because i believe any login must have a password just like i looked where i can change it, so i went in my browser got in the localhost or 127.0.0.1 to access mysql. over there i switched to Security on the left menu, a new window should open and on the bottom you have a link to: http://localhost/security/xamppsecurity.php
get in that.

now over here you can input a new password on the top, dunno whats that on the bottom so dont mess with it....

anyway after i made a new pass i put it in the My.ini and in Localdatabase.xml and it worked.

anyway, do it on your on risk tho it dosent look so harmfull :)

hope i helped

bb
p.s and if someone knows how to change user name it might be also helpfull :D tx alot.

lobzore
pedestrian
pedestrian
Posts: 5
Joined: 06 Dec 2006 18:26
Location: Netherlands

The Solution ;)

Post by lobzore » 07 Dec 2006 14:00

Because I have some experience with databases I found the problem in just a few seconds.
It's só simple that it scared me ;)

The one above this post has the easy solution, but this one is the most secure and normal.

Okay this is what you do:
Go to your PHPMyAdmin (http://localhost/phpmyadmin/ or http://localhost and then click on 'PHPMyAdmin)
Then select your 'aseco' database from the list in the left sidebar.
In your main screen click on a button at the top right corner, called 'rights'.
As you see, you have only one user in the database called 'root'. We have to make one with the settings of your config file of Aseco.
To do this click on the little edit button behind your 'root' user.
Scroll down when the page is loaded, till you see something like 'edit user information'.
Edit 'root' to the username you have put in the config file of Aseco.
Leave 'localhost' as it is.
At 'password' choose in the menu to use the textfield or something similar to it (I've got the dutch version, so I don't know how it's translated in English) and
type your chosen password there. Then in the next field you have to repeat your password.

Now just click on 'start' at the bottom of the page.

If everything went fine you get a confirmation of the add of an user to the database aseco.

Good luck and have fun with your server :D
And I'm sorry for my poor english but I guess you are able to understand it...

Post Reply