Banner 468 x 60px

Monday, October 29, 2012

Unlocking SAP users like(SAP* & DDIC) in DB2

0 comments


1.Login to db2 using db2<SID> user.

2.db2 connect to SID user sapSID using <password>

Here SID = XYZ Password = 1234
e.g db2 connect to XYZ user sapxyz using 1234

3.db2 select bname,uflag from sapxyz.usr02 where mandt='700' and bname='SAP*'

BNAME                                UFLAG
------------------------------------ ------
SAP*                                  128

  1 record(s) selected.

4.db2 update usr02 set uflag=0 where mandt='700' and bname='SAP*'
  DB20000I  The SQL command completed successfully.

db2 commit

DB20000I  The SQL command completed successfully.

Read more...

Wednesday, September 26, 2012

SAP backup log extensions

0 comments

aab        BRARCHIVE        BRARCHIVE abort
afd        BRBACKUP        Whole offline database backup to local disk
aff        BRBACKUP        Whole offline database backup using BACKINT at file level
afp        BRBACKUP        Whole offline database backup to remote tape
afr        BRBACKUP        Whole offline database backup using RMAN
afs        BRBACKUP        Whole offline database backup to remote disk
aft        BRBACKUP        Whole offline database backup to local tape
afv        BRBACKUP        Whole offline database backup using BACKINT at volume level
alf        BRRECOVER        Restore and apply archivelog files
aly        BRCONNECT        Collect optimizer statistics
and        BRBACKUP        Whole online database backup to local disk
anf        BRBACKUP        Whole online database backup using BACKINT at file level
anp        BRBACKUP        Whole online database backup to remote tape
anr        BRBACKUP        Whole online database backup using RMAN
ans        BRBACKUP        Whole online database backup to remote disk
ant        BRBACKUP        Whole online database backup to local tape
anv        BRBACKUP        Whole online database backup using BACKINT at volume level
bab        BRBACKUP        BRBACKUP abort
cds        BRARCHIVE        Second backup and deletion + first backup of archivelogs
chk        BRCONNECT        Database check
cln        BRCONNECT        Clean up DBA logs
cma        BRARCHIVE        Determination of archivelog compression rates
cmb        BRBACKUP        Determination of database compression rates
cpd        BRARCHIVE        Second backup and deletion of archivelogs
cps        BRARCHIVE        Second backup + first backup of archivelogs
cpy        BRARCHIVE        Second backup of archivelogs
crv        BRRECOVER        Complete database recovery
dba        BRSPACE        Alter database
dbc        BRSPACE        Recreate database
dbp        BRSPACE        Alter database parameter
dbr        BRSPACE        Start up database
dbs        BRSPACE        Shut down database
dbv        BRBACKUP        Database verification using DBVERIFY or RMAN validate
dbw        BRSPACE        Show database information
dcp        BRARCHIVE        Deletion of archivelogs backed up twice
ddb        BRBACKUP        Deletion of disk backup
dfa        BRSPACE        Alter data file
dfm        BRSPACE        Move data file
dpt        BRRECOVER        Database point-in-time recovery
drs        BRRECOVER        Whole database reset
drv        BRRECOVER        Disaster recovery
dst        BRCONNECT        Delete optimizer stat
aab        BRARCHIVE        BRARCHIVE abort
afd        BRBACKUP        Whole offline database backup to local disk
aff        BRBACKUP        Whole offline database backup using BACKINT at file level
afp        BRBACKUP        Whole offline database backup to remote tape
afr        BRBACKUP        Whole offline database backup using RMAN
afs        BRBACKUP        Whole offline database backup to remote disk
aft        BRBACKUP        Whole offline database backup to local tape
afv        BRBACKUP        Whole offline database backup using BACKINT at volume level
alf        BRRECOVER        Restore and apply archivelog files
aly        BRCONNECT        Collect optimizer statistics
and        BRBACKUP        Whole online database backup to local disk
anf        BRBACKUP        Whole online database backup using BACKINT at file level
anp        BRBACKUP        Whole online database backup to remote tape
anr        BRBACKUP        Whole online database backup using RMAN
ans        BRBACKUP        Whole online database backup to remote disk
ant        BRBACKUP        Whole online database backup to local tape
anv        BRBACKUP        Whole online database backup using BACKINT at volume level
bab        BRBACKUP        BRBACKUP abort
cds        BRARCHIVE        Second backup and deletion + first backup of archivelogs
chk        BRCONNECT        Database check
cln        BRCONNECT        Clean up DBA logs
cma        BRARCHIVE        Determination of archivelog compression rates
cmb        BRBACKUP        Determination of database compression rates
cpd        BRARCHIVE        Second backup and deletion of archivelogs
cps        BRARCHIVE        Second backup + first backup of archivelogs
cpy        BRARCHIVE        Second backup of archivelogs
crv        BRRECOVER        Complete database recovery
dba        BRSPACE        Alter database
dbc        BRSPACE        Recreate database
dbp        BRSPACE        Alter database parameter
dbr        BRSPACE        Start up database
dbs        BRSPACE        Shut down database
dbv        BRBACKUP        Database verification using DBVERIFY or RMAN validate
dbw        BRSPACE        Show database information
dcp        BRARCHIVE        Deletion of archivelogs backed up twice
ddb        BRBACKUP        Deletion of disk backup
dfa        BRSPACE        Alter data file
dfm        BRSPACE        Move data file
dpt        BRRECOVER        Database point-in-time recovery
drs        BRRECOVER        Whole database reset
drv        BRRECOVER        Disaster recovery
dst        BRCONNECT        Delete optimizer stat
Read more...

