修改OS X的$PATH變量

編輯/private/etc/profile,用$sudo vi /private/etc/profile 編輯。
內容是在任意位置加入:export path=/usr/local:$path就可以了。
Save the file then "source /private/etc/profile"。

echo $PATH. You will see it works.

下面是在OS X中安裝MySQL:

If you want to install MySQL on Lion it’s pretty easy, just head on over and download the DMG from mysql.com (for lion you’ll need the 64bit DMG Archive).

Then double click on mysql package to install it, then on MySQLStartupitem.pkg, and then on the MySQL.prefPane. Once that’s done start it up via system prefs.

Finally, you will need to add ‘/usr/local/mysql/bin’ to your path environment. 

在系統設置中有MySQL圖標,點擊選擇啓動服務。

進行root密碼配置:

mysql -u root
SET PASSWORD FOR root@localhost=PASSWORD('your_password_here');
FLUSH PRIVILEGES;

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章