My Oracle Support Banner

Update of Shared Library and Re-deployment of Applications Which use it Giving HTTP-401 Unauthorized Error and Server Restart is Needed (Doc ID 1959270.1)

Last updated on FEBRUARY 20, 2019

Applies to:

Oracle WebCenter Portal - Version 11.1.1.8.4 and later
Information in this document applies to any platform.

Symptoms

After redeploying a new version of a shared library and its WebCenter Portal application, when accessing the application, an error is displayed.

Error 401--Unauthorized


The URL displayed is /<APPLICATION_NAME>-Portal-context-root/adfAuthentication?success_url=/faces/jsp/error404.jsp

After restarting the managed server, the application works again.

The requirement was to have minimal downtime while the shared library was being updated.  Restarting the managed server is not acceptable due to the long downtime.


Installation
Issue reproduces intermittently with the following scenario
- 11.1.1.8.4 WCP installation
- 10.3.6.0.8 WLS installation
- Policy & Credential store of the domain in Oracle Database
- Seems to reproduce more consistently when Domain is in PRODUCTION MODE


Steps to reproduce

Do initial deployment
==============
1. Deploy shared libraries sharedLib1war and sharedLib2war using Admin Console
2. Deploy parent_shared_lib.war which references sharedLib1war and sharedLib2war using Admin Console
3. Deploy TestApplication application which references parent_shared_lib.war using EM Console
4. Test access to TestApplication -- eg http://<HOSTNAME>:<PORT>/TestApplication-Portal-context-root
5. Login and logout - all is working fine.

Update the library
===========
6. Increase the parent_shared_lib.war library version by updating MANIFEST.MF within the .war and increasing Implementation-Version
eg change:
Implementation-Version: 11.1.21
to
Implementation-Version: 11.1.22
7. In the Admin Console - Deployments choose to 'Lock and Edit'
8. Select parent_shared_lib library and click 'Update'
9. Choose to also redeploy TestApplication application
10. Confirm that the version number is the new one
11. When completed, Activate changes

Test new version
===========
12. Go to http://<HOSTNAME>:<PORT>/TestApplication-Portal-context-root
    If the problem occurs it will redirect to http://<HOSTNAME>:<PORT>/TestApplication-Portal-context-root/adfAuthentication?success_url=/faces/jsp/error404.jsp
    If it works (the problem doesn't occur), it will redirect to http://<HOSTNAME>:<PORT>/TestApplication-Portal-context-root/faces/wcnav_defaultSelection

In both occasions the Admin Server log shows the deployment to be successful:

Working
####<Nov 6, 2014 11:00:30 AM GMT-00:00> <Info> <J2EE Deployment SPI> <> <AdminServer> <[ACTIVE] ExecuteThread: '7' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <ECID> <1415271630164> <BEA-260121> <Initiating redeploy operation for application, parent_shared_lib.webapp#11.1.1@11.1.21 [archive: /refresh/home/Desktop/parent_shared_lib.war], to WC_CustomPortal .> 

####<Nov 6, 2014 11:00:41 AM GMT-00:00> <Info> <J2EE Deployment SPI> <> <AdminServer> <[ACTIVE] ExecuteThread: '7' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <ECID> <1415271641124> <BEA-260121> <Initiating redeploy operation for application, TestApplication_application1 [archive: /<DOMAIN_HOME>/sysman/upload/deploy/TestApplication_application1/archive/TestApplication_application1.ear], to WC_CustomPortal .>
####<Nov 6, 2014 11:01:39 AM GMT-00:00> <Info> <Deployer> <> <AdminServer> <[ACTIVE] ExecuteThread: '10' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <ECID> <1415271699584> <BEA-149038> <Initiating Task for TestApplication_application1 : [Deployer:149026]deploy application TestApplication_application1 on WC_CustomPortal.>
####<Nov 6, 2014 11:01:39 AM GMT-00:00> <Info> <Deployer> <> <AdminServer> <[ACTIVE] ExecuteThread: '10' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <ECID> <1415271699594> <BEA-149038> <Initiating Task for parent_shared_lib.webapp [LibSpecVersion=11.1.1,LibImplVersion=11.1.22] : [Deployer:149117]deploy library parent_shared_lib.webapp [LibSpecVersion=11.1.1,LibImplVersion=11.1.22] on WC_CustomPortal.>

...then after activating changes
####<Nov 6, 2014 11:03:48 AM GMT-00:00> <Info> <Deployer> <> <AdminServer> <[ACTIVE] ExecuteThread: '12' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <ECID> <1415271828251> <BEA-149074> <Successfully completed deployment task: [Deployer:149117]deploy library parent_shared_lib.webapp [LibSpecVersion=11.1.1,LibImplVersion=11.1.22] on WC_CustomPortal.>
####<Nov 6, 2014 11:03:48 AM GMT-00:00> <Info> <Deployer> <HOSTNAME> <AdminServer> <[ACTIVE] ExecuteThread: '12' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <ECID> <1415271828251> <BEA-149074> <Successfully completed deployment task: [Deployer:149026]deploy application TestApplication_application1 on WC_CustomPortal.>


Not working
####<Nov 6, 2014 11:08:49 AM GMT-00:00> <Info> <J2EE Deployment SPI> <> <AdminServer> <[ACTIVE] ExecuteThread: '19' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <ECID> <1415272129039> <BEA-260121> <Initiating redeploy operation for application, parent_shared_lib.webapp#11.1.1@11.1.22 [archive: /refresh/home/Desktop/parent_shared_lib.war], to WC_CustomPortal .>
####<Nov 6, 2014 11:08:59 AM GMT-00:00> <Info> <J2EE Deployment SPI> <> <AdminServer> <[ACTIVE] ExecuteThread: '19' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <ECID> <1415272139148> <BEA-260121> <Initiating redeploy operation for application, TestApplication_application1 [archive: /<DOMAIN_HOME>/sysman/upload/deploy/TestApplication_application1/archive/TestApplication_application1.ear], to WC_CustomPortal .>
####<Nov 6, 2014 11:09:54 AM GMT-00:00> <Info> <Deployer> <> <AdminServer> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <ECID> <1415272194940> <BEA-149038> <Initiating Task for TestApplication_application1 : [Deployer:149026]deploy application TestApplication_application1 on WC_CustomPortal.> ####<Nov 6, 2014 11:09:54 AM GMT-00:00> <Info> <Deployer> <> <AdminServer> <[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <ECID> <1415272194941> <BEA-149038> <Initiating Task for parent_shared_lib.webapp [LibSpecVersion=11.1.1,LibImplVersion=11.1.23] : [Deployer:149117]deploy library parent_shared_lib.webapp [LibSpecVersion=11.1.1,LibImplVersion=11.1.23] on WC_CustomPortal.>

...then after activating changes
####<Nov 6, 2014 11:10:57 AM GMT-00:00> <Info> <Deployer> <> <AdminServer> <[ACTIVE] ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <ECID> <1415272257460> <BEA-149074> <Successfully completed deployment task: [Deployer:149117]deploy library parent_shared_lib.webapp [LibSpecVersion=11.1.1,LibImplVersion=11.1.23] on WC_CustomPortal.>
####<Nov 6, 2014 11:10:57 AM GMT-00:00> <Info> <Deployer> <> <AdminServer> <[ACTIVE] ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <ECID> <1415272257460> <BEA-149074> <Successfully completed deployment task: [Deployer:149026]deploy application TestApplication_application1 on WC_CustomPortal.>

 

The Custom Portal Managed Server access_log looks different when it fails.

Working
<IP ADD> - - [06/Nov/2014:10:55:11 +0000] "GET /TestApplication-Portal-context-root/ HTTP/1.1" 200 360
<IP ADD> - - [06/Nov/2014:10:55:11 +0000] "GET /TestApplication-Portal-context-root/faces/wcnav_defaultSelection HTTP/1.1" 200 8295
<IP ADD> - - [06/Nov/2014:10:55:12 +0000] "GET /TestApplication-Portal-context-root/faces/wcnav_defaultSelection;jsessionid=<JSESSIONID>?_afrLoop=65240697688899&_afrWindowMode=0&_afrWindowId=null HTTP/1.1" 200 20562
<IP ADD> - - [06/Nov/2014:10:55:14 +0000] "GET /TestApplication-Portal-context-root/afr/AdfTranslations-11.1.1.7.0-4127en.js?loc=en&skinId=portal.desktop HTTP/1.1" 200 38410
<IP ADD> - - [06/Nov/2014:10:55:14 +0000] "GET /TestApplication-Portal-context-root/afr/ss.gif HTTP/1.1" 200 14936
<IP ADD> - - [06/Nov/2014:10:55:14 +0000] "GET /TestApplication-Portal-context-root/adf/styles/cache/portal-desktop-6z8smb-en-ltr-ie-8.0-cmp.css HTTP/1.1" 200 226908
<IP ADD> - - [06/Nov/2014:10:55:14 +0000] "GET /TestApplication-Portal-context-root/adf/jsLibs/Locale1_2_12_3_3.js HTTP/1.1" 200 11772
<IP ADD> - - [06/Nov/2014:10:55:14 +0000] "GET /TestApplication-Portal-context-root/afr/partition/ie/n/default/opt/boot-11.1.1.7.0-4127.js HTTP/1.1" 200 305481
<IP ADD> - - [06/Nov/2014:10:55:14 +0000] "GET /TestApplication-Portal-context-root/afr/partition/ie/n/default/opt/core-11.1.1.7.0-4127.js HTTP/1.1" 200 420395
<IP ADD> - - [06/Nov/2014:10:55:15 +0000] "GET /TestApplication-Portal-context-root/adf/styles/cache/portal-desktop-6z8smb-en-ltr-ie-8.0-cmp2.css HTTP/1.1" 200 206537

Non working
<IP ADD> - - [06/Nov/2014:11:11:06 +0000] "GET /TestApplication-Portal-context-root/faces/wcnav_defaultSelection HTTP/1.1" 200 8145
<IP ADD> - - [06/Nov/2014:11:11:07 +0000] "GET /TestApplication-Portal-context-root/faces/wcnav_defaultSelection?_afrLoop=66195464911699&_afrWindowMode=0&_afrWindowId=<AFRWINDOWID> HTTP/1.1" 302 453
<IP ADD> - - [06/Nov/2014:11:11:39 +0000] "GET /TestApplication-Portal-context-root/adfAuthentication?success_url=/faces/jsp/error404.jsp HTTP/1.1" 401 1468


Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Cause
Solution
References


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.