随笔-118  评论-117  文章-25  trackbacks-0

1:download resource
----------------------------------------------|
download jboss4.0.5                           |
download  j2ee-1_4-doc-tutorial_2.zip         | 
download apache-ant-1.6.2-bin.tar             |
download  j2sdk-1_4_2_15-linux-i586.bin       |
download  jbossj2ee-src.zip                   |
----------------------------------------------|


2: create user .
----------------------------------------------| 
root                                          |
useradd jboss -g oinstall                     |
passwd jboss                                  |
password:123456                               |
su - jboss                                    | 
----------------------------------------------|

3:copy releated file and unzip files
----------------------------------------------------------------------------------|
pwd                                                                               |
/home/jboss                                                                       |
mkdir soft                                                                        |
ll                                                                                |
/home/jboss/soft                                                                  |
copy ant ,tutorial ,jdk, jboss and jbosstutorial to /home/jboss/soft              |
[jboss@ohebt soft]$ ll                                                            |
total 139560                                                                      | 
-rw-r--r--  1 jboss oinstall  7931179 Nov 26 15:16 apache-ant-1.6.2-bin.tar       |
-rw-r--r--  1 jboss oinstall 17135608 Jan 15 10:56 j2ee-1_4-doc-tutorial_2.zip    |
-rwxr--r--  1 jboss oinstall 36377609 Jul 27 16:13 j2sdk-1_4_2_15-linux-i586.bin  |
-rw-r--r--  1 jboss oinstall 80866589 Jan 10 09:13 jboss-4.0.5.GA.zip             |
-rw-r--r--  1 jboss oinstall   399391 Jan 14 16:47 jbossj2ee-src.zip              |
                                                                                  |
tar -zxvf apache-ant-1.6.2-bin.tar                                                |
./j2sdk-1_4_2_15-linux-i586.bin                                                   |
unzip jboss-4.0.5.GA.zip                                                          |
unzip j2ee-1_4-doc-tutorial_2.zip -d ..                                           |
unzip jbossj2ee-src.zip -d ../j2eetutorial14                                      |
                                                                                  |
[jboss@ohebt ~]$ cd ~                                                             |
[jboss@ohebt ~]$                                                                  |
[jboss@ohebt ~]$ ll                                                               |
total 24                                                                          |
drwxr-xr-x  2 jboss oinstall 4096 Jan 17 03:39 Desktop                            |
drwxr-xr-x  5 jboss oinstall 4096 Jan 17 08:03 j2eetutorial14                     |
drwxr-xr-x  5 jboss oinstall 4096 Jan 17 07:59 soft                               |
----------------------------------------------------------------------------------|

4 modify user env
----------------------------------------------------------|
vi .bashrc                                                |
add the following four lines to the end of .bashrc        |
export ANT_HOME=/home/jboss/soft/apache-ant-1.6.2         |
export JAVA_HOME=/home/jboss/soft/j2sdk1.4.2_15           |
export JBOSS_HOME=/home/jboss/soft/jboss-4.0.5.GA         |
export PATH=${ANT_HOME}/bin:${JAVA_HOME}/bin:$PATH        |
----------------------------------------------------------|

5:logout and relogin
---------------------------------|
 the user env become effective   |
---------------------------------|

6: config  hsqldb-ds.xml
---------------------------------------------------------------------------------------------------------|
cd /home/jboss/soft/jboss-4.0.5.GA/server/default/deploy                                                 |
vi hsqldb-ds.xml                                                                                         |
comment  <connection-url>jdbc:hsqldb:${jboss.server.data.dir}${/}hypersonic${/}localDB</connection-url>  |
add      <connection-url>jdbc:hsqldb:hsql://localhost:1701</connection-url>                              |
uncomment                                                                                                |
   <mbean code="org.jboss.jdbc.HypersonicDatabase"                                                       |
     name="jboss:service=Hypersonic">                                                                    |
     <attribute name="Port">1701</attribute>                                                             |
     <attribute name="BindAddress">${jboss.bind.address}</attribute>                                     |
     <attribute name="Silent">true</attribute>                                                           |
     <attribute name="Database">default</attribute>                                                      | 
     <attribute name="Trace">false</attribute>                                                           |
     <attribute name="No_system_exit">true</attribute>                                                   |
   </mbean>                                                                                              |
comment                                                                                                  |
      <mbean code="org.jboss.jdbc.HypersonicDatabase"                                                    |
     name="jboss:service=Hypersonic,database=localDB">                                                   |
     <attribute name="Database">localDB</attribute>                                                      |
     <attribute name="InProcessMode">true</attribute>                                                    |
   </mbean>                                                                                              |
                                                                                                         |
uncomment                                                                                                | 
     <depends>jboss:service=Hypersonic,database=localDB</depends>                                        |
add                                                                                                   |
                                                                                                         |
   <depends>jboss:service=Hypersonic</depends>                                                           |
---------------------------------------------------------------------------------------------------------|
  
  
7:modify j2ee_tutorial related file
--------------------------------------------------|
cd /home/jboss/j2eetutorial14/examples/bank       |
vi  build.properties                              |
only modify one line                              |
jdbc.resource.name=DefaultDS                      |
                                                  |
cd /home/jboss/j2eetutorial14/examples/bank/web   |
there's three \$ exits in the follwoing file      |
transferAck.jsp                                   |
atmAck.jsp                                        |
accountList.txt                                   |
                                                  |
delete \$ from the above three file.              |
--------------------------------------------------|

8: starup jboss
--------------------------------------------------|
cd /home/jboss/soft/jboss-4.0.5.GA/bin            |
nohup ./run.sh                                    |
--------------------------------------------------|

9: Modify build related file
--------------------------------------------|
cd /home/jboss/j2eetutorial14               |
modify jboss-build.properties               |
jboss.home=/home/jboss/soft/jboss-4.0.5.GA  |
jboss.server=${jboss.home}/server/default   |
jboss.deploy.dir=${jboss.server}/deploy     |
--------------------------------------------|

 

 

 

 

 

posted on 2008-01-18 10:42 loocky 阅读(916) 评论(0)  编辑  收藏 所属分类: java

标题  
姓名  
主页
验证码 *  
内容(请不要发表任何与政治相关的内容)  
  登录  使用高级评论  新用户注册  返回页首  恢复上次提交      
 
 
相关链接:
网站导航: