]> jfr.im git - irc.git/blame - software/!RELEASES/ircservices/achurch.org/services/lists/ircservices/2006/005124.html
RELEASE -> !RELEASE
[irc.git] / software / !RELEASES / ircservices / achurch.org / services / lists / ircservices / 2006 / 005124.html
CommitLineData
3bd189cb
JR
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
2<HTML>
3 <HEAD>
4 <TITLE> [IRCServices] Support request: Services cannot connect to IRCD,
5 strerror error 22.
6 </TITLE>
7 <LINK REL="Index" HREF="index.html" >
8 <LINK REL="made" HREF="mailto:ircservices%40ircservices.esper.net?Subject=%5BIRCServices%5D%20Support%20request%3A%20Services%20cannot%20connect%20to%20IRCD%2C%0A%09strerror%20error%2022.&In-Reply-To=">
9 <META NAME="robots" CONTENT="index,nofollow">
10 <META http-equiv="Content-Type" content="text/html; charset=us-ascii">
11 <LINK REL="Previous" HREF="005125.html">
12 <LINK REL="Next" HREF="005126.html">
13 </HEAD>
14 <BODY BGCOLOR="#ffffff">
15 <H1>[IRCServices] Support request: Services cannot connect to IRCD,
16 strerror error 22.</H1>
17 <B>Dave Moore</B>
18 <A HREF="mailto:ircservices%40ircservices.esper.net?Subject=%5BIRCServices%5D%20Support%20request%3A%20Services%20cannot%20connect%20to%20IRCD%2C%0A%09strerror%20error%2022.&In-Reply-To="
19 TITLE="[IRCServices] Support request: Services cannot connect to IRCD,
20 strerror error 22.">dave.j.moore at gmail.com
21 </A><BR>
22 <I>Tue Feb 14 12:23:32 PST 2006</I>
23 <P><UL>
24 <LI>Previous message: <A HREF="005125.html">[IRCServices] mlocking channel modes O and A
25</A></li>
26 <LI>Next message: <A HREF="005126.html">[IRCServices] ircservices 4.5.45
27</A></li>
28 <LI> <B>Messages sorted by:</B>
29 <a href="date.html#5124">[ date ]</a>
30 <a href="thread.html#5124">[ thread ]</a>
31 <a href="subject.html#5124">[ subject ]</a>
32 <a href="author.html#5124">[ author ]</a>
33 </LI>
34 </UL>
35 <HR>
36<!--beginarticle-->
37<PRE>Hello all. I am using IRCServices 5.0.57 on UltimateIRCd(Tsunami)-3.0(01),
38though this problem occurs regardless of what IRCd is used. (Services never
39makes it to the IRCd)
40
41Following are a C&amp;P of services' log, followed by the contents of socktest.c,
42which is a socket testing program my buddy wrote (so he says) for me,
43followed by the output of ./socktest.
44
45I hope I've provided enough information, if anyone needs more information or
46needs me to take any additional steps for further troubleshooting, that's no
47problem at all.
48
49Any help would be appreciated, thanks in advance.
50
51Dave
52
53Logs:
54[Feb 14 20:12:25.677031 2006] IRC Services 5.0.57 starting up (options:
55debug)
56[Feb 14 20:12:25.722001 2006] debug: Loading language 0 from file
57`languages/en_us'
58[Feb 14 20:12:25.728089 2006] debug: Loading language 10 from file
59`languages/nl'
60[Feb 14 20:12:25.734271 2006] debug: Loading language 6 from file
61`languages/fr'
62[Feb 14 20:12:25.740649 2006] debug: Loading language 9 from file
63`languages/de'
64[Feb 14 20:12:25.747259 2006] debug: Loading language 11 from file
65`languages/hu'
66[Feb 14 20:12:25.753610 2006] debug: Loading language 8 from file
67`languages/it'
68[Feb 14 20:12:25.758795 2006] debug: Loading language 2 from file
69`languages/ja_euc'
70[Feb 14 20:12:25.764741 2006] debug: Loading language 3 from file
71`languages/ja_sjis'
72[Feb 14 20:12:25.770444 2006] debug: Loading language 5 from file
73`languages/pt'
74[Feb 14 20:12:25.779258 2006] debug: Loading language 12 from file
75`languages/ru'
76[Feb 14 20:12:25.785985 2006] debug: Loading language 4 from file
77`languages/es'
78[Feb 14 20:12:25.792501 2006] debug: Loading language 7 from file
79`languages/tr'
80[Feb 14 20:12:25.798826 2006] debug: Loaded languages
81[Feb 14 20:12:25.802596 2006] debug: Loading module `protocol/bahamut'
82[Feb 14 20:12:25.809033 2006] debug: Successfully loaded module
83`protocol/bahamut'
84[Feb 14 20:12:25.812829 2006] debug: Loading module `database/version4'
85[Feb 14 20:12:25.821537 2006] debug: Successfully loaded module
86`database/version4'
87[Feb 14 20:12:25.825316 2006] debug: Loading module `mail/main'
88[Feb 14 20:12:25.830547 2006] debug: Successfully loaded module `mail/main'
89[Feb 14 20:12:25.834844 2006] debug: Loading module `mail/smtp'
90[Feb 14 20:12:25.841417 2006] debug: Successfully loaded module `mail/smtp'
91[Feb 14 20:12:25.844974 2006] debug: Loading module `operserv/main'
92[Feb 14 20:12:25.852625 2006] debug: Successfully loaded module
93`operserv/main'
94[Feb 14 20:12:25.856821 2006] debug: Loading module `operserv/akill'
95[Feb 14 20:12:25.862871 2006] debug: Successfully loaded module
96`operserv/akill'
97[Feb 14 20:12:25.866979 2006] debug: Loading module `operserv/news'
98[Feb 14 20:12:25.872761 2006] debug: Successfully loaded module
99`operserv/news'
100[Feb 14 20:12:25.876803 2006] debug: Loading module `operserv/sessions'
101[Feb 14 20:12:25.883016 2006] debug: Successfully loaded module
102`operserv/sessions'
103[Feb 14 20:12:25.888510 2006] debug: Loading module `operserv/sline'
104[Feb 14 20:12:25.894708 2006] debug: Successfully loaded module
105`operserv/sline'
106[Feb 14 20:12:25.898628 2006] debug: Loading module `nickserv/main'
107[Feb 14 20:12:25.910032 2006] debug: Successfully loaded module
108`nickserv/main'
109[Feb 14 20:12:25.913969 2006] debug: Loading module `nickserv/access'
110[Feb 14 20:12:25.920316 2006] debug: Successfully loaded module
111`nickserv/access'
112[Feb 14 20:12:25.924218 2006] debug: Loading module `nickserv/link'
113[Feb 14 20:12:25.930096 2006] debug: Successfully loaded module
114`nickserv/link'
115[Feb 14 20:12:25.933580 2006] debug: Loading module `nickserv/mail-auth'
116[Feb 14 20:12:25.940245 2006] debug: Successfully loaded module
117`nickserv/mail-auth'
118[Feb 14 20:12:25.944046 2006] debug: Loading module `nickserv/sendpass'
119[Feb 14 20:12:25.951050 2006] debug: Successfully loaded module
120`nickserv/sendpass'
121[Feb 14 20:12:25.954684 2006] debug: Loading module `chanserv/main'
122[Feb 14 20:12:25.963185 2006] debug: Successfully loaded module
123`chanserv/main'
124[Feb 14 20:12:25.967062 2006] debug: Loading module `chanserv/access-levels'
125[Feb 14 20:12:25.974581 2006] debug: Successfully loaded module
126`chanserv/access-levels'
127[Feb 14 20:12:25.978429 2006] debug: Loading module `chanserv/sendpass'
128[Feb 14 20:12:25.984940 2006] debug: Successfully loaded module
129`chanserv/sendpass'
130[Feb 14 20:12:25.989298 2006] debug: Loading module `memoserv/main'
131[Feb 14 20:12:25.996230 2006] debug: Successfully loaded module
132`memoserv/main'
133[Feb 14 20:12:25.999969 2006] debug: Loading module `memoserv/forward'
134[Feb 14 20:12:26.006549 2006] debug: Successfully loaded module
135`memoserv/forward'
136[Feb 14 20:12:26.010419 2006] debug: Loading module `memoserv/ignore'
137[Feb 14 20:12:26.014360 2006] debug: Successfully loaded module
138`memoserv/ignore'
139[Feb 14 20:12:26.015657 2006] debug: Loading module `statserv/main'
140[Feb 14 20:12:26.020414 2006] debug: Successfully loaded module
141`statserv/main'
142[Feb 14 20:12:26.021535 2006] debug: Loading module `misc/helpserv'
143[Feb 14 20:12:26.025979 2006] debug: Successfully loaded module
144`misc/helpserv'
145[Feb 14 20:12:26.026995 2006] debug: Loading module `httpd/main'
146[Feb 14 20:12:26.031818 2006] httpd/main: Listening on 72.20.8.98:5347
147[Feb 14 20:12:26.033102 2006] debug: Successfully loaded module `httpd/main'
148[Feb 14 20:12:26.034463 2006] debug: Loading module `httpd/auth-ip'
149[Feb 14 20:12:26.039295 2006] debug: Successfully loaded module
150`httpd/auth-ip'
151[Feb 14 20:12:26.040407 2006] debug: Loading module `httpd/auth-password'
152[Feb 14 20:12:26.044648 2006] debug: Successfully loaded module
153`httpd/auth-password'
154[Feb 14 20:12:26.045835 2006] debug: Loading module `misc/xml-export'
155[Feb 14 20:12:26.050744 2006] debug: Successfully loaded module
156`misc/xml-export'
157[Feb 14 20:12:26.051928 2006] debug: Loading module `misc/xml-import'
158[Feb 14 20:12:26.057501 2006] debug: Successfully loaded module
159`misc/xml-import'
160[Feb 14 20:12:26.058620 2006] debug: Loaded modules
161[Feb 14 20:12:26.068373 2006] FATAL: Can't connect to server (
16272.20.8.98:8899): Invalid argument
163
164--END LOG--
165
166Code from socktest.c:
167#include &lt;stdarg.h&gt;
168#include &lt;stdio.h&gt;
169#include &lt;stdlib.h&gt;
170#include &lt;string.h&gt;
171#include &lt;unistd.h&gt;
172#include &lt;signal.h&gt;
173#include &lt;time.h&gt;
174#include &lt;errno.h&gt;
175#include &lt;grp.h&gt;
176#include &lt;limits.h&gt;
177#include &lt;netdb.h&gt;
178#include &lt;netinet/in.h&gt;
179#include &lt;sys/socket.h&gt;
180#include &lt;sys/stat.h&gt; /* for umask() on some systems */
181#include &lt;sys/types.h&gt;
182#include &lt;sys/time.h&gt;
183
184int conn(const char *host, int port, const char *lhost, int lport);
185void disconn(int s);
186
187int conn(const char *host, int port, const char *lhost, int lport)
188{
189struct hostent *hp;
190struct sockaddr_in sa, lsa;
191int sock;
192
193printf(&quot;Conn() called\n&quot;);
194
195memset(&amp;lsa, 0, sizeof(lsa));
196if (lhost) {
197if ((hp = gethostbyname(lhost)) != NULL) {
198memcpy((char *) &amp;lsa.sin_addr, hp-&gt;h_addr, hp-&gt;h_length);
199lsa.sin_family = hp-&gt;h_addrtype;
200} else {
201lhost = NULL;
202}
203}
204if (lport)
205lsa.sin_port = htons((unsigned short) lport);
206
207printf(&quot;Conn() LocalHost stuff setup\n&quot;);
208
209memset(&amp;sa, 0, sizeof(sa));
210if (!(hp = gethostbyname(host))) {
211printf(&quot;Error during gethostbyname\n&quot;);
212return -1;
213}
214printf(&quot;Conn() gethostbyname successful\n&quot;);
215
216memcpy((char *) &amp;sa.sin_addr, hp-&gt;h_addr, hp-&gt;h_length);
217sa.sin_family = hp-&gt;h_addrtype;
218sa.sin_port = htons((unsigned short) port);
219
220printf(&quot;Conn() before socket call\n&quot;);
221
222printf(&quot;Check sa family %d AF_INET %d\n&quot;, sa.sin_family, AF_INET);
223printf(&quot;Check sa port %d %d htons check %d\n&quot;, port, sa.sin_port,
224htons((unsigned short) port));
225printf(&quot;Check sa address %s\n&quot;, inet_ntoa(sa.sin_addr));
226
227if ((sock = socket(sa.sin_family, SOCK_STREAM, 0)) &lt; 0) {
228printf(&quot;Error during socket\n&quot;);
229return -1;
230}
231printf(&quot;Conn() sock %d\n&quot;, sock);
232
233if ((lhost || lport)
234&amp;&amp; bind(sock, (struct sockaddr *) &amp;lsa, sizeof(lsa)) &lt; 0) {
235close(sock);
236printf(&quot;Error during bind\n&quot;);
237return -1;
238}
239
240if (connect(sock, (struct sockaddr *) &amp;sa, sizeof(sa)) &lt; 0) {
241printf(&quot;Error during connect\n&quot;);
242printf(&quot;Errno is %d\n&quot;, errno);
243printf(&quot;strerror says %s\n&quot;, strerror(errno));
244printf(&quot;Check sizeof(sa) %ld\n&quot;, sizeof(sa));
245printf(&quot;Check socket %d\n&quot;, sock);
246printf(&quot;Check sa family %d AF_INET %d\n&quot;, sa.sin_family, AF_INET);
247printf(&quot;Check sa port %d\n&quot;, sa.sin_port);
248printf(&quot;Check sa address %s\n&quot;, inet_ntoa(sa.sin_addr));
249
250close(sock);
251return -1;
252}
253printf(&quot;Successful sock value %d&quot;, sock);
254return sock;
255}
256
257/*************************************************************************/
258
259void disconn(int s)
260{
261shutdown(s, 2);
262close(s);
263}
264
265int main(int ac, char **av, char **envp)
266{
267int s;
268printf(&quot;Calling conn()\n&quot;);
269s = conn(&quot;72.20.8.98&quot;, 8899, &quot;72.20.8.98&quot;, 8891);
270printf(&quot;after conn()\n&quot;);
271disconn(s);
272printf(&quot;exit\n&quot;);
273return 0;
274}
275
276
277--END OF socktest.c--
278
279
280And, finally, the output from socktest.c:
281
282Calling conn()
283Conn() called
284Conn() LocalHost stuff setup
285Conn() gethostbyname successful
286Conn() before socket call
287Check sa family 2 AF_INET 2
288Check sa port 8899 49954 htons check 49954
289Check sa address 72.20.8.98
290Conn() sock 3
291Error during connect
292Errno is 22
293strerror says Invalid argument
294Check sizeof(sa) 16
295Check socket 3
296Check sa family 2 AF_INET 2
297Check sa port 49954
298Check sa address 72.20.8.98
299after conn()
300exit
301
302--END OF socktest output--
303-------------- next part --------------
304An HTML attachment was scrubbed...
305URL: <A HREF="../attachments/20060214/a368be7a/attachment-0001.html">../attachments/20060214/a368be7a/attachment-0001.html</A>
306</PRE>
307
308
309
310<!--endarticle-->
311 <HR>
312 <P><UL>
313 <!--threads-->
314 <LI>Previous message: <A HREF="005125.html">[IRCServices] mlocking channel modes O and A
315</A></li>
316 <LI>Next message: <A HREF="005126.html">[IRCServices] ircservices 4.5.45
317</A></li>
318 <LI> <B>Messages sorted by:</B>
319 <a href="date.html#5124">[ date ]</a>
320 <a href="thread.html#5124">[ thread ]</a>
321 <a href="subject.html#5124">[ subject ]</a>
322 <a href="author.html#5124">[ author ]</a>
323 </LI>
324 </UL>
325
326</body></html>