Anope IRC Services

Please login or register.

Login with username, password and session length
Advanced search  

News:

Pages: [1]   Go Down

Author Topic: Problems using MySQL and Anope on Ubuntu 10.04  (Read 13131 times)

0 Members and 1 Guest are viewing this topic.

neX

  • Anope User
  • Offline Offline
  • Posts: 9
Problems using MySQL and Anope on Ubuntu 10.04
« on: April 09, 2011, 02:36:34 PM »

First I've used the mydbgen tool.

MysqlHost "localhost"
MysqlUser "servicios_chat"
MysqlPass "******************"
MysqlName "servicios_chat"
MysqlSock ""
MysqlPort ""

When I tried to run anope it showed an error about the MySQL Port so i write that on the services.conf

MysqlHost "localhost"
MysqlUser "servicios_chat"
MysqlPass "******************"
MysqlName "servicios_chat"
MysqlSock ""
MysqlPort 3306

MysqlSecure "md5"
MysqlRetries 10
MysqlRetryGap 1
UseRDB

I can see the data base with phpMyAdmin. It has been built but Anope doesn't use the data base. Why?

I have tried to find the mysql.sock file but i don't know where is it. I am using Ubuntu Server 10.04 where can I find that file?
Logged

Charles Kingsley

  • Contributor
  • *
  • Offline Offline
  • Posts: 1405
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #1 on: April 09, 2011, 02:54:37 PM »

Does it work if you telnet to localhost on port 3306?
Logged

neX

  • Anope User
  • Offline Offline
  • Posts: 9
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #2 on: April 09, 2011, 02:56:57 PM »

yes of course. And I have other data bases with other logins on the same server.
This is the my.cnf file on /etc/mysql

Code: [Select]
[client]
port = 3306
socket = /var/run/mysqld/mysqld.sock

Should have to set the MySQLSock param as "/var/run/mysqld/mysqld.sock"  ???
« Last Edit: April 09, 2011, 02:58:59 PM by neX »
Logged

neX

  • Anope User
  • Offline Offline
  • Posts: 9
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #3 on: April 09, 2011, 03:53:32 PM »

I have do it
Quote
MysqlHost "localhost"
MysqlUser "servicios_chat"
MysqlPass "*******************"
MysqlName "servicios_chat"
MysqlSock "/var/run/mysqld/mysqld.sock"
MysqlPort 3306

But it doesn't work :(
Logged

katsklaw

  • Supporter
  • Anope User
  • Offline Offline
  • Posts: 537
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #4 on: April 10, 2011, 06:37:03 PM »

what do you mean by "Anope doesn't 'use' the database"? do you mean Anope doesn't dump data to the mysql db, as in the db and tables exist but no data populates the tables? or do you mean you made changes from outside Anope and Anope doesn't see the changes you made?
Logged

neX

  • Anope User
  • Offline Offline
  • Posts: 9
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #5 on: April 14, 2011, 12:17:16 AM »

what do you mean by "Anope doesn't 'use' the database"? do you mean Anope doesn't dump data to the mysql db, as in the db and tables exist but no data populates the tables? or do you mean you made changes from outside Anope and Anope doesn't see the changes you made?

I'm trying to say that Anope doesn't insert any info to the mysql DB. I have created the tables using the mydbgen tool (./mydbgen on console) but they use the binary files from the HDD, but they don't insert any info to the MySQL DB. They work fine but they insert all registered nicknames, channels and everything on the binary files, but not to de MySQL DB.

I've configured the .conf file like this.

MysqlHost "localhost"
MysqlUser "servicios_chat"
MysqlPass "******************"
MysqlName "servicios_chat"
MysqlSock ""
MysqlPort 3306

MysqlSecure "md5"
MysqlRetries 10
MysqlRetryGap 1
UseRDB
Logged

katsklaw

  • Supporter
  • Anope User
  • Offline Offline
  • Posts: 537
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #6 on: April 14, 2011, 01:46:03 AM »

did you enable sql from IRC? /os set sql on

Additionally, they will always use the .db files. They only dump data to mysql and can load from mysql, but not use mysql in a live state.
Logged

Jan Milants

  • Team
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 1372
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #7 on: April 14, 2011, 09:18:31 AM »

normally anope will automatically dump its DB to MySQL if it is configure properly..  enable debug or start anope in debug (./services -support)  and check the logfiles to see what exactly is going wrong..
Logged
If you like me donate coins to 1FBmZVT4J8WAUMHKqpWhgNVj3XXnRN1cCk :)

neX

  • Anope User
  • Offline Offline
  • Posts: 9
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #8 on: April 14, 2011, 10:56:17 AM »

did you enable sql from IRC? /os set sql on

Additionally, they will always use the .db files. They only dump data to mysql and can load from mysql, but not use mysql in a live state.

[11:55:25] : -OperServ- --(Private notice)-- SQL Unknown option.

 ???
Logged

Charles Kingsley

  • Contributor
  • *
  • Offline Offline
  • Posts: 1405
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #9 on: April 14, 2011, 10:57:55 AM »

When you ran ./Config did it say MySQL: Yes?
Logged

