Sunday, September 14, 2014

Installation of CF03 on Portal 8.0 may fail with exception

When trying to install CF03 on Portal 8.0, Installation fails with below error:

opt/IBM/Rendering/PortalServer/installer/wp.config/config/includes/wp_cluster_cfg.xml:1436: Detected single app deployment time greater than 5 minutes.

Check the \wp_profile\ConfigEngine\log\ConfigTrace.log log file for the following error:-
/opt/IBM/Rendering/PortalServer/installer/wp.config/config/includes/wp_cluster_cfg.xml:1436: Detected single app deployment time greater than 5 minutes at  com.ibm.wplc.deploy.tasks.impl.ClusterWaitForSyncToCompleteImpl.execute(ClusterWaitForSyncToCompleteImpl.java:289) at  com.ibm.wplc.deploy.tasks.AbstractBaseAdminTask.executeBean(AbstractBaseAdminTask.java:541) at com.ibm.wplc.deploy.tasks.AbstractBaseAdminTask.executeTask(AbstractBaseAdminTask.java:525)  at com.ibm.wplc.deploy.tasks.AbstractBaseWsAdminWrapperTask.executeTask(Abs
tractBaseWsAdminWrapperTask.java:376)

In addition to that you will see error like below:
[wplc-wait-for-sync-to-complete] Distribution of AJAX Proxy Configuration not complete.
[wplc-wait-for-sync-to-complete] Distribution of Dojo_Resources not complete.

Workaround 1:

1. Try to increase maxAppTimeToWait="5" to 15 min. in wp_cluster_cfg.xml and run the installation again.
If doesn't work and you notice that wp_cluster_cfg.xml parameter revert back to lower value, then try the workaround below:

Workaround 2:

1. Edit the PortalServer/wps.properties file and remove the lines for:
ProfileName
ProfileDirectory

Do not just comment them out; remove them completely.

2. Install CF03. It should go through successfully this time. It will NOT update the profile so it should skip the failing script.
3. Make the same timeout changes to wp_cluster_cfg.xml again.
4. Add ProfileName and ProfileDirectory back to wps.properties.
5. Execute this ConfigEngine script to update the profile:
./ConfigEngine.sh CONFIG-WP-PTF-CF -DWasPassword= -DPortalAdminPwd=

If doesn't work, continue to next step.

Workaround 3:

1 Edit the Installation Manager configuration file, found at /opt/IBM/InstallationManager/eclipse/configuration/config.ini
2. Add the following line to this file: WP_UPDATE_SKIP_CONFIG=true
3. Save the file and run the portal installation again. You will need to run ./ConfigEngine.sh CONFIG-WP-PTF-CF -DWasPassword= -DPortalAdminPwd= to finish update.

Technote reference : http://www-01.ibm.com/support/docview.wss?uid=swg21622946


Friday, August 8, 2014

EJPSG0002E: Requested Member does not exist

You receive the following error message in the WebSphere Portal log: EJPSG0002E: Requested Member does not exist. uid=wpsadmin,o=defaultWIMFileBasedRealm/nullcauses initialization failures for portal server startup.

SystemOut.log says :

PortalCollect E com.ibm.hrl.portlets.WsPse.PortalCollectionsService PortalCollectionsService EJPJO0119E: Failed to initialize portal collections services.
java.lang.NoClassDefFoundError: com.ibm.wps.ac.impl.AccessControlDataManagement (initialization failure)
...
Caused by: java.lang.RuntimeException: Exception while loading dynamically re-ordered service class com.ibm.wps.ac.impl.AccessControlDataManagementService
...
Caused by: com.ibm.wps.ac.DomainAdministratorNotFoundException: EJPSB0107E: Exception occurred while retrieving the identity of the domain admin user/admingroup uid=wpsadmin,o=defaultWIMFileBasedRealm.
...
Caused by: com.ibm.portal.puma.MemberNotFoundException: EJPSG0002E: Requested Member does not exist.uid=wpsadmin,o=defaultWIMFileBasedRealm
...
Caused by: com.ibm.wps.um.exceptions.impl.MemberNotFoundExceptionImpl: com.ibm.portal.puma.MemberNotFoundException: EJPSG0002E: Requested Member does not exist.uid=wpsadmin,o=defaultWIMFileBasedRealm/null
...
Caused by: com.ibm.portal.puma.MemberNotFoundException: EJPSG0002E: Requested Member does not exist.uid=wpsadmin,o=defaultWIMFileBasedRealm/null
...

Accessing the Portal from a browser returns the following error:

404: Initialization of one or more services failed

Environment

Any Portal 6.1, 7.0 or 8.0 environment
Resolving the problem

Change the administrative user and group by running the ConfigEngine task wp-change-portal-admin-user. Specify an administrative user and group that exist in the repository.

Only if the ConfigEngine task fails and you need a manual work-around that enables WebSphere Portal to start:
Update all AdminUser and AdminGroup properties for the Access Control Data Management Service with the appropriate administrative user and group from the LDAP. 

Technote : 

http://www-01.ibm.com/support/docview.wss?uid=swg21366141





SECJ0371W: Validation of the LTPA token failed

WebSphere Portal received a request with an expired or otherwise invalid LTPA token for which it needed to generate one or more URLs. By default, the LTPA token timeout is two hours. This timeout is encoded into the token itself. With the default settings, this condition could occur if someone logged in and worked in WebSphere Portal for longer than two hours.

