To configure the Apache Web Server to work with Web Report Server/400:
Prerequisite: Web Report Server/400 version 1.18 or above.
Note: If you are using the AS/400 HTTP Server, these settings are not required.
- Get to the RJSWRS main menu by typing:
ADDLIBLE RJSWRS
GO RJSWRS
- Choose 20. Restore HTML Files to /RJSWRS IFS Directory - WRSIFS1.
- Run the following command to copy the CGI server program to the RJSWRS library:
CRTDUPOBJ OBJ(QTMHCGI) FROMLIB(QHTTPSVR) OBJTYPE(*SRVPGM)
- Run the following command to add web server access directives to the Apache Web Server instance:
Note: This example uses a web server instance named WEBSERVER1.
WRSAPACH1 WEBSVRNAME(WEBSERVER1)
Note: You can also use the browser-based Apache configuration screen to manually add web server directives.
The following lines are added to the AS/400 Apache web server configuration:
ScriptAliasMatch ^/RJSWRS/(.*) /QSYS.LIB/RJSWRS.LIB/$1.PGM
AllowOverride None
SetHandler cgi-script
Options +ExecCGI
order allow,deny
allow from all
- Run the following commands to set object authorities on the RJSWRS library and the /RJSWRS IFS folder:
GRTOBJAUT OBJ(RJSWRS/*ALL) OBJTYPE(*ALL) USER(*PUBLIC) AUT(*USE)
GRTOBJAUT OBJ(QSYS/RJSWRS) OBJTYPE(*ALL) USER(*PUBLIC) AUT(*USE)
CHGAUT OBJ('/RJSWRS/*') USER(*PUBLIC) DTAAUT(*RWX) OBJAUT(*ALL)
- Run one of the following commands from the RJSWRS library to set the Web Report Server/400 web server setting:
Note: The AS/400 Apache Web Server returns HTML files in EBCDIC format unless the web server setting is set correctly.
- To set for Apache Web Server (V5R1 and above), use:
RJSWRS/WRSWEBSVR WEBSVR(APACHE)
- To set for the old AS/400 HTTP Server, use:
RJSWRS/WRSWEBSVR WEBSVR(AS400HTTP)
- To display the current setting, use:
DSPDTAARA DTAARA(RJSWRS/WRSWEBSVR)
- Stop and re-start the Apache Web Server instance:
Note: This example uses a web server instance named WEBSERVER1.
- Stop the Apache Web Server instance:
ENDTCPSVR SERVER(*HTTP) HTTPSVR(APACHEDFT)
- Run:
WRKACTJOB SBS(QHTTPSVR)
- Press F5 to refresh the WRKACTJOB screen until the jobs for the web server instance end completely.
- Re-start the Apache Web Server instance:
STRTCPSVR SERVER(*HTTP) HTTPSVR(APACHEDFT)
- Use a web browser to log in to Web Report Server/400, where 1.1.1.1 is your IP address:
http://1.1.1.1/RJSWRS/WRS200R?ACTION=INIT
If the web server is on a port other than port 80, use the following URL format, where 1.1.1.1 is your IP address and 1080 is the port:
http://1.1.1.1:1080/RJSWRS/WRS200R?ACTION=INIT
Last Modified On:
No, open a new Support Case