一·首先安裝是CentOS 7.0的源。php
#rpm -ivh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm 查看可安裝的包 # yum list --enablerepo=remi --enablerepo=remi-php56 | grep php 開始安裝 # yum install --enablerepo=remi --enablerepo=remi-php56 php php-opcache php-devel php-mbstring php-mcrypt php-mysqlnd php-phpunit-PHPUnit php-pecl-xdebug php-pecl-xhprof 查看版本 # php --version
二·#yum list httpd 安裝httpdhtml
三·下載並解壓dokuwiki程序包(去網上找源碼包穩定版)
wget -c http://download.dokuwiki.org/src/dokuwiki/dokuwiki-stable.tgz
tar -zvxf dokuwiki-stable.tgz
把解壓好的放到/var/www/html/wiki
mv dokuwiki-2017-02-19e/ /var/www/html/wikimysql
四·修改文件夾所屬用戶及組
chown -R apache:apache /var/www/html/wikisql
五·啓動
service httpd startapache
六. firewall 開通80端口 檢查是否開通
firewall-cmd --zone=public --add-port=80/tcp --permanent
firewall-cmd --reloadtcp
七·訪問網頁
http://IP或者域名/wikiide
過程當中我遇到的錯誤就是
1)rpm -ivh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm報錯 緣由是沒有下載rpm 使用命令是yum install rpmdebug
2)重啓的時候沒有關防火牆應使用命令 systemctl stop firewalld 3)php得下載5.6 或者比5.6高的版本 4)在開通80端口時會報錯FirewallD is not running 解決:1.經過systemctl status firewalld查看firewalld狀態,發現當前是dead狀態,即防火牆未開啓 2.經過systemctl start firewalld開啓防火牆,沒有任何提示即開啓成功。 3.再經過systemctl status firewalld查看firewalld狀態,顯示running即已開啓了。 4.再次執行 firewall-cmd --zone=public --add-port=80/tcp --permanent 提示success,表示設置成功