r1ch.net forums
* Home Help Search Login Register
r1ch.net  |  r1ch.net stuff  |  Bitchbot  |  Topic: Bot automatically exits...
Pages: [1]
Print
Author Topic: Bot automatically exits...  (Read 9220 times)
Phigment
Guest
« on: April 23, 2003, 05:41:54 pm »

When I crank up the bitchbot, it connects to a server and channel correctly.  Users can interact with it, set factoids, make queries, admins can tell it to shut down, etc.  

However, it shuts down 30 seconds to a minute after connecting.  (Unless an admin tells it to quit first, of course.)  This happens whether it gets messaged or not, and whether anyone else is in the channel or not.  Not really sure whether it's just crashing or shutting itself down gracefully; if there's a way to tell, I haven't found it yet.  The debugging messages don't seem to indicate errors, they just stop.

Any ideas?
Logged
R1CH
Administrator
Member

Posts: 2625



« Reply #1 on: April 25, 2003, 09:26:47 pm »

What OS are you running it on?
Logged
Phigment
Guest
« Reply #2 on: April 30, 2003, 08:55:29 pm »

Suse Linux 8.2
Logged
R1CH
Administrator
Member

Posts: 2625



« Reply #3 on: May 06, 2003, 09:41:33 am »

Are you using perl 5.8.0? Try removing the "use Time::HiRes" module from bitch.pl - perl 5.8 has a bug with this.
Logged
Phigment
Guest
« Reply #4 on: May 09, 2003, 03:33:59 am »

That seems to have done the trick.

Excellent.

Thanks for the help.
Logged
bbotuser
Guest
« Reply #5 on: February 11, 2004, 10:09:04 pm »

I'm getting the identical behavior with 1.0.2
Using perl 5.8.0   linux kernel 2.4.22

I comment out the eval for Time::HiRes and hard set the $notime to 1 in bitch.pl with no luck.
Logged
bbotuser
Guest
« Reply #6 on: February 11, 2004, 10:22:17 pm »

Here is some more info, it appears to be giving an alarm 30

I strace'd it, it connects to irc fine, joins channel, can talk to it, it repsonds etc... but after 30 seconds or so it just dies... the strace reports alarm30 when this happens.. not sure if that is the cause or not... but hope that helps.

Here is an strace snippet:

it sits on "read(5," for awhile before it dies.

read(5, 0x401b4000, 4096)               = ? ERESTARTSYS (To be restarted)
--- SIGALRM (Alarm clock) ---
sigreturn()                             = ? (mask now [])
time(NULL)                              = 1076556026
alarm(30)                               = 0
open("./bitchquit.log", O_WRONLY|O_APPEND|O_CREAT|0x8000, 0666) = 6
fstat64(0x6, 0xbffff41c)
Logged
R1CH
Administrator
Member

Posts: 2625



« Reply #7 on: February 15, 2004, 08:41:51 pm »

I think this is a bug in the Time::HiRes module as it uses alarms. I think it is unsetting the bitchbot internal alarm handler to detect timeouts. Just comment out the alarm (120) or whatever it is in bitch.pl and it should work fine.
Logged
Pages: [1]
Print
r1ch.net  |  r1ch.net stuff  |  Bitchbot  |  Topic: Bot automatically exits...
Jump to:  

Powered by SMF 1.1.19 | SMF © 2013, Simple Machines