文件 链接:http://pan.baidu.com/s/1ntTi41V 密码:pgox
#下载tomcat
wget http://mirror.bit.edu.cn/apache/tomcat/tomcat-7/v7.0.65/bin/apache-tomcat-7.0.65.tar.gz
tar -zxvf apache-tomcat-7.0.65.tar.gz
mv apache-tomcat-7.0.65 /usr/local/
cd /usr/local/apache-tomcat-7.0.65/bin/
#安装JDK
cd /usr/lib
sudo mkdir jdk1.7.0_60
tar zxvf ./jdk-7u60-linux-x64.tar.gz -C /usr/lib/jdk1.7.0_60
3,配置环境变量
(1)只对当前用户生效
vim ~/.bashrc
export JAVA_HOME=/usr/lib/jvm/jdk1.7.0_60
export JRE_HOME=${JAVA_HOME}/jre
export CLASSPATH=.:${JAVA_HOME}/lib:${JRE_HOME}/lib
export PATH=${JAVA_HOME}/bin:$PATH
保存退出,然后输入下面的命令来使之生效
source ~/.bashrc
(2)对所有用户生效
vim /etc/profile
export JAVA_HOME=/usr/lib/jvm/jdk1.7.0_60
export JRE_HOME=${JAVA_HOME}/jre
export CLASSPATH=.:${JAVA_HOME}/lib:${JRE_HOME}/lib
export PATH=${JAVA_HOME}/bin:$PATH
保存退出,然后输入下面的命令来使之生效
source /etc/profile
配置默认JDK(一般情况下这一步都可以省略)
由于一些Linux的发行版中已经存在默认的JDK,如OpenJDK等。所以为了使得我们
刚才安装好的JDK版本能成为默认的JDK版本,我们还要进行下面的配置。
执行下面的命令:
sudo update-alternatives --install /usr/bin/java java
/usr/lib/jdk1.7.0_60/bin/java 300
sudo update-alternatives --install /usr/bin/javac javac
/usr/lib/jdk1.7.0_60/bin/javac 300
注意:如果以上两个命令出现找不到路径问题,只要重启一下机器在重复上面两行
代码就OK了。
如果不小心写错路径用下面命令删除:
sudo update-alternatives --remove java
/usr/lib/jvm/jdk1.7.0_60/bin/java
java -version
javac -version
#写一个hello world 测试程序,这里就不贴了
vi Test.java
javac Test.java
java Test
cd /usr/local/apache-tomcat-7.0.65/bin
./startup.sh
iptables -I INPUT -p tcp -m multiport --dports 8080:8081 -j ACCEPT
service iptables save
iptables -L -n
查换命令(which httpd)
mv atlassian-jira-6.3.6-standalone/ /usr/local/
cd /usr/local/atlassian-jira-6.3.6-standalone/conf/
vi server.xml 8080 改为 8081
lsof -i:8081
echo $JAVA_HOME
#配置jira_home
vi /usr/local/atlassian-jira-6.3.6-standalone/atlassian-jira/WEB-
INF/classes/jira-application.properties
jira.home = /usr/lib/jdk1.7.0_60 (这里配置Java的home)
#启动JIRA
/usr/local/atlassian-jira-6.3.6-standalone/bin/start-jira.sh
==============================================================
/usr/local/atlassian-jira-6.3.6-standalone/bin/start-jira.sh
[[email protected] /]# /usr/local/atlassian-jira-6.3.6-standalone/bin/start-
jira.sh
To run JIRA in the foreground, start the server with start-jira.sh -fg
executing as current user
.....
.... .NMMMD. ...
.8MMM. $MMN,..~MMMO.
.?MMM. .MMM?.
OMMMMZ. .,NMMMN~
.IMMMMMM. .NMMMN. .MMMMMN,
,MMMMMM$..3MD..ZMMMMMM.
=NMMMMMM,. .,MMMMMMD.
.MMMMMMMM8MMMMMMM,
.ONMMMMMMMMMMZ.
,NMMMMMMM8.
.:,.$MMMMMMM
.IMMMM..NMMMMMD.
.8MMMMM: :NMMMMN.
.MMMMMM. .MMMMM~.
.MMMMMN .MMMMM?.
Atlassian JIRA
Version : 6.3.6
Detecting JVM PermGen support...
PermGen switch is supported. Setting to 384m
If you encounter issues starting or stopping JIRA, please see the
Troubleshooting guide at
http://confluence.atlassian.com/display/JIRA/Installation
+Troubleshooting+Guide
Server startup logs are located in /usr/local/atlassian-jira-6.3.6-
standalone/logs/catalina.out
Using CATALINA_BASE: /usr/local/atlassian-jira-6.3.6-standalone
Using CATALINA_HOME: /usr/local/atlassian-jira-6.3.6-standalone
Using CATALINA_TMPDIR: /usr/local/atlassian-jira-6.3.6-standalone/temp
Using JRE_HOME: /usr/lib/jdk1.7.0_60/jre
Using CLASSPATH: /usr/local/atlassian-jira-6.3.6-
standalone/bin/bootstrap.jar:/usr/local/atlassian-jira-6.3.6-
standalone/bin/tomcat-juli.jar
Using CATALINA_PID: /usr/local/atlassian-jira-6.3.6-
standalone/work/catalina.pid
Tomcat started.
#启动成功
====================================================================
yum -y install mysql-server
#设开机启动
chkconfig mysqld on
#启动mysql服务
service mysqld start
#设置mysql的root用户设置密码
mysql -u root
#查看显示用户密码
select user,host,password from mysql.user;
set password for [email protected]=password(‘root‘);
#删除空密码
delete from mysql.user where user=‘‘;
#修改编码utf8
将:/usr/share/doc/mysql-server-5.1.73/my-large.cnf 内容拷贝到
/etc/my.cnf
vi /etc/my.cnf
#在[client]下添加一行:
default-character-set=utf8
#在[mysqld]下添加一行:
default-character-set=utf8
#重启MySQL:
service mysqld restart
mysql -u root -p
show variables like ‘%character%‘;
#如下图就对了
+--------------------------+----------------------------+
| Variable_name | Value |
+--------------------------+----------------------------+
| character_set_client | utf8 |
| character_set_connection | utf8 |
| character_set_database | utf8 |
| character_set_filesystem | binary |
| character_set_results | utf8 |
| character_set_server | utf8 |
| character_set_system | utf8 |
| character_sets_dir | /usr/share/mysql/charsets/ |
+--------------------------+----------------------------+
8 rows in set (0.00 sec)
#创建数据库
CREATE DATABASE jiradb CHARACTER SET utf8 COLLATE utf8_bin;
#创建mysql jira用户
insert into mysql.user(host,user,password) values ("localhost","jirauser",password("123.com"));
#授权
grant select,insert,update,delete on redmine1.* to [email protected]"%" identified by "jira";
#授权
grant select,insert,update,delete on *.* to [email protected]"%" Identified by "123.com";
#汉化
JIRA-Language-STD-CN.jar汉化包换成JIRA-6.3.3-language-pack-zh_CN.jar
将汉化包 和 jdbc驱动包mysql-connector-java-5.1.25-bin.jar复制到/atlassian-jira-6.3.6-standalone/atlassian-jira/WEB-INF/lib下面,之后
重启jira服务
#发现没有mysql配置服务 无法返回上一步
删除/usr/lib/jdk1.7.0_60/dbconfig.xml重启JIRA 重新配置
========================================================================
#破解
将atlassian-extras-2.2.2 复制到 /usr/local/atlassian-jira-6.3.6-
standalone/atlassian-jira/WEB-INF/lib/下
========================================================================
Description=JIRA: Commercial,
CreationDate=你的安装日期,格式(yyyy-mm-dd),
jira.LicenseEdition=ENTERPRISE,
Evaluation=false,
jira.LicenseTypeName=COMMERCIAL,
jira.active=true,
licenseVersion=2,
MaintenanceExpiryDate=你想设置的失效日期如:2099-12-31,
Organisation=joiandjoin,
SEN=你申请到的SEN注意没有前缀LID,
ServerID=你申请到的ServerID,
jira.NumberOfUsers=-1,
LicenseID=LID你申请到的SEN,注意LID前缀不要丢掉,
LicenseExpiryDate=你想设置的失效日期如:2099-12-31,
PurchaseDate=你的安装日期,格式(yyyy-mm-dd)
========================================================================
Description=JIRA: Commercial,
CreationDate=2015-12-07,
jira.LicenseEdition=ENTERPRISE,
Evaluation=false,
jira.LicenseTypeName=COMMERCIAL,
jira.active=true,
licenseVersion=2,
MaintenanceExpiryDate=2099-12-31,
Organisation=xiaocz,
SEN=SEN-L6925973,
ServerID=BTMV-NXRZ-EX5U-7DQE,
jira.NumberOfUsers=-1,
LicenseID=AAABBw0ODAoPeNptkFtLxDAQhd/zKwI
+R9Kwy66FPKxthGhvtF0p4kuso0a6sUwvuP/edissyj4MD
HPOfHOYqzu0tICWeoJy4a
+FzzkNwpIK7q1ICF2Ntu3tl5P3Ot89+1SNphnMPCEBwqkJTQ9y9jN+w
zxBPi2a68jW4DpQr/a0rZJS5VmuC0XOBNnjAH/s5bGFxBxABmkcqzzQu2jRTd3bEZaFZvE
+AnYzR
JDYWNeDM64G9d1aPJ4TeXxOlOK7cbZbjrbNgkyGwwtg+rbvJpBkHikAR0Adytt0XzFV7R5Y
+qQzV
kWZIoVK5FQsWq03YrvdkN/Ekz3S4SXlcpRswPrDdPD/aT
+P1nzDMC0CFQCM9+0LlHVNnZQnSTwuR
O3eK+2gVgIUCteTs4Q3khIgrnsY64hxYB/d8bM=X02dh,
LicenseExpiryDate=2099-12-31,
PurchaseDate=2015-12-07
========================================================================