亚洲av成人无遮挡网站在线观看,少妇性bbb搡bbb爽爽爽,亚洲av日韩精品久久久久久,兔费看少妇性l交大片免费,无码少妇一区二区三区

  免費(fèi)注冊(cè) 查看新帖 |

Chinaunix

  平臺(tái) 論壇 博客 文庫
12345下一頁
最近訪問板塊 發(fā)新帖
查看: 20932 | 回復(fù): 46
打印 上一主題 下一主題

菜鳥架站之BBS服務(wù)器 [復(fù)制鏈接]

論壇徽章:
0
跳轉(zhuǎn)到指定樓層
1 [收藏(0)] [報(bào)告]
發(fā)表于 2007-10-01 13:50 |只看該作者 |倒序?yàn)g覽
菜鳥架站之BBS服務(wù)器
=====================================================================================================





FreeBSD6.2架設(shè)Discuz!6.0 BBS服務(wù)器指南

Discuz!6.0 BBS Server On FreeBSD6.2 HowTo

Mongolia



Index:

  • 簡介
  • Step 1 installation Apache22.
  • Step 2 installation MySQL Server.
  • Step 3 installation PHP.
  • Step 4 ZendOptimizer.
  • Step 5 Discuz!6.0.
  • F.A.Q.
  • Links to other sources

簡介


學(xué)習(xí)FreeBSD很久了,一直是菜鳥水平。現(xiàn)在記錄下我的BBS on FreeBSD安裝歷程,發(fā)表到CU論壇,請(qǐng)各位達(dá)人批評(píng)指正。
本文目標(biāo):

使用Very Very GoodFreeBSD6.2作為系統(tǒng),原因是高人們說這個(gè)小惡魔很穩(wěn)定、很快速。而且有獨(dú)特的FreeBSD最引以為傲的Ports,所以系統(tǒng)使用FreeBSD6.2。Ports的好處是,安裝程序方便(只需找到程序目錄,然后執(zhí)行make install clean),升級(jí)維護(hù)程序方便,卸載方便。本文的應(yīng)用程序均使用Ports方式安裝。FreeBSD6.2+Apache22+PHP5+php5-extensions+ZendOptimizer+ Discuz!6.0


軟件版本信息:

  • FreeBSD 6.2-RELEASE
  • Apache-2.2.3
  • Mysql-server-5.0.27
  • Php5-5.1.6_3
  • Php5-extensions-1.0
  • ZendOptimizer-3.0.1_1
  • Perl-5.8.8
  • Discuz!_6.0.0_SC_UTF8.zip
  • Step 1 安裝 Apache22.


Installation of the Apache server:

跟隨下面步驟安裝 Apache2.

Shell:

cd /usr/ports/www/apache22
make install clean



安裝完成后,需要編輯/etc/rc.conf文件,添加下面內(nèi)容到/etc/rc.conf(要添加的內(nèi)容,可以cat /usr/local/etc/rc.d/apache22查看到具體說明)

Editor:

# Apache 22
apache22_enable="YES"




[ 本帖最后由 freemongolia 于 2007-10-2 09:34 編輯 ]

index.JPG (103.09 KB, 下載次數(shù): 100)

index.JPG

論壇徽章:
0
2 [報(bào)告]
發(fā)表于 2007-10-01 13:51 |只看該作者

Step 2 安裝 MySQL.



Installation of the MySQL server:
安裝MySQL server5.0

Shell:

cd /usr/ports/databases/mysql50-server
make install clean


安裝完成后,需要編輯/etc/rc.conf文件,添加下面內(nèi)容到/etc/rc.conf
Editor:

# MySQL Server 5.0
mysql_enable="YES"


啟動(dòng)MySQL服務(wù)
Shell:

/usr/local/etc/rc.d/mysql-server start


使用mysqladmin命令更改MySQL密碼
Shell:

mysqladmin -uroot password 'passwd' (passwd是你要設(shè)置的密碼)



[ 本帖最后由 freemongolia 于 2007-10-2 09:35 編輯 ]

論壇徽章:
0
3 [報(bào)告]
發(fā)表于 2007-10-01 13:53 |只看該作者

Step 3 安裝 PHP.




Installation of the PHP:
安裝PHP5

Shell:

cd /usr/ports/lang/php5
make install clean



選擇如下安裝選項(xiàng)

Options for php5 5.1.6_3

[X]

CLI

Build CLI version


[X]

CGI

Build CGI version

[X]

APACHE

Build Apache module

[X]

SUHOSION

Enable Suhosin protection system

[X]

FASTCGI

