ÔÚUbuntuÖÐͨ¹ýÔ´Âë°²×°±àÒë°²×°Èí¼þ(MySQLƪ)
ʹÓÃUbuntu
Server×÷Ϊ±¾µØ²âÊÔ»·¾³ÒѾÓÐÒ»¶Îʱ¼äÁË£¬Ò»Ö±¶¼ÊÇʹÓÃapt-get·½Ê½À´°²×°¸÷ÖÖÓ¦ÓÃÈí¼þ£¬Í¨¹ýÔ´Âë±àÒë°²×°Ó¦ÓÃÈí¼þÊÇLinuxºÍUnix»·
¾³ÏÂ×î³£Óõķ½Ê½¡£Í¨¹ýÔ´Âë±àÒë°²×°µÄ×î´óºÃ´¦¾ÍÊÇÄãÖªµÀ×Ô¼º×öÁËʲô£¬ÕâÖÖ·½Ê½°²×°Èí¼þ×ÔÓÉÁé»î£¬Ò²ÊÊÓÃÓÚ¸÷ÖÖƽ̨¡¢Î¬»¤·½±ã£»±¾ÏµÁÐÎÄÕ¶¼ÊÇÔÚ
Ubuntu ServerϵͳµÄÃüÁîÐÐģʽÏÂÍê³É¡£
ÔÚ½øÐÐÔ´Âë±àÒ밲װ֮ǰ£¬ÎÒÃÇÊ×ÏÈÐèÒª×÷ÈçϵÄ×¼±¸¹¤×÷£º
1¡¢¸üÐÂÄúµÄUbuntu
sudo apt-get update
sudo apt-get upgrade
2¡¢°²×°ËùÐèÈí¼þ°ü
sudo
apt-get install binutils cpp fetchmail flex gcc libarchive-zip-perl
libc6-dev libcompress-zlib-perl libdb4.3-dev libpcre3 libpopt-dev lynx
m4 make ncftp nmap perl perl-modules unzip zip zlib1g-dev autoconf
automake1.9 libtool bison autotools-dev g++ build-essential
apt-get¿ÉÒ»´Î°²×°¶à¸öÈí¼þ,ÒÔÉÏ°²×°¿É¸ù¾ÝÐèҪѡװ.ÔÚ°²×°¹ý³ÌÖпÉÄÜ»áÌáʾÄã²åÈëUbuntuµÄ¹âÅÌ.Èç¹ûͨ¹ýSSHÔ¶³Ì¹ÜÀíUbuntu³öÏÖÂÒÂë,²»ÄÜÕý³£²é¿´ºº×ÖÐÅÏ¢,Çë²Î¿¼PuTTYÁ¬UbuntuµÄSSH³öÏÖÂÒÂëµÄ´¦Àí
3¡¢°²×°libncurses5-dev
sudo apt-get install libncurses5-dev
ͨ¹ýÔ´Âë±àÒë°²×°Èí¼þʱ£¬³öÏÖ´íÎóÐÅÏ¢£º
checking for termcap functions library… configure: error: No curses/termcap library found
°²×°libncurses5-dev¿â·½¿É½â¾ö.
½ñÌìÊ×ÏȽéÉܵÄÊÇLAMP×éÖÐ×÷ΪÊý¾Ý´æ´¢µÄMySQLµÄÔ´Âë±àÒë°²×°¹ý³Ì:
mysqlʹÓÃutf-8×÷ΪĬÈϱàÂ룺
groupadd mysql
useradd -g mysql mysql
tar -zxvf mysql-5.0.45.tar.gz
cd mysql-5.0.45
./configure –prefix=/usr/local/mysql –with-charset=utf8 –with-collation=utf8_general_ci –with-extra-charsets=latin1
make
make install
cp support-files/my-medium.cnf /etc/my.cnf
Æô¶¯vimÐÞ¸Ämy.cnfÎļþ
vim /etc/my.cnf
ÕÒµ½log-bin=mysql-binÕâÒ»ÐУ¬½«Æä×¢Ê͵ô:#log-bin=mysql-bin
cd /usr/local/mysql
bin/mysql_install_db --user=mysql
chown -R root .
chown -R mysql /usr/local/mysql/var
chgrp -R mysql .
Æô¶¯MySQL:
bin/mysqld_safe --user=mysql &
ÈÃmysqlËæϵͳһÆðÆô¶¯:
Ê
Ïà¹ØÎĵµ£º
Query ProfilerÊÇMYSQL×Ô´øµÄÒ»ÖÖqueryÕï¶Ï·ÖÎö¹¤¾ß£¬Í¨¹ýËü¿ÉÒÔ·ÖÎö³öÒ»ÌõSQLÓï¾äµÄÐÔÄÜÆ¿¾±ÔÚʲôµØ·½¡£Í¨³£ÎÒÃÇÊÇʹÓõÄexplain,ÒÔ¼°slow query log¶¼ÎÞ·¨×öµ½¾«È··ÖÎö£¬µ«ÊÇQuery ProfilerÈ´¿ÉÒÔ¶¨Î»³öÒ»ÌõSQLÓï¾äÖ´Ðеĸ÷ÖÖ×ÊÔ´ÏûºÄÇé¿ö£¬±ÈÈçCPU£¬IOµÈ£¬ÒÔ¼°¸ÃSQLÖ´ÐÐËùºÄ·ÑµÄʱ¼äµÈ¡£²»¹ý¸Ã¹¤¾ßÖ»ÓÐÔÚMYSQL 5.0.37ÒÔ ......
MySQL ODBC connection strings
Open connection to local MySQL database using MySQL ODBC 3.51 Driver
"Provider=MSDASQL; DRIVER={MySQL ODBC 3.51Driver}; SERVER= localhost; DATABASE=Your_MySQL_Database; UID= Your_Username; PASSWORD=Your_Password; OPTION=3"
MySQL OLE DB & OleDbConnection (.NET fr ......
mysqlÊÇÒ»¸öÓÅÐãµÄ¿ªÔ´Êý¾Ý¿â£¬ËüÏÖÔÚµÄÓ¦Ó÷dz£µÄ¹ã·º£¬Òò´ËºÜÓбØÒª¼òµ¥µÄ½éÉÜÒ»ÏÂÓÃpython²Ù×÷mysqlÊý¾Ý¿âµÄ·½·¨¡£python²Ù×÷Êý¾Ý¿âÐèÒª°²×°Ò»¸öµÚÈý·½µÄÄ£¿é£¬ÔÚhttp://mysql-python.sourceforge.net/
ÓÐÏÂÔغÍÎĵµ¡£
ÓÉÓÚpythonµÄÊý¾Ý¿âÄ£¿éÓÐרÃŵÄÊý¾Ý¿âÄ£¿éµÄ¹æ·¶£¬ËùÒÔ£¬Æäʵ²»¹ÜʹÓÃÄÄÖÖÊý¾ ......
×î½üÓõ½ÁËÒ»¿îÊý¾Ý¿âͼÐλ¯¹ÜÀí¹¤¾ßNavicat for MySQL £¬Ê¹ÓÃÖ®ºóÓÐÒ»Öָоõ£ºÔÀ´±à³Ì¿ÉÒԺܸßЧ£¡
ÒÔǰʹÓÃMySQLʱ£¬Ã¿´Î¶¼Ö»ÄÜÔÚÀàËÆDOSµÄ½çÃ濪·¢£¬Ê¹Óùٷ½ÌṩµÄ¹¤¾ßºÜÈÝÒ׾ͱ»¿¨µ½ÁË£¬¾õµÃ»¹ÊÇ×ÖÌõ½çÃæ±È½Ï¸ßЧ£¬µ«ÊdzõѧMySQL,ºÜ¶à¹¦Äܶ¼»¹Ã»ÓÐÍêÈ«Çå³þ£¬Ê¹Óð²È«ÐÔÉϵĿ¼ÂÇÒ²²»¹»³ÉÊì¡£ÕâʱºòÎÒ¿ ......
MYSQLÓв»Í¬ÀàÐ͵ÄÈÕÖ¾Îļþ(¸÷×Ô´æ´¢Á˲»Í¬ÀàÐ͵ÄÈÕÖ¾)£¬´ÓËüÃǵ±ÖпÉÒÔ²éѯµ½MYSQLÀﶼ×öÁËЩʲô£¬¶ÔÓÚMYSQLµÄ¹ÜÀí¹¤×÷£¬ÕâЩÈÕÖ¾ÎļþÊDz»¿ÉȱÉٵġ£
1.´íÎóÈÕÖ¾(The error log)£º¼Ç¼ÁËÊý¾Ý¿âÆô¶¯¡¢ÔËÐÐÒÔ¼°Í£Ö¹¹ý³ÌÖдíÎóÐÅÏ¢£»
2.ISAM²Ù×÷ÈÕÖ¾(The isam log)£º¼Ç¼ÁËËùÓжÔISAM±íµÄÐ޸ģ¬¸ÃÈÕÖ¾½ö½öÓÃÓÚµ÷ÊÔISAMģʽ ......