Wednesday, 25 December 2013

How to configure Logon groups in SAP ( SMLG )

Logon Groups:

Logon groups (or work groups) are configured to dynamically distribute the load being processed by the dialog work processes.

In many cases, SAP systems will have 2 or more sap abap instances. In these cases, logon groups can be configured to achieve dynamic distribution of dialog users on the ABAP instances.

A report runs in SAP every 5minutes which determines the load across each server and updates in the memory area of the message server.

Other criteria:

Logon groups according to SAP application / module:  Separate logon groups can be setup for applications/modules such as HR, FI/CO, SD, MM etc. It means HR module users will be restricted to logon to identified instances, similarly other module users are allowed to login to their respective identified instances.  The advantages of this method, is only the programs of the respective module are loaded into the program buffer of the particular instances of that logon group. Due to this, program buffer requires less memory and this helps to avoid buffer displacements thus improving system performance.

Logon groups according to language, country or company division: 

 If your SAP system is operating across multiple countries or languages, in that case it is good idea to create logon groups specific to a country or language. By this way the data and text related to specific country or language will be loaded into the buffers of the respective instances. 

This minimizes buffer displacements and improves system performance. Also less memory is required for the table buffer.

         Logon groups for certain user groups:

i)             We can setup separate logon groups for some department like sales whose work is performance critical. For that logon groups we assign  instances which operates with high level of performance (e.g: high speed processors, less users per server, no background or update workprocesses configured or a dedicated network etc)
ii)            Some department users may take time-consuming reports in dialog mode. For these type of users, you may have to create separate logon group and assign an sap instance where profile parameter rdisp/max_wprun_time is set to very high
In this way we can separate performance critical/resource intensive applications from others.

Logon groups for the SAP Web Dispatcher:

 For direct ABAP web service requests, we can setup logon groups that the SAP Web Dispatcher can use. If logon groups are not configured for web dispatcher, the load is distributed to all ABAP instances on which ICM is configured.  Also, based on URLs we can distribute certain group of requests to dedicated logon groups.

Logon groups for ALE/RFC:

Asynchronous RFCs are used to process in parallel. However if the parallel processes are not limited properly, they can occupy all the available processes which impacts dialog users and can bring down the application. So, it is good idea to create separate logon groups for incoming RFC calls so that RFCs are kept separate from workprocesses of online users and thus avoids impact to dialog users.

Guide lines:

After assigning instances to logon groups
i)             We need to verify whether the instances of logon groups are evenly distributed or not.

ii)            If an instance hangs or temporarily got disconnected, you should be able to redistribute the users
So, you need to setup at least 2 sap instances for each logon group.

iii)           Setting up logon groups involves extra administration and monitoring. So, unnecessarily large number of logon groups shouldn’t be setup

How to setup logon groups?

SMLG transaction code is used for creating logon groups.

Logon to SAP system and goto SMLG transaction as shown below:

In the above example there are 2 instances (00 and 09) in this SAP system. These are not yet assigned to any logon group.

We can create a new logon group by clicking on highlighted create icon on the above screen. It results in below screen.

In the above screen, either select logon group from dropdown or provide its name if you are newly creating. After that assign instance for that logon group and click on copy to save the assignment.

In this example iam creating two logon groups hr and fico and assigning instances 00 and 09 respectively. Please find below screenshots which explains the same.

Repeat the same step and create logon group fico and assign instance 09 for it as shown above.

After doing this, you can see following logon groups in SMLG

Once you are done with logon group setup, please log off from SAP system and goto SAPGUI of the respective SAP system.

Click on properties of the respective GUI entry and goto to connection tab as shown below.

Please select Group/Server selection option from the drop down of Connection Type as shown above and maintain description and system id of the instance as shown above.

Now, you should be able to view the newly created logon groups as shown in below figure:

Also, please note you are able to view logon group SPACE also which gets created by default

Now, you can configure any desired logon group to the users as shown below:

For example in the above screen fico group is assigned to the end users in his GUI so that now onwards, he will login into instance number 09 only.

How to delete logon group or assignment?

If you no longer require any logon group, you can delete by proceeding as shown below:

i)Goto SMLG transaction

ii) Select the respective row and click on delete assignment which deletes the assignment of an instance to a logon group (highlighted in green color in below screen)

Click on delete icon above which confirms deletion of assignment

iii)If you wish to delete logon group itself, then select the respective logon group and click on “delete group” in the above screen highlighted in red color (please refer screen 1 of point ii above). This deletes the logon group itself and removes all assignments related to this group.

How to check logon load distribution in SAP?

Goto transaction code SMLG as shown below and click on highlighted icon below to view the load distribution across instances

Alternatively, you can view this by navigating to Goto -> Load Distribution or  by pressing F5 key in the above screen

Friday, 6 December 2013

How to view database parameters at SAP level

  • How to view database active parameters at SAP level ?
    Goto transaction DB02 and navigate to Additional Functions -> Database parameters as shown below  :

    Click on Active parameters tab to view active database parameters

    How to view SPFILE parameters at SAP level ?
    Click on SPFILE tab to view SPFILE parameters

    How to view database Parameters history at SAP level ?
    Click on parameters history tab to view the parameters that are changed in the recent past.

    In the above screen click on Show parameters history. It displays window as below

    Provide the date from which you would like to view the database parameter changes.

    And then click on tick mark to view the database parameter changes from the selected date.

    How to export the database parameters to an excel sheet ?

    Click on export button (highlighted below) and select table as the output as shown in below screen and the parameters can be exported to an excel or word as per the selection by you.

How to check database, tablespace sizes in SAP

How to check the database size ?

Goto transaction DB02  and navigate to Space -> Space overview to view

  • Database name
  • Database system
  • Size
  • Free size
  • Used percentage
  • Number of database users
  • Number of tablespaces
  • Number of tables and size
  • Number of indexes and size

In DB02, navigate to Space -> Space overview to find all the above mentioned details

    How to check  the users that are present in database at SAP level ?
    In DB02, navigate to Space -> Users -> Overview as below
              How to check various tablespaces in SAP and their sizes ?
              In DB02, navigate to Space -> Table spaces -> Overview to view tablespaces details as below.

                    Wednesday, 4 December 2013

                    Difference Between SAP_ALL and SAP_NEW

                    What is the difference between SAP_ALL and SAP_NEW

                    Definition of SAP_NEW:-
                    SAP_NEW is a SAP standard Profile which is usually assigned to system users temporarily during an upgrade to ensure that the activities and operations of SAP users is not hindered, during the Upgrade. It contains all the necessary objects and transactions for the users to continue their work during the upgrade. It should be withdrawn once all upgrade activities is completed, and replaced with the now modified Roles as it has extensive authorizations than required.

                    Definition of SAP_ALL:-

                    SAP_ALL is a SAP standard profile, which is used on need basis, to resolve particular issues which may arise during the usage of SAP. It is used by Administrators/Developers only and is applied on a need to use basis, then withdrawn. It contains all SAP system objects and Transactions. SAP_ALL is very critical and only SAP* contains SAP_ALL attached to it in the production system. No other dialog users have SAP_ALL attached to them.

                    SAP_NEW is used in the Production environment during a version upgrade whereas SAP_ALL shouldn't be or not allowed be used in Production (for audit purposes obviously), except where necessary, in a controlled manner with all proper approvals from the customer.

                    Few Important values to be monitored in ST02 & ST06/ST06N

                    In ST02,

                    1) Hit ratio for each buffer should be greater than 95%.
                    2) If hit ratio is less than 95%, no swap should be there.
                    3) Current usage of extended memory should not cross 75%.
                    4) We have to check the swaps for each buffer. For program buffers it should be 10000 hits/ day & for other buffers it should be 1000 hits/ day.
                    5) We have to check the free space & the free directory for each buffer.

                    In ST06/ST06N,

                    1) Ideally CPU should be free for 60% of the time.
                    2) Page out/s should be 0.
                    3) Under LAN, we have to check for collisions & errors. They should be 0.
                    4) We have to check for the SAPOSCOL status.

                    Freezing Transports in SAP

                    Freezing Transports------

                     You can freeze transports by simply creating a file in the transport bin directory called:  
                    T_OFF.ALL (will not allow transports to any system)
                    T_OFF. (will not allow transports to a specific system) 
                    This would be an easy way to freeze transports during an upgrade or for any other reason.