Enable fastcgi support (CGI only)

[X]

PATHINFO

Enable path-info-check support (CGI only)




安裝完成后,備份/usr/local/etc/apache22/httpd.conf文件

Shell:

cp /usr/local/etc/apache22/httpd.conf /usr/local/etc/apache22/httpd.conf.bak



編輯/usr/local/etc/apache22/httpd.conf文件,以使Apache22 Server支持php


編輯/usr/local/etc/apache22/httpd.conf,在AddType application/x-gzip .gz .tgz(大約354)下面添加以下內(nèi)容

Editor:

AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps



修改前:



# probably should define those extensions to indicate media types:


#


AddType application/x-compress .Z


AddType application/x-gzip .gz .tgz



修改后:


# probably should define those extensions to indicate media types:


#


AddType application/x-compress .Z


AddType application/x-gzip .gz .tgz


AddType application/x-httpd-php .php


AddType application/x-httpd-php-source .phps




[ 本帖最后由 freemongolia 于 2007-10-1 13:55 編輯 ]

論壇徽章:
0
4 [報(bào)告]
發(fā)表于 2007-10-01 13:56 |只看該作者
先不要退出,添加'index.php' 'DirectoryIndex' 主目錄索引(大約212)

Editor:

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


修改前:

#

<IfModule dir_module>


DirectoryIndex index.html

</IfModule>


#


修改后:

#

<IfModule dir_module>


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

</IfModule>


#

論壇徽章:
0
5 [報(bào)告]
發(fā)表于 2007-10-01 13:59 |只看該作者

Installation of the PHP Extensions:

安裝php5-extensions擴(kuò)展.

Shell:

cd /usr/ports/lang/php5-extensions
make config
make install clean


安裝選項(xiàng)如下:

詳細(xì)安裝選項(xiàng)

Options for php5-extensions 1.0


[X]

BZ2

bzip2 library support

[X]

CALENDAR

calendar conversion support

[X]

CTYPE

ctype functions

[X]

GD

GD library support

[X]

ICONV

iconv support

[X]

MBSTRING

multibyte string support

[X]

MYSQL

MySQL database support

[X]

PCRE

Perl Compatible Regular Expression support

[X]

POSIX

POSIX-like functions

[X]

SESSION

session support

[X]

SOCKETS

sockets support

[X]

TOKENIZER

tokenizer support

[X]

ZIP

ZIP support

[X]

ZLIB

ZLIB support



復(fù)制/usr/local/etc/php.ini-dist/usr/local/etc/php.ini
Shell:

cp /usr/local/etc/php.ini-dist /usr/local/etc/php.ini



[ 本帖最后由 freemongolia 于 2007-10-1 14:01 編輯 ]

論壇徽章:
0
6 [報(bào)告]
發(fā)表于 2007-10-01 14:00 |只看該作者
安裝完成后,重新啟動(dòng)你的 web server.

Execute the following command to start / restart the Apache webserver.

Shell:

/usr/local/etc/rc.d/apache22 restart


提示:

如果出現(xiàn)這樣的錯(cuò)誤

root@WOW[/root]#/usr/local/etc/rc.d/apache22 restart

httpd not running, trying to start

[Sat Sep 29 16:05:07 2007] [warn] (2)No such file or directory: Failed to enable the 'httpready' Accept Filter


解決辦法:

/boot/loader.conf添加accf_http_load=”yes”
root@WOW[/root]#echo accf_http_load="YES" >> /boot/loader.conf

然后reboot一下就可以解決了

這是因?yàn)?/font>Apache無法開啟FreeBSDaccept filter 的機(jī)制,

FreeBSD 系統(tǒng)還提供了http filter,會(huì)自動(dòng)過濾掉不完整的HTTP請(qǐng)求。

解決方法:

root@WOW[/root]#kldload accf_http

并修改/boot/defaults/loader.conf,以便下次啟動(dòng)自動(dòng)裝載模塊(大約364)
修改前:

accf_data_load="NO"
accf_http_load=
"NO"

修改后:

accf_data_load="YES"
accf_http_load=
"YES"



[ 本帖最后由 freemongolia 于 2007-10-2 09:37 編輯 ]

論壇徽章:
0
7 [報(bào)告]
發(fā)表于 2007-10-01 14:01 |只看該作者
測(cè)試Apache Server
瀏覽器打開http://youipaddress
顯示:
It works!
OK,現(xiàn)在Aapche Server工作正常。什么?為什么只有一行It works!?因?yàn)?/font>FreeBSD開發(fā)的達(dá)人們只追求速度、簡單,呵呵。