Check your SystemOut.log for :

at com.ibm.wps.util.HttpUtils.validateLTPATokenCookies(HttpUtils.java:458)
at com.ibm.wps.auth.extensions.impl.ExtendedAuthenticationServiceImpl.isUserLoggedIn(ExtendedAuthenticationServiceImpl.java:136)
at com.ibm.wps.state.accessors.url.EngineURLOnRequest.isProtected(EngineURLOnRequest.java:371)
at com.ibm.wps.state.accessors.url.EngineURLOnRequest.reset(EngineURLOnRequest.java:450)
atcom.ibm.wps.state.accessors.url.URLAccessorFactoryExImpl.newURL(URLAccessorFactoryExImpl.java:319)

Such stack traces indicate that WebSphere Portal explicitly requests LTPA token validation from WebSphere Application Server during URL generation. This is by design.


You may either ignore the warning or suppress them. To suppress such warnings, set:

com.ibm.ws.security.ltpa.LTPAServerObject=severe

per the WebSphere Application Server InfoCenter section on Log level settings.


Monday, August 4, 2014

Scheduler Error Messages upon Portal Startup

Problem

Upon the portal startup, the following error message can be found in the log:

[...] 0000006a AlarmListener E SCHD0063E: A task with ID 451 failed to run on Scheduler WPSTaskScheduler (wps/Scheduler) because of an exception:
java.rmi.RemoteException: CORBA INTERNAL 0x4942f58c No;
nested exception is as follows:
org.omg.CORBA.INTERNAL: initial and forwarded IOR inaccessible vmcid: IBM minor code: 58C completed: No.

Symptom

The scheduler does not run.

Cause

One known cause is that a WAS upgrade was done. WAS cannot migrate schedulers, therefore this part of the migration needs to be done by the application - in this case the portal.
Note: There can be other causes and other scheduler related error messages that require the scheduler to be recreated.


Diagnosing the problem

Check the logs.

Resolving the problem


Remove and recreate the scheduler by using the following config tasks:

WebSphere Portal V 6.1 and later:
  1. Remove the scheduler by running the following task:
    ConfigEngine remove-scheduler

  2. Recreate the scheduler by running the following task:
    ConfigEngine create-scheduler

     
  3. Modify the settings by running the following task:
    ConfigEngine create-scheduler-custom-property


WebSphere Portal V 6.0 and later:
  1. Remove the scheduler by running the following task:
    WPSConfig action-remove-scheduler-cleanup-daemon

  2. Recreate the scheulder by running the following task:
    WPSConfig action-create-scheduler-cleanup-daemon

  3. Modify the settings by using the following tasks:
    WPSConfig action-modify-scheduler-base-properties-cleanup-daemon
    WPSConfig action-modify-scheduler-custom-properties-cleanup-daemon


WebSphere Portal V 5.1 and later:
  1. Remove the scheduler by running the following task:
    WPSConfig action-remove-scheduler-cleanup-daemon

  2. Recreate the scheulder by running the following task:
    WPSConfig action-create-scheduler-cleanup-daemon

  3. Modify the settings by running the following task:
    WPSConfig action-modify-scheduler-cleanup-daemon-jndi-wps-ds

If these tasks do not help, you need to remove the schedules with this command:

WebSphere Portal V 5.1, V 6.0 and later:
   WPSConfig action-clean-scheduled-tasks

WebSphere Portal V 6.1 and later:
   ConfigEngine action-clean-scheduled-tasks

After you have done this, restart the server. Upon restart, the server will re-insert the default schedule. If you modified the default scheduled task, recreate your schedules by using the XML configuration interface.

Note: In a cluster you need to do this only on the primary node.   

Source : https://www-304.ibm.com/support/docview.wss?uid=swg21289958



Tuesday, July 8, 2014

THE DEFAULT SETTINGS FOR JVM HEAP SIZE MAY NOT BE ADEQUATE FOR LARGE ENVIRONMENTS

By default, we set the Maximum Heap size to 1024.

This may cause a problem with memory available to WAS:

Exceptions visible in the logs:

2012/05/30 11:30:47:545 CAT] 00000016 TimerImpl     E ASYN0012E:  Alarm/Timer threw exception commonj.work.WorkCompletedException: java.lang.RuntimeException: java.lang.OutOfMemoryError
Caused by: java.lang.OutOfMemoryError  at java.lang.String.(String.java:365) at com.ibm.license.mgmt.dao.ProductReplacementDAO$ReplacingBranchVO.depure(Unknown Source)  at com.ibm.license.mgmt.dao.ProductReplacementDAO$ReplacingBranchVO.(Unknown Source)  at com.ibm.license.mgmt.dao.ProductReplacementDAO.getBranch(Unknown Source)

This may happen during aggregation, catalog import,recalculation.

Local fix
a) increase the WebSphere JVM memory, by navigating  from Tivoli
Integrated Portal to  > Settings > WebSphere Administrative Console > Launch console

 > In the WebSphere web console, select Servers -> Server Types

WebSphere application servers -> Server Infrastructure -> Java and Process Management -> Process definition

 > In Additional Properties section, select Java Virtual Machine

 > In General Properties section, increase the values for "Initial heap size" and for "Maximum heap size".

b) restart the server

In some cases reverting aggregation process may be necessary.

source : http://www-01.ibm.com/support/docview.wss?uid=swg1IV22047


