lmgsanm

每天学习一点,每天进步一点点…… Tomorrow is another beatifull day

导航

< 2025年1月 >
29 30 31 1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31 1
2 3 4 5 6 7 8

统计

testlink简单部署

CentOS+LAMP+testlink

环境

系统

         CentOS6.5

软件

         testlink-1.9.14

IP

192.168.0.158

部署

LAMP环境搭建

remi配置

wget http://rpms.remirepo.net/enterprise/remi-release-6.rpm

rpm -Uvh remi-release-6.rpm epel-release-latest-6.noarch.rpm

wget http://rpms.remirepo.net/enterprise/remi.repo

cp remi.repo /etc/yum.repos.d/

wget http://repo.mysql.com//mysql57-community-release-el6-8.noarch.rpm

rpm -ivh mysql57-community-release-el6-8.noarch.rpm

 

httpd

yum -y install httpd httpd-devel httpd-tools httpd-manual libmicrohttpd-doc libmicrohttpd libmicrohttpd-devel mod_dav_svn mod_dnssd mod_auth_mellon mod_lookup_identity mod_ssl php56-php-xcache php56-xcache-admin

chkconfig httpd on

 

mysql

yum -y install mysq mod_auth_mysql MySQL-python mysql-connector-java mysql-connector-odbc mysql-devel mysql-embedded mysql-embedded-devel mysql-libs mysql-server perl-DBD-MySQL

chkconfig mysqld on

 

php56

yum -y install php56-php-bcmath php56-php-dba php56-php-dbg php56-php-devel php56-php-embedded php56-php-enchant php56-php-fpm php56-php-gd php56-php-intl php56-php-ldap php56-php-libvirt php56-php-litespeed php56-php-mbstring php56-php-mysqlnd php56-php-oci8 php56-php-odbc php56-php-pdo php56-php-pear

testlink安装

testlink解压

tar xzf testlink-1.9.14.tar.gz

cp -r testlink-1.9.14 /var/www/html/testlink

cd /var/www/html/testlink/

mysql配置

修改root密码

mysqladmin -uroot password 'limugen@uce.cn'

mysql -uroot -p'limugen@uce.cn

         CREATE DATABASE testlink CHARACTER SET utf8 COLLATE utf8_general_ci

导入sql数据

mysql -uroot -p'limugen@uce.cn' testlink < install/sql/mysql/testlink_create_tables.sql

mysql -uroot -p'limugen@uce.cn' testlink < install/sql/mysql/testlink_create_default_data.sql

php配置

vim /opt/remi/php56/root/etc/php.ini

         max_execution_time = 120

建立文件目录及修改权限

mkdir -p /var/testlink/upload_area/

mkdir -p /var/testlink/logs/

chmod 777 /var/www/html/testlink/gui/templates_c

chmod 777 /var/testlink/upload_area/

chmod 777 /var/testlink/logs/

testlink配置

vim config_db.inc.php

         <?php // Automatically Generated by TestLink Installer

define('DB_TYPE', 'mysql');

define('DB_USER', 'root');

define('DB_PASS', 'limugen@uce.cn');

define('DB_HOST', 'localhost');

define('DB_NAME', 'testlink');

?>

数据自动备份

脚本

vim  /home/gat/backup/db_backup.sh

         #!/bin/sh

# Script for backup TestLink service

# create filenames

mydate=`date +%y%m%d`

backup_folder="/home/gat/backup"

upload_folder="/home/gat/web/testlink/upload_area/"

filename1="$backup_folder/testlink_db_$mydate.bck.sql"

filename2="$backup_folder/testlink_upload_$mydate.bck.tgz"

# dump data

mysqldump -uroot -pyour_password testlink_17 > $filename1

# compress

gzip -f9 $filename1

# backup attachments

tar -cvzf $filename2 $upload_folder

# save to backuped area on server titan

# mount titan:/export/gat /home/gat/backup/titan/ -o

soft,nosuid,rw,noauto,user,noexec

#cp $filename.gz /home/gat/backup/titan/

chmod u+x  /home/gat/backup/db_backup.sh

定时任务

15 2 * * * su - gat -c /home/gat/backup/db_backup.sh >/dev/null 2>&1

 

登陆

http://192.168.0.158/testlink

posted on   lmgsanm  阅读(461)  评论(0编辑  收藏  举报

编辑推荐:
· 如何打造一个高并发系统?
· .NET Core GC压缩(compact_phase)底层原理浅谈
· 现代计算机视觉入门之:什么是图片特征编码
· .NET 9 new features-C#13新的锁类型和语义
· Linux系统下SQL Server数据库镜像配置全流程详解
阅读排行:
· Sdcb Chats 技术博客:数据库 ID 选型的曲折之路 - 从 Guid 到自增 ID,再到
· Winform-耗时操作导致界面渲染滞后
· Phi小模型开发教程:C#使用本地模型Phi视觉模型分析图像,实现图片分类、搜索等功能
· 语音处理 开源项目 EchoSharp
· drools 规则引擎和 solon-flow 哪个好?solon-flow 简明教程
点击右上角即可分享
微信分享提示