日期:2014-05-16  浏览次数:20653 次

linux 下 bugfree安装

首先下载XAMPP:
XAMPP Linux 1.7.2:
安装之前首先确认你服务器的80端口有没被占用
netstat -an|grep -w 80
如果被占用了请先关闭相关服务,XAMPP启动要用到80端口.

安装XAMPP:?? 注意是安装到/opt,如何修改到其他的目录还没试过
[root@localhost ~]#tar xvfz xampp-linux-1.7.2.tar.gz -C /opt
然后启动:
opt/lampp/lampp start

您应该能在屏幕上看到类似下面的提示信息:

Starting XAMPP 1.7.2...
LAMPP: Starting Apache...
LAMPP: Starting MySQL...
LAMPP started.
好了。Apache 和 MySQL 正在运行中
只需在您的浏览器中输入下面的链接即可:http://localhost

看到一些示例程序的 XAMPP 开始页面就表示XAMPP安装成功了。接下来我们要配置XAMPP的安全性。

配置XAMPP安全性:
[root@localhost ~]# /opt/lampp/lampp security

64位linux会提示“XAMPP is currently only availably as 32 bit application. Please use a 32 bit

compatibility library for your system.”
搜索“XAMPP is currently 32 bit only“引号里的那句话。用#号注释下面的判断环境的语句。
#case `uname -m` in
#??? *_64)
#??? if /opt/lampp/bin/php -v > /dev/null 2>&1
#??? then
#??????? :
#??? else
#??????? $de && echo "XAMPP gibt es zur Zeit nur als 32-Bit Applikation. Bitte verwende eine 32-Bit

Kompatibilitaetsbibliothek fuer Dein System."
#??????? $de || echo "XAMPP is currently only availably as 32 bit application. Please use a 32 bit

compatibility library for your system."
#??????? exit
#??? fi
#??? ;;
#esac”
修改后保存

还要修改一个权限
chown -R root.root /opt/lampp/var/mysql?

并设置 XAMPP 随系统自动启动
[root@localhost ~]# ln -s /opt/lampp/lampp /etc/rc.d/rc3.d/S99lampp
[root@localhost ~]# ln -s /opt/lampp/lampp /etc/rc.d/rc4.d/S99lampp
[root@localhost ~]# ln -s /opt/lampp/lampp /etc/rc.d/rc5.d/S99lampp

或者直接修改/opt/rc.local文件,在exit 0之前加上下面一句话就可以了
/opt/lampp/lampp start

取消随系统自动运行
ln -s /opt/lampp/lampp K01lampp

自此,XAMPP已经配置好了!下面我们来配置BugFree:
下载BugFree2:
[root@localhost ~]# wget -chttp://www.bugfree.org.cn/download/bugfree2.tar.gz
解压到Xampp下的htdocs文档下:
[root@localhost ~]#tar xvfz bugfree2.tar.gz -C /opt/lampp/htdocs/

然后复制Include/Config.inc.Sample.php为Include/Config.inc.php,编辑并修改数据库链接地址:编辑/opt/lampp/htdocs/bugfree/Include/Config.inc.php

[root@ua006 lampp]# vi ./htdocs/bugfree/Include/Config.inc.php
?*
?* @link????????http://www.bugfree.org.cn
?* @package???? BugFree
?*/

/* Report all errors except E_NOTICE. */
error_reporting(E_ALL ^ E_NOTICE);

/* 1. Define surported language list and default language. Note: you can use only one charset Chinese

lanuage now. */
$_CFG['LangList']['EN_UTF-8']??? = 'English UTF-8';
$_CFG['LangList']['ZH_CN_UTF-8'] = 'ZH_CN UTF-8';
$_CFG['DefaultLang']???????????? = 'ZH_CN_UTF-8';

/* 2. Define admin user list. Like this: array('admin','yourloginname') */
$_CFG['AdminUser'] = array('admin');

/* Define report user list. Like this: array('admin',?'someone@example.com');*/
$_CFG['MailReportUser'] = array('');

/* 3. Define the username and password of the BugFree database. */

$_CFG['DB']['User']??????? = 'root';????????? // 数据库登录用户名
$_CFG['DB']['Password']??? = 'password';????? // 数据库登录用户密码
$_CFG['DB']['Host']??????? = 'localhost';???? // 数据库服务器地址
$_CFG['DB']['Database']??? = 'bugfree';?????? // 指定BugFree数据库名称
$_CFG['DB']['TablePrefix'] = 'bf_';?????????? // 数据库表前缀,默认为bf_。除非有冲突,不建议修改或为空
$_CFG['DBCharset']???????? = 'UTF8';????????? // 数据库编码设置,保留默认值

注意:这里使用的是已经安装好的mysql管理员账号,账号错误的话页面仍然会提示创建数据库成功,所以一定要注意

,否则问题很难找。

自动发送邮件的配置

/* 8. Mail setting. */
$_CFG['Mail']['On']????????? = true;
$_CFG['Mail']['FromAddress'] = "124961193@163.com";
$_CFG['Mail']['FromName']??? = 'BugFree';
$_CFG['Mail']['ReportTo']??? = array();? // Where bug statistics message sened t
o. If empty, t