Tuesday, February 18, 2014

Step-by-step Migration Guide for IBM WebSphere Portal version 8 from 61x

Whether you are migrating an IBM® WebSphere® Portal or Workplace Web Content Management™ 6.1.x server to version 8, these guides are designed to aid you through the process.

Content

The paper describes the steps and best practices for migrating an existing standalone WebSphere Portal 6.1.x environment to a standalone WebSphere Portal V8 and should be followed by the majority of customers, even those in a Web Content Management environment.
The foundation for this document is the initial release of the V8 Information Center with additional information based on the outcome and experiences of our pre-release testing. With this document, we provide a more comprehensive guide and highlight some of the common pitfalls and mistakes when migrating.

*Special note - if you are using this guide on an operating system that is different than the example documented, some allowances must be made to convert commands and screens shown to your environment. This might include changing executable script commands from batch files (.bat) to shell scripts (.sh) or vice versa, or when using command-line utilities in place of graphical interfaces that might be shown.

Friday, December 13, 2013

PROPFIND is not defined in RFC 2068

Problem(Abstract)

Receiving the message PROPFIND is not defined in RFC 2068 in the maximo logs

Symptom

The Maximo log files show the following message.
[Servlet Error]-[webclient]: com.ibm.ws.webcontainer.webapp.
WebAppErrorReport: Method PROPFIND is not defined in RFC 2068 and is
not supported by the Servlet API


Resolving the problem

This error can be resolved by adding the PROPFIND module and disabling it in the httpd.conf.

The file is located in the IBM\HTTPServer\conf folder

1) Add the following to the bottom of the file

# disable PROPFIND
LoadModule rewrite_module modules/mod_rewrite.so
RewriteEngine On
RewriteCond %{REQUEST_METHOD} ^PROPFIND
RewriteRule .* - [F]

2) Restart the IBM HTTP Server service.

source : http://www-01.ibm.com/support/docview.wss?uid=swg21641024

Wednesday, November 27, 2013

How to generate a thread dump and heap dump in WebSphere 7 on UNIX/LINUX/AIX

So you want to manually invoke a heapdump?
  1. SSH/Telnet to the box.
  2. Get to your WebSphere 7 AppServer/bin directory, e.g. /opt/Was7/AppServer/bin.
  3. Run ./wsadmin.sh -profileName myProfileName -user wasadmin -password adminpassword (substitute your WAS profile name, user and password of course).
  4. This will give you a prompt where you can enter commands.
  5. First, we set a substitution variable with the full name of the object representing our app server:
    set jvm [$AdminControl completeObjectName type=JVM,process=MyServerName,*]
  6. Next, we can invoke the dumpThreads and/or generateHeapDump methods of that object:
    $AdminControl invoke $jvm dumpThreads
    $AdminControl invoke $jvm generateHeapDump

  7. By default, the commands above will place the dump files in the root directory for your application profile, e.g. /opt/Was70/AppServer/profiles/myAppProfile.
And you are done :-)

Thursday, November 21, 2013

Portal v7002 fixpack installation fails with "Target `check-portal-level-CF' does not exist in this project

When installing the Portal v7002 fixpack on a binary Portal installation after installing any cumulative fix, the 7002 fixpack installation may fail with "Target `check-portal-level-CF' does not exist in this
project"

Symptom
In the console output at the time of the failure, you see the following exception:
=============================
Result: StdErr: BUILD FAILED
Result: StdErr: Target `check-portal-level-CF' does not exist in this project. It is used from target `action-validate-portal-version-for-multProfile-CF'.
Result: StdErr:
Result: StdErr: Total time: 4 seconds
Log: ExecCmd::launch returns 1
Task 2 out of 630; End Uninstalling fix ' PM49013', component 'wp.ptf.config'.
Task 3 out of 630; Begin Completing fix ' PM49013' subTmpDir to be cleaned up: /tmp/ptfs
The directory does not exist, or is not a directory, continue to run: /tmp/ptfs
Fix pack installation has failed. Consult
/usr/WebSphere7/PortalServer/version/log/20120217_085936_PM49013_uninsta
ll.log for error details.
chmod -R 550 /usr/WebSphere7/PortalServer done!
UpdateInstaller.puiReturnCode is 9
End of [ ./updatePortal.sh ]
=============================

A similar error can be seen in the ConfigTrace.log as well.

Cause

This issue occurs when the user has done the following:
- Installed Portal as a binary installation
- Upgraded Portal to v7001 + any CF
- Created a profile (or migrated)
- Updated the wps.properties with the new profile information
- Attempted to upgrade to v7002
The first step for any fixpack installation is to remove all fixes and cumulative fixes. The CF uninstall fails in this case and that is why the fixpack fails.
The CF uninstall fails because of a defect in the Portal Update Installer that prevents any fix or CF from uninstalling cleanly when it was originally installed on a binary install. This will be fixed in a later version of the Portal Update Installer.

Resolving the problem

If you encounter this exception, you must take the following steps to resolve it:

1. Edit the PortalServer/wps.properties file
2. Remove the ProfileName and ProfilePath parameters from it.
3. Manually uninstall the cumulative fix(es) you have applied
4. If the following file still exists after the CF uninstall, manually remove it:

PortalServer/installer/wp.config/config/includes/preconfig_cumulative_fix.xml

5. Edit the PortalServer/wps.properties file again and add ProfileName and ProfilePath back to the file.
6. Reattempt the 7002 fixpack installation.

Source :  http://www-01.ibm.com/support/docview.wss?uid=swg21585265


Wednesday, November 20, 2013

Creating the WebSphere Portal 7 databases

Creating DB2 database

A remote database resides on a different system than Web Sphere Portal. When you use a remote server, you must manually create the databases that are required by Web Sphere Portal.

Before creating these databases, note the following information:
    o If the DB2 JDBC type 4 driver is used, only the instructions on the remote server are required. You do not need to install the DB2 client software, and you do not need to complete the steps related to the DB2 client.
    o The client software, DB2 Connect, must be correctly configured to connect to the remote DB2 server instance, for example, db2inst1.
These instructions assume that a remote DB2 server and DB2 Connect are already installed and running. For information on installing DB2 Connect, see the DB2 product documentation.
These instructions assume that you are using DB2 Connect to connect to a remote DB2 server, and that WebSphere Application Server, WebSphere Portal, and DB2 Connect are installed on the same system


1. Log in to the DB2 server system as a user with sufficient database privileges.
       $ db2inst1/password (A common user name is db2inst1)

2. Ensure that the user database has been created, granted appropriate privileges, and has a password assigned to it.
    If  the user has not been created, refer to the Creating users topic for information on how to create users.

3. Initialize a DB2 command environment by opening a command prompt and typing su - db2inst1

4. Run the following commands on the DB2 server system to configure the DB2 database instance:    
      DB2 Version 9
db2set DB2_RR_TO_RS=YES
db2set DB2_EVALUNCOMMITTED=YES                                                                                                                                                                                                                                                                                                                                                     
db2set DB2_INLIST_TO_NLJN=YES
db2 "UPDATE DBM CFG USING query_heap_sz 32768"
db2 "UPDATE DBM CFG USING maxagents 500"        
db2 "UPDATE DBM CFG USING sheapthres 50000"

5. Run the following commands on the DB2 server system to create the necessary databases:
 Notes:
          * Replace dbname with the actual name of the database. Run the commands and each time replace dbname with the actual values for release, community, customization, Java Content Repository, Feedback, and Likeminds.
            Remember: DB2 database names cannot exceed eight characters. Therefore, consider using these database names: release, commun, custom, jcrdb, fdbkdb, and lmdb.

               I.      create release db:

db2 "CREATE DB release using codeset UTF-8 territory us PAGESIZE 8192"
db2 "UPDATE DB CFG FOR release USING applheapsz 4096"
db2 "UPDATE DB CFG FOR release USING app_ctl_heap_sz 1024"
db2 "UPDATE DB CFG FOR release USING stmtheap 32768"
db2 "UPDATE DB CFG FOR release USING dbheap 2400"
db2 "UPDATE DB CFG FOR release USING locklist 1000"
db2 "UPDATE DB CFG FOR release USING logfilsiz 4000"
db2 "UPDATE DB CFG FOR release USING logprimary 12"
db2 "UPDATE DB CFG FOR release USING logsecond 20"
db2 "UPDATE DB CFG FOR release USING logbufsz 32"
db2 "UPDATE DB CFG FOR release USING avg_appls 5"
db2 "UPDATE DB CFG FOR release USING locktimeout 30"
db2 "UPDATE DB CFG FOR release using AUTO_MAINT off"

             II.      create community db

db2 "CREATE DB commun using codeset UTF-8 territory us PAGESIZE 8192"
db2 "UPDATE DB CFG FOR commun USING applheapsz 4096"
db2 "UPDATE DB CFG FOR commun USING app_ctl_heap_sz 1024"
db2 "UPDATE DB CFG FOR commun USING stmtheap 32768"
db2 "UPDATE DB CFG FOR commun USING dbheap 2400"
db2 "UPDATE DB CFG FOR commun USING locklist 1000"
db2 "UPDATE DB CFG FOR commun USING logfilsiz 4000"
db2 "UPDATE DB CFG FOR commun USING logprimary 12"
db2 "UPDATE DB CFG FOR commun USING logsecond 20"
db2 "UPDATE DB CFG FOR commun USING logbufsz 32"
db2 "UPDATE DB CFG FOR commun USING avg_appls 5"
db2 "UPDATE DB CFG FOR commun USING locktimeout 30"
db2 "UPDATE DB CFG FOR commun using AUTO_MAINT off"

           III.      creating customization db

db2 "CREATE DB custom using codeset UTF-8 territory us PAGESIZE 8192"
db2 "UPDATE DB CFG FOR custom USING applheapsz 4096"
db2 "UPDATE DB CFG FOR custom USING app_ctl_heap_sz 1024"
db2 "UPDATE DB CFG FOR custom USING stmtheap 32768"
db2 "UPDATE DB CFG FOR custom USING dbheap 2400"
db2 "UPDATE DB CFG FOR custom USING locklist 1000"
db2 "UPDATE DB CFG FOR custom USING logfilsiz 4000"
db2 "UPDATE DB CFG FOR custom USING logprimary 12"
db2 "UPDATE DB CFG FOR custom USING logsecond 20"
db2 "UPDATE DB CFG FOR custom USING logbufsz 32"
db2 "UPDATE DB CFG FOR custom USING avg_appls 5"
db2 "UPDATE DB CFG FOR custom USING locktimeout 30"
db2 "UPDATE DB CFG FOR custom using AUTO_MAINT off"

          IV.      creating jcrdb db

