[Home] [Downloads] [Search] [Help/forum]


Register forum user name Search FAQ

Gammon Forum

[Folder]  Entire forum
-> [Folder]  SMAUG
. -> [Folder]  SMAUG coding
. . -> [Subject]  Random Crashes after installing erwin's global board snippet

Random Crashes after installing erwin's global board snippet

It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page


Posted by Typhon   USA  (112 posts)  [Biography] bio
Date Fri 11 Jul 2003 11:21 AM (UTC)
Message
hey there
pretty much.. ive been having problems with erwin's global board code.. it seesm the mud crashs every time i issue one of the commands after a hotboot/copyover.. since gdb crashes when you try to hotboot the mud in it i cant check the debugger.. is there a way to get the mud to du,mp the core file perhaps.. since it doesnt do it now?
thanks
-typ
[Go to top] top

Posted by David Haley   USA  (3,881 posts)  [Biography] bio
Date Reply #1 on Fri 11 Jul 2003 02:57 PM (UTC)
Message
Try typing ulimit -a in your shell environment. Look for a line that says:
core file size        (blocks, -c) 0

That's probably your problem. The little 0 there says that the maximum filesize for a core dump is 0 bytes - in other words, core dumps are not generated.

To change this, type something like:
ulimit -c 16384

Or higher if for some reason you need a bigger core file. (Although, I think that should be enough.)

You will have to add this to your .bash_profile file (in your home directory type ls -a and look for it... if you're not using bash it may be slightly different.) Mine for example has this at the bottom (default configuration on my system):
# User specific environment and startup programs

PATH=$PATH:$HOME/bin

export PATH
unset USERNAME

Just stick the ulimit thing after that, and it should be fine.

Then you'll have to kill your mud, kill the startup script (if you're using one) - use shutdown mud now to do this. Then, log out of your server, log back on, and make sure that ulimit -a shows you that your core file size is no longer 0. Once you have that, you can start up the MUD again, and it should give you core dumps.

However, I found interestingly enough that the core dumps my new system (Redhat Linux 7.1 I think) it generates are not just "core", but rather "core.xxxxx" where the xxxxx is the process ID. So if you don't find the core file don't assume straight away it doesn't exist, but also look for these alternate core files.

Hope that helps :)

David Haley aka Ksilyan
Head Programmer,
Legends of the Darkstone

http://david.the-haleys.org
[Go to top] top

Posted by Typhon   USA  (112 posts)  [Biography] bio
Date Reply #2 on Fri 11 Jul 2003 11:52 PM (UTC)

Amended on Fri 11 Jul 2003 11:53 PM (UTC) by Typhon

Message
yes that worked great.. now ive got a core file that i cant seem to do anythign with.. when i gdb -c core all i get is...
Quote:

[typhon@boralis ~/area]$ gdb -c core
GNU gdb Red Hat Linux (5.3post-0.20021129.18rh)
Copyright 2003 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i386-redhat-linux-gnu".
Core was generated by `smaug 4600 hotboot 6 7 8 9 -1'.
Program terminated with signal 11, Segmentation fault.
#0 0x0809485c in ?? ()
(gdb) bt
#0 0x0809485c in ?? ()
#1 0x08094c3f in ?? ()
#2 0x080f591d in ?? ()
#3 0x080b7a08 in ?? ()
#4 0x080b6f4a in ?? ()
#5 0x420156a4 in ?? ()
(gdb)

not that i know what that means but i know i cant figure squat out from that :p any help is greatly appreciated
thanks
-typ
[Go to top] top

Posted by Typhon   USA  (112 posts)  [Biography] bio
Date Reply #3 on Sat 12 Jul 2003 12:32 AM (UTC)
Message
forget that last post i think i figured out what i did to be able to read everything normally.. ehres what i get..
Quote:

(gdb) bt
#0 0x0809485c in do_nread (ch=0x8d92918, argument=0xbfffc004 "")
at board.c:657
#1 0x08094c3f in do_global_note (ch=0x8d92918, argument=0xbfffc004 "")
at board.c:788
#2 0x080f591d in interpret (ch=0x8d92918, argument=0xbfffc004 "")
at interp.c:739
#3 0x080b7a08 in game_loop () at comm.c:803
#4 0x080b6f4a in main (argc=8, argv=0xbfffe030) at comm.c:324
#5 0x420156a4 in ?? ()
(gdb)

well i figured i'd start at the top
so i entered 'up' a bunch of times and started in main
and i get this..
Quote:

(gdb) info local
now_time = {tv_sec = 1057968379, tv_usec = 367291}
hostn = "boralis.arthmoor.com\000\003\000\000LÜ\000BPj\000B\024\032\023B,üÿ¿\024áÿ¿\224àÿ¿pÂ\000@\177\003\000\000\b\000\000\000\000ª\aB\017\206\000@ì]\001@¼\002\000\000ø_\001@Ðàÿ¿³Ã\000@\224a\001@Èk\001@\001\000\000\000\000\000\000\000ö\020\002@*ï\005\b\030\037\023B\024\032\023B¸àÿ¿©è\005\b"
fCopyOver = 1 '\001'
(gdb)

now i know that cant be good... but i just pressed on.. now i looked in game_loop and heres what i got
Quote:

(gdb) info local
last_time = {tv_sec = 1057968382, tv_usec = 459034}
cmdline = "note\000600.\n\r\000Ra&rt&Rh&z ./}r*&d&z\.&d&d\000e&zan&rc&Re&W% &R/&r|&z*&W*&r|&R\&z<&w^^&z>&d&d\000=&d&d\000^&B)&c\&d&d\000know my contact info I believe.\n\r \n\rSmokey - the pissed old fart of a dragon who wants out of h"...
d = (DESCRIPTOR_DATA *) 0x8d8d0a8
(gdb)

so yea that didnt blow up the mud so i went on...
and i get this in interprt
Quote:

(gdb) down
#2 0x080f591d in interpret (ch=0x8d92918, argument=0xbfffc004 "")
at interp.c:739
739 (*cmd->do_fun) ( ch, argument );
(gdb) info local
command = "note\000\200\000\000Ø\220×\b\000|×\b\000z./}r*&d&z\. Rune of &RD&re&Ra&rt&Rh&z ./}r*&d&z\.&d\000re&zng&we&zan&rc&Re&W% &R/&r|&z*&W*&r|&R\&z<&w^^&z>&d\000 goblets of wine is ample evidence of the tastes these two\n\rhave for alcohol"...
logline = "note\000!Ù\b\205\001\000\000\rto be written for them.\n\r\000 die die die\n\r\n\r", ' ' <repeats 16 times>, "die", ' ' <repeats 11 times>, "diedie die\n\r\n\r", ' ' <repeats 13 times>, "die", ' ' <repeats 14 times>, "die die die\n\r\n\r die", ' ' <repeats 14 times>, "diedie die\n\r\n\r "...
logname = "&g1201 (I):0 &r=&O-&d\000t could easily\n\r\n\rpound the life out of anything that might even attempt to threaten it.\n\r\n\rIt moves painfully slowly though, and you could easily outrun it if\n\r\n\ryou wanted to.\n"...
newcommand = '\0' <repeats 4028 times>, "\005þ\006BLWÿ¿ ~ÿ¿$\000\000\000\000\000\000\000¼º\030\b¼º\030\bHVÿ¿\213g\004B\200Vÿ¿¼º\030\b\001", '\0' <repeats 59 times>, "èQÿ¿\000\000\000\000(Vÿ¿\025\224\004B", '\0' <repeats 298 times>, "s \000\000\000\000ÿÿÿÿÜÿÿÿ", '\0' <repeats 36 times>, " ~ÿ¿", '\0' <repeats 20 times>, "´º\030\bðQÿ¿\002\000\000\000\002\000\000\0008~ÿ¿(Vÿ¿\000\000\000\000¼º\030\bA\000\000\000ÿÿÿÿ", '\0' <repeats 104 times>, "½º\030\b", '\0' <repeats 196 times>, "\034*\031\b\034*\031"...
arg2 = '\0' <repeats 4788 times>, " 4\002@\005\000\000\000Ü\000\000\000\000\000\000\000 4\002@\005\000\000\000\231\231\231\031", '\0' <repeats 20 times>, "À2ÿ¿\000\000\000\000\024\032\023Bl¸\030\b\000\000\000\000\2108ÿ¿\nh\005BÀ2ÿ¿\b8ÿ¿\n\000\000\000\000\000\000\000220", '\0' <repeats 977 times>, "Z¸\030\bx8ÿ¿\227H\005---Type <return> to continue, or q <return> to quit---
B 8ÿ¿c¸\030\b\2108ÿ¿\227H\005B°8ÿ¿0", '\0' <repeats 171 times>, "0", '\0' <repeats 15 times>, "2", '\0' <repeats 15 times>, "ø\201\032\bø\201\032\bH>ÿ¿\000\000\000\000\211¬\026\b\211¬\026\bX>ÿ¿\213g"...
buf = 0x0
timer = (TIMER *) 0x8d92918
cmd = (CMDTYPE *) 0x831ff38
trust = 148449560
loglvl = 148449560
found = 1 '\001'
time_used = {tv_sec = 1057968382, tv_usec = 459195}
tmptime = 0
(gdb)

[Go to top] top

Posted by Typhon   USA  (112 posts)  [Biography] bio
Date Reply #4 on Sat 12 Jul 2003 12:33 AM (UTC)
Message
and this in global_notes
Quote:

(gdb) down
#1 0x08094c3f in do_global_note (ch=0x8d92918, argument=0xbfffc004 "")
at board.c:788
788 do_nread (ch, argument);
(gdb) info local
arg = '\0' <repeats 5968 times>, "üM\022B\000\036ÿ¿\030\027ÿ¿µ4\006B\000\036ÿ¿üM\022B\001", '\0' <repeats 15 times>, "\001\000\000\000üM\022B", '\0' <repeats 24 times>, ";4\006B\000\000\000\000ÞS\022BÞS\022BØ\035ÿ¿\213g\004B\000\036ÿ¿ÞS\022B\001", '\0' <repeats 59 times>, "x\031ÿ¿\000\000\000\000¸\035ÿ¿\025\224\004B", '\0' <repeats 60 times>, "NE\032\bNE\032\bx\036ÿ¿\213g\004B \036ÿ¿NE\032\b", '\0' <repeats 60 times>, "\030\032ÿ¿\000\000\000\000X\036ÿ¿\025\224\004B", '\0' <repeats 52 times>, "o\232\004B\024\032\023B"...
arg2 = '\0' <repeats 4364 times>, "\005þ\006B@øþ¿`)\023B\030\000\000\000\000\000\000\000¼º\030\b¼º\030\bX÷þ¿\213g\004B\220÷þ¿¼º\030\b\001", '\0' <repeats 59 times>, "øòþ¿\000\000\000\0008÷þ¿\025\224\004B", '\0' <repeats 298 times>, "s \000\000\000\000ÿÿÿÿñÿÿÿ", '\0' <repeats 36 times>, "\200\207.\b", '\0' <repeats 20 times>, "´º\030\b\000óþ¿\002\000\000\000\002\000\000\000H\037ÿ¿8÷þ¿\000\000\000\000¼º\030\b,\000\000\000ÿÿÿÿ", '\0' <repeats 104 times>, "½º\030\b", '\0' <repeats 968 times>, "3\035\rB\024\032\023"...
(gdb)

and finally this in do_nread
Quote:

(gdb) down
#0 0x0809485c in do_nread (ch=0x8d92918, argument=0xbfffc004 "")
at board.c:657
657 for (p = ch->pcdata->board->note_first; p ; p = p->next, count++)
(gdb) info local
buf = '\0' <repeats 199 times>
p = (NOTE_DATA *) 0xbfffc004
count = 1
number = 148449560
last_note = (time_t *) 0x8d931a8
(gdb)

sorry for the rediculously long note.. but it seems there some sort of memory leak or something.. but the only ocmmand it affects is the global notes/boards... and i cant figure out where i can limit it down.. seems like a buffer isnt cleared out someplace but becuase gdb shits out if i try to run the debugger and hotboot the mud i have to scan the core file every time.. if anyone has an idea i'd appreciate it... tanks
-typ
[Go to top] top

Posted by Dace K   Canada  (169 posts)  [Biography] bio
Date Reply #5 on Mon 24 May 2004 11:04 PM (UTC)
Message
Hey Typhon.. did you ever figure this out?
Only, I'm having the same problems now..

If anyone has an answer, hit me back. Ty.

ASJ Games - .Dimension 2, Resident Evil, and snippets - oh my!
http://asj.mudmagic.com

Drop by the area archives and find something for your mud. http://areaarchives.servegame.com
[Go to top] top