論壇徽章:
0
8 [報(bào)告]
發(fā)表于 2007-10-01 14:03 |只看該作者

Step 4 安裝 ZendOptimizer.


Installation of the ZendOptimizer:

安裝ZendOptimizer.


Shell:

root@ohaha[/root]#cd /usr/ports/devel/ZendOptimizer/

root@ohaha[/usr/ports/devel/ZendOptimizer/]#make install clean

安裝完成提示如下

********************************************************************************


You have installed the ZendOptimizer package.


Edit /usr/local/etc/php.ini and add:


[Zend]

zend_optimizer.optimization_level=15

zend_extension_manager.optimizer="/usr/local/lib/php/20060613/Optimizer"

zend_extension_manager.optimizer_ts="/usr/local/lib/php/20060613/Optimizer_TS"

zend_extension="/usr/local/lib/php/20060613/ZendExtensionManager.so"

zend_extension_ts="/usr/local/lib/php/20060613/ZendExtensionManager_TS.so"


********************************************************************************

編輯/usr/local/etc/php.ini

增加內(nèi)容如下

Editor:

zend_optimizer.optimization_level=15

zend_extension_manager.optimizer="/usr/local/lib/php/20060613/Optimizer"

zend_extension_manager.optimizer_ts="/usr/local/lib/php/20060613/Optimizer_TS"

zend_extension="/usr/local/lib/php/20060613/ZendExtensionManager.so"

zend_extension_ts="/usr/local/lib/php/20060613/ZendExtensionManager_TS.so"



[ 本帖最后由 freemongolia 于 2007-10-1 14:04 編輯 ]

論壇徽章:
0
9 [報(bào)告]
發(fā)表于 2007-10-01 14:05 |只看該作者


重新啟動(dòng)你的 web server.
Execute the following command to start / restart the Apache webserver.
Shell:


/usr/local/etc/rc.d/apache22 restart



測(cè)試Aapche Server 對(duì)PHPZendOptimizer支持
瀏覽器打開http://youipaddress


顯示:




PHP Version 5.1.6




System


FreeBSD ohaha.3322.org 6.2-RELEASE FreeBSD 6.2-RELEASE #0: Fri Jan 12 10:40:27 UTC 2007 root@dessler.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC i386


Build Date


Oct 1 2007 08:43:04


Configure Command


'./configure' '--enable-versioning' '--enable-memory-limit' '--with-layout=GNU' '--with-config-file-scan-dir=/usr/local/etc/php' '--disable-all' '--enable-libxml' '--with-libxml-dir=/usr/local' '--enable-reflection' '--enable-spl' '--program-prefix=' '--enable-fastcgi' '--with-apxs2=/usr/local/sbin/apxs' '--with-regex=php' '--with-zend-vm=CALL' '--disable-ipv6' '--prefix=/usr/local' 'i386-portbld-freebsd6.2'


OK,現(xiàn)在Aapche Server支持PHP工作正常。


[ 本帖最后由 freemongolia 于 2007-10-2 09:38 編輯 ]

論壇徽章:
0
10 [報(bào)告]
發(fā)表于 2007-10-01 14:07 |只看該作者
Step 5 安裝 Discuz!6.0.
Installation of the PHP Extensions:
安裝Discuz!6.0論壇BBS程序
登陸[url=http://www.discuz.com/download/]http://www.discuz.com/download/官方網(wǎng)站下載簡體 UTF-8版本Discuz!6.0
Shell:
cd /tmp
fetch " http://download.discuz.net/6.0.0/Discuz!_6.0.0_SC_UTF8.zip"
tar zxvf Discuz\!_6.0.0_SC_UTF8.zip
cd ftp
chown www config.php
您需要登錄后才可以回帖 登錄 | 注冊(cè)

本版積分規(guī)則 發(fā)表回復(fù)

  

北京盛拓優(yōu)訊信息技術(shù)有限公司. 版權(quán)所有 京ICP備16024965號(hào)-6 北京市公安局海淀分局網(wǎng)監(jiān)中心備案編號(hào):11010802020122 niuxiaotong@pcpop.com 17352615567
未成年舉報(bào)專區(qū)
中國互聯(lián)網(wǎng)協(xié)會(huì)會(huì)員  聯(lián)系我們:huangweiwei@itpub.net
感謝所有關(guān)心和支持過ChinaUnix的朋友們 轉(zhuǎn)載本站內(nèi)容請(qǐng)注明原作者名及出處

清除 Cookies - ChinaUnix - Archiver - WAP - TOP