neX

  • Anope User
  • Offline Offline
  • Posts: 9
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #10 on: April 14, 2011, 11:06:34 AM »

normally anope will automatically dump its DB to MySQL if it is configure properly..  enable debug or start anope in debug (./services -support)  and check the logfiles to see what exactly is going wrong..

Code: [Select]
[Apr 14 12:03:39 2011] Loading IRCD Protocol Module: [unreal32]
[Apr 14 12:03:39 2011] status: [0][Module, Okay - No Error]
[Apr 14 12:03:39 2011] Loading Encryption Module: [enc_none]
[Apr 14 12:03:39 2011] status: [0][Module, Okay - No Error]
[Apr 14 12:03:39 2011] Anope 1.8.5 (3037) (ircd protocol: UnrealIRCd 3.2+) starting up
[Apr 14 12:03:39 2011] ns_noticeunregister: module loaded and active.
[Apr 14 12:03:39 2011] NServ v0.1 module loaded.
[Apr 14 12:03:39 2011] Loaded ns_restrictdrop: Only Service Admins and Root will be able to use NickServ Drop
[Apr 14 12:03:39 2011] cs_autolimit.so: Add Command 'AutoLimit' Status: 0
[Apr 14 12:03:39 2011] cs_autolimit.so: DataBase loaded!
[Apr 14 12:03:39 2011] cs_autovoice: Nuevo comando: /msg ChanServ HELP AUTOVOICE
[Apr 14 12:03:39 2011] cs_autovoice: Modulo cargado correctamente.
[Apr 14 12:03:39 2011] [os_massmode]: Module loaded.
[Apr 14 12:03:39 2011] Loading os_statsonid [Status: 0]
[Apr 14 12:03:39 2011] hs_setonhost.c v1.0 by Roy loaded
[Apr 14 12:03:39 2011] Databases loaded
[Apr 14 12:03:39 2011] Info: Reflecting database records.
[Apr 14 12:03:39 2011] Connected to Server 1 (87.106.210.209:4400)
[Apr 14 12:03:39 2011] trying to load [cs_appendtopic]
[Apr 14 12:03:39 2011] [cs_appendtopic] Loaded successfully
[Apr 14 12:03:39 2011] status: [0][Module, Okay - No Error]
[Apr 14 12:03:39 2011] trying to load [cs_enforce]
[Apr 14 12:03:39 2011] status: [0][Module, Okay - No Error]
[Apr 14 12:03:39 2011] trying to load [ns_maxemail]
[Apr 14 12:03:39 2011] status: [0][Module, Okay - No Error]
[Apr 14 12:03:39 2011] trying to load [os_info]
[Apr 14 12:03:39 2011] os_info: Loading configuration directives...
[Apr 14 12:03:39 2011] os_info: Directive OSInfoDBName loaded (os_info.db)...
[Apr 14 12:03:39 2011] status: [0][Module, Okay - No Error]
[Apr 14 12:03:39 2011] trying to load [hs_request]
[Apr 14 12:03:39 2011] hs_request loaded
[Apr 14 12:03:39 2011] status: [0][Module, Okay - No Error]
Logged

neX

  • Anope User
  • Offline Offline
  • Posts: 9
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #11 on: April 14, 2011, 11:08:41 AM »

When you ran ./Config did it say MySQL: Yes?

Yes. I can compile them again. But take a look.


Quote
Allow anope to automatically check for mysql libaries?
unless you get errors with make, there is no need to
change this setting.
[yes]

.................................
................................


configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/bin/anoperc
config.status: creating include/sysconf.h
config.status: include/sysconf.h is unchanged

Modules: Yes
  MySQL: No

What do you think about this?
Logged

Jan Milants

  • Team
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 1372
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #12 on: April 14, 2011, 11:13:51 AM »

anope couldn't find the required libraries on your system...
Logged
If you like me donate coins to 1FBmZVT4J8WAUMHKqpWhgNVj3XXnRN1cCk :)

Charles Kingsley

  • Contributor
  • *
  • Offline Offline
  • Posts: 1405
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #13 on: April 14, 2011, 11:15:05 AM »

Quote
Yes. I can compile them again. But take a look.

You mean no.

You need the development libraries for MySQL libmysqlclient-dev I think
Logged

neX

  • Anope User
  • Offline Offline
  • Posts: 9
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #14 on: April 14, 2011, 11:15:31 AM »

anope couldn't find the required libraries on your system...

I'm using Ubuntu. How can I install them?

apt-get install libmysqlclient-dev

 ???
Logged

Charles Kingsley

  • Contributor
  • *
  • Offline Offline
  • Posts: 1405
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #15 on: April 14, 2011, 11:17:00 AM »

Sounds like a reasonable thing to try.
Logged

neX

  • Anope User
  • Offline Offline
  • Posts: 9
Re: Problems using MySQL and Anope on Ubuntu 10.04
« Reply #16 on: April 14, 2011, 11:19:16 AM »

FIXED

I used apt-get install libmysqlclient-dev and install the MySQL libraries and it worked great!!

thank you so much!!  ;D ;D ;D ;D ;D
Logged
Pages: [1]   Go Up