安裝phpMyAdmin,遇到幾個問題,記錄一下要點:
安裝phpMyAdmin
解壓到/var/www
配置Apache
Listen 8030
<VirtualHost *:8030>
DocumentRoot /var/www/phpMyAdmin
</VirtualHost>
cp config.sample.inc.php config.inc.php
vi config.inc.php
修改以下段
/*
* First server
*/
$i++;
/* Authentication type */
$cfg['Servers'][$i]['auth_type'] = 'cookie';
/* Server parameters */
$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['compress'] = false;
/* Select mysqli if your server has it */
$cfg['Servers'][$i]['extension'] = 'mysql';
$cfg['Servers'][$i]['AllowNoPassword'] = false;
串連多個host,複製上面一段,改變一下$cfg['Servers'][$i]['host']即可,
在登入的時候會多億個host選擇框。
RedHat php升級到5.2
搜到一個簡單的方法
wget -q -O - http://www.atomicorp.com/installers/atomic.sh | sh
yum update php
重啟apache
service httpd restart
MySQL安裝
./configure && make && make install
安裝基本庫
scripts/mysql_install_db
[按提示設定root密碼]
選擇設定檔
cp support-files/my-huge.cnf /etc/my.cnf
vi /etc/my.cnf 增加以下內容
[client]
default-character-set=utf8
default-character-set=utf8
[mysqld]
datadir = /opt/mysql_data
default-character-set=utf8
增加mysql使用者
adduser mysql
賦許可權給mysql使用者
chown -R mysql.mysql /opt/mysql_data
設定自啟動
cp support-files/mysql.server /etc/init.d/mysql
賦執行許可權
chomd +x /etc/init.d/mysql
啟動mysql
service mysql restart