Você está na página 1de 27

DB REFRESH

Activities to be carried on PRD System:

1. Take backup using BRTOOLS :


Here I have considered Offline Backup (Compression Mode).

Click Start -> Run -> Type BRTOOLS and click OK


The above window denotes that the backup has started and being saved in the location D:\oracle\PRD\sapbackup.
Here the backup file name is bdjvujux.afd.
It shuts down the Database Instance as we are taking an Offline Backup.
The backup has been completed successfully.

Exit from the BRTOOLS by selecting option s and then select the option y.
2. Create a Control file.

Click Start -> Run -> Type sqlplus "/as sysdba" and click OK.
You can find the trace file in the following location “D:\oracle\PRD\saptrace\usertrace”. Check the latest file that is
generated.
Copy that file and paste it onto the Desktop and rename it with control.sql .

Open the control.sql file and perform the following:


a. Remove the lines present above “STARTUP NOMOUNT” and below “CHARACTER SET UTF8;“
and save the file.
b. Replace <SOURCE SID> with <TARGET SID>. Here it is from PRD to QAS.
c. Replace REUSE with SET.
d. Replace NORESETLOGS with RESETLOGS
e. Replace ARCHIVELOG with NOARCHIVELOG.
Activities to be carried on NAG System:

1. Goto SE01 and create a Transport Request (Transport of Copies).


2. Specify the objects that you would like to backup from the QAS system, like USR01, USR02, RFCDES,
TBDLS etc as per your organization requirements and release the transport request. Ensure that the target
system is specified before releasing the TR.
3. The co-file and data files are generated in \usr\sap\trans\cofiles , \usr\sap\trans\data locations. Backup them
onto a removable media.
4. Make screen captures of the following tcodes :
SM59 (RFC destinations)
BD54 (logical systems)
SPAD (printers --> could be done by export on flat file).
DB13 (export DBA scheduling calendar).
SM37 (export name of released jobs with details).
AL11 (SAP Directories)
WE20 (Partner profile)
WE21 (Post IDOCS Processing)
SMLG (Logon Group)
RZ12 (RFC Server Group)
RZ70 (SLD Configuration)
RZ04 (Operation Mode)
SM63 (Time Table)
SCC4 (Clients Overview)
SPAM (Package level)

5. Stop the SAP Instance, Oracle and Oracle services.


6. Delete the directories on the QAS system
è Delete directories sapdata1, 2, 3, 4, 5, 6 (keep the tree structure D:\oracle\QAS).
è Delete files redolog and mirrorlog (keep the tree structure)
è Delete the three control files oracle (keep the tree structure)
è Delete files from the directories sapbackup, sapcheck, sapreorg, saptrace\background,
saptrace\usertrace (keep the tree structure).
7. Copy the sapbackup folder from PRD, along with the control.sql file pasted on the Desktop to QAS
(\oracle\QAS\sapbackup).
8. Open the .afd /.and backup file (Eg.: bdjvujux.afd) present in sapbackup directory. Replace the PRD with
the QAS and save it.
9. Go to \oracle\QAS\sapbackup\xxxx (Eg.: bdjvujux) backup file name folder location. Rename the files with
PRD to QAS.
10. Start -> Run -> cmd. Goto the location \oracle\QAS\sapbackup and type :
brrestore –m full –b <filename> -c -d disk
Backup is restored successfully.

11. Check the presence of the paths for the creation of the control files oracle

\oracle\QAS\origloga\cntrl
\oracle\QAS\origlogb\cntrl
\oracle\QAS\sapdata1\cntrl

If one of these paths is not present, create it.

12. Start the Oracle services.

13. Login to sql from the location where the control.sql file is located.
@control.sql not created GOTO \oracle\QAS\origloga\cntrl
\oracle\QAS\origlogb\cntrl
\oracle\QAS\sapdata1\cntrl

In these files romove the contrl files and goto cmd prompt

After the control file is created, the Oracle is in Mounted state.


Now, the database is open status.

You can view the PRD OPS$ users in the above screen.
Goto location: C:\Program Files\sapinst_instdir\ERP\SYSTEM\ORA\CENTRAL\AS. Copy the ORADBUSR.SQL
file and paste it in \oracle\QAS\sapbackup\
Execute the ORADBUSR.SQL file and provide the inputs as follows:

Enter value for 1: SAPR3


Enter value for 2: NT
Enter value for 3: Target Hostname
Enter value for 4: Target <SID> ie.. QAS
Login to SQL and check the users.

Drop the Source System users ie.. PRD user’s.


Below screen displays the list of user’s available after dropping PRD user’s.

Provide permissions to the following QAS user’s as mentioned in the below screen.
Start the SAP instance or MMC.

Install the License for the QAS system and remove the PRD system license..
saplicense –show (Displays the licenses of both QAS and PRD systems.)
saplicense –delete (Delete the PRD system license).
saplicense –install (Install license for the QAS system).

Login through Client - 000 and User – SAP*.

Perform post installation activities as shown below.

1. SICK
2. SE06 and select “Database copy or Database migration” option. Click Perform Post-Installation Actions.

Click Yes.
Accept the source system.

Click Yes.

Accept.

Click Yes.

Click Yes.
Click Yes.

3. Configure STMS. Run TC-STMS.

NOTE: Here we are considering the system (NAG) as Domain Controller. If it is a child system, include that system
into the Domain Controller as per below screen.
3. Run RZ10

Select Extended maintenance and click on Display button


To delete profiles of PRD system. For that follow the below path
Profile -> Delete -> All versions -> Of a profile

Click Yes
Click No

Click on continue
Similarly delete Start profile and Default profile. As shown above screens.
After deleting all profiles of the PRD system then import profiles of NAG system by using below path.

Go to Utilities -> Import profile -> Of a active servers.

Você também pode gostar