Thursday, September 19, 2019

How to Configure Webutil in Forms 12c weblogic


How to Configure Webutil in Forms 12c

1)- Download Webutil files from the following link:
-Webutil version 1.0.6

( With Oracle developersuite 10.1.2.2 or higher , webutil 10.1.2.2.x will be automatically installed !)

It is not recommented to use with Forms 10.1.2.2 or higher webutil version 1.0.6 !

-WebUtil Demo from OTN

-The JACOB libraries version 1.8


2)- Create folder “webutil” under
%ORACLE_HOME%\forms

3)- Copy the following files into %ORACLE_HOME%\forms\webutil :
(a) jacob.dll ---> included in jacob_18.zip
(b) ffisamp.dll ---> included in Webutil_demo.zip
(c) d2kwut60.dll ---> included in webutil_106.zip, under webutil subfolder
(d) JNIsharedstubs.dll ---> included in webutil_106.zip, under webutil subfolder
(e) sign_webutil.bat ---> included in webutil_106.zip, under webutil subfolder


4)- Copy the following files to %ORACLE_HOME%\forms\java :
webutil_106\java \forms_base_ie.js
webutil_106\java \forms_ie.js
webutil_106\java \frmwebutil.jar
jacob_18\jacob.jar

5)-Sign the "jacob.jar"as follows:
- start the command prompt
- cd %ORACLE_HOME%\forms\java
- set PATH=%ORACLE_HOME%\jdk\bin;%PATH%
- %ORACLE_HOME%\forms\webutil\sign_webutil.bat %ORACLE_HOME%\forms\java\jacob.jar

6)- Sign the "frmwebutil.jar"as follows:

    a)-For Forms 10.1.2.0.2:
    - start the command prompt
    - cd %devsuitHOME%\forms\java
    - set PATH=%devsuitHOME%\jdk\bin;%PATH% %devsuitHOME%\forms\webutil\sign_webutil.bat %devsuitHOME%\forms\java\frmwebutil.jar

     b)-For Forms 10.1.2.2 or higher:

    1)-Get frmwebutil.jar from an Oracle Developer Suite installation which has the same version as the OAS and then ,copy it to“%ORACLE_HOME%\forms\java”.

    OR

    Get the frmwebutil.jar file from the Patchset 10.1.2.x kit as described in the following note and then ,copy it to “%ORACLE_HOME%\forms\java” :

    Note 421930.1- How to get FRMWEBUTIL.JAR from IAS/IDS Patchset 10.1.2.x Kit

    2)-Then, sign the frmwebutil.jar using the same steps as (6-a) .

Explanation:
frmwebutil.jar 1.0.6 is available for use with Forms versions 9.0.4 and 10.1.2.0.2. However,starting with Forms 10.1.2.2,the version of frmwebutil.jar has to be the same as the running Forms version .
frmwebutil.jar 10.1.2.2 or higer is included with Patchset 10.1.2.x, which is the base release (10.1.2.0.2) plus a Patchset applied. This frmwebutil.jar version gets installed on Oracle Developer Suite Home when the Patchset is applied but not with Oracle AS Home .


6)-Copy the following files from webutil_106\server to %ORACLE_HOME%\forms\server
- webutil.cfg
- webutilbase.htm
- webutiljini.htm
- webutiljpi.htm

7)- The following variable must be defined in %ORACLE_HOME%\forms\server\default.env:
WEBUTIL_CONFIG=<ORACLE_HOME>\forms\server\webutil.cfg

8). The following jars must be included in the CLASSPATH in forms/server/default.env:
%ORACLE_HOME%\forms\java\frmall.jar;%ORACLE_HOME%\forms\java\frmwebutil.jar;%ORACLE_HOME%\forms\java\jacob.jar;%ORACLE_HOME%\jdk\jre\lib\rt.jar

9)- The configuration file formsweb.cfg should have the following section :
[webutil]
WebUtilArchive=frmwebutil.jar,jacob.jar
WebUtilLogging=off
WebUtilLoggingDetail=normal
WebUtilErrorMode=Alert
WebUtilDispatchMonitorInterval=5
WebUtilTrustInternal=true
WebUtilMaxTransferSize=16384
baseHTMLjinitiator=webutiljini.htm
baseHTMLjpi=webutiljpi.htm
archive_jini=frmall_jinit.jar
archive=frmall.jar
lookAndFeel=oracle