db2 "CREATE DB jcrdb using codeset UTF-8 territory us PAGESIZE 8192"
db2 "UPDATE DB CFG FOR jcrdb USING applheapsz 4096"
db2 "UPDATE DB CFG FOR jcrdb USING app_ctl_heap_sz 1024"
db2 "UPDATE DB CFG FOR jcrdb USING stmtheap 32768"
db2 "UPDATE DB CFG FOR jcrdb USING dbheap 2400"
db2 "UPDATE DB CFG FOR jcrdb USING locklist 1000"
db2 "UPDATE DB CFG FOR jcrdb USING logfilsiz 4000"
db2 "UPDATE DB CFG FOR jcrdb USING logprimary 12"
db2 "UPDATE DB CFG FOR jcrdb USING logsecond 20"
db2 "UPDATE DB CFG FOR jcrdb USING logbufsz 32"
db2 "UPDATE DB CFG FOR jcrdb USING avg_appls 5"
db2 "UPDATE DB CFG FOR jcrdb USING locktimeout 30"

 V.      creating fdbkdb db
                                                                                                     
db2 "UPDATE DB CFG FOR jcrdb using AUTO_MAINT off"

db2 "CREATE DB fdbkdb using codeset UTF-8 territory us PAGESIZE 8192"  
 db2 "UPDATE DB CFG FOR fdbkdb USING applheapsz 4096"
db2 "UPDATE DB CFG FOR fdbkdb USING app_ctl_heap_sz 1024"
db2 "UPDATE DB CFG FOR fdbkdb USING stmtheap 32768"
db2 "UPDATE DB CFG FOR fdbkdb USING dbheap 2400"
db2 "UPDATE DB CFG FOR fdbkdb USING locklist 1000"
db2 "UPDATE DB CFG FOR fdbkdb USING logfilsiz 4000"
db2 "UPDATE DB CFG FOR fdbkdb USING logprimary 12"
db2 "UPDATE DB CFG FOR fdbkdb USING logsecond 20"
db2 "UPDATE DB CFG FOR fdbkdb USING logbufsz 32"
db2 "UPDATE DB CFG FOR fdbkdb USING avg_appls 5"
db2 "UPDATE DB CFG FOR fdbkdb USING locktimeout 30"
db2 "UPDATE DB CFG FOR fdbkdb using AUTO_MAINT off"

          VI.      creating lmdb db

db2 "CREATE DB lmdb using codeset UTF-8 territory us PAGESIZE 8192"
db2 "UPDATE DB CFG FOR lmdb USING applheapsz 4096"
db2 "UPDATE DB CFG FOR lmdb USING app_ctl_heap_sz 1024"
db2 "UPDATE DB CFG FOR lmdb USING stmtheap 32768"
db2 "UPDATE DB CFG FOR lmdb USING dbheap 2400"
db2 "UPDATE DB CFG FOR lmdb USING locklist 1000"
db2 "UPDATE DB CFG FOR lmdb USING logfilsiz 4000"
db2 "UPDATE DB CFG FOR lmdb USING logprimary 12"
db2 "UPDATE DB CFG FOR lmdb USING logsecond 20"
db2 "UPDATE DB CFG FOR lmdb USING logbufsz 32"
db2 "UPDATE DB CFG FOR lmdb USING avg_appls 5"
db2 "UPDATE DB CFG FOR lmdb USING locktimeout 30"
db2 "UPDATE DB CFG FOR lmdb using AUTO_MAINT off"

6. Complete the following:

          On the DB2 server system, run the following commands. This step is only required for the IBM Java Content     
          Repository database (jcrdb).
                * jcrdb is the name of the database used to store user data and objects
                * jcr is the database user for jcrdb
                  Note: This value can be replaced with any ID that has administrative authority.
                * dbpassword is the password for jcrdb

db2 "CONNECT TO jcrdb USER db2inst1 USING password"
db2 "CREATE BUFFERPOOL ICMLSFREQBP4 SIZE 1000 PAGESIZE 4 K"
db2 "CREATE BUFFERPOOL ICMLSVOLATILEBP4 SIZE 8000 PAGESIZE 4 K"
db2 "CREATE BUFFERPOOL ICMLSMAINBP32 SIZE 8000 PAGESIZE 32 K"
db2 "CREATE BUFFERPOOL CMBMAIN4 SIZE 1000 PAGESIZE 4 K"
db2 "CREATE REGULAR TABLESPACE ICMLFQ32 PAGESIZE 32 K MANAGED BY SYSTEM USING ('ICMLFQ32') BUFFERPOOL ICMLSMAINBP32"
db2 "CREATE REGULAR TABLESPACE ICMLNF32 PAGESIZE 32 K MANAGED BY SYSTEM USING ('ICMLNF32') BUFFERPOOL ICMLSMAINBP32"                                                    
db2 "CREATE REGULAR TABLESPACE ICMVFQ04 PAGESIZE 4 K MANAGED BY SYSTEM USING ('ICMVFQ04') BUFFERPOOL ICMLSVOLATILEBP4"
db2 "CREATE REGULAR TABLESPACE ICMSFQ04 PAGESIZE 4 K MANAGED BY SYSTEM USING ('ICMSFQ04') BUFFERPOOL ICMLSFREQBP4"
db2 "CREATE REGULAR TABLESPACE CMBINV04 PAGESIZE 4 K MANAGED BY SYSTEM USING ('CMBINV04') BUFFERPOOL CMBMAIN4"
db2 "CREATE SYSTEM TEMPORARY TABLESPACE ICMLSSYSTSPACE32 PAGESIZE 32 K MANAGED BY SYSTEM USING ('icmlssystspace32') BUFFERPOOL ICMLSMAINBP32"
db2 "CREATE SYSTEM TEMPORARY TABLESPACE ICMLSSYSTSPACE4 PAGESIZE 4 K MANAGED BY SYSTEM USING ('icmlssystspace4') BUFFERPOOL ICMLSVOLATILEBP4"

