Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
From: <ppetrakis@firestorm.tzo.org>
To: axp-list@redhat.com
Cc: "MySQL (E-mail)" <mysql@lists.mysql.com>
Subject: Re: UPDATE: DATETIME fields incorrect on alpha
Date: Mon, 13 Dec 1999 18:33:23 -0500 (EST)	[thread overview]
Message-ID: <Pine.LNX.4.10.9912131816150.24303-100000@voodoo.alphalinux.org> (raw)
In-Reply-To: <Pine.LNX.4.10.9912130321170.2187-100000@dialup.isc.tuc.gr>



On Mon, 13 Dec 1999, Nikolaos Ntarmos wrote:
 
> TCP_NODELAY is simply defined to be 1 , provided that __KERNEL__ is defined :
> #if defined(__KERNEL__) || !defined(__GLIBC__) || (__GLIBC__ < 2)
> ...
> #define TCP_NODELAY     1
> ...
> #endif /* not kernel and not glibc */
> 
> in the file $KERNEL_ROOT/include/linux/socket.h and therefore in the standard
> /usr/include/linux/socket.h. All this in my 2.2.14pre9-based system. Try
> defining __KERNEL__ (-D__KERNEL__) during compilation or hardcoding 1 for
> TCP_NODELAY.
> 
> Hope i helped...

Yes you did help :-) Thank you. Here's what I did.
Turns out there was another file that was effected the same way. I patched
them as follows:

diff -uNr mysql-3.23.7-alpha-GOLD/client/net.c
mysql-3.23.7-alpha/client/net.c
--- mysql-3.23.7-alpha-GOLD/client/net.c        Mon Nov 29 14:29:51 1999
+++ mysql-3.23.7-alpha/client/net.c     Mon Dec 13 11:52:54 1999
@@ -8,6 +8,9 @@
 ** 3 byte length & 1 byte package-number.
 */
+#ifdef alpha_linux_port
+#define TCP_NODELAY 1
+#endif
 #ifdef _WIN32
 #include <winsock.h>
 #endif
diff -uNr mysql-3.23.7-alpha-GOLD/sql/net_serv.c
mysql-3.23.7-alpha/sql/net_serv.c
--- mysql-3.23.7-alpha-GOLD/sql/net_serv.c      Mon Nov 29 14:29:51 1999
+++ mysql-3.23.7-alpha/sql/net_serv.c   Mon Dec 13 13:30:12 1999
@@ -8,6 +8,9 @@
 ** 3 byte length & 1 byte package-number.
 */
+#ifdef alpha_linux_port
+#define TCP_NODELAY 1
+#endif
 #ifdef _WIN32
 #include <winsock.h>
 #endif

Since I pass -D_alpha_linux_port to enable big file support it will catch
it and make the define. (BTW it still dumps core with the
-D_alpha_linux_port flag)

Now I can get this thing to finally compile but it it still SEGV's at
startup.

I went back to the stable release of MySQL for now (since they both dump
core might as well get the one that's stable working first) and ran gdb on
the core again.

[root@voodoo:~]$ mysqld
Segmentation fault (core dumped)
[root@voodoo:~]$ gdb mysqld core
GNU gdb 4.17.0.11 with Linux support
Copyright 1998 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 "alpha-redhat-linux"...
Core was generated by `mysqld'.
Program terminated with signal 11, Segmentation fault.
#0  0x1200d4208 in pthread_setcanceltype (type=1, oldtype=0x11ffffa80)
    at cancel.c:42
42        if (oldtype != NULL) *oldtype = THREAD_GETMEM(self,
p_canceltype);
(gdb) bt
#0  0x1200d4208 in pthread_setcanceltype (type=1, oldtype=0x11ffffa80)
    at cancel.c:42
#1  0x1200d3368 in fcntl (fd=0, cmd=1) at wrapsyscall.c:77
#2  0x1200ddd44 in check_standard_fds () at
../sysdeps/generic/libc-start.c:99
#3  0x1200ddf30 in __libc_start_main (main=0x120041bc0 <main>, argc=1,
    argv=0x11ffffb68, init=0x120000120 <_init>, fini=0x12013e260 <_fini>,
    rtld_fini=0, stack_end=0x11ffffb50) at
../sysdeps/generic/libc-start.c:60
Current language:  auto; currently c
(gdb) l
37      int pthread_setcanceltype(int type, int * oldtype)
38      {
39        pthread_descr self = thread_self();
40        if (type < PTHREAD_CANCEL_DEFERRED || type >
PTHREAD_CANCEL_ASYNCHRONOUS)
41          return EINVAL;
42        if (oldtype != NULL) *oldtype = THREAD_GETMEM(self,
p_canceltype);
43        THREAD_SETMEM(self, p_canceltype, type);
44        if (THREAD_GETMEM(self, p_canceled) &&
45            THREAD_GETMEM(self, p_cancelstate) == PTHREAD_CANCEL_ENABLE
&&
46            THREAD_GETMEM(self, p_canceltype) ==
PTHREAD_CANCEL_ASYNCHRONOUS)
(gdb) 
...

(gdb) run
The program being debugged has been started already.
Start it from the beginning? (y or n) y
Starting program: /usr/sbin/mysqld
Breakpoint 1, pthread_setcanceltype (type=1, oldtype=0x11ffffac0)
    at cancel.c:38
38      {
(gdb) cont
Continuing.
Breakpoint 2, pthread_setcanceltype (type=1, oldtype=0x11ffffac0)
    at cancel.c:40
40        if (type < PTHREAD_CANCEL_DEFERRED || type >
PTHREAD_CANCEL_ASYNCHRONOUS)
(gdb) cont
Continuing.
Breakpoint 4, pthread_setcanceltype (type=1, oldtype=0x11ffffac0)
    at cancel.c:42
42        if (oldtype != NULL) *oldtype = THREAD_GETMEM(self,
p_canceltype);
(gdb) cont
Continuing.
Program received signal SIGSEGV, Segmentation fault.
0x1200d4208 in pthread_setcanceltype (type=1, oldtype=0x11ffffac0)
    at cancel.c:42
42        if (oldtype != NULL) *oldtype = THREAD_GETMEM(self,
p_canceltype);
(gdb) cont
Continuing.
Error accessing memory address 0x120286088: No such process.


This is over my head. Any ideas?
Thanks.

Peter
--
www.alphalinux.org
Peter Petrakis         Warrior/Engineer        ppetrakis@alphalinux.org
"Oh my God! They killed Xena! You bastards!!"
"<BLAM!!> Who the hell are you!? Name's Ash <click clock> Housewares..." 


      reply	other threads:[~1999-12-13 23:33 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-12-13  2:11 UPDATE: DATETIME fields incorrect on alpha ppetrakis
1999-12-13  3:32 ` Nikolaos Ntarmos
1999-12-13 23:33   ` ppetrakis [this message]
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox