【转载】ubuntu下配置BugFree

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, to all users.
$_CFG['Mail']['SendMethod']  = 'SMTP';   // MAIL|SENDMAIL|SMTP|QMAIL

/* 9. SMTP param setting. */
$_CFG['Mail']['SendParam']['Host']     = 'smtp.163.com';       // The server to
connect. Default is localhost
$_CFG['Mail']['SendParam']['SMTPAuth'] = true;    // Whether or not to use SMTP
authentication. Default is FALSE
$_CFG['Mail']['SendParam']['Username'] = 'etune_song';       // The username to
use for SMTP authentication.
$_CFG['Mail']['SendParam']['Password'] = 'xxx';       // The password to u
se for SMTP authentication.

然后设置文件目录权限:
[root@localhost ~]# cd /opt/lampp/htdocs/bugfree
[root@localhost bugfree]# chmod 777 Data/TplCompile/
[root@localhost bugfree]# chmod 777 BugFile/
[root@localhost bugfree]# chmod 777 Include/Config.inc.php

全部配置好就可以访问BugFree了:
http://localhost/bugfree/设置新的数据库
admin缺省口令123456

按页面提示一步步操作,创建成功后会提示输入admin的口令我用的是bugfreeadmin

登陆后会显示几行警告信息
------------信息如下------------------------------------
Deprecated: Call-time pass-by-reference has been deprecated in

/opt/lampp/htdocs/bugfree/Include/Class/XmlParse.class.php on line 46

Deprecated: Call-time pass-by-reference has been deprecated in

/opt/lampp/htdocs/bugfree/Include/Class/XmlParse.class.php on line 47

Deprecated: Call-time pass-by-reference has been deprecated in

/opt/lampp/htdocs/bugfree/Include/Class/XmlParse.class.php on line 47

Deprecated: Call-time pass-by-reference has been deprecated in

/opt/lampp/htdocs/bugfree/Include/Class/XmlParse.class.php on line 48

Deprecated: Call-time pass-by-reference has been deprecated in

/opt/lampp/htdocs/bugfree/Include/Class/XmlParse.class.php on line 49

Deprecated: Call-time pass-by-reference has been deprecated in

/opt/lampp/htdocs/bugfree/Include/Class/XmlParse.class.php on line 51

Deprecated: Call-time pass-by-reference has been deprecated in

/opt/lampp/htdocs/bugfree/Include/Class/XmlParse.class.php on line 56

Deprecated: Call-time pass-by-reference has been deprecated in

/opt/lampp/htdocs/bugfree/Include/Class/XmlParse.class.php on line 56

解决办法:
修改/opt/lampp/etc/php.ini

找到allow_call_time_pass_reference = Off一行,将Off修改为On

--------------------------------------------------------

数据的备份、恢复

1.备份

做为系统安全保障的一部分,及时、全面的备份是一项必不可少的工作。数据库以及各软件的配置文件、日志等,经常会使管理员晕头转向,一不小心就会漏掉一项。而XAMPP则让这一工作变得非常简单,输入下面的命令就可一步完成:

/opt/lampp/lampp backup ****

命令后面跟着的是MySQL 的 root 用户的密码。命令执行后会看到下面的内容:

Backing up databases...

Backing up configuration, log and htdocs files...

Calculating checksums...

Building final backup file...

Backup finished.

Take care of /opt/lampp/backup/xampp-backup-19-02-06.sh

2.恢复

恢复以前的备份,只需以 root 用户身份运行下面的命令:

# sh /opt/lampp/backup/xampp-backup-19-02-06.sh ****

命令后面跟着的是MySQL 的 root 用户的密码,这时用户将看到如下信息:

Checking integrity of files...

Restoring configuration, log and htdocs files...

Checking versions...

Installed: XAMPP 1.5.1

Backup from: XAMPP 1.5.1

Restoring MySQL databases...

Restoring MySQL user databases...

Backup complete. Have fun!

You may need to restart XAMPP to complete the restore.

恢复完后,需要重新启动XAMPP,才能使恢复的数据可用。

--------------------------------------------------------

如果本机访问没有问题了,但局域网等访问不了的话,可能就是防火墙阻止了,各个linux版本关防火墙有所不同

比如ubuntu的命令就是:#sudo ufw disable

至此,全部安装完成!XAMPP平台真的是个好东西,省去了很多在Linux安装的麻烦!

原文地址:https://www.cnblogs.com/fx2008/p/2303754.html