Anope IRC Services

Please login or register.

Login with username, password and session length
Advanced search  

News:

Pages: [1]   Go Down

Author Topic: strange issue with ns_access when using mysql  (Read 4861 times)

0 Members and 1 Guest are viewing this topic.

Shadowed_Ghost

  • Guest
strange issue with ns_access when using mysql
« on: January 07, 2009, 06:45:38 AM »

I'm having an issue with anope always panicking when certain users modify their nickserv access list, and it doesn't matter what the mask that's added is: services always panics when the user or users add them.  I have had the problem with two users total, ever, though only one currently has the issue.  I believe it may be something to do with the user's flags, as other users can modify their access list without incident.  The user currently having the issue has a flags/options mask of '1521'. 

I've never had this problem when not using MySQL.  I would also think it prudent to mention that I do in fact make use of the RDB functionality of anope and run a cronjob every four hours to import users from the services' registration website.  Also, to preempt any os_raw superstition: I have DisableRaw enabled in services.conf.

I was wondering if anyone else had an issue similar to this and if so, what they did to rectify the issue.  As of right now, I'm leaving the ns_access module unloaded to prevent the users that are able to freeze services from doing so.  Clearly this is a less than ideal solution, so I'd really appreciate any help.
« Last Edit: January 07, 2009, 06:53:47 AM by Shadowed_Ghost »
Logged

deiks

  • Anope User
  • Offline Offline
  • Gender: Male
  • Posts: 139
  • Shizle my nizle
Re: strange issue with ns_access when using mysql
« Reply #1 on: January 07, 2009, 01:53:28 PM »

Try ./services -support

And report logs
Logged

Shadowed_Ghost

  • Guest
Re: strange issue with ns_access when using mysql
« Reply #2 on: January 08, 2009, 03:25:26 PM »

I just replicated the services panic with debugging enabled.  However, the logs are gigantic and contain every SQL query executed by services during the time, and this includes lots of sensitive information such as passwords.  Is there anything in particular that would be most helpful or that I could leave out?
Logged

deiks

  • Anope User
  • Offline Offline
  • Gender: Male
  • Posts: 139
  • Shizle my nizle
Re: strange issue with ns_access when using mysql
« Reply #3 on: January 08, 2009, 04:45:13 PM »

Find part where is panic buffer, and copy 10 lines before and 10 lines after.. ;)
Logged

Charles Kingsley

  • Contributor
  • *
  • Offline Offline
  • Posts: 1405
Re: strange issue with ns_access when using mysql
« Reply #4 on: January 08, 2009, 05:57:30 PM »

The version you're using would be helpful.

There was an issue rectified some time ago now that was exactly this, so if you're not on 1.8, upgrade and this should be fixed there.
Logged

Shadowed_Ghost

  • Guest
Re: strange issue with ns_access when using mysql
« Reply #5 on: January 08, 2009, 07:33:40 PM »

I'm using version 'Anope-1.8.0 (1899)', having previously upgraded from 1.7.21 -> 1.8.0 RC1 and then 1.8.0 RC1 -> 1.8.0.  I've had the issue on 1.8.0 and 1.8.0 RC1 for sure, and possible 1.7.21 as well, though I can't recall for sure.  As for the logs, I'll be able to retrieve those later.
Logged

Shadowed_Ghost

  • Guest
Re: strange issue with ns_access when using mysql
« Reply #6 on: January 09, 2009, 07:19:39 PM »

Here are the -support logs of the issue around the time of the panic