10)- The following virtual path must be defined in the %ORACLE_HOME%\forms\server\forms.conf file:
AliasMatch ^/forms/webutil/(..*) "%ORACLE_HOME%/forms/webutil/$1"


11)- Open webutil.cfg file and add the following line
Add the following line :
install.syslib.0.user.1=ffisamp.dll|40960|1.0|true

below :
install.syslib.0.7.1=jacob.dll|94208|1.0|true
install.syslib.0.9.1=JNIsharedstubs.dll|65582|1.0|true
install.syslib.0.9.2=d2kwut60.dll|192512|1.0|true

12)- In the webutil.cfg file ensure you have the lines
transfer.appsrv.workAreaRoot=d:\temp
transfer.appsrv.accessControl=FALSE
transfer.database.enabled=TRUE
transfer.appsrv.enabled=TRUE

13)- Create a database user "Webutil" .

14)- Run the script. "create_webutil_db.sql" (included in webutil_106.zip file).

15)- Create a file called d:\temp\downloaded_from_as.txt. Ensure you add text to this file.This is a test file
which will be used to demonstrate loading files from the application server to the client.The Download test
expects this file to exist in this location on the Application Server.

16)- Open forms builder and connect as "Webutil" user .Compile ALL" (shift-Control-K) form. WU_TEST_106.fmb and webutil.pll ,then generate the fmx and plx using (Control-T).

17)-Move the following files to %ORACLE_HOME%\forms :
WU_TEST_106.fmx
webutil plx
webutil.olb

(c) Run the Demo form. WU_TEST_106 as the following to make sure that the installation went fine:
http://host:port/forms/frmservlet?config=webutil&form=WU_TEST_106&userid=webutil/webutil@db

(d) For more information ,go through the webutil documentation (specially "Runtime Setup Checklist" and
"WebUtil Installation Steps").You will also find more describtion about the various webutil program units :

Webutil Documentation

18)-You may also run the diagnostic test form. described in the following note for furthur checking on the Webutil configuration :
Note :553849.1Webutil Diagnostic Test Form. For Checking Webutil Configuration


Run this sql script   .directory ORACLE_HOME/forms
“ create_webutil_db.sql



C:\WINDOWS\system32>cd D:
D:\

C:\WINDOWS\system32>D:

D:\>cd D:\Oracle\Middleware\Oracle_Home\forms

D:\Oracle\Middleware\Oracle_Home\forms>sqlplus / as sysdba

SQL*Plus: Release 12.1.0.1.0 Production on Thu Sep 19 16:12:16 2019

Copyright (c) 1982, 2013, Oracle.  All rights reserved.


Connected to:

Oracle Database 12c Enterprise Edition Release 12.1.0.1.0 - 64bit Production
With the Partitioning, OLAP, Advanced Analytics and Real Application Testing options

SQL> @create_webutil_db.sql;

Package created.

Package body created.

Disconnected from Oracle Database 12c Enterprise Edition Release 12.1.0.1.0 - 64bit Production
With the Partitioning, OLAP, Advanced Analytics and Real Application Testing options

How to Configure Webutil in Forms 12c (Doc ID 2070183.1)

Applies to:
Oracle Forms - Version 12.2.1.0.0 and later
Oracle Reports Developer - Version 12.2.1.0.0 to 12.2.1.0.0 [Release 12c]
Information in this document applies to any platform.
Goal
 How to configure WebUtil in your 12c Forms installation.
Solution
NOTE: General information about Webutil may be found on OTN

Important Point:  The configuration steps here assume you need Microsoft OLE functionality which requires jacob.jar configuration.  Microsoft OLE functions are used primarily in Forms by Forms Developers who wish to interact with Microsoft applications such as Word or Excel from Forms.  If there is no need to do this, then there is no reason to accomplish the jacob.jar configuration steps detailed here.  If you do not need OLE functions, then do not use this note and skip to Note 1644754.1 Webutil Demo with No Jacob Dependency/ No OLE Features.

The WebUtil utility is largely configured in your 12c Forms installation.  However, there are some additional steps you will need to accomplish in order to make it work properly.

1.  Configure your DB for WebUtil by running the script called "create_webutil_db.sql" located in the ORACLE_HOME/forms directory against the schema of your choice. See section 2.4 of the WebUtil User's Guide for details about the package this script creates. Note that the only time you will need to be connected to a DB that contains this package is if:

a. You need to regenerate your webutil Form or webutil.pll
b. You are using WEBUTIL_FILE_TRANSFER functions related to the DB.
 
IMPORTANT NOTE!!!  12c Forms - all versions -  require JACOB 1.18-M2 if one wishes to use OLE features and/or if the application was not created with the WebUtil Object Group named WEBUTIL_NO_OLE.  JACOB 1.18-M2 is the only supported version of jacob with 12c Forms.

2.  Download jacob-1.18-M2 and unzip it in the directory of your choice.

3.The jacob.jar file is not signed so will cause Java Security Warning messages which which must be addressed.  See Note 2065434.1 for available options to address these.
Note:  Unlike earlier versions of jacob, this version of jacob.jar already has the required entries in its manifest so there is normally no need to modify these.
Also, if using WebStart, jacob.jar will need to be referenced in the ORACLE_HOME/forms/java/extensions.jnlp file.  See Note 2083540.1.


4. Once you have signed jacob.jar or implemented one of the other methods outlined in Note 2065434.1 , place jacob.jar in your ORACLE_HOME/forms/java directory. If using Webstart or JNLP methods of running Forms with Webutil, ensure you configure the extensions.jnlp file according to Note 2083540.1 - Configuring Webutil For Java WebStart (JavaWS).
Note that frmwebutil.jar, like all Oracle supplied jar files, is already signed by Oracle.  It is not recommended that you resign this or other Oracle provided jar files.

5.  If you will be developing with WebUtil using Forms Builder, ensure ORACLE_HOME/forms/java/frmwebutil.jar is contained in the FORMS_BUILDER_CLASSPATH environment variable.

6. Note that two critical files - webutil.pll and webutil.olb - are already located in the ORACLE_HOME/forms directory, which, by default, is in the FORMS_PATH environment variable.

7.  Place the jacob supporting dlls in the appropriate directories.

a. Place jacob-1.18-M2-x86.dll in the ORACLE_HOME/forms/webutil/win32 directory.
b. Place jacob-1.18-M2-x64.dll in the ORACLE_HOME/forms/webutil/win64 directory.

Note: Do note rename these files since they are referenced in the webutil.cfg file by these names.


8. Using Oracle Enterprise Manager 12c Fusion Middleware Control, make the following modifications to the [webutil] configuration section in the formsweb.cfg:

  a. Verify that  frmwebutil.jar and jacob.jar are included in the WebutilArchive parameter in the [webutil] configuration section.
  b. Specify webutil_demo as the form to be run in the [webutil] configuration section.

9. Download the WebUtil demo form from Note 1272222.1 and place it in the ORACLE_HOME/forms  directory.  This will be used to confirm to determine that basic WebUtil functionality is working.
NOTE: To configure and use all of the features in the WebUtil demo, you will need to follow all of the steps in the readme that comes with the demo.  This is beyond the scope of this note.  The purposes of this note is only to ensure basic WebUtil functionality is working.

10.  Regenerate the webutil.pll and the WebUtil Demo Form (webutil_demo.fmb) using frmcmp.sh/bat or from the Forms Builder against the schema where you ran the create_webutil_db.sql script.
Description: To BottomNOTE:  Ensure that you have no other copies of the webutil.pll or webutil.plx in locations which are included in FORMS_PATH set in default.env (or your own custom env file).

11.  Run the webutil_demo form.   You will need to run it referencing the appropriate webutil configuration section. If you don't have it referenced in the webutil configuration section, then run it as follows:
From a standard browser: http://machine.domain:port/forms/frmservlet?config=webutil&form=webutil_demo
For WebStart: http://machine.domain:port/forms/frmservlet?config=webutil_webstart&form=webutil_demo
For JNLP: http://machine.domain:port/forms/frmservlet?config=webutil_jnlp&form=webutil_demo
For Forms Standalone Application Launcher: http://machine.domain:port/forms/frmservlet?config=webutil_standaloneapp&form=webutil_demo

12.  Basic functionality such as "Get Client Info" and "About Webutil" on the "About" tab should function with no errors.  When you exit the demo you should be redirected to ->

Forms OTN Product Page

You can easily verify your webutil configuration by downloading and running the Webutil Diagnostic Test Form from Note 553849.1
Beware of the following issues:
  • An issue that has been known to occur occasionally with jacob.jar -> "jacob/com/ComFailException.class HTTP/1.1 and HTTP 404 (File not Found) with Jacob.jar Note 1283729.1.
  • The application server file upload demo has a hard coded reference to the C:\temp file. See the following document for more details: Webutil_demo Form Failing for File Upload Action on New Server Note 2431019.1.

1 comment: