× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hi,

I haven't maintained the log of the whole process because of all that haste
we've had.

This is the short list of things you need to do:

1. Take source of JBoss 3.0.0 (3.0.1 and later fail with
NullPointerException in MBeanRegistry, if anybody can fix it - fine)
2. Comment out all deleteOnExit() functions you may encounter
3. Rebuild the whole thing with jikes compiler
4. Copy it to AS/400
5. Try to run. Below is an exerpt from JBoss forum - I haven't found its
original online so I'm posting it here.
6. Any problems? Then ask me, I probably can remember how I've solved it.

Regards,
Timur

--- cut


Re: Instructions on Installing JBoss on AS/400 Posted: Aug 5, 2002 1:03 PM
Reply

I've seen several request concerning running JBoss on an AS/400 and/or
iSeries. Therefore, I thought I would share with everyone how I have JBoss
3.0 running, in batch, on one of our iSeries systems. Hopefully, this will
point other AS/400 and/or iSeries users in the right direction.
I'm currently evaluating the JBoss server to see how it performs and it is
strictly in Test Mode at this time.
(My apologies for the length, but I thought it best to include all the
details for clarity. In addition, the assumption is made the reader knows
how to use SEU and create programs and commands.)
First this is my current cumulative PTF level and the JDK I have running
=======================================================
System Configuration.
OS/400 V5R1M0 with Cumulative PTF Level C2134510, with current Group PTF?s.
Resource
ID Option Feature Description
5722JC1 *BASE 5050 AS/400 Toolbox for Java
5722JC1 *BASE 2924 AS/400 Toolbox for Java
5722JV1 *BASE 5050 IBM Developer Kit for Java
5722JV1 *BASE 2924 IBM Developer Kit for Java
5722JV1 5 5105 Java Developer Kit 1.3
========================================================
Instructions for Running Jboss 3.0 in Batch on an AS/400 and/or iSeries.

1) Create a job queue for JBOSS.
CRTJOBQ JOBQ(QGPL/JBOSS) TEXT('Jobq for JBoss Application Server')

2) Create a run class for the jobs
CRTCLS CLS(QGPL/JBOSS) RUNPTY(25) TEXT('JBoss Job Class')
The resulting class will look like this:
=======================================================
Display Class Information
Class . . . . . . . . . . : JBOSS
Library . . . . . . . . : QGPL
Run Priority . . . . . . . : 25
Time slice in milliseconds : 2000
Eligible for purge . . . .: *YES
Default wait time in seconds : 30
Maximum CPU time in milliseconds . : *NOMAX
Maximum temporary storage in Megabytes : *NOMAX
Maximum threads . . . .. . . . . : *NOMAX
Text . . . . . . . : JBoss Job Class
======================================================
3) Create a Subsystem for the jobs to run in.
CRTSBSD SBSD(QGPL/JBOSS) POOLS((1 *BASE)) TEXT('JBoss Web Application Server
SubSystem')

4) Now associate the job queue we created in step 1, to the subsystem.
ADDJOBQE SBSD(QGPL/JBOSS) JOBQ(QGPL/JBOSS) MAXACT(*NOMAX)

5) Now we need to add a routing entry into the subsystem and tie in the
Class we created in Step 2.
ADDRTGE SBSD(QGPL/JBOSS) SEQNBR(9999) CMPVAL(*ANY) PGM(QCMD) CLS(QGPL/JBOSS)
At this point you now have a new subsystem, in which to run the JBoss Web
Application Server. It has its own job queue and its own run class.
The next section deals with user profiles, paths, starting and stopping, and
enhancements you can make.

I. User Profile:
In order to make things easier I created a unique user profile called
JBOSSADMIN for the JBoss Jobs to run under. This is what I did, and you can
run the jobs under whatever profile gives you the access you need on your
system while staying in compliance with your security rules.
The major point about my profile (JBOSSADMIN) is that I set its ?home?
directory (HOMEDIR) to point to the JBOSS bin directory in the IFS:
CRTUSRPRF USRPRF(JBOSSADMIN) TEXT('JBoss Web Application Server Admin
Profile') HOMEDIR('/jboss-3.0.0_tomcat-4.0.3/bin')

II. Create a ShortCut to the Jboss Directory.
I found it very useful to create a shortcut to the JBOSS directory instead
of typing in ?/jboss-3.0.0_tomcat-4.0.3? everytime. On the AS/400 this is
called a Symbolic Link and should be placed in the Root of the IFS.
ADDLNK OBJ('/jboss-3.0.0_tomcat-4.0.3') NEWLNK(JBOSS)
This will give you the following link.
========================================================
Display Symbolic Link
Object link . . . . . : /JBOSS
Content of Link . . . : /jboss-3.0.0_tomcat-4.0.3
========================================================

III. Commands and Programs to Submit the JBoss Server.
I created a CLP program and a command to submit the job for me so that all I
have to do is execute the command.
The command and the CLP program are both named SBMJBOSS.
First the CLP program looks like this:
SEU==> SBMJBOSS
FMT ** ...+... 1 ...+... 2 ...+... 3 ...+... 4 ...+... 5 ...+... 6 ...+... 7
*************** Beginning of data *************************************
0001.00 PGM
0002.00
0002.01 SBMJOB CMD(RUNJVA CLASS(org.jboss.Main) +
0002.02 CLASSPATH('/JBOSS/bin/run.jar:/tools.jar')) +
0002.03 JOB(JBOSSSERVR) JOBQ(JBOSS) +
0002.04 USER(JBOSSADMIN) CPYENVVAR(*YES) +
0002.05 ALWMLTTHD(*YES)
0013.00
0014.00 ENDPGM
****************** End of data ****************************************

You will note that the job name is JBOSSSERVR and that the user profile it
will run under is JBOSSADMIN. The job is submitted to the job queue JBOSS
which will then feed the job to the JBOSS subsystem. In addition, you will
see on the CLASSPATH variable that I use the JBOSS symbolic link name to
point to the bin directory. Also, note that I use the CPYENVVAR parameter on
the SBMJOB command, in order to copy any special environmental setting I may
have in place. Finally, I?ve specified the ALWMLTTHD(*YES), to allow the job
to use multiple threads.

Here is the command source and the command to create it.
SEU==> SBMJBOSS
FMT ** ...+... 1 ...+... 2 ...+... 3 ...+... 4 ...+... 5 ...+... 6 ...+... 7
*************** Beginning of data *************************************
0001.00 0002.00 CMD PROMPT('Submit the JBOSS Web Server')
****************** End of data ****************************************
Here is the command for creating the command:
=========================================================
CRTCMD CMD(SBMJBOSS) PGM(SBMJBOSS) TEXT('Submit the JBOSS Web Application
Server')

IV. Starting the JBoss Web Application Server.
First the JBoss Subsystem has to be up and running:
STRSBS SBSD(QGPL/JBOSS)
Next, since I have a command, I type in SBMJBOSS. And this submits the job
to the JBOSS job queue. (Note: You could just CALL PGM(SBMJBOSS) on a
command line if you like.)
This starts up the server in the JBoss Subsytem and will look like this:
====================================================
Work with Active Jobs
CPU %: 3.5 Elapsed time: 00:00:01 Active jobs: 197
Subsystem/Job User Type CPU % Function Status
JBOSS QSYS SBS .0 DEQW
JBOSSSERVR JBOSSADMIN BCH .0 CMD-RUNJVA TIMW
QJVACMDSRV JBOSSADMIN BCI .0 PGM-QJVACMDSRV JVAW
=========================================================

V. Stopping the JBoss Web Application Server.
I have not had the opportunity to create an AS/400 command to stop the
server, however its in my ?to do? list for the future. I plan to access the
?org.jboss.util.Shutdown? service to accomplish this.
Currently, I just access the ?Agent View?, via my web browser, by accessing
the JBoss Webserver at port 8082.
http://?server name?:8082
Then I select ?jboss.server? and under it I select ?type=Server?, then I
select the last button in the list which is the Mbean operation ?Shutdown?.
This ends the server in a nice orderly fashion.

VI. Enhancements you can make if you would like.
Since I prefer to run the web and application servers in their own memory
pool instead of *BASE, which is what was used in Step 3, when the subsysem
was created, I?ve changed my subsystem description, to use a shared memory
pool. This involves a little knowledge about ?Work Management? on the AS/400
and/or iSeries so I?ll just detail all the steps here. (These steps are
optional, but can give you more flexibility in allocating resources.)
1) First, I created a ?Shared? memory pool for the servers and gave it (256)
Meg of memory to work with.
A) Use the WRKSHRPOOL command to list out all your current memory pools.

