SAP BASIS

How to delete an SAP Client

How to delete an SAP Client

 

    • Log on to the client to be deleted.
    • Use the menu option use Transaction code SCC5 or from the SAP System initial screen choose Tools _ Administration _ Administration _ Client admin _ Special functions _Delete client.
    • Start the deletion of the client, preferably using background processing.
    • When you delete a client entry from table T000 with client maintenance (TransactionSCC4), you can no longer log on to the client or update it using change requests. The deletion process, however, does not eliminate the data belong to the client. This means the client-dependent data remains in your SAP System, occupying space in the database. Therefore, to eliminate an SAP client entirely, that is, to delete both the client and the client-dependent data, use the client delete functionality (Transaction SCC5).
    • Deleting a client entry with client maintenance (Transaction SCC4) allows you to temporarily lock the client. The deletion procedure preserves the data for the client but prevents users from logging on to the client or accessing the data belonging to the client. To restore the client and allow logon, recreate the client entry using client maintenance.
    • The amount of time required for the deletion of a client can be reduced by performing the deletion using parallel processes.

Share this article :

 

What are the different types of Transports requests?

There are 3 types of requests:
K type:
The transport K type implements transports of DE objects from the integration system into the consolidation system. When you create a transport request using the workbench organizer, it always uses this transport type by default meaning that all the transportable change requests stored in the workbench organizer are allocate this transport type. For this transport type, the objects are transported to the consolidated systems without changing the object’s system owner which means that the transported objects in the consolidated system become repair objects and no corrections are allowed for the imported objects.
C type:
With this transport type the objects change the system owner after they are transported which means that the source system of the object loses its ownership after the object is transported. So the target system in which the objects are transported becomes the original system. In other words objects are transported as original objects. So they can be corrected or modified in the target system too. That means that change authorization is also transported. In SAP terms, objects that are transported with C types are checked out of a system and checked into another system.
T type:
This transport type is useful when you have to copy object between two systems in a group ie when a system(other than consolidation system) receives a copy of objects, the corresponding transport takes place with transport type T. Object including the object of transport type T do not change their system owner. So the original system remains same.

How to unlock SAP* user id.

Use the below commands

update sapsr3.usr02 set flag=0 where bname=”ddic” and mandt=’100′;

or

update sapsd1.usr02 set uflag=0 where bname=’SAP*’ and mandt=’120′;

To check the status of SAP* user id
select status from sapr3e.usr02 where bname=’SAP*’ and mandt=’120′

Delete SAP* user id.

delete from sapsr3.usr02 where bname=’SAP*’ and mandt=’120′;

Setup Single sign on (SSO) setup for Netweaver 7.0

Verify the following profile parameters are set correctly in the backend using rz11
login/accept_sso2_ticket = 1
login/create_sso2_ticket = 0
Make sure that in the portal the connector to back end is defined with following setting and permission is set correct.
Authentication Ticket Type – SAP Logon Ticket
Logon Method – SAPLOGONTICKET
User Mapping Type – useradmin,user
Fix certificate
Login in to Visual Administrator
1. Select the Key Storage Service.
2. Select the TicketKeystore view.
3. Delete the SAPLogonTicketKeypair and SAPLogonTicketKeypair-cert entries.
4. Under Entry, choose Create . The Key and Certificate Generation dialog appears.
5. Enter the Subject Properties in the corresponding fields.
The entries in these fields build a Distinguished Name in the form:
CN= , OU= , O=, L=, ST= , C=
Use capital letters for the Country Name.
6. Enter SAPLogonTicketKeypair as the Entry Name.
Do not enter a different name. This J2EE Engine uses the entry with this name to sign logon tickets.
7. Select the Store certificate option and choose DSA as the algorithm to use.
8. Choose Generate .

SAP SYSTEM MONITORING

System Monitoring has to be done regularly in order to track the efficiency and the utilization of the systems. Monitoring the systems for system logs, successful backups, runtime errors, locks, updates, buffer quality, CPU performance etc achieve this.

