Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

ÐÞ¸ÄmysqlµÄĬÈÏ×Ö·û¼¯

 °²×°mysql
sudo apt-get install mysql-server#Ö±½Ó×Ô¶¯»ñµÃ¿ÉÓð汾
Ò²¿ÉÒÔÕâÑùд
sudo apt-geti nstall mysql-server-5.0#°²×°mysql·þÎñÆ÷5.0°æ±¾
°²×°ºó
/etc/init.d/mysqlstart(stop)ΪÆô¶¯ºÍÍ£Ö¹·þÎñÆ÷
/etc/mysql/Ö÷ÒªÅäÖÃÎļþËùÔÚλÖÃmy.cnf
/var/lib/mysql/·ÅÖõÄÊÇÊý¾Ý¿â±íÎļþ¼Ð£¬ÕâÀïµÄmysqlÏ൱ÓÚwindowsÏÂmysqlµÄdateÎļþ¼Ð
Æô¶¯mysqlºó£¬ÒÔrootµÇ¼mysql
isher@isher-ubuntu:~$mysql-uroot
>showvariableslike''character%'';#Ö´ÐбàÂëÏÔʾ
-------------------------- ----------------------------
|Variable_name|Value|
-------------------------- ----------------------------
|character_set_client|latin1|
|character_set_connection|latin1|
|character_set_database|latin1|
|character_set_filesystem|binary|
|character_set_results|latin1|
|character_set_server|latin1|
|character_set_system|utf8|
|character_sets_dir|/usr/share/mysql/charsets/|
-------------------------- ----------------------------
ÔÚijЩʱºò£¬ÎÒÃÇÐøÒªÐÞ¸ÄmysqlĬÈÏÊý¾Ý¿âµÄ±àÂ룬ÒÔ±£Ö¤Ä³Ð©Ç¨ÒƵijÌÐò¿ÉÒÔÕý³£ÏÔʾ£¬±à¼­my.cnfÎļþ½øÐбàÂëÐÞ¸Ä,windows¿ÉÒÔÖ±½ÓÓãÍysqlServerInstanceConfigWizard½øÐÐÉèÖÃ
ÔÚlinuxÏÂÐÞ¸Ä3¸ömy.cnfµÄ1¸ö/etc/mysql/my.cnfÎļþ
ÕÒµ½¿Í»§¶ËÅäÖÃ[client]ÔÚÏÂÃæÌí¼Ó
default-character-set=utf8ĬÈÏ×Ö·û¼¯Îªutf8
ÔÚÕÒµ½[mysqld]Ìí¼Ó
default-character-set=utf8ĬÈÏ×Ö·û¼¯Îªutf8
init_connect=''SET NAMES utf8''£¨É趨Á¬½ÓmysqlÊý¾Ý¿âʱʹÓÃutf8±àÂ룬ÒÔÈÃmysqlÊý¾Ý¿âΪutf8ÔËÐУ©
Ð޸ĺúó£¬ÖØÐÂÆô¶¯mysql¼´¿É£¬²éѯһÏÂshow variables like ''character%'';
-------------------------- ----------------------------
|Variable_name|Value|
-------------------------- ----------------------------
|character_set_client|utf8|
|character_set_connection|utf8|
|character_set_database|utf8|
|character_set_filesystem|binary|
|character_set_results|utf8|
|character_set_server|utf8|
|character_set_system|utf8|
|character_sets_dir|/usr/share/mysql/charsets/|
-------------------------- ----------------------------
´Ë·½·¨ÓÃÓÚ±ê×¼mysql°æ±¾Í¬ÑùÓÐЧ£¬¶ÔÓÚ/etc/my.cnfÎļþ£¬ÐèÒª´Ómysql/support-filesµÄÎļþ¼Ð


Ïà¹ØÎĵµ£º

linuxÏÂÆô¶¯mysqlµÄÃüÁî

 
Ò»¡¢×ܽáһϣº
1.linuxÏÂÆô¶¯mysqlµÄÃüÁ
   mysqladmin start
/ect/init.d/mysql start (Ç°ÃæΪmysqlµÄ°²×°Â·¾¶)
2.linuxÏÂÖØÆômysqlµÄÃüÁ
   mysqladmin restart
/ect/init.d/mysql restart (Ç°ÃæΪmysqlµÄ°²×°Â·¾¶)
3.linuxϹرÕmysqlµÄÃüÁ
   mysqladmin shut ......

¼òµ¥ÅäÖÃapache + mysql + discuz +php

 °²×°apache + mysql + discuz +php
apache      http://www.apache.org/
mysql        http://dev.mysql.com/downloads/
MySQL GUI Tools           http://dev.mysql.com/downloads/gui-tools/5.0.html
php &n ......

mysqlÃüÁî´óÈ«

Æô¶¯£ºnet start mySql;
¡¡¡¡½øÈ룺mysql -u root -p/mysql -h localhost -u root -p databaseName;
¡¡¡¡ÁгöÊý¾Ý¿â£ºshow databases;
¡¡¡¡Ñ¡ÔñÊý¾Ý¿â£ºuse databaseName;
¡¡¡¡Áгö±í¸ñ£ºshow tables£»
¡¡¡¡ÏÔʾ±í¸ñÁеÄÊôÐÔ£ºshow columns from tableName£»
¡¡¡¡½¨Á¢Êý¾Ý¿â£ºsource fileName.txt;
¡¡¡¡Æ¥Åä× ......

Mysql Âý²éѯÆôÓÃ

 MySQLÂý²éѯ¼Ç¼ÈÕÖ¾¶ÔÓÚ¸ú×ÙMySQL¸ºÔص÷ÓÅÎÊÌâºÜÓÐÓô¦£¬ÆäʵÆôÓÃMySQLµÄÂý²éѯÈÕÖ¾ºÜ¼òµ¥,Ö»ÐèÒªÔÚMySQLµÄÅäÖÃÎļþÀïÌí¼Ólog-slow-queriesºÍlong_query_timeÁ½¸ö²ÎÊý¼´¿É¡£
WindowsÏ¿ªÆôMySQLÂý²éѯ
MySQLÔÚWindowsϵͳÖеÄÅäÖÃÎļþÒ»°ãÊÇÊÇmy.iniÕÒµ½[mysqld]ÏÂÃæ¼ÓÉÏ
log-slow-queries = F:\MySQL\log\mysqls ......

linuxϵͳµÄ°²×°(redhat7.2)+jsp»·¾³+mysql+°²È«ÉèÖÃ

 1 1 Linux Red Hat 7.2 °²×°
¡¡¡¡Red Hat Linux 7.2µÄ°²×°¹âÅ̹²ÓÐÁ½ÕÅ£ºµÚÒ»ÕÅ¿ÉÒÔÖ±½Ó´Ó¹âÅÌÆô¶¯£¬°üº¬Á˴󲿷ֵÄÈí¼þ°üºÍһЩ°²×°¹¤¾ß£»µÚ¶þÕŹâÅ̳ýÁ˸½¼ÓµÄÈí¼þ°üÍ⣬Ö÷ÒªÊÇÔ´Âë¡¢Ô¤ÀÀ°æÈí¼þµÈ¡£
¡¡¡¡Red Hat Linux 7.2µÄ°²×°½çÃæ·Ç³£ÓѺã¬×óÃæÓм´Ê±Ï꾡µÄ°ïÖúÐÅÏ¢£¬ÓÒÃæÊÇÑ¡ÏÍêÈ«Ö§³ÖÊó±ê²Ù×÷¡£
¡¡¡¡½« ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