db2 "DISCONNECT jcrdb"
db2 "TERMINATE"

7. On the DB2 server system, check the services file. If it does not specify DB2 connection and interrupt service ports,
     specify the ports for your operating system:
    Use a text editor to open the file vi /etc/services and add the following text (where db2inst1 is the name of the DB2    
     instance ID on the system):
    (Shift G -- end of line in vi editor)

db2c_db2inst1 50000/tcp # DB2 connection service port
db2i_db2inst1 50001/tcp # DB2 interrupt service port


8. On the DB2 server system, set DB2COMM to TCP/IP by using the db2set command:

     db2set DB2COMM=TCPIP

9. Set up the correct service name by entering the following command on the DB2 server system:

db2 "UPDATE DBM CFG USING svcename db2c_db2inst1"


where svce_name is the connection service port name that is specified above.
DB2 Migration


In addition, the database administrator user “db2inst1” will be used as the user ID for each database.

For Cluster :All of the steps in this section will be done from the primary Portal node.
                                                                             
1. Stop the WebSphere_Portal and server1 by executing the following commands from the command window in the   
    /bin directory:

         stopServer.bat WebSphere_Portal -user -password 
         stopServer.bat server1 -user -password   pwd>

2. Ensure the database Enterprise Edition is installed and configured on the node.
    Since we are using Type 4 Drivers for DB2, all that is needed is to copy the db2jcc.jar and db2jcc_license_cu.jar   
    files from the DB2 server (/opt/ibm/db2/V9.7/java)to some directory on the primary Portal server.

3. From the /ConfigEngine/properties directory, make a backup of the following files:
wkplc.properties
wkplc_dbtype.properties
wkplc_dbdomin.properties

4. Edit the wkplc_dbtype.properties file and make the following changes:
    copy jars from db2 server to portal and give the path here:
             db2.DbDriver=com.ibm.db2.jcc.DB2Driver
             db2.DbLibrary=C:/IBM/db2drivers/db2jcc.jar;C:/IBM/db2drivers/db2jcc_license_cu.jar
             db2.JdbcProviderName=wpdbJDBC_db2

NOTE: The entry for db2.DbLibrary is an example only. Please ensure this is a valid path on your system.For Windows the separator is ; and Unix its : (e.g /opt/db2jars/db2jcc4.jar:/opt/db2jars/db2jcc_license_cu.jar)

5. Edit the wkplc_comp.properties file and make the following changes: ( Use wkplc_dbdomain.properties in Portal 7.0    
    instead wkplc_comp)

feedback.DbType=db2
feedback.DbName=fdbkdb    
feedback.DbSchema=FEEDBACK
feedback.DataSourceName=wpdbDS_fdbk
feedback.DbUrl=jdbc:db2://mydbserver.ibm.com:50000/fdbkdb:returnAlias=0;
feedback.DbUser=db2inst1
feedback.DbPassword=password
feedback.DBA.DbUser=db2inst1
feedback.DBA.DbPassword=password

likeminds.DbType=db2
likeminds.DbName=lmdb
likeminds.DbSchema=likeminds
likeminds.DataSourceName=wpdbDS_lmdb
likeminds.DbUrl=jdbc:db2://mydbserver.ibm.com:50000/lmdb:returnAlias=0;   
likeminds.DbUser=db2inst1
likeminds.DbPassword=password
likeminds.DBA.DbUser=db2inst1
likeminds.DBA.DbPassword=password

release.DbType=db2
release.DbName= release
release.DbSchema=release
release.DataSourceName=wpdbDS_release
release.DbUrl=jdbc:db2://mydbserver.ibm.com:50000/release:returnAlias=0;
release.DbUser=db2inst1
release.DbPassword=password
release.DBA.DbUser=db2inst1
release.DBA.DbPassword=password

community.DbType=db2
community.DbName=commun
community.DbSchema=community
community.DataSourceName=wpdbDS_commun
community.DbUrl=jdbc:db2://mydbserver.ibm.com:50000/commun:returnAlias=0;
community.DbUser=db2inst1
community.DbPassword=password
community.DBA.DbUser=db2inst1
community.DBA.DbPassword=password


customization.DbType=db2
customization.DbName=custom
customization.DbSchema=customization
customization.DataSourceName=wpdbDS_custom
customization.DbUrl=jdbc:db2://mydbserver.ibm.com:50000/custom:returnAlias=0;
customization.DbUser=db2inst1
customization.DbPassword=password
customization.DBA.DbUser=db2inst1
customization.DBA.DbPassword=password

