mysql 3.23.49_mysql 3.2.49 源代码安装-redhat 5 x64

本文档详细介绍了在Redhat 5 x64系统上,如何通过源代码安装mysql 3.23.49。在安装过程中,遇到了Linuxthreads不兼容新内核的问题,通过修改pthread.h文件和安装libtool解决了问题。随后,成功配置并编译了mysql源码,完成了安装。
摘要由CSDN通过智能技术生成

[mysql@localhost ~]$ uname -r

2.6.32

[root@localhost ~]#cp /usr/include/pthread.h /usr/include/pthread.h.bak

[root@localhost ~]#echo '/* Linuxthreads */' >> /usr/include/pthread.h

解决

checking for int8... no checking "LinuxThreads"... "Not found" configure: error: This is a linux system and Linuxthreads was not found. On linux Linuxthreads should be used.  Please install Linuxthreads (or a new glibc) and try again.  See the Installation chapter in the Reference Manual for more information.

原因:新内核使用了NTPL这种先进的线程处理方式,

[root@localhost ~]#tar   -zxvf  libtool-1.4.1.tar.gz

./configure &&make$$make install

[root@localhost ~]#tar   -zxvf  mysql-3.23.49.tar.gz

[root@localhost ~]# cd mysql-3.23.49

[root@localhost mysql-3.23.49]#CFLAGS="-O0 -mpentiumpro" CXXFLAGS="-O0 -mpentiumpro -felide-constructors -fno-exceptions -fno-rtti" ./configure --prefix=/usr/local/mysql --enable-assembler --with-mysqld-ldflags=-all-static --with-innodb --with-debug

不指明 CXX=gcc  ,否则在在MAKE时出错

[root@localhost mysql-3.23.49]# cp /usr/local/bin/libtool .

替换当前目录版本

顺序不能倒

[root@localhost mysql-3.23.49]#make

[root@localhost mysql-3.23.49]#make install

mysql 服务目录

[mysql@localhost libexec]$ pwd

/usr/local/mysql/libexec

[mysql@localhost libexec]$ ls

mysqld

mysql 客户端目录

[mysql@localhost bin]$ ls

comp_err mysqlbug mysql_setpermission

isamchk mysqlcheck mysqlshow

isamlog mysql_config mysqltest

msql2mysql mysql_convert_table_format mysql_zap

myisamchk mysqld_multi pack_isam

myisamlog mysqldump perror

myisampack mysqldumpslow replace

my_print_defaults mysql_find_rows resolveip

mysql mysql_fix_privilege_tables resolve_stack_dump

mysqlaccess mysqlhotcopy safe_mysqld

mysqladmin mysqlimport

mysqlbinlog mysql_install_db

[mysql@localhost bin]$ pwd/usr/local/mysql/bin

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值