B) Select an open shared pool and allocate the memory, active job
information, and paging options.
Below I?ve selected *SHRPOOL4 and given it 256 Meg of memory with 20 maximum
active jobs and *CALC for the paging option.
==================================================
Work with Shared Pools
Main storage size (M) . : 2005.37
Type changes (if allowed), press Enter.
Defined Max Allocated Pool -Paging Option--
Pool Size (M) Active Size (M) ID Defined Current
*MACHINE 350.00 +++++ 350.00 1 *FIXED *FIXED
*BASE 550.8 1500 550.81 2 *CALC *CALC
*INTERACT 404.55 80 404.55 5 *CALC *CALC
*SPOOL 50.00 10 *FIXED
*SHRPOOL1 250.00 50 250.00 3 *FIXED *FIXED
*SHRPOOL2 100.00 50 100.00 6 *CALC *CALC
*SHRPOOL3 350.00 50 350.00 4 *CALC *CALC
*SHRPOOL4 256.00 20 *CALC
======================================================

C) Now change the subsystem to use the new memory pool.
CHGSBSD SBSD(QGPL/JBOSS) POOLS((2 *SHRPOOL4))
Note: Make sure you set the pool to be pool #2, the change to the subsystem
will then cause it to have the following memory pools:
=============================================
Display Pool Definitions
Subsystem description: JBOSS Status: ACTIVE
Pool Storage Activity
ID Size (K) Level
1 *BASE
2 *SHRPOOL4
=============================================

D) Finally, change the routing entry, so that all new jobs will use the
second pool, for their memory.
CHGRTGE SBSD(QGPL/JBOSS) SEQNBR(9999) POOLID(2)

This completes the instructions I use for running JBoss in a Batch Job on
the AS/400. It is not the only way you can do it, but it works fine for me.
As I test more, these instructions are subject to change based on what I
might find.
Hope this helps!
Keith
--- cut

----- Original Message -----
From: "Stefan Groschupf" <sg@media-style.com>
To: <java400-l@midrange.com>
Sent: Monday, November 04, 2002 2:00 PM
Subject: Re: AS 400 & ejbs


> Hi Timur,
>
> > We've managed to run JBoss at AS/400, after a couple of tweaks and
> > nearly a man-week spent on this.
>
> Sorry for asking, but would you publish the changes of jboss?
> Would be very great and solve a lot of time for my testing phase.
>
>
> Thank you very much.
> Stefan
>
>
> _______________________________________________
> This is the Java Programming on and around the iSeries / AS400 (JAVA400-L)
mailing list
> To post a message email: JAVA400-L@midrange.com
> To subscribe, unsubscribe, or change list options,
> visit: http://lists.midrange.com/cgi-bin/listinfo/java400-l
> or email: JAVA400-L-request@midrange.com
> Before posting, please take a moment to review the archives
> at http://archive.midrange.com/java400-l.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.