Posted by Zeno   USA  (2,871 posts)  [Biography] bio
Date Reply #6 on Tue 25 May 2004 02:31 AM (UTC)
Message
I've seen lots of issues with memory leaks with this snippet... There should be other topics about this, and how to solve it. If not, check www.mudmagic.com

Personally, after installing this snippet some years ago, I had no trouble.

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
[Go to top] top

Posted by Dace K   Canada  (169 posts)  [Biography] bio
Date Reply #7 on Fri 28 May 2004 07:36 PM (UTC)
Message
I can't find anything from searching through mudmagic, here, or SML.

Can anybody help me out, or at least link me to a topic? =P

ASJ Games - .Dimension 2, Resident Evil, and snippets - oh my!
http://asj.mudmagic.com

Drop by the area archives and find something for your mud. http://areaarchives.servegame.com
[Go to top] top

Posted by Zeno   USA  (2,871 posts)  [Biography] bio
Date Reply #8 on Fri 28 May 2004 08:43 PM (UTC)
Message
How did you install it? The patch didn't work, so I manually installed it, and it worked fine.

Zeno McDohl,
Owner of Bleached InuYasha Galaxy
http://www.biyg.org
[Go to top] top

Posted by Typhon   USA  (112 posts)  [Biography] bio
Date Reply #9 on Fri 28 May 2004 09:00 PM (UTC)
Message
I just emailed someone about this.

after a hotboot the mud sets a players default board to null. this is bad. so i did the simplest thing i could think of and it works.

add
if(ch->pcdata->board == NULL)
ch->pcdata->board = &boards[DEFAULT_BOARD];

to both do_global_notes and do_global_boards and you should be ok.
enjoy :)
[Go to top] top

Posted by Dace K   Canada  (169 posts)  [Biography] bio
Date Reply #10 on Fri 28 May 2004 09:49 PM (UTC)
Message
..yeah, it was me you emailed :D

Dude, you're a lifesaver. Thanks a lot!

ASJ Games - .Dimension 2, Resident Evil, and snippets - oh my!
http://asj.mudmagic.com

Drop by the area archives and find something for your mud. http://areaarchives.servegame.com
[Go to top] top

Posted by Typhon   USA  (112 posts)  [Biography] bio
Date Reply #11 on Sat 29 May 2004 06:51 PM (UTC)
Message
lol np :)
[Go to top] top

The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).

To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.


26,455 views.

It is now over 60 days since the last post. This thread is closed.     [Refresh] Refresh page

Go to topic:           Search the forum


[Go to top] top

Quick links: MUSHclient. MUSHclient help. Forum shortcuts. Posting templates. Lua modules. Lua documentation.

Information and images on this site are licensed under the Creative Commons Attribution 3.0 Australia License unless stated otherwise.

[Home]


Written by Nick Gammon - 5K   profile for Nick Gammon on Stack Exchange, a network of free, community-driven Q&A sites   Marriage equality

Comments to: Gammon Software support
[RH click to get RSS URL] Forum RSS feed ( https://gammon.com.au/rss/forum.xml )

[Best viewed with any browser - 2K]    [Hosted at HostDash]