jcr.DbType=db2
jcr.DbName=jcrdb
jcr.DbSchema=jcr
jcr.DataSourceName=wpdbDS_jcrdb
jcr.DbUrl=jdbc:db2://mydbserver.ibm.com:50000/jcrdb:returnAlias=0;
jcr.DbUser=db2inst1
jcr.DbPassword=password
jcr.DBA.DbUser=db2inst1
jcr.DBA.DbPassword=password


Update the following property in the file wkplc.properties.

 For WasPassword, type the password for the WebSphere Application Server security authentication used in your  
 environment.

PortalAdminPwd=password
WasPassword=password

6. From a command window, change directories to /ConfigEngine

7. Execute the following ConfigEngine scripts to validate the database properties:
ConfigEngine.bat validate-database-driver
ConfigEngine.bat validate-database-connection

8. Execute the following ConfigEngine script to transfer the database from Derby to DB2:

ConfigEngine.bat database-transfer -DPortalAdminPwd= -DWasPassword=

9.Restart all servers and check the logs. (server1 and WebSphere_Portal)


source : http://www-10.lotus.com/ldd/portalwiki.nsf/dx/ConfigureWeb_Sphere_Portal_to_use_DB2

Monday, November 18, 2013

Step by Step Instructions for Configuring WebSphere Portal with Oracle

This article shows you how to transfer from default database to Oracle database in WebSphere Portal 6.1.

The article explains the various steps that are required to completely configure the WebSphere Portal to Oracle. These instructions can be used to perform the database transfer process for a stand-alone WebSphere Portal instance or can also be applied for a Clustered environment.

In WebSphere Portal 6.1, the Portal databases can be configured to DB2, Oracle or SQL Server. The portal databases can be configured to a local database server installed on the same machine or databases can be distributed to multiple database servers, located on the multiple remote database machines. This document explains how to configure the WebSphere Portal with Oracle database.

Assumptions:
WebSphere Portal 6.1 installed on a machine
Oracle 10g Server is running on a separate machine.

Steps:
  1. The Oracle databases must be created manually before configuring WebSphere Portal. Make sure that all databases to be used with WebSphere Portal are created as UNICODE character set such as UTF8, AL32UTF8, or AL16UTF16.
In this scenario, I am considering creating 6 different oracle databases that will be used by WebSphere Portal. However multiple domains can share a single database, depending on your environment.

Domain                        Database

                      
Release                        RELDB
Community                   COMDB
Customization               CUSDB
Likeminds                     LMDB
Feedback                     FDBKDB
Jcr                                JCRDB

  1. Make sure that the created databases are configured with the following values; the values for all databases will remain same except JCRDB that should have a value for open_cursors as 2500.

        db_block_size = 8192
        db_cache_size = 300M
        db_files = 1024
      & nbsp; log_buffer = 65536
        open_cursors = 1500  (2500 for JCR database)
        pga_aggregate_target = 200M
        pre_page_sga = true
        processes = 300
        shared_pool_size = 200M

  1. If you are using remote Oracle databases, you must also copy the ojdbc14.jar file from the remote Oracle server to the WebSphere Portal/jdbc/lib
    machine. For example, the location of the jar file on the Portal machine can be C:/IBM/WebSphere/PortalServer/drivers

  1. The database users should be created with certain privileges so that these users can access the Oracle databases used by WebSphere Portal.
        
create user release identified by passw0rd default tablespace ts_release temporary tablespace ts_release;
grant connect, resource to release;

create user community identified by passw0rd default tablespace ts_community temporary tablespace ts_community;
grant connect, resource to community;

create user customization identified by passw0rd default tablespace ts_customization temporary tablespace ts_customization;
grant connect, resource to customization;

create user feedback identified by passw0rd default tablespace ts_feedback temporary tablespace ts_feedback;
grant connect, resource, create session to feedback;

create user likeminds identified by passw0rd default tablespace ts_likeminds temporary tablespace ts_likeminds;
grant connect, resource, create session to likeminds;

create user jcr identified by passw0rd default tablespace ts_jcr temporary tablespace ts_jcr;
grant connect, reso urce, create session, alter session, create table, create view, create trigger, create library, execute any procedure, create sequence, insert any table to jcr;

create user wsadmin identified by passw0rd default tablespace ts_wsadmin temporary tablespace ts_wsadmin;
grant dba to feedback;


  1. Use a text editor to open the properties file wp_profile_root/ConfigEngine/properties/wkplc_comp.properties and modify the values to correspond to your environment.

feedback.DbType=oracle
feedback.DbName=FDBKDB
feedback.DbSchema=feedback
feedback.DataSourceName=wpfdbkDS
feedback.DbUrl=jdbc:oracle:thin:@oracle.test.ibm.com:1521:FDBKDB
feedback.DbUser=feedback
feedback.DbPassword=passw0rd
feedback.DBA.DbUser=wsadmin
feedback.DBA.DbPassword=passw0rd

likeminds.DbType=oracle
likeminds.DbName=LMDB
likeminds.DbSchema=likeminds
likeminds.DataSourceName=wplmDS
likeminds.DbUrl=jdbc:oracle:thin:@oracle.test.ibm.com:1522:LMDB
likeminds.DbUser=likeminds
likeminds.DbPassword=passw0rd
likeminds.DBA.DbUser=wsadmin
likeminds.DBA.DbPassword=passw0rd

