Using Google Chrome?

Download my
free Chrome Extension, Power Notes Searcher, to make searching for and evaluating SAP notes, much easier.

Recent Posts

Thursday, January 29, 2015

Testing SAP BI Java Query Outside iView

To test a SAP BI Java query outside of an Enterprise Portal iView call, you can use the URL:

http://[EP Server]/irj/servlet/prt/portal/prtroot/pcd!3aportal_content!2fcom.sap.pct!2fplatform_add_ons!2fcom.sap.ip.bi!2fiViews!2fcom.sap.ip.bi.bex?TEMPLATE=TEMP1

You should substitute "[EP Server]" with your SAP Enterprise Portal server hostname, and change "TEMP1" to be the name of the BEx query you wish to run.  You should take the same name as that used in the iView.

Thursday, January 22, 2015

Starting and Stopping Individual SAP AS Java Server Processes

Should you need to restart either manually or automatically (via script) a specific AS Java server node, it's possible to use the sapcontrol tool to provide precise control.
The method detailed below is based on the documentation provided here:

Performs a given control function (EnableProcess/StartProcess, DisableProcess/StopProcess,
SoftStopProcess, ActivateProcess, DeactivateProcess, RestartProcess, SoftRestartProcess,
DumpStackTrace, EnableDebugging, DisableDebugging, IncrementTrace, DecrementTrace) on a given AS
Java process. processname must match a process name in the AS Java process list returned by
J2EEGetProcessList. To perform AS Java instance-wide operations (StartInstance, StopInstance,
RestartInstance, BootInstance, RebootInstance), use processname “all”.
Based on the above information, we can query the AS Java processes for a specific AS Java instance, using the following command line as the sidadm user:

sidadm> sapcontrol -host [host] -nr [sys##] -function J2EEGetProcessList

You should substitute the "host" and "sys##" with the host of your application server (virtual host) and the SAP instance number.
The command will return a list of the processes that the instance is running.
For a 2 node AS Java system, you can see the Server0 and Server1 processes in the list.
To restart Server0 on the AS Java instance use the below command line as the sidadm user:

sidadm> sapcontrol -host [host] -nr [sys##] -function J2EEControlProcess "server0" "RestartProcess"

You should substitute the "host" and "sys##" with the host of your application server (virtual host) and the SAP instance number.
Change "server0" for "server1" if you want to restart server1.
Based on the above restart, you can monitor the restart by using the below command line to see when the restart is completed:
sidadm> sapcontrol -host [host] -nr [sys##] -function J2EEGetProcessList | awk -F, '{ if ( $2 != "" && FNR > 5 ){ print "Name: "$2"\t\tState: "$8"\t\tStarted: "$9 }}'

You should substitute the "host" and "sys##" with the host of your application server (virtual host) and the SAP instance number.

Thursday, January 15, 2015

Deploying SAP Portal JDBC Adapter SDA using Telnet

Once you've built a new com.sap.aii.adapter.lib.sda file ready for deployment into the SAP AS Java, you have two options for deployment in a NW 731 system:
- Deploy using SUM
- Deploy using Telnet

The SUM method can be arduous, taking anywhere from 20 minutes to over a couple of hours if you don't already have the software.
Using Telnet is the lowest common denominator, uses existing software already installed and can take as little as 5-10 minutes.
As the <sid>adm user on the AS Java application server, use Telnet (must be installed on the Unix, Linux or Windows O/S, to perform the deployment:

sidadm> telnet 127.0.0.1 5<##>08
Administrator
<pw>

Once connected, you can query the version of the SDA: 

explore name=com.sap.aii.adapter.lib

Development Component:
name: [com.sap.aii.adapter.lib], vendor: [sap.com], location: [SAP AG], version: [7.3113.20140808110905.0000], software type: [primary-library], csn component: [BC-XI-CON-AFW], dependencies: [[name: 'engine.j2ee14.facade', vendor: 'sap.com']], archive type: [DC]

Then deploy your new SDA file:

deploy /tmp/sap.com_com.sap.aii.adapter.lib  on_deploy_error=stop version_rule=all

Notice that you are disconnected from Telnet at this point.
You should wait around 5-10mins, then re-connect into Telnet as Administrator, then run get_result:

> get_result
The status of the deployed SDUs is Success.
Additional information:

[sdu id: [sap.com_com.sap.aii.adapter.lib]
sdu file path:
/usr/sap/<SID>/J##/j2ee/cluster/server1/temp/tc~bl~deploy_controller/archives/124/1416245030759972000/com.sap.aii.adapter.lib.sda]
version status: [SAME]
deployment status: [Success]
description: []

That's it.





Thursday, January 08, 2015

Drop a SAP DB2 10.1 Database & Remove Instance

In case you have installed an IBM DB2 database instance using the SAP Software Provisioning Manager, and you would now like to remove this database and the DB2 software installation (SAP DB instance), then here's a quick method:

As db2<sid>:

db2<sid> # db2stop
db2<sid> # db2 drop database

Then as root:

# cd /db2/db2<sid>/db2_software/instance
# ./db2idrop db2<sid>

# cd /db2/db2<sid>/db2_software/install
# ./db2_deinstall -a

Finally, remove DB related directories (if necessary):

# rm -rf /db2/<SID>/db2dump/*
# rm -rf /db2/<SID>/log_dir/*
# rm -rf /db2/<SID>/*archlogs/*

Friday, January 02, 2015

Power Notes Searcher Updated to v1.2

First off, a Happy New Year to you!

During the festivities, I've managed to squeeze in a little time to make a couple of modifications to the Power Notes Searcher.  My free Google Chrome Extension for searching for SAP notes and helping you organise the SAP notes you find.

The changes include 1 fix to the Google Font API link which was no longer working due to Google's move to ensure that it's infrastructure is accessed via HTTPS.
I've also included some enhancements to the list of hard SAP links to useful areas of the SAP support site, such as the Support Package Stack schedule and the SL Toolset (for SUM and SWPM).
I also adjusted the link to the SWDC so that it now uses the new support.sap.com site (instead of the old service.sap.com).

As a bonus, I increased the number of note tabs that can be opened in one go, from 5 to 10.
This means that entering 10 SAP notes into the search box (or omni box), will open all of them.
Finally, I increased the number of allowed SAP notes in the history, from 50 to 100.
I found that on a regular project for 1 system installation, I was regularly exceeding the 50 note limit.

With regards to up & coming features, well I originally meant to include the ability to tag notes listed in the history.  This would provide a way of saving favourite notes, plus saving specific notes as a project set or collection.
The initial core code for storing tags against notes is already built in, I just need to spend some time around the peripheral code creating the interface etc.  Let's hope I can get this done in the next few months.

In case you've not installed the extension, you can see the details here on the Google Chrome Extensions Web Store (or from the link on my initial blog post here).