虛擬機軟體版本:VMware 7.1.3 build-324285
Ubuntu版本:10.10
在 “應用程序》附屬應用程序》終端機” 中依家輸入以下語名, 執行命令:
1)Install SSH Client and Server (for my remote access)
sudo apt-get install ssh
2)Install Database Server
sudo apt-get install mysql-server
3)Install Apache HTTP Server
sudo apt-get install apache2
4)Install PHP5 and Apache PHP5 module
sudo apt-get install php5 libapache2-mod-php5
5)Restart Apache
sudo /etc/init.d/apache2 restart
6)Optionally, install phpMyAdmin
sudo apt-get install phpmyadmin
注:如果使用apt-get安装不知道装哪去啦,可以使用dpkg -L phpmyadmin 看看安装在什么地方。
sudo ln -s /usr/share/phpmyadmin/ /var/www/ (为phpmyadmin创建一个连结,方便直接使用http://localhost/phpmyadmin/访问)
以下為一些與相關的常用命令:
1. 重启 apache
sudo /etc/init.d/apache2 restart
2. 配置PHP.INI
sudo gedit /etc/php5/apache2/php.ini
3. 配置apache2.conf
sudo gedit /etc/apache2/apache2.conf
4. 安裝完apache之后默認的根目錄
/var/www/
5. 配置虚拟主机
sudo gedit /etc/apache2/sites-enabled/000-default
6. 配置MYSQL
sudo gedit /etc/mysql/my.cnf
除非注明,干草博客文章均为原创,转载请以链接形式标明本文地址
