LinuxÏ°²×°MySQL¿Î³Ì_MySQLÊý¾Ý¿â_ºÚ¿Í·ÀÏßÍø°²·þÎñÆ÷ά»¤»ùµØ--Powered by WWW.RONGSEN.COM.CN

LinuxÏ°²×°MySQL¿Î³Ì

×÷ÕߣººÚ¿Í·ÀÏßÍø°²Íøվά»¤»ùµØ À´Ô´£ººÚ¿Í·ÀÏßÍø°²Íøվά»¤»ùµØ ä¯ÀÀ´ÎÊý£º0

±¾Æª¹Ø¼ü´Ê£ºLinuxMySQL
ºÚ¿Í·ÀÏßÍø°²ÍøѶ£º
1£®½« mysql-standard-4.0.24-pc-linux-gnu-i686.tar.gz ¿½±´µ½Ò»¸öĿ¼ÖÐ
2£®shell> tar zvxf 
mysql-standard-4.0.24-pc-linux-gnu-i686.tar.gz 
3£®ÉÏÃæµÄÃüÁÔÚµ±Ç°Ä¿Â¼ÏÂÉú³ÉÒ»¸ömysql-standard-4.0.24-pc-


1£®½« mysql-standard-4.0.24-pc-linux-gnu-i686.tar.gz ¿½±´µ½Ò»¸öĿ¼ÖÐ
2£®shell> tar zvxf
mysql-standard-4.0.24-pc-linux-gnu-i686.tar.gz
3£®ÉÏÃæµÄÃüÁÔÚµ±Ç°Ä¿Â¼ÏÂÉú³ÉÒ»¸ömysql-standard-4.0.24-pc-linux-gnu-i686Îļþ¼Ð
4£®shell>mv mysql-standard-4.0.24-pc-linux-gnu-i686 /usr/local/mysql
5£®ÉÏÃæµÄÃüÁîÊǽ«mysql-standard-4.0.24-pc-linux-gnu-i686ϵÄËùÓ櫶«£¬¼ôÇе½/usr/local/mysql Ï£¬½øÐÐÕâÒ»²½ÊÇΪÁËÒÔºóµÄ·½±ã¡£
6£®shell> groupadd mysql Ôö¼ÓÒ»¸öÃûΪmysqlµÄÓû§×é
7£®shell> useradd -g mysql mysql ÔÚmysqlÓû§×éÖмÓÒ»¸öÃûΪmysqlµÄÓû§Èç¹ûÉÏÃæµÄÁ½¸öÃüÁî²»ÄÜÖ´ÐУ¬ÄÇôҪÇл»µ½rootÓû§ÏÂÖ´ÐÐ

shell>su root -
8£®shell> cd /usr/local/mysql support-files/my-medium.cnf /etc/my.cnf Õâʱ»áÎÊÊÇ·ñ¸²¸ÇÖØÃûÎļþ£¬»Ø´ðy

10.shell> scripts/mysql_install_db --user=mysql

11.shell> chown -R root . ×¢ÒâºóÃæÓе㣬±íʾ½«µ±Ç°Ä¿Â¼ÏµÄËùÓÐÎļþÓë×ÓĿ¼µÄÓµÓÐÕßÉ趨ΪrootÓû§

12.shell> chown -R mysql data ±íʾ½«µ±Ç°Ä¿Â¼ÏµÄdataĿ¼µÄÓµÓÐÕßÉ趨ΪmysqlÓû§

13.shell> chgrp -R mysql . ×¢ÒâºóÃæÓе㣬±íʾ½«µ±Ç°Ä¿Â¼ÏµÄÎļþµÄÎļþ×éÉèΪmysql×é

14.shell> bin/mysqld_safe --user=root & ´ËʱÈç¹ûûÓгöÏÖ“……ended”×ÖÑù£¬´ó¹¦¸æ³É£¡

15.»Ø³µÏÔʾshell>

ͨ¹ý shell>netstat –atln ÃüÁî²é¿´3306¶Ë¿ÚÊÇ·ñÒѾ­ÆôÓÃ

Ò²¿ÉÒÔ shell>ps -ef | grep mysqld ²é¿´µ±Ç°ÏµÍ³ÖеÄmysqldµÄ½ø³Ì

»òÖ±½Ó shell>bin/mysql –u root ½øÈëmysql¿Í»§¶Ë£¬½øÐÐmysql²Ù×÷

»òshell>bin/mysqladmin shutdown Í£Ö¹mysql·þÎñ

¼Çס£º

´ËʱÄãµÄrootÓû§ÊÇûÓÐÃÜÂëµÄ£¬ÈκÎÉí·Ý¶¼¿ÉÒÔÓÃroot½øÈ룬Äã¿ÉÒÔͨ¹ýshell> bin /mysqladmin -u root password пÚÁî À´É趨rootÓû§µÄ¿ÚÁ´Ë¿ÚÁÔÚ½øÈëmysql¿Í»§¶ËºÍÍ£Ö¹mysql·þÎñʱÐèÒªÊäÈëÌáʾ£ºÔÚÆôµ¥¸ö·þÎñµÄʱºò£¬¿ÉÒÔͨ¹ýÐÞ¸Ä/etc/my.cnfÎļþÀ´ÅäÖÿÉÒÔÓÃVI±à¼­Æ÷´ò¿ªmy.cnf £¬Ôõô´ò¿ª ¿´ÏÂÃæ £º

shell>vi my.cnf

´ò¿ªmy.cnf ÕÒµ½ÏÂÃæÕâ¶Î

[mysqld]

port = 8888

socket = /tmp/mysql.sock

¿ÉÒÔÔÚºóÃæ¼ÓÉÏÏàÓ¦µÄÅäÖÃ

log = /var/log/mysql.log

datadir = /free/mysqldbf

Èç log = /* ¸Ä±älogµÄ±£´æλÖÃ

datadir = /free/mysqldbf ¸Ä±ädataµÄ±£´æλÖÃ

    ºÚ¿Í·ÀÏßÍø°²·þÎñÆ÷ά»¤·½°¸±¾ÆªÁ¬½Ó£ºhttp://www.rongsen.com.cn/show-4831-1.html
Íøվά»¤½Ì³Ì¸üÐÂʱ¼ä:2011-03-06 15:01:23  ¡¾´òÓ¡´ËÒ³¡¿  ¡¾¹Ø±Õ¡¿
ÎÒÒªÉêÇë±¾Õ¾£ºNµã | ºÚ¿Í·ÀÏß¹ÙÍø |  
רҵ·þÎñÆ÷ά»¤¼°Íøվά»¤ÊÖ¹¤°²È«´î½¨»·¾³£¬ÍøÕ¾°²È«¼Ó¹Ì·þÎñ¡£ºÚ¿Í·ÀÏßÍø°²·þÎñÆ÷ά»¤»ùµØÕÐÉ̽øÐÐÖУ¡QQ:29769479

footer  footer  footer  footer