工作,学习,生活,这里将会有一些记录. 备用域名:http://meisw.wdlinux.cn 注册 | 登陆
浏览模式: 标准 | 列表2009年03月的文章

mysql 编译参数

CFLAGS="-O3" CXX=gcc CXXFLAGS="-O3 -felide-constructors -fno-exceptions -fno-rtti" ./configure --prefix=/servers/mysql --enable-assembler --with-mysqld-ldflags=-all-static --enable-thread-safe-client --with-extra-charsets=gb2312,gbk,utf8,latin1

 

#设置一下 CFLAGS 和 CXXFLAGS,尤其要注意打开 HAVE_DLOPEN 选项
CFLAGS='-O2 -DHAVE_DLOPEN -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector -param=ssp-buffer-size=4 -m64 -mtune=generic'
CXXFLAGS='-O2 -DHAVE_DLOPEN -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector -param=ssp-buffer-size=4 -m64 -mtune=generic'

./configure --prefix=/usr/local/mysql5137 --with-extra-charsets=gb2312,gbk,utf8,latin1 --enable-thread-safe-client \
--with-embedded-server --with-plugins=innobase,archive --with-big-tables --disable-shared --without-man \
--with-mysqld-ldflags=-all-static --with-named-curses-libs=/usr/lib/libncursesw.so.5
make;make install-strip

CC=gcc CFLAGS="-O2" CXX=gcc CXXFLAGS="-O2 -felide-constructors -fno-exceptions -fno-rtti" ./configure --prefix=/www/servers/mysql --with-extra-charsets=gb2312,gbk,utf8,latin1 --enable-thread-safe-client --with-embedded-server --with-plugins=innobase,archive --with-big-tables --disable-shared --with-named-curses-libs=/usr/lib/libncursesw.so.5

20100423

./configure '--prefix=/www/servers/mysql51' '--enable-assembler' '--enable-thread-safe-client' '--with-extra-charsets=gb2312,gbk,utf8,latin1' '--with-named-curses-libs=/usr/lib/libncursesw.so.5' '--without-debug' '--with-embedded-server'

 

CFLAGS="-O3 -march=pentiumpro" CXX=gcc CXXFLAGS="-O3 -march=pentiumpro -felide-constructors -fno-exceptions -fno-rtti" ./configure --prefix=/www/servers/mysql51 --enable-static --enable-assembler --enable-thread-safe-client --with-extra-charsets=gb2312,gbk,utf8,latin1 --with-named-curses-libs=/usr/lib/libncursesw.so.5 --without-debug --with-embedded-server --with-unix-socket-path=/tmp/mysql51.sock --with-pthread --without-innodb


--with-mysqld-ldflags=-all-static

selinux介绍

bind loggin example

logging {
        channel warning
        { file "log/named.log" versions 3 size 2048k;
        severity warning;
        print-category yes;
        print-severity yes;
        print-time yes;
        };      
        channel query
        { file "log/query.log" versions 3 size 2048k;
        severity info;
        print-category yes;
        print-severity yes;
        print-time yes;
        };
        category default { warning; };
        category queries { query; };       
};

Records:271234