release.DbType=oracle
release.DbName=RELDB
release.DbSchema=release
release.DataSourceName=wprelDS
release.DbUrl=jdbc:oracle:thin:@oracle.test.ibm.com:1523:RELDB
release.DbUser=release
release.DbPassword=passw0rd
release.DBA.DbUser=wsadmin
release.DBA.DbPassword=passw0rd

community.DbType=oracle
community.DbName=COMDB
community.DbSchema=community
community.DataSourceName=wpcomDS
community.DbUrl=jdbc:oracle:thin:@oracle.test.ibm.com:1524:COMDB
community.DbUser=community
community.DbPassword=passw0rd
community.DBA.DbUser=wsadmin
community.DBA.DbPassword=passw0rd

customization.DbType=oracle
customization.DbName=CUSDB
customization.DbSchema=customization
customization.DataSourceName=wpcusDS
customization.DbUrljdbc:oracle:thin:@oracle.test.ibm.com:1525:CUSDB
customization.DbUser=customization
customization.DbPassword=passw0rd
customization.DBA.DbUser=wsadmin
customization.DBA.DbPassword=passw0rd

jcr.DbType=oracle
jcr.DbName=JCRDB
jcr.DbSchema=jcr
jcr.DataSourceName=wpjcrDS
jcr.DbUrl= jdbc:oracle:thin:@oracle.test.ibm.com:1526:JCRDB
jcr.DbUser=jcr
jcr.DbPassword=passw0rd
jcr.DBA.DbUser=wsadmin
jcr.DBA.DbPassword=passw0rd

Note that these values might be different in your case and should be changed according to your environment. For example, Oracle database host, instance port, database name, database names, user, passwords, schema names.

  1. Use a text editor to open the properties file wp_profile_root/ConfigEngine/properties/wkplc_dbtype.properties and modify the following values to correspond to your environment. The value of oracle.DbLibrary must be the path where ojdbc14.jar was copied on the WebSphere Portal box.

oracle.DbDriver=oracle.jdbc.driver.OracleDriver
oracle.DbLibrary=C:/IBM/WebSphere/PortalServer/drivers/jdbc/lib/ojdbc14.jar
oracle.JdbcProviderName=wpdbJDBC_oracle

  1. Open the following mapping files under wp_profile_root/PortalServer/config/tablespaces that specify the table space and index space property pairs for each database table:

community.space_mapping.properties
customization.space_mapping.properties
feedback.space_mapping.properties
jcr.space_mapping.properties
likeminds.space_mapping.properties
release.space_mapping.properties

Assign a table space to each entry in the mapping files. The table space name must be prepended by the keyword TABLESPACE and a space. For example: community.COMP_INST.tablespace=TABLESPACE TS_COMMUNITY Repeat this step for each domain that you are transferring.

8.   Create the tablespaces that are required for JCR domain using the following commands;           
Before using the following commands, replace &dbpath. with the actual database path on oracle jcr db. You also need to replace JCRDB with the name of jcr database if this is different in your case.
create tablespace ICMLFQ32 datafile '&dbpath./JCRDB/data/JCRDB_ICMLFQ32_01.dbf' size 300M reuse autoextend on next 10M maxsize UNLIMITED extent management local autoallocate;
create tablespace ICMLNF32 datafile '&dbpath./JCRDB/data/JCRDB_ICMLNF32_01.dbf' size 25M reuse autoextend on next 10M maxsize UNLIMITED extent management local autoallocate;
create tablespace ICMVFQ04 datafile '&dbpath./JCRDB/data/JCRDB_ICMVFQ04_01.dbf' size 25M reuse autoextend on next 10M maxsize UNLIMITED extent management local autoallocate;
create tablespace ICMSFQ04 datafile '&dbpath./JCRDB/data/JCRDB_ICMSFQ04_01.dbf' size 150M reuse autoextend on next 10M maxsize UNLIMITED extent management local autoallocate;
create tablespace ICMLSNDX datafile '&dbpath./JCRDB/index/JCRDB_ICMLSNDX_01.dbf' size 10M reuse autoextend on next 10M maxsize UNLIMITED extent management local autoallocate;
 
9.  Run the following commands as user SYS:
grant select on pending_trans$ to ;
grant select on dba_2pc_pending to ;
grant select on dba_pending_transactions to ;
grant execute on dbms_system to ;

Where is the username configured in the Oracle datasource's authentication alias.
 
10. Open a command prompt and change to the directory wp_profile_root\ConfigEngine. Enter the following commands to validate configuration properties.
ConfigEngine.bat validate-database-driver
-DTransferDomainList=release,customization,community,jcr,feedback,likeminds

ConfigEngine.bat validate-database-connection
-DTransferDomainList=release,customization,community,jcr,feedback,likeminds

11. Stop both WebSphere Application Server and the WebSphere Portal server:
 
12.  Open a command prompt and change to the directory wp_profile_root\ConfigEngine. Enter the following commands to transfer the database to Oracle.
ConfigEngine.bat database-transfer
-DTransferDomainList=release,customization,community,jcr,feedback,likeminds -DuseCustomTablespaceMapping=true
 
13. Start the Portal Server and test if you can login to the Portal Server.

Source : http://www-10.lotus.com/ldd/portalwiki.nsf/dx/06152009050451pmwebsuc.htm

Generate reports from Opportunities using a Visualforce Page in Salesforce

  Step 1: Create a Visualforce Page Go to the Setup menu in Salesforce. Search for "Visualforce Pages" in the Quick Find box and c...