Thursday, July 12, 2012

DB2 Online Backup failed due to ABCD Error

0 comments
DB2 Online Backup failed with ABCD Error


Error Log

Job started
Step 001 started (program RSDBAJOB, variant &0000000000005, user ID AMIT)
Backup_Dev:Database Backup to Device
Backup_Dev:started by CL_DB6_JOB_BACKUP_DEVICE       on server eccqa
Backup_Dev:Parameter TESTMODE has not been set
Backup_Dev:Parameter RUNTIME has not been set
Backup_Dev:Parameter BACKUP_MODE has been set to "ONLINE"
Backup_Dev:Parameter PARTITION has not been set
Backup_Dev:Parameter BACKUP_TYPE has been set to ""
Backup_Dev:Parameter COMPRESS has been set to "COMPRESS"
Backup_Dev:Parameter INCLUDE LOGS has been set to "INCLUDE LOGS"
Backup_Dev:Parameter NUMBER_BUFFERS has been set to " 0"
Backup_Dev:Parameter BUFFER_SIZE has been set to " 0"
Backup_Dev:Parameter PARALLELISM has been set to " 0"
Backup_Dev:Parameter UTIL_IMPACT_PRIORITY has not been set
Backup_Dev:Parameter FILE_PATH has been set to "/dev/rmt0"
Backup_Dev:Command ' BACKUP DATABASE GEQ ON DBPARTITIONNUM (0 ) ONLINE TO"/dev/rmt0" COMPRESS INCLUDE LOGS  'f
Backup_Dev:ailed
Exception CX_DB6_CON in program CL_DB6_JOB_BACKUP=============CP / CL_DB6_JOB_BACKUP=============CM002 at line ADBC error with r
Backup_Dev:Exception CX_DBA_JOB in class CL_DB6_JOB_BACKUP method line 0
Backup_Dev:  Kernel Error ID:
Backup_Dev:  WP ID: 12
Backup_Dev:  WP PID: 9633896
Backup_Dev:SYSID:
Backup_Dev:  SY-SUBRC: 1208
Backup_Dev:  SY-TABIX: 0
Backup_Dev:  Message: ADBC error
Backup_Dev:  Database:
Backup_Dev:caused by
Backup_Dev:Exception CX_DB6_ADMINCMD in class CL_DB6_ADMIN_CMD method SSV_BACKUP
Backup_Dev:line 59
Backup_Dev:  Kernel Error ID:
Backup_Dev:  WP ID: 12
Backup_Dev:  WP PID: 9633896
Backup_Dev:  SYSID: GEQ
Backup_Dev:  SY-SUBRC: 1208
Backup_Dev:  Message: ADBC error
Backup_Dev:  Command:BACKUP DATABASEGEQ ON DBPARTITIONNUM ( 0 ) ONLINE TO"/dev/rm
Backup_Dev:  t0" COMPRESS INCLUDE LOGS
Backup_Dev:  Database:
Backup_Dev:caused by
Backup_Dev:Exception CX_SQL_EXCEPTION in class CL_SQL_STATEMENT
Backup_Dev:  Kernel Error ID:
Backup_Dev:  DB Error: Yes
Backup_Dev:  SQL Code: 2413-
Backup_Dev:  SQL Message: SQL2413N Online backup is not allowed because the dat
Backup_Dev:  abase is not recoverable or a backup pending condition is in effect ro
Backup_Dev:w=1
Backup_Dev:  DB Object Exists: No
Backup_Dev:  Duplicated Key: No
Backup_Dev:  Internal Error: 1
Backup_Dev:  Invalid Cursor: No
Backup_Dev:  Unknown Connection: No
Backup_Dev:  Connection Closed: No
Exception CX_DBA_JOB in class CL_DB6_JOB_BACKUP method  line 40
Backup_Dev:terminated with error
REASON=ADBC error
Job finished



Solution

This error was causing due to achlog method. In DB2 after changing archive log method you have to take offline backup else sub sequent online backups are failed.

Find any pending jobs are terminated with out complete

DB2 LIST APPLICATIONS FOR DATABASE SID SHOW DETAIL

terminate all pending backups

DB2 FORCE APPLICATION ALL

brdb6brt 

trigger offline backup from command prompt

db2 backup db <SID> to <path- tape address/file system path) compress