Code: [Select]
[Jan 08 08:53:41.303812 2009] LOGUSERS: shadowed (shadowed@x.hlrn.qwest.net => what.am.i) (Z) changed nick to IssueCauser (chat.somenet.com).
[Jan 08 08:53:41.303948 2009] debug: Emitting event "change_nick" (1 args)
[Jan 08 08:53:41.304301 2009] debug: Sent: :services.somenet.com n IssueCauser -r+d 1
[Jan 08 08:53:41.304467 2009] debug: Changing mode for IssueCauser to -r+d
[Jan 08 08:53:41.304914 2009] debug: Sent: :NickServ B IssueCauser :This nick is owned by someone else.  Please choose another.
[Jan 08 08:53:41.305391 2009] debug: Sent: :NickServ B IssueCauser :(If this is your nick, type ^B/msg NickServ IDENTIFY ^_password^_^B.)
[Jan 08 08:53:41.305750 2009] debug: Sent: :NickServ B IssueCauser :If you do not change within 20 seconds, I will change your nick.
[Jan 08 08:53:43.603590 2009] debug: Received: :IssueCauser ! nickserv@services.somenet.com :identify xxxxxxxxx
[Jan 08 08:53:43.604623 2009] debug: Sent: :services.somenet.com n IssueCauser +rd 1231426419
[Jan 08 08:53:43.604884 2009] debug: Changing mode for IssueCauser to +rd
[Jan 08 08:53:43.605003 2009] debug: Emitting event "nick_id" (1 args)
[Jan 08 08:53:43.605097 2009] NickServ: IssueCauser!shadowed@x.hlrn.qwest.net identified for nick IssueCauser
[Jan 08 08:53:43.605565 2009] debug: Sent: :NickServ B IssueCauser :Password accepted - you are now recognized.
[Jan 08 08:53:43.605992 2009] debug: Sent: :HostServ B IssueCauser :Your vhost of ^B^B@^Bwhat.am.i^B is now activated.
[Jan 08 08:53:43.606767 2009] debug: Sent: :services.somenet.com AZ IssueCauser
[Jan 08 08:53:43.607242 2009] debug: Sent: :services.somenet.com AL IssueCauser what.am.i
[Jan 08 08:53:43.607381 2009] debug: Setting correct user modes for IssueCauser on #admin (current status: 9, giving modes)
[Jan 08 08:53:43.608002 2009] debug: Sent: :CS-Bot G #admin -qo IssueCauser IssueCauser
[Jan 08 08:53:43.608290 2009] debug: Received: :chat.somenet.com 461 services.somenet.com CHGIDENT :Not enough parameters
[Jan 08 08:53:43.608601 2009] debug: Received: :chat.somenet.com NOTICE services.somenet.com :*** /ChgHost Error: requested host is same as current host.
[Jan 08 08:53:49.129229 2009] debug: Received: :IssueCauser ! nickserv@services.somenet.com :access add *@*.co.nz
[Jan 08 08:53:49.129636 2009] PANIC! buffer = :IssueCauser ! nickserv@services.somenet.com :access add *@*.co.nz
[Jan 08 08:53:49.130402 2009] debug: Sent: :services.somenet.com ] :PANIC! buffer = :IssueCauser ! nickserv@services.somenet.com :access add *@*.co.nz

There was nothing interesting after the panic because services went unresponsive.
Logged

Charles Kingsley

  • Contributor
  • *
  • Offline Offline
  • Posts: 1405
Re: strange issue with ns_access when using mysql
« Reply #7 on: January 09, 2009, 08:14:06 PM »

Hmm..

Without being rude; can you confirm what exactly your import script is doing; as we made a change to the ns_access table in version 1.8.0-rc1 which you might want to look into to rectify an issue exactly like this.

I'm interested in whether you could do a bit of research and manage to cause this panic on a testnet with your config, and some dummy data to isolate where the issue lies; ie. in anope, or in your script.

We don't have a great deal of networks who put up with the MySQL implementation currently in 1.8 and even less with UseRDB so your efforts would be appreciated.
Logged

Shadowed_Ghost

  • Guest
Re: strange issue with ns_access when using mysql
« Reply #8 on: January 09, 2009, 08:45:23 PM »

I ran the most recent change in Changes.mysql before upgrading services.  Just now I stopped services, altered ns_access again to be sure, restarted services, and still saw a panic after identifying as the user that currently causes the issue and attempting to add the access entry.

The import script currently sends a SIGTERM to the services process, waits for services to exit, processes an update queue which is populated by the registration server and inserts or updates the necessary values in anope_ns_core and anope_ns_alias.  After it finishes processing its update queue, it execve's services.

I will setup a test net with my current configuration as soon as time permits.
Logged
Pages: [1]   Go Up