Transactions to be executed daily by any Basis consulatnt  to ensure sustained availability and view overall performance are as below. This list of Tcode  is the most important  and used almost daily

SM21              System Log

SM37              Simple Job Selection

ST22               ABAP Runtime Errors

SM12              Lock Entries

SM13              Update Requests

SM51              SAP Servers

SP01               Spool Requests

ST02               Tune Summary

ST03/ST03N  Workload Analysis

ST04               Database Performance Analysis

ST06               Operating System Monitor

DB12              Database Backup

DB13              DBA Calendar

DB02              Tablespace Overview

RZ20               CCMS

SMQ1            Outbound Queue

SMQ2             Inbound Queue

SPAD             Spool Administration

SMICM          

GRMG           Generic Request Message Generator

ST01               System Trace

SAP file system cleanup

If you need to reduce a filesystem urgently check below and remove old files safely

  • Check for old files in /usr/sap/SID/instance/work directory
  • Check for core file in /usr/sap/SID/instance/work , /usr/sap/SID/instance/j2ee/… AND /usr/sap/SID/SYS/profile directories
  • Check for large stat files in /usr/sap/SID/instance/data directory. Either compress the files older than 3 days or delete the files by logging on to the SAP system, run transaction ST03N–>Expert Mode–>Collector and Performance DB–>Statistics Records and File–>Delete File–>Double click on that application server and click on ‘yes’ on subsequent pop-ups
  • Check for old trace files in /usr/sap/SID/instance/j2ee/cluster/server<n>/log/..

SQL Script for oracle tablespace monitoring

Use the below script and alter the threshold,emailadddress and schema username and password for your systems and run it in crontab to send you alerts when the tablespace exceeds the threshold value. We know we can do this by CCMS setup but this is good to have functionality.

DBALIST=”email address”
sqlplus -s <<!
SAPschemausername/password
set feed off
set linesize 100
set pagesize 200
spool tablespace.alert
SELECT F.TABLESPACE_NAME,
TO_CHAR ((T.TOTAL_SPACE – F.FREE_SPACE),’999,999,99′) “USED(MB)”,
TO_CHAR (F.FREE_SPACE, ‘999,999’) “FREE(MB)”,
TO_CHAR (T.TOTAL_SPACE, ‘999,999,999’) “TOTAL(MB)”,
TO_CHAR ((ROUND ((F.FREE_SPACE/T.TOTAL_SPACE)*100)),’999,999′)||’ %’ PER_FREE
FROM   (
SELECT       TABLESPACE_NAME,
ROUND (SUM (BLOCKS*(SELECT VALUE/1024
FROM V\$PARAMETER
WHERE NAME = ‘db_block_size’)/1024)
) FREE_SPACE
FROM DBA_FREE_SPACE
GROUP BY TABLESPACE_NAME
) F,
(
SELECT TABLESPACE_NAME,
ROUND (SUM (BYTES/1048576)) TOTAL_SPACE
FROM DBA_DATA_FILES
GROUP BY TABLESPACE_NAME
) T
WHERE F.TABLESPACE_NAME = T.TABLESPACE_NAME
AND FREE_SPACE < (size below which it should alert,exe 5000mb)

AND T.TABLESPACE_NAME = ‘tablespacename you want to monitor’;
spool off
exit
!
if [ `cat tablespace.alert|wc -l` -gt 0 ]
then
cat tablespace.alert > tablespace.tmp
mailx -s “TABLESPACE ALERT-PLEASE TAKE ACTION ” $DBALIST < tablespace.tmp
fi

query to find free space in a tablespace

col “Tablespace” for a22
col “Used MB” for 99,999,999
col “Free MB” for 99,999,999
col “Total MB” for 99,999,999

select df.tablespace_name “Tablespace”,
totalusedspace “Used MB”,
(df.totalspace – tu.totalusedspace) “Free MB”,
df.totalspace “Total MB”,
round(100 * ( (df.totalspace – tu.totalusedspace)/ df.totalspace))
“Pct. Free”
from
(select tablespace_name,
round(sum(bytes) / 1048576) TotalSpace
from dba_data_files
group by tablespace_name) df,
(select round(sum(bytes)/(1024*1024)) totalusedspace, tablespace_name
from dba_segments
group by tablespace_name) tu
where df.tablespace_name = tu.tablespace_name ;

AIX commands -Must needed for an engineer

//topas – show Server Status
topas

//netstat – View Networking
netstat -i

//iostat – Reports CPU Stats
iostat 5 10

//show java version
java -fullversion (show java version)

//search directory and subdirectories
grep -r text *

//display os and TL
oslevel -s

//Estimate the dump device size
sysdumpdev -e

//List system configuration
prtconf

//List processor assigned to Lpar
lscfg |grep proc |wc -l
lsdev -Cc processor

//View what the processors are doing
sar -P ALL 3 10

//Cut and Paste in AIX
left click and draw box around test control/insert to cut, shift/insert to paste

//lslpp – Lists installed software products
lslpp -L xlC.aix50.rte (shows version)
lslpp -L xlC.rte (shows version)

//Find and change all file, directory, and symbolic link ownership to new UID
find / -user old_uid -exec chown -h new_uid {} \;

//Create file that lists all files, folders, symbolic links with no ownership/old ownership
find / \( -fstype jfs -o -fstype jfs2 \) -nouser -print > /tmp/find_owner_script.txt

######################
Disk Commands
######################

//chfs – change filesystem attributes
chfs -a options=cio /file_path  (correct invalid argument errors)

//View all information about how an Hdisk is setup
lsattr-El hdisk###

//Test if data can be written to hdisk
dd if=/dev/hdisk0 of=/dev/null bs=512 count=1

//Test to see if you can communicate with the disk
lquerypv -h /dev/hdisk0   or lquerypv -h /dev/hdisk0 80 10

//View output information of specified hdisk
lqueryvg -Atp hdisk0

//Review VGDA status
readvgda hdisk0

//Verify if disk is available
lsdev -Cc disk

//Paging Command (perminent change)
vmo -p -o lru_file_repage=0  (Default is ‘1’, but if there is a problem with paging..set to ‘0’)

######################
Volume Group Commands
######################

//Synchronize logical volume copies that are not current (ie.. hd3)
syncvg -l hd3

//Redefine rootvg hdisk settings
redefinevg -d hdisk1 rootvg

//Extend hdisk into volume group
extendvg rootvg hdisk0

//Mirror logical volumes across hdisk
mirrorvg rootvg hdisk0

######################
Config/ODM Commands
######################

//show config of physical scsi adapter
lscfg -vl fcs0

//odm information
odmget -q name=inet0 CuAt
odmdelete -q “value=$info” -o CuAt
//Example
odmdelete -q “value=net,-hopcount,0,,0,192.168.0.1” -o CuAt

######################
Boot/Info Commands
######################

//Write boot information to hdisk
bosboot -ad /dev/hdisk0

//View current bootlist settings
bootlist -m normal -o

//Set bootlist order
bootlist -m normal hdisk0 hdisk1

//Show whether the hardware is in 32-bit or 64-bit
bootinfo -y

//Shows if the 64-bit kernel is active
bootinfo -K

//Shows which disk is bootable on the lpar
ipl_varyon -i

######################
Microcode Commands
######################

//View Microcode levels
lsmcode

######################
Fiber Channel Settings
######################

//Enable Dynamic Tracking
chdev -l fscsi0 -a dyntrk=yes

//View FC Settings
lsattr -El fscsi0

//Change FC Fabric Event Error “Recovery” Settings
chdev -a fc_err_recov=fast_fail -l fscsi0

//show Microcode level of the HBA
lsmcode -d fcs0