MediaWiki 1.17.0 安装

1.安装环境

操作系统:CentOS 5.5
数据库:MySQL 5.5.14
Web服务器:Apache (httpd-2.2.19)
脚本语言:PHP 5.3.6

安装之前请先用yum或rpm删除之前安装的mysql,apache以及php

 

2.安装MySQL 5.5.14
软件包mylsql-5.5.14-linux2.6-x86_64.tar.gz

地址http://www.mysql.com->Platform:Linux Generic

# groupadd mysql

# useradd -r -g mysql mysql

# cd /usr/local

# tar zxvf /path/to/mysql-VERSION-OS.tar.gz

# ln -s full-path-to-mysql-VERSION-OS mysql

# cd mysql

# chown -R mysql .

# chgrp -R mysql .

# scripts/mysql_install_db --user=mysql

# chown -R root .

# chown -R mysql data

# cp support-files/mysql.server /etc/init.d/mysql.server

# cp support-files/my-medium.cnf /etc/my.cnf

vi /etc/my.cnf在[mysqld]段中加入 skip-grant-tables

# bin/mysqld_safe --user=mysql &

修改mysql密码

# mysql

Welcome to the MySQL monitor. Commands end with ; or \g.

Your MySQL connection id is 3 to server version: 3.23.56

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> USE mysql ;

Reading table information for completion of table and column names

You can turn off this feature to get a quicker startup with -A
Database changed

mysql> UPDATE user SET Password = password ( 'password' ) WHERE User = 'root' ; (注意这里不是mysql)

Query OK, 0 rows affected (0.00 sec)Rows matched: 2 Changed: 0 Warnings: 0
mysql> flush privileges

;Query OK, 0 rows affected (0.01 sec)
mysql> quit

Bye

 

3.安装Apache (httpd-2.2.19)
地址http://www.apache.org
# tar zvxf httpd-2.2.19.tar.gz
# cd httpd-2.2.19
# ./configure --prefix=/usr/local/apache \
--enable-module=most \
--enable-shared=max
# make
# make install

在 /usr/local/apache/conf/httpd.conf文件中,有这么一段

<Directory/>
  Options FollowSymLinks
  AllowOverride None
  Order deny,allow
  Deny from all 
</Directory>

把Deny改成Allow

4.安装PHP 5.3.6

地址:www.php.net
# tar jvxf php-5.3.6.tar.bz2

# cd php-5.3.6
# ./configure --prefix=/usr/local/php \
--with-mysql=/usr/local/mysql \
--with-apxs2=/usr/local/apache/bin/apxs
# make
# make install
# cp php.ini-dist /usr/local/php/lib/php.ini

5.配置Apache服务的 /usr/local/apache/conf/httpd.conf文件
在LoadModule处添加 LoadModule php5_module module/libphp5.so
在DirectoryIndex处添加 index.php
在AddType application处添加
AddType application/x-httpd-php .php .phtml
AddType applicatoin/x-httpd-php-source .phps

6. 安装mediaWiki

tar xzvf mediawiki-1.17.0.tar.gz

cp mediawiki-1.17.0 /var/www/wiki

vi  /usr/local/apache/conf/httpd.conf

DocumentRoot "/var/www/wiki"

DirectoryIndex index.html index.html.var index.php

----------------------------------启动Apache服务----------------------------------

# /usr/local/apache/bin/apachectl start

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值