Page 1 of 1

Problem moving offline archives to backup (RDB/Oracle)

Posted: Wed Nov 27, 2019 1:44 pm
by jimtaylor
Hi,

I am having problems with RDB/Oracle not being able to move Offline archives to the backup area. This is from the panel:

System Management -> Database -> RDB Archive Groups -> Manual Export / Import

All the controls under the left table work fine, I can set archives online & offline, and manually start a new archive. However, when I select an offline archive and click the -> arrow, it does not move to the backup area. I get the popup with the progress bar and the message saying backing up, but then the popup closes and no archives have moved.

In the WinCC OA log I can see that a new Ctrl manager is starting up, but there are no errors being raised.

Can you give me any ideas as to why this might not be working?

Thanks,

Jim

Re: Problem moving offline archives to backup (RDB/Oracle)

Posted: Thu Nov 28, 2019 9:31 am
by jimtaylor
A bit more information: we are running v3.16 patch 12 and Oracle 12.2.0.1.

Like I said, the WinCC OA log is not throwing up any errors, but after digging around on the internet, it seems that the ARC_LOG table is a good place to find any Oracle errors. Sure enough, there are 3 errors in the ARC_LOG table whenever I click the "->" button to try to move an offline archive to the backup.

Do the following ARC_LOG errors help shed light on what the issue might be?

Thanks

Error 1

Code: Select all

PROGRAM
CopyBaseSet(TREND, 100033)

ORA_CODE
ORA-00376: file 42 cannot be read at this time

INFO
Could not copy base set!
insert /*+ APPEND */ into TRENDHISTORYVALUES_00100034 (ELEMENT_ID,TS,POSITION,VALUE_DYNNUMBER,SYS_ID,BASE,VALUE_DYNSTRING,VALUE_DYNTIMESTAMP,CORRVALUE_DYNNUMBER,OLVALUE_DYNNUMBER,CORRVALUE_DYNSTRING,OLVALUE_DYNSTRING,CORRVALUE_DYNTIMESTAMP,OLVALUE_DYNTIMESTAMP,MODIFIED_TIME,VALTYPE)
 select ELEMENT_ID,TS,POSITION,VALUE_DYNNUMBER,SYS_ID,'1',VALUE_DYNSTRING,VALUE_DYNTIMESTAMP,CORRVALUE_DYNNUMBER,OLVALUE_DYNNUMBER,CORRVALUE_DYNSTRING,OLVALUE_DYNSTRING,CORRVALUE_DYNTIMESTAMP,OLVALUE_DYNTIMESTAMP,MODIFIED_TIME,VALTYPE from TRENDHISTORYVALUES_00100033 where (element_id, ts) in  (select element_id, max(ts) from TRENDHISTORYVALUES_00100033 group by element_id)

ERRORSTACK
ORA-00376: file 42 cannot be read at this time
ORA-01110: data file 42: 'C:\APP\ORACLEHOME\ORADATA\WINCCOA\OA_RDB_TREND_00100033.DBF'
ORA-06512: at "OA_RDB.ARCHIVECONTROL", line 1812
----- PL/SQL Call Stack -----
  object      line  object
  handle    number  name
00007FFA219B1A70        61  package body OA_RDB.ARCUTILS.ARCLOG
00007FFA219E7128      1820  package body OA_RDB.ARCHIVECONTROL.COPYBASESET
00007FFA219E7128      3345  package body OA_RDB.ARCHIVECONTROL.BACKUPARC
00007FFA18CE51E0         2  anonymous block
Error 2

Code: Select all

PROGRAM
**Java** SystemCall(C:\app\oraclehome\product\12.2.0\client_1\bin\rman @C:\Users\ORACLE~1\AppData\Local\Temp\rman.scr, true)

ORA_CODE
(null)

INFO
Exception: Cannot run program "C:\app\oraclehome\product\12.2.0\client_1\bin\rman": 
The handle is invalid.

ERRORSTACK
(null)
Error 3

Code: Select all

PROGRAM
BackupArc(TREND, 100033)

ORA_CODE
ORA-20122: Error occurred during RMAN-Backup of Datafile

INFO
Could not backup Archive (internal error-code -4, return value -1): 

ERRORSTACK
ORA-20122: Error occurred during RMAN-Backup of Datafile
ORA-06512: at "OA_RDB.ARCHIVECONTROL", line 3406
----- PL/SQL Call Stack -----
  object      line  object
  handle    number  name
00007FFA219B1A70        61  package body OA_RDB.ARCUTILS.ARCLOG
00007FFA219E7128      3566  package body OA_RDB.ARCHIVECONTROL.BACKUPARC
00007FFA18CE51E0         2  anonymous block

Re: Problem moving offline archives to backup (RDB/Oracle)

Posted: Fri Nov 29, 2019 4:57 pm
by jimtaylor
We managed to trace the cause of this issue and I'm happy to say it is now resolved. The second error message was the clue: C:\app\oraclehome\product\12.2.0\client_1\bin\rman.

It seems that during the original RDB installation the RDB_config.sql file had been set up to point at the Oracle bin directory on the WinCC OA server (which is an Oracle client) instead of the Oracle server. With the path_oraclebin field in the RDB_config.sql file corrected to 'C:\app\oraclehome\product\12.2.0\dbhome_1\bin\', the moving of offline archives to the backup folder is now working.

So strange that the rest of the RDB/Oracle archiving worked fine even though this parameter was incorrect all along, and no errors appeared in the WinCC OA log. Anyway, it is working now. Maybe this post is useful to someone else in the future.

Re: Problem moving offline archives to backup (RDB/Oracle)

Posted: Thu Dec 05, 2019 8:23 am
by eivanovic
Hi Jim,

Just for an explanation why rdb still was working and writing values. The Values are written over the oracle client into the database, who always talks to the listener of the oracle server. The path which is entered in the config entry is only needed for the serverside of Oracle. There are Oracle jobs (needed for the file switch and the backup) running on the Oracle server. They need to know where the path for the oracle binaries is located.

Hope this explains it a bit.

BR
Emanuel