]> jfr.im git - irc.git/blame - software/RELEASES/ircservices/achurch.org/services/lists/ircservices/2003/003854.html
init
[irc.git] / software / RELEASES / ircservices / achurch.org / services / lists / ircservices / 2003 / 003854.html
CommitLineData
3bd189cb
JR
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
2<HTML>
3 <HEAD>
4 <TITLE> [IRCServices] Compiling and Crashing on boot under Solaris 9
5 </TITLE>
6 <LINK REL="Index" HREF="index.html" >
7 <LINK REL="made" HREF="mailto:ircservices%40ircservices.za.net?Subject=%5BIRCServices%5D%20Compiling%20and%20Crashing%20on%20boot%20under%20Solaris%209&In-Reply-To=">
8 <META NAME="robots" CONTENT="index,nofollow">
9 <META http-equiv="Content-Type" content="text/html; charset=us-ascii">
10 <LINK REL="Previous" HREF="003853.html">
11 <LINK REL="Next" HREF="003855.html">
12 </HEAD>
13 <BODY BGCOLOR="#ffffff">
14 <H1>[IRCServices] Compiling and Crashing on boot under Solaris 9</H1>
15 <B>Kevin Kane</B>
16 <A HREF="mailto:ircservices%40ircservices.za.net?Subject=%5BIRCServices%5D%20Compiling%20and%20Crashing%20on%20boot%20under%20Solaris%209&In-Reply-To="
17 TITLE="[IRCServices] Compiling and Crashing on boot under Solaris 9">kane at firelion.org
18 </A><BR>
19 <I>Sun Jun 8 12:22:33 PDT 2003</I>
20 <P><UL>
21 <LI>Previous message: <A HREF="003853.html">[IRCServices] BUG: Services crash under heavy akill removal load.
22</A></li>
23 <LI>Next message: <A HREF="003855.html">[IRCServices] Compiling and Crashing on boot under Solaris 9
24</A></li>
25 <LI> <B>Messages sorted by:</B>
26 <a href="date.html#3854">[ date ]</a>
27 <a href="thread.html#3854">[ thread ]</a>
28 <a href="subject.html#3854">[ subject ]</a>
29 <a href="author.html#3854">[ author ]</a>
30 </LI>
31 </UL>
32 <HR>
33<!--beginarticle-->
34<PRE>I am attempting to use IRC Services 5.0.19.
35
36The IRCD is Unreal3.2-beta16cvs20030527.
37
38I have successfully been using IRC Services 5.0.16 with this server,
39although I had to do similar tinkering as mentioned below to get it to
40compile. But since compiled, no problems.
41
42The server is an UltraSPARC 1 (sun4u) running Solaris 9. Compiler is GCC
433.2.2.
44
45First, I had to add a -libs parameter to configure with &quot;-lsocket -lnsl
46-lresolv&quot; so that it would find hstrerror() and gethostbyname(). It seems
47to figure out that it needs -lsocket on its own, so I probably don't have
48to add it myself, but I did just to be sure. It refuses to compile
49dynamic modules, but I didn't care enough to try and correct that. I also
50had to tell Make to be sure to use bash as the shell, instead of Solaris'
51braindead /bin/sh by adding a SHELL=/usr/local/bin/bash parameter to the
52make command. After that it compiles fine. It still complains that it
53cannot find strtok, although this isn't fatal. Solaris does seem to have
54this function, however. Here is the relevant snippet from the
55configure.log when it attempts to locate strtok:
56 --
57check_strtok : &gt;&gt;&gt; gcc -O2 -fno-strict-aliasing conf-tmp/test.c
58-lsocket -lsocket -lnsl -lresolv -ldl -o conf-tmp/test
59conf-tmp/test.c: In function `main':
60conf-tmp/test.c:8: warning: comparison between pointer and integer
61conf-tmp/test.c:10: warning: comparison between pointer and integer
62conf-tmp/test.c:12: warning: comparison between pointer and integer
63conf-tmp/test.c:14: warning: comparison between pointer and integer
64conf-tmp/test.c:16: warning: comparison between pointer and integer
65conf-tmp/test.c:18: warning: comparison between pointer and integer
66conf-tmp/test.c:20: `buf4' undeclared (first use in this function)
67conf-tmp/test.c:20: (Each undeclared identifier is reported only once
68conf-tmp/test.c:20: for each function it appears in.)
69conf-tmp/test.c:20: warning: comparison between pointer and integer
70conf-tmp/test.c:22: warning: comparison between pointer and integer
71check_strtok : *** Command failed (exit code 1)
72check_strtok : didn't find strtok
73 --
74
75While I'm at it, I might as well clip out the section of log of its
76attempt to use dynamic modules. But as advertised, things have worked
77fine in the past without dynamic modules:
78 --
79check_shared : found dlfcn.h in /usr/include
80check_shared : testing dlfcn method
81check_shared : &gt;&gt;&gt; gcc -O2 -fno-strict-aliasing -lsocket -lsocket -lnsl
82-lresolv -ldl conf-tmp/test-dlopen.c -o conf-tmp/test
83check_shared : dlopen() found (no libs)
84check_shared : &gt;&gt;&gt; gcc -rdynamic -O2 -fno-strict-aliasing -lsocket
85-lsocket -lnsl -lresolv -ldl conf-tmp/test-dlopen.c -o conf-tmp/test
86gcc: unrecognized option `-rdynamic'
87check_shared : -rdynamic works
88check_shared : &gt;&gt;&gt; gcc -shared -O2 -fno-strict-aliasing -lsocket
89-lsocket -lnsl -lresolv -ldl conf-tmp/test-lib.c -o conf-tmp/test-lib.so
90Text relocation remains referenced
91 against symbol offset in file
92no_such_symbol 0x0 /var/tmp//cccAI8HB.o
93no_such_symbol 0x4 /var/tmp//cccAI8HB.o
94ld: fatal: relocations remain against allocatable but non-writable
95sections
96collect2: ld returned 1 exit status
97check_shared : *** Command failed (exit code 1)
98check_shared : no -shared, aborting dlfcn test
99check_shared : static modules selected
100 --
101
102
103
104The crash occurs on starting services whenever there are database files
105present. It starts successfully the first time ever, when no databases
106yet exist.
107
108I have attempted two scenarios. I will include the verbose log entries
109and the backtrace from gdb for both circumstances.
110
111
112
113SCENARIO 1. IRC Services was already started with no database files
114present, so that it created blank files. Services is gracefully shut down
115with SIGTERM (leaving new db files behind), and then restarted. It
116segmentation faults and dumps core.
117
118Log file contents:
119 --
120[Jun 08 12:52:14.090067 2003] IRC Services 5.0.19 starting up (options:
121debug)
122[Jun 08 12:52:14.092986 2003] debug: Loading language 0 from file
123`languages/en_us'
124[Jun 08 12:52:14.240809 2003] debug: Loading language 10 from file
125`languages/nl'
126[Jun 08 12:52:14.384819 2003] debug: Loading language 6 from file
127`languages/fr'
128[Jun 08 12:52:14.538818 2003] debug: Loading language 9 from file
129`languages/de'
130[Jun 08 12:52:14.688365 2003] debug: Loading language 11 from file
131`languages/hu'
132[Jun 08 12:52:14.835368 2003] debug: Loading language 8 from file
133`languages/it'
134[Jun 08 12:52:14.946416 2003] debug: Loading language 2 from file
135`languages/ja_euc'
136[Jun 08 12:52:15.108724 2003] debug: Loading language 3 from file
137`languages/ja_sjis'
138[Jun 08 12:52:15.255023 2003] debug: Loading language 5 from file
139`languages/pt'
140[Jun 08 12:52:15.376611 2003] debug: Loading language 4 from file
141`languages/es'
142[Jun 08 12:52:15.527586 2003] debug: Loading language 7 from file
143`languages/tr'
144[Jun 08 12:52:15.671046 2003] debug: Loaded languages
145[Jun 08 12:52:15.672898 2003] debug: Loading module `protocol/unreal'
146[Jun 08 12:52:15.681838 2003] debug: Successfully loaded module
147`protocol/unreal'
148[Jun 08 12:52:15.683772 2003] debug: Loading module `database/version4'
149[Jun 08 12:52:15.693401 2003] debug: Successfully loaded module
150`database/version4'
151[Jun 08 12:52:15.695319 2003] debug: Loading module `mail/main'
152[Jun 08 12:52:15.698281 2003] debug: Successfully loaded module
153`mail/main'
154[Jun 08 12:52:15.700118 2003] debug: Loading module `mail/smtp'
155[Jun 08 12:52:15.702835 2003] debug: Successfully loaded module
156`mail/smtp'
157[Jun 08 12:52:15.704677 2003] debug: Loading module `operserv/main'
158[Jun 08 12:52:15.709453 2003] debug: Successfully loaded module
159`operserv/main'
160[Jun 08 12:52:15.711354 2003] debug: Loading module `operserv/akill'
161[Jun 08 12:52:15.715177 2003] debug: Successfully loaded module
162`operserv/akill'
163[Jun 08 12:52:15.717199 2003] debug: Loading module `operserv/news'
164[Jun 08 12:52:15.720836 2003] debug: Successfully loaded module
165`operserv/news'
166[Jun 08 12:52:15.722642 2003] debug: Loading module `operserv/sessions'
167[Jun 08 12:52:15.727185 2003] debug: Successfully loaded module
168`operserv/sessions'
169[Jun 08 12:52:15.729063 2003] debug: Loading module `operserv/sline'
170[Jun 08 12:52:15.733909 2003] debug: Successfully loaded module
171`operserv/sline'
172[Jun 08 12:52:15.735940 2003] debug: Loading module `nickserv/main'
173[Jun 08 12:52:15.742644 2003] debug: Successfully loaded module
174`nickserv/main'
175[Jun 08 12:52:15.744537 2003] debug: Loading module `nickserv/access'
176[Jun 08 12:52:15.750246 2003] debug: Successfully loaded module
177`nickserv/access'
178[Jun 08 12:52:15.752109 2003] debug: Loading module `nickserv/autojoin'
179[Jun 08 12:52:15.757868 2003] debug: Successfully loaded module
180`nickserv/autojoin'
181[Jun 08 12:52:15.759752 2003] debug: Loading module `nickserv/link'
182[Jun 08 12:52:15.765427 2003] debug: Successfully loaded module
183`nickserv/link'
184[Jun 08 12:52:15.767832 2003] debug: Loading module `memoserv/main'
185[Jun 08 12:52:15.774760 2003] debug: Successfully loaded module
186`memoserv/main'
187[Jun 08 12:52:15.776911 2003] debug: Loading module `memoserv/ignore'
188[Jun 08 12:52:15.783875 2003] debug: Successfully loaded module
189`memoserv/ignore'
190[Jun 08 12:52:15.785721 2003] debug: Loading module `statserv/main'
191 --
192
193Output from gdb:
194 --
195&gt;<i> gdb ../bin/ircservices core
196</I>GNU gdb 5.3
197Copyright 2002 Free Software Foundation, Inc.
198GDB is free software, covered by the GNU General Public License, and you
199are welcome to change it and/or distribute copies of it under certain
200conditions.
201Type &quot;show copying&quot; to see the conditions.
202There is absolutely no warranty for GDB. Type &quot;show warranty&quot; for
203details.
204This GDB was configured as &quot;sparc-sun-solaris2.9&quot;...
205Core was generated by `./ircservices -debug'.
206Program terminated with signal 11, Segmentation fault.
207Reading symbols from /usr/lib/libsocket.so.1...done.
208Loaded symbols for /usr/lib/libsocket.so.1
209Reading symbols from /usr/lib/libnsl.so.1...done.
210Loaded symbols for /usr/lib/libnsl.so.1
211Reading symbols from /usr/lib/libresolv.so.2...done.
212Loaded symbols for /usr/lib/libresolv.so.2
213Reading symbols from /usr/lib/libdl.so.1...done.
214Loaded symbols for /usr/lib/libdl.so.1
215Reading symbols from /usr/lib/libc.so.1...done.
216Loaded symbols for /usr/lib/libc.so.1
217Reading symbols from /usr/lib/libmp.so.2...done.
218Loaded symbols for /usr/lib/libmp.so.2
219Reading symbols from /usr/platform/SUNW,Ultra-1/lib/libc_psr.so.1...done.
220Loaded symbols for /usr/platform/SUNW,Ultra-1/lib/libc_psr.so.1
221#0 0x0003b380 in load_one_serverstats (f=0x25e468) at version4.c:2163
2222163 SAFE(read_int32(&amp;tmp32, f)); /* t_quit */
223(gdb) bt
224#0 0x0003b380 in load_one_serverstats (f=0x25e468) at version4.c:2163
225#1 0x0003b50c in open_statserv_db (dbname=0x25dd78 &quot;stats.db&quot;)
226 at version4.c:2219
227#2 0x00072f6c in init_module_statserv_main (module_=0x0) at main.c:622
228#3 0x00023c08 in internal_init_module (module=0x1) at modules.c:363
229#4 0x00023ce8 in load_module (modulename=0x1065d0 &quot;statserv/main&quot;)
230 at modules.c:392
231#5 0x0001eb0c in init (ac=2, av=0xffbff74c) at init.c:826
232#6 0x00020ec0 in main (ac=2, av=0xffbff74c, envp=0x0) at main.c:192
233 --
234
235
236SCENARIO 2. IRC Services is started with the database files that have
237been correctly working under version 5.0.16. This time, it reports a bus
238error upon booting, and coredumps. The database files are pretty small
239because it's a private server with only a few years -- 3 nicks, no
240channels registered, and some logon news.
241
242Output from the log file:
243 --
244[Jun 08 12:58:35.059589 2003] IRC Services 5.0.19 starting up (options:
245debug)
246[Jun 08 12:58:35.062554 2003] debug: Loading language 0 from file
247`languages/en_us'
248[Jun 08 12:58:35.218619 2003] debug: Loading language 10 from file
249`languages/nl'
250[Jun 08 12:58:35.370950 2003] debug: Loading language 6 from file
251`languages/fr'
252[Jun 08 12:58:35.525613 2003] debug: Loading language 9 from file
253`languages/de'
254[Jun 08 12:58:35.688053 2003] debug: Loading language 11 from file
255`languages/hu'
256[Jun 08 12:58:35.840262 2003] debug: Loading language 8 from file
257`languages/it'
258[Jun 08 12:58:35.959109 2003] debug: Loading language 2 from file
259`languages/ja_euc'
260[Jun 08 12:58:36.110231 2003] debug: Loading language 3 from file
261`languages/ja_sjis'
262[Jun 08 12:58:36.267636 2003] debug: Loading language 5 from file
263`languages/pt'
264[Jun 08 12:58:36.393828 2003] debug: Loading language 4 from file
265`languages/es'
266[Jun 08 12:58:36.547625 2003] debug: Loading language 7 from file
267`languages/tr'
268[Jun 08 12:58:36.707242 2003] debug: Loaded languages
269[Jun 08 12:58:36.709075 2003] debug: Loading module `protocol/unreal'
270[Jun 08 12:58:36.717808 2003] debug: Successfully loaded module
271`protocol/unreal'
272[Jun 08 12:58:36.719731 2003] debug: Loading module `database/version4'
273[Jun 08 12:58:36.729420 2003] debug: Successfully loaded module
274`database/version4'
275[Jun 08 12:58:36.731331 2003] debug: Loading module `mail/main'
276[Jun 08 12:58:36.734309 2003] debug: Successfully loaded module
277`mail/main'
278[Jun 08 12:58:36.736161 2003] debug: Loading module `mail/smtp'
279[Jun 08 12:58:36.738885 2003] debug: Successfully loaded module
280`mail/smtp'
281[Jun 08 12:58:36.740750 2003] debug: Loading module `operserv/main'
282[Jun 08 12:58:36.745704 2003] debug: Successfully loaded module
283`operserv/main'
284[Jun 08 12:58:36.747718 2003] debug: Loading module `operserv/akill'
285[Jun 08 12:58:36.751530 2003] debug: Successfully loaded module
286`operserv/akill'
287[Jun 08 12:58:36.753503 2003] debug: Loading module `operserv/news'
288[Jun 08 12:58:36.757556 2003] debug: Successfully loaded module
289`operserv/news'
290[Jun 08 12:58:36.759519 2003] debug: Loading module `operserv/sessions'
291[Jun 08 12:58:36.764352 2003] debug: Successfully loaded module
292`operserv/sessions'
293[Jun 08 12:58:36.766345 2003] debug: Loading module `operserv/sline'
294[Jun 08 12:58:36.771531 2003] debug: Successfully loaded module
295`operserv/sline'
296[Jun 08 12:58:36.773604 2003] debug: Loading module `nickserv/main'
297 --
298
299Output from GDB:
300 --
301GNU gdb 5.3
302Copyright 2002 Free Software Foundation, Inc.
303GDB is free software, covered by the GNU General Public License, and you
304are
305welcome to change it and/or distribute copies of it under certain
306conditions.
307Type &quot;show copying&quot; to see the conditions.
308There is absolutely no warranty for GDB. Type &quot;show warranty&quot; for
309details.
310This GDB was configured as &quot;sparc-sun-solaris2.9&quot;...
311Core was generated by `./ircservices -debug'.
312Program terminated with signal 10, Bus error.
313Reading symbols from /usr/lib/libsocket.so.1...done.
314Loaded symbols for /usr/lib/libsocket.so.1
315Reading symbols from /usr/lib/libnsl.so.1...done.
316Loaded symbols for /usr/lib/libnsl.so.1
317Reading symbols from /usr/lib/libresolv.so.2...done.
318Loaded symbols for /usr/lib/libresolv.so.2
319Reading symbols from /usr/lib/libdl.so.1...done.
320Loaded symbols for /usr/lib/libdl.so.1
321Reading symbols from /usr/lib/libc.so.1...done.
322Loaded symbols for /usr/lib/libc.so.1
323Reading symbols from /usr/lib/libmp.so.2...done.
324Loaded symbols for /usr/lib/libmp.so.2
325Reading symbols from /usr/platform/SUNW,Ultra-1/lib/libc_psr.so.1...done.
326Loaded symbols for /usr/platform/SUNW,Ultra-1/lib/libc_psr.so.1
327#0 open_nick_db (dbname=0x1e7820 &quot;nick.db&quot;) at version4.c:478
328478 } while (root-&gt;last_realmask);
329(gdb) bt
330#0 open_nick_db (dbname=0x1e7820 &quot;nick.db&quot;) at version4.c:478
331#1 0x00057688 in init_module_nickserv_main (module_=0xa7c00) at
332main.c:1696
333#2 0x00023c08 in internal_init_module (module=0x1) at modules.c:363
334#3 0x00023ce8 in load_module (modulename=0x106558 &quot;nickserv/main&quot;)
335 at modules.c:392
336#4 0x0001eb0c in init (ac=2, av=0xffbff74c) at init.c:826
337#5 0x00020ec0 in main (ac=2, av=0xffbff74c, envp=0x0) at main.c:192
338 --
339
340Let me know if you need more information, and thanks.
341
342 Kevin Kane &lt;<A HREF="http://www.ircservices.za.net/mailman/listinfo/ircservices">kane at firelion.org</A>&gt;
343</PRE>
344
345<!--endarticle-->
346 <HR>
347 <P><UL>
348 <!--threads-->
349 <LI>Previous message: <A HREF="003853.html">[IRCServices] BUG: Services crash under heavy akill removal load.
350</A></li>
351 <LI>Next message: <A HREF="003855.html">[IRCServices] Compiling and Crashing on boot under Solaris 9
352</A></li>
353 <LI> <B>Messages sorted by:</B>
354 <a href="date.html#3854">[ date ]</a>
355 <a href="thread.html#3854">[ thread ]</a>
356 <a href="subject.html#3854">[ subject ]</a>
357 <a href="author.html#3854">[ author ]</a>
358 </LI>
359 </UL>
360
361</body></html>