db2 UPDATE DB CFG FOR <SID> using LOGARCHMETH1 DISK:/db2/<SID>/archive_log

Procedure of backup
stopsap r3
Login as db2<sid>
db2 backup database <sid> to /dev/rmt0
Monitor backup using command
db2 list utilities show detail

Links useful






Read more...

Wednesday, July 11, 2012

SAP Router Installation

0 comments

general Information about saprouter from the link.http://help.sap.com/saphelp_nw04/helpdata/en/4f/992ce8446d11d189700000e8322d00/frameset.htm

  • I would like to highlight steps required for successful sap router installation and configuration.
  • 1- First download required files from service.sap.com
  •  

    image015.jpg

                    Required applications consist of ;

                    'SAPROUTER'

                    'SAP Cryptographic Software'

     

    'SAPROUTER' file can be found at

     

    Downloads - SAP Software Distribution Center – Download - Support Packages and Patches - Additional Components – SAPROUTER -SAPROUTER 7.10 - SAPROUTER 7.10 – Windows Server on x64 64bit     

     

    Find  'SAP Cryptographic Software' from;

     

    Downloads - SAP Software Distribution Center – Download - SAP Cryptographic Software -  SAP Cryptographic Library Microsoft Windows 2003 for x86_64

     

    2- Copy downloaded files into c:\usr\sap\saprouter (created manually)

     

    3- Use sapcar.exe  tool to unpack *.sar extension files.

     

    Browse to c:\usr\sap\saprouter  in command prompt and execute

    1. sapcar.exe -xvf saprouter.sar
    2. sapcar.exe -xvf 90000114.SAR

     

    4- To get saprouter certificate you should obtain Distinguished name and execute command as example.

    sapgenpse get_pse -v -r certreq -p local.pse "<Your Distinguished Name>"     

     

    This command created 2 files  "Certreg" and " local.pse".

     

    Content of "Certreg"  file should copied.       

     

    5- Browse to below adress www.service.sap.com/SAPROUTER-SNCADD Here we should insert content of certreg file.

     

    6- Paste content copied from web into "srcert" file which created at c:\usr\sap\saprouter with no extension.

     

    7- Execute sapgenpse import_own_cert -c srcert -p local.pse at folderC:\usr\sap\saprouter  

     

    8- Determine which windows account user will use saprouter and execute command below accordingly;

    sapgenpse seclogin -p local.pse -O <user_for _saprouter>           

    This command executed created "cred_v2"  file

     

    If this file not created this 2  comands should solve the problem.            

    sapgenpse get_pse -v -noreq -p local.pse "<Your Distinguished Name>"


    sapgenpse get_pse -v -onlyreq -r certreq -p local.pse

     

    image026.jpg

    9- Create an empty file with no extension name as "Saprouttab"  at C:\usr\sap\saprouter folder.

     

    This file will include access authorization rights.Depending on the required usage saprouttab have to be configured.

     

    Saprouter can be used in 2 different ways;

    1- Can be used for Sap OSS service.

    2- Can be used for sap users to access sap systems from outer network.

     

    For more information about saprouttab parameters refer to linkhttp://help.sap.com/saphelp_nw04/helpdata/en/4f/992ce8446d11d189700000e8322d00/frameset.htm

     

    10-  You should configure  Windows Environment variables to enable saprouter working environment.

     

    1.Variable name: SAPROUTTAB  Variable value: C:\usr\sap\saprouter

    2.Variable name: SECUDIR          Variable value: C:\usr\sap\saprouter

    3.Variable name: SNC_LIB          Variable value:  C:\use\sap\saprouter\sapcrypto.dll

     

    11- To see saprouter settings use sapgenpse get_my_name -v -n Issuer command and evaluate.

     

    12- To start saprouter  manually use command saprouter.exe –r 3299 –K "Your Distinguished name" –V 2 –G "c:\usr\sap\saprouter\router.log" –W 60000

    For detailed information about parameters please refer to linkhttp://help.sap.com/saphelp_nw04/helpdata/en/4f/992ce8446d11d189700000e8322d00/frameset.htm

     

    13- To close saprouter from command prompt use saprouter -s

     

    14- To check saprouter configuration and connection you can use telnet as explained below;

     

    For external access you should configure NAT of your router. Forward  3200-3299 port interval to your saprouter's local ip adress.

     

    -To check if saprouter is correctly configured for sap oss connection try telnet <ip adress> 3299

     

    -To check if saprouter is working from another computer you can use telnet <hostmane or ip> 3299

     

    -To check saprouter connection with sapgui you should enter saprouter string /H/externalip/W/password/H/

     

    15 - To configure oss connection go to tcode oss1 and enter details and try to logon.

     

    16- You can use saprouter as windows service also;

     

    Please check Note 525751 - Installation of the SNC SAPRouter as NT Service.

     

    Service from the command line: ntscmgr install saprouter -b <path>\saprouter.exe -p "service -r -W 60000 -R <path>\saprouttab -K p:<your_distinguished_name>"


    Read more...