Log missing
Hi,
I am working in Oracle standby database 11g on HP-UX. Some of the archive logs are missing in the standby site.
For ex.. the log sequence from 1 to 10... sequence # 6 and 7 are missing...
Kindly share me how to find the missing logs (from and to sequence#) which are not in RFS also.
Rgds...
you need to be sure what logs has not been applied yet by
select sequence#,status from v$archived_log
where applied='NO'To resolve this issue either rollforward yours standby database by having incremental backup at primary (if you dont have those lgo at primary database too) and recover it or copy those missing archivelog (if availiable at primary) to standby database register those log and then put standby database in recovery mode.
Khurram
Similar Messages
-
Hi Experts
We have a peculiar problem where change logs are missing for some of the transactions made through OB52 for modifying FI posting periods.
I vefired that change logging has been correctly activated for table T001B. Though change logs are displayed for most of the transactions through SCU3 or in table DBTABLOG, logs will be missing for some records.
Can you please let us know what could be the possible scenarios where change logs are not recorded for OB52 or table T001B even though logging has been activated.
Any inputs on this will be very helpful.
Regards,
Santoshtry log on tcode S_ALR_87003642
-
Vmware.log missing information
Hi!
I was wondering if somebody can please enlighten me, I have noticed some of the information is missing from vmware.log file on the VM.
For eg: I am investigating if there was any problem on 2015-03-12T15:00:00 but the log is stopping at 2015-03-12T13:18:50 and then continues onto the next day to 2015-03-13T08:23:54.?
The log file is over 1GiB and the VM is a mail server with DAG. Any help or pointers would be greatly appreciated.
Thanks in advance.Hi,
According to your description, your audit log may have some entries which are lost. Firstly, I’d like to confirm if all results can be get after you set the search level.
Based on my research, Administrator audit logging relies on Active Directory replication to replicate the configuration settings you specify to the domain controllers in your organization. Depending on your replication settings, the changes you make may
not be immediately applied to all servers running Exchange 2010 in your organization. Thus, if there are multiple AD sites, we can check if there is something wrong with AD replication.
Additionally, we can also check if there is any related error in your event log.
Thanks,
Angela Shi
TechNet Community Support -
Archived log missed in standby database
Hi,
OS; Windows 2003 server
Oracle: 10.2.0.4
Data Guard: Max Performance
Dataguard missed some of the archivelog files and but latest log files are applying. standby database is not in sync with primary.
SELECT LOCAL.THREAD#, LOCAL.SEQUENCE# FROM (SELECT THREAD#, SEQUENCE# FROM V$ARCHIVED_LOG WHERE DEST_ID=1) LOCAL WHERE LOCAL.SEQUENCE# NOT IN (SELECT SEQUENCE# FROM V$ARCHIVED_LOG WHERE DEST_ID=2 AND THREAD# = LOCAL.THREAD#);
I queried above command and I found some files are missed in standby.
select status, type, database_mode, recovery_mode,protection_mode, srl, synchronization_status,synchronized from V$ARCHIVE_DEST_STATUS where dest_id=2;
STATUS TYPE DATABASE_MODE RECOVERY_MODE PROTECTION_MODE SRL SYNCHRONIZATION_STATUS SYN
VALID PHYSICAL MOUNTED-STANDBY MANAGED MAXIMUM PERFORMANCE NO CHECK CONFIGURATION NO
Anyone can tell me how to apply those missed archive log files.
Thanks in advacneDeccan Charger wrote:
I got below error.
SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE DISCONNECT FROM SESSION;
ALTER DATABASE RECOVER MANAGED STANDBY DATABASE DISCONNECT FROM SESSION
ERROR at line 1:
ORA-01153: an incompatible media recovery is activeYou need to essentially do the following.
1) Stop managed recovery on the standby.
ALTER DATABASE RECOVER MANAGED STANDBY DATABASE CANCEL;2) Resolve the archive log gap - if you have configured FAL_SERVER and FAL_CLIENT Oracle should do this when you follow step 3 below, as you've manually copied the missed logs you should be OK
3) restart managed recovery using the command shown above.
You can monitor archive log catchup using the alert.log or your original query.
Niall Litchfield
http://www.orawin.info/
Edited by: Niall Litchfield on May 4, 2010 2:29 PM
missed tag -
Archive log missing on standby: FAL[client]: Failed to request gap sequence
My current environment is Oracle 10.2.0.4 with ASM 10.2.0.4 on a 2 node RAC in production and a standby that is the same setup. I'm also running on Oracle Linux 5. Almost daily now an archivelog doesnt make it to the standby and oracle doesnt seem to resolve the gap sequence from the primary. If I stop and restart recovery it gets the logfile and continues recovery just fine. I have checked my fal_client and fal_server settings and they look good. The logs after this error do continue to get written to the standby but the standby wont continue recovery until I stop and restart recovery and it fetches this missing log.
The only thing I know thats happening is that the firewall people are disconnecting any connections that are inactive for 60 minutes and recently did an upgrade that they are claiming didnt change anything:) I dont know if this is causing this problem or not. Any thoughts on what might be happening?
Error in standby alert.log:
Tue Jun 29 23:15:35 2010
RFS[258]: Possible network disconnect with primary database
Tue Jun 29 23:15:36 2010
Fetching gap sequence in thread 2, gap sequence 9206-9206
Tue Jun 29 23:16:46 2010
FAL[client]: Failed to request gap sequence
GAP - thread 2 sequence 9206-9206
DBID 661398854 branch 714087609
FAL[client]: All defined FAL servers have been attempted.
Error on primary alert.log:
Tue Jun 29 23:00:07 2010
ARC0: Creating remote archive destination LOG_ARCHIVE_DEST_2: 'WSSPRDB' (thread 1 sequence 9265)
(WSSPRD1)
ARC0: Transmitting activation ID 0x29c37469
Tue Jun 29 23:00:07 2010
Errors in file /u01/app/oracle/admin/WSSPRD/bdump/wssprd1_arc0_14024.trc:
ORA-03135: connection lost contact
FAL[server, ARC0]: FAL archive failed, see trace file.
Tue Jun 29 23:00:07 2010
Errors in file /u01/app/oracle/admin/WSSPRD/bdump/wssprd1_arc0_14024.trc:
ORA-16055: FAL request rejected
ARCH: FAL archive failed. Archiver continuing
Tue Jun 29 23:00:07 2010
ORACLE Instance WSSPRD1 - Archival Error. Archiver continuing.
Tue Jun 29 23:00:41 2010
Redo Shipping Client Connected as PUBLIC
-- Connected User is Valid
Tue Jun 29 23:00:41 2010
FAL[server, ARC2]: Begin FAL archive (dbid 0 branch 714087609 thread 2 sequence 9206 dest WSSPRDB)
FAL[server, ARC2]: FAL archive failed, see trace file.
Tue Jun 29 23:00:43 2010
Errors in file /u01/app/oracle/admin/WSSPRD/bdump/wssprd1_arc2_14028.trc:
ORA-16055: FAL request rejected
ARCH: FAL archive failed. Archiver continuing
Tue Jun 29 23:00:43 2010
ORACLE Instance WSSPRD1 - Archival Error. Archiver continuing.
Tue Jun 29 23:01:16 2010
Redo Shipping Client Connected as PUBLIC
-- Connected User is Valid
Tue Jun 29 23:15:01 2010
Thread 1 advanced to log sequence 9267 (LGWR switch)
I have checked the trace files that get spit out but they arent anything meaningful to me as to whats really happening. Snipit of the trace file:
tkcrrwkx: Starting to process work request
tkcrfgli: SRL header: 0
tkcrfgli: SRL tail: 0
tkcrfgli: ORL to arch: 4
tkcrfgli: le# seq thr for bck tba flags
tkcrfgli: 1 359 1 2 0 3 0x0008 ORL active cur
tkcrfgli: 2 358 1 0 1 1 0x0000 ORL active
tkcrfgli: 3 361 2 4 0 0 0x0008 ORL active cur
tkcrfgli: 4 360 2 0 3 2 0x0000 ORL active
tkcrfgli: 5 -- entry deleted --
tkcrfgli: 6 -- entry deleted --
tkcrfgli: 7 -- entry deleted --
tkcrfgli: 8 -- entry deleted --
tkcrfgli: 9 -- entry deleted --
tkcrfgli: 191 -- entry deleted --
tkcrfgli: 192 -- entry deleted --
*** 2010-03-27 01:30:32.603 20998 kcrr.c
tkcrrwkx: Request from LGWR to perform: <startup>
tkcrrcrlc: Starting CRL ARCH check
*** 2010-03-27 01:30:32.603 66085 kcrr.c
Beginning controlfile transaction 0x0x7fffd0b53198 [kcrr.c:20395 (14011)]
*** 2010-03-27 01:30:32.645 66173 kcrr.c
Acquired controlfile transaction 0x0x7fffd0b53198 [kcrr.c:20395 (14024)]
*** 2010-03-27 01:30:32.649 66394 kcrr.c
Ending controlfile transaction 0x0x7fffd0b53198 [kcrr.c:20397]
tkcrrasgn: Checking for 'no FAL', 'no SRL', and 'HB' ARCH process
# HB NoF NoS CRL Name
29 NO NO NO NO ARC0
28 NO YES YES NO ARC1
27 NO NO NO NO ARC2
26 NO NO NO NO ARC3
25 YES NO NO NO ARC4
24 NO NO NO NO ARC5
23 NO NO NO NO ARC6
22 NO NO NO NO ARC7
21 NO NO NO NO ARC8
20 NO NO NO NO ARC9
Thanks.
KristiIt's the network that's messing up; unlikely due to firewall timeout as it waits for 60 minutes and you are switching every 15 minutes. There may be some other network glitch that needs rectified.
In any case - arch file missing/ corrupt / halfway through - FAL setting should have refetched the problematic archive log automatically.
As many had suggested already, the best way to resolve RFS issues I believe is to use real-time apply by configuring standby redo logs. It's very easy to configure it and you can opt for real-time apply even in max-performance mode that you are using right now.
Even though you are maintaining (I guess) 1-1 between primary & standby instances, you can provide both primary instances in fal_server (like fal_server=string1,string2). See if that helps.
lastly, check if you are having simiar issue at other times as well that might be getting rectified automatically as expected.
col message for a80
col time for a20
select message, to_char(timestamp,'dd-mon-rr hh24:mi:ss') time
from v$dataguard_status
where severity in ('Error','Fatal')
order by timestamp;
Cheers. -
Archive log miss : How to restart capture
Hi Gurus,
I configured hotlog CDC distributed on 10.2.0.4 Databases.
I make a mistake: in my source Db I have deleted an Archive log,
and now the state of Capture process in V_$STREAM_CAPTURE is "WAITING FOR REDO: LAST SCN MINED 930696".
Now I'd like to restart the capture process from the next archive (just after the missed archive)
How is it possible?
tnk FabioI'm sorry to tell you that, but it's not possible. (Just as it's not possible to recover database with missing logs...)
You will have to recreate the capture process and to re-instantiate the replicated tables.
Regards, -
Hi Gurus
While Configuring Data Guard for ORacle 10g (10.2.0.4) 64 bits on Windows 2007 Server 64 bits.
I got few questions
1. What is the Default mode of Standby Database?
2. Should we Always Start Physical Standby Database to Recover Missing Redo Archive Log?
SQL> startup mount;
ORACLE instance started.
Total System Global Area 591396864 bytes
Fixed Size 2067496 bytes
Variable Size 163578840 bytes
Database Buffers 419430400 bytes
Redo Buffers 6320128 bytes
Database mounted.
SQL> alter databse recover managed standby database disconnect from session;
Database altered.
3. When there are missing Redo Log Archives e.g.
----On Standby Database--------
SQL> SELECT RESETLOGS_ID,SEQUENCE#,STATUS,ARCHIVED FROM V$ARCHIVED_LOG
2 ORDER BY RESETLOGS_ID,SEQUENCE#;
RESETLOGS_ID SEQUENCE# S ARC
812980008 15 A YES
812980008 16 A YES
812980008 17 A YES
812980008 18 A YES
812980008 19 A YES
812980008 20 A YES
812980008 21 A YES
812980008 22 A YES
812980008 23 A YES
812980008 24 A YES
812980008 25 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 26 A YES
812980008 27 A YES
812980008 28 A YES
812980008 29 A YES
812980008 30 A YES
812980008 31 A YES
812980008 32 A YES
812980008 33 A YES
812980008 34 A YES
812980008 35 A YES
812980008 36 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 37 A YES
812980008 38 A YES
812980008 39 A YES
812980008 40 A YES
812980008 41 A YES
812980008 42 A YES
812980008 43 A YES
29 rows selected.
---------------On Primary Database---------------------
SQL> SELECT RESETLOGS_ID,SEQUENCE#,STATUS,ARCHIVED FROM V$ARCHIVED_LOG
2 ORDER BY RESETLOGS_ID,SEQUENCE# ;
RESETLOGS_ID SEQUENCE# S ARC
*812980008 8 A YES*
*812980008 9 A YES*
*812980008 10 A YES*
*812980008 11 A YES*
*812980008 12 A YES*
*812980008 13 A YES*
*812980008 14 A YES*
812980008 15 A YES
812980008 15 A YES
812980008 16 A YES
812980008 16 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 17 A YES
812980008 17 A YES
812980008 18 A YES
812980008 18 A YES
812980008 19 A YES
812980008 19 A YES
812980008 20 A YES
812980008 20 A YES
812980008 21 A YES
812980008 21 A YES
812980008 22 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 22 A YES
812980008 23 A YES
812980008 23 A YES
812980008 24 A YES
812980008 24 A YES
812980008 25 A YES
812980008 25 A YES
812980008 26 A YES
812980008 26 A YES
812980008 27 A YES
812980008 27 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 28 A YES
812980008 28 A YES
812980008 29 A YES
812980008 29 A YES
812980008 30 A YES
812980008 30 A YES
812980008 31 A YES
812980008 31 A YES
812980008 32 A YES
812980008 32 A YES
812980008 33 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 33 A YES
812980008 34 A YES
812980008 34 A YES
812980008 35 A YES
812980008 35 A YES
812980008 36 A YES
812980008 36 A YES
812980008 37 A YES
812980008 37 A YES
812980008 38 A YES
812980008 38 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 39 A YES
812980008 39 A YES
812980008 40 A YES
812980008 40 A YES
812980008 41 A YES
812980008 41 A YES
812980008 42 A YES
812980008 42 A YES
812980008 43 A YES
812980008 43 A YES
65 rows selected.
Log 8, 9, 10, 11, 12, 13, 14, 15 are missing.
How to Apply / Recover These Logs on Standby Database?
Regards
Thunder2777Hi
Thunder2777 wrote:
Hi Gurus
While Configuring Data Guard for ORacle 10g (10.2.0.4) 64 bits on Windows 2007 Server 64 bits.
I got few questions
1. What is the Default mode of Standby Database?
What is default mode? I think you want ask in what mode standby database is apply redo logs.
Standby database can apply received redo only MOUNT mode, (your version is 10g, after 11g can apply open mode with READ ONLY WITH APPLY)
2. Should we Always Start Physical Standby Database to Recover Missing Redo Archive Log?
If Standby database opened mount mode, then database can receive redo.
If you are start Redo Apply then MPR can request from primary for missing redo logs.
SQL> startup mount;
ORACLE instance started.
Total System Global Area 591396864 bytes
Fixed Size 2067496 bytes
Variable Size 163578840 bytes
Database Buffers 419430400 bytes
Redo Buffers 6320128 bytes
Database mounted.
SQL> alter databse recover managed standby database disconnect from session;
Database altered.
It is started recovery, in other words Redo Apply (MRP0 process)
>
3. When there are missing Redo Log Archives e.g.
----On Standby Database-------->
SQL> SELECT RESETLOGS_ID,SEQUENCE#,STATUS,ARCHIVED FROM V$ARCHIVED_LOG
2 ORDER BY RESETLOGS_ID,SEQUENCE#;
RESETLOGS_ID SEQUENCE# S ARC
812980008 15 A YES
812980008 16 A YES
812980008 17 A YES
812980008 18 A YES
812980008 19 A YES
812980008 20 A YES
812980008 21 A YES
812980008 22 A YES
812980008 23 A YES
812980008 24 A YES
812980008 25 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 26 A YES
812980008 27 A YES
812980008 28 A YES
812980008 29 A YES
812980008 30 A YES
812980008 31 A YES
812980008 32 A YES
812980008 33 A YES
812980008 34 A YES
812980008 35 A YES
812980008 36 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 37 A YES
812980008 38 A YES
812980008 39 A YES
812980008 40 A YES
812980008 41 A YES
812980008 42 A YES
812980008 43 A YES
29 rows selected.
---------------On Primary Database---------------------
SQL> SELECT RESETLOGS_ID,SEQUENCE#,STATUS,ARCHIVED FROM V$ARCHIVED_LOG
2 ORDER BY RESETLOGS_ID,SEQUENCE# ;
RESETLOGS_ID SEQUENCE# S ARC
*812980008 8 A YES*
*812980008 9 A YES*
*812980008 10 A YES*
*812980008 11 A YES*
*812980008 12 A YES*
*812980008 13 A YES*
*812980008 14 A YES*
812980008 15 A YES
812980008 15 A YES
812980008 16 A YES
812980008 16 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 17 A YES
812980008 17 A YES
812980008 18 A YES
812980008 18 A YES
812980008 19 A YES
812980008 19 A YES
812980008 20 A YES
812980008 20 A YES
812980008 21 A YES
812980008 21 A YES
812980008 22 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 22 A YES
812980008 23 A YES
812980008 23 A YES
812980008 24 A YES
812980008 24 A YES
812980008 25 A YES
812980008 25 A YES
812980008 26 A YES
812980008 26 A YES
812980008 27 A YES
812980008 27 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 28 A YES
812980008 28 A YES
812980008 29 A YES
812980008 29 A YES
812980008 30 A YES
812980008 30 A YES
812980008 31 A YES
812980008 31 A YES
812980008 32 A YES
812980008 32 A YES
812980008 33 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 33 A YES
812980008 34 A YES
812980008 34 A YES
812980008 35 A YES
812980008 35 A YES
812980008 36 A YES
812980008 36 A YES
812980008 37 A YES
812980008 37 A YES
812980008 38 A YES
812980008 38 A YES
RESETLOGS_ID SEQUENCE# S ARC
812980008 39 A YES
812980008 39 A YES
812980008 40 A YES
812980008 40 A YES
812980008 41 A YES
812980008 41 A YES
812980008 42 A YES
812980008 42 A YES
812980008 43 A YES
812980008 43 A YES
65 rows selected.
Log 8, 9, 10, 11, 12, 13, 14, 15 are missing.It is no missing, you are created standby database, after sequence 15.
As you know , if a sequence redo is not applied, then after is sequenced redo log is cannot apply to standby database.
It means GAP.
There have 43 archived redo log, and your last sequenced archive log received by standby database
and applied.
You can check with following scripts, too
select max(Sequence#) from v$archived_log; -- on primary
select max(Sequence#) from v$archived_log where applied = 'YES'; - on standby Regards
Mahir M. Quluzade -
Access logs (missing)
Hi,
I'm trying to determine when a user accessed the server via AFP. I've found /Library/Logs/AppleFileService/ logs but many are missing - only the last 2 weeks are there. I also found entries in another log deleting these files since disk was full, however it only shows logs been deleted from March (it's now November) and earlier:
Fri Oct 29 11:48:44 2010: recover: About to perform action "delete" on file "/Library/Logs/AppleFileService/AppleFileServiceAccess.log 01.18.10.gz" on critical volume "Server HD" which is 4.96% full because size 0 MB >= trigger size 2 MB or age 289 >= trigger age 2 days.
Questions:
- is there any way to tell when/if AFP logging was enabled/disabled?
- is there any other way to tell if users logged in via AFP (accessed a share)?
- any ideas why April-October logs would be missing?
Thanks!The only other way I found would be to use :
%Req->reqpb.method% %Req->reqpb.uri% instead of %Req->reqpb.clf-request%, that way the protocol just wouldn't be logged! My log analyser (Awstats 5.6) would then be able to crunch them by NOT checking for a protocol with the %methodurlnoproto parameter in awstats.
This is causing me yet another problem. With only the URI, I don't have the querystring. Of course, it is possible to use %Req->reqpb.query%, but this isn't linked to the URI in the log. I need to hardcode a '?' between the two. Therefor, I would also get requests such as '/foo.htm?' logged.
Another problem I seem to be having when using just the URI is that iPlanet seems to get only the first 128 caracteres from the request. After that numbers, it cuts off the URI.
I'm a bit confused here on what's the best solution...
Pat. -
Redo Log Missing + AWR Reports
Hi Techies,
1)how to start up the database, if my active group of redo is missing or corrupted. can you please suggest me with steps?
2)What are the main things we need look in the AWR reports. (How to analyze the AWR reports)
Thanks,
TippuHi,
1)how to start up the database, if my active group of redo is missing or corrupted. can you please suggest me with steps?If your last shutdown was clean then you can follow these steps...
1. Start mount
2. Alter database recover until cancel;-------just a fake recovery...nothing done if your database was shutdown cleanly..
3. Alter database open resetlogs;......This step will recreate the missing or corrupted redo logs
4. Backup your database
2)What are the main things we need look in the AWR reports. (How to analyze the AWR reports)Go through the link http://www.nyoug.org/Presentations/2008/Sep/Ault_AWR.pdf
Regards -
Capture process issue...archive log missing!!!!!
Hi,
Oracle Streams capture process is alternating between INITIALIZING and DICTIONARY INITIALIZATION state and not proceeding after this state to capture updates made on table.
we have accidentally missing archivelogs and no backup archive logs.
Now I am going to recreate the capture process again.
How I can start the the capture process from new SCN ?
And Waht is the batter way to remove the archive log files from central server, because
SCN used by capture processes?
Thanks,
Faziarain
Edited by: [email protected] on Aug 12, 2009 12:27 AMUsing dbms_Streams_Adm to add a capture, perform also a dbms_capture_adm.build. You will see in v$archived_log at the column dictionary_begin a 'yes', which means that the first_change# of this archivelog is first suitable SCN for starting capture.
'rman' is the prefered way in 10g+ to remove the archives as it is aware of streams constraints. If you can't use rman to purge the archives, then you need to check the min required SCN in your system by script and act accordingly.
Since 10g, I recommend to use rman, but nevertheless, here is the script I made in 9i in the old time were rman was eating the archives needed by Streams with appetite.
#!/usr/bin/ksh
# program : watch_arc.sh
# purpose : check your archive directory and if actual percentage is > MAX_PERC
# then undertake the action coded by -a param
# Author : Bernard Polarski
# Date : 01-08-2000
# 12-09-2005 : added option -s MAX_SIZE
# 20-11-2005 : added option -f to check if an archive is applied on data guard site before deleting it
# 20-12-2005 : added option -z to check if an archive is still needed by logminer in a streams operation
# set -xv
#--------------------------- default values if not defined --------------
# put here default values if you don't want to code then at run time
MAX_PERC=85
ARC_DIR=
ACTION=
LOG=/tmp/watch_arch.log
EXT_ARC=
PART=2
#------------------------- Function section -----------------------------
get_perc_occup()
cd $ARC_DIR
if [ $MAX_SIZE -gt 0 ];then
# size is given in mb, we calculate all in K
TOTAL_DISK=`expr $MAX_SIZE \* 1024`
USED=`du -ks . | tail -1| awk '{print $1}'` # in Kb!
else
USED=`df -k . | tail -1| awk '{print $3}'` # in Kb!
if [ `uname -a | awk '{print $1}'` = HP-UX ] ;then
TOTAL_DISK=`df -b . | cut -f2 -d: | awk '{print $1}'`
elif [ `uname -s` = AIX ] ;then
TOTAL_DISK=`df -k . | tail -1| awk '{print $2}'`
elif [ `uname -s` = ReliantUNIX-N ] ;then
TOTAL_DISK=`df -k . | tail -1| awk '{print $2}'`
else
# works on Sun
TOTAL_DISK=`df -b . | sed '/avail/d' | awk '{print $2}'`
fi
fi
USED100=`expr $USED \* 100`
USG_PERC=`expr $USED100 / $TOTAL_DISK`
echo $USG_PERC
#------------------------ Main process ------------------------------------------
usage()
cat <<EOF
Usage : watch_arc.sh -h
watch_arc.sh -p <MAX_PERC> -e <EXTENTION> -l -d -m <TARGET_DIR> -r <PART>
-t <ARCHIVE_DIR> -c <gzip|compress> -v <LOGFILE>
-s <MAX_SIZE (meg)> -i <SID> -g -f
Note :
-c compress file after move using either compress or gzip (if available)
if -c is given without -m then file will be compressed in ARCHIVE DIR
-d Delete selected files
-e Extention of files to be processed
-f Check if log has been applied, required -i <sid> and -g if v8
-g Version 8 (use svrmgrl instead of sqlplus /
-i Oracle SID
-l List file that will be processing using -d or -m
-h help
-m move file to TARGET_DIR
-p Max percentage above wich action is triggered.
Actions are of type -l, -d or -m
-t ARCHIVE_DIR
-s Perform action if size of target dir is bigger than MAX_SIZE (meg)
-v report action performed in LOGFILE
-r Part of files that will be affected by action :
2=half, 3=a third, 4=a quater .... [ default=2 ]
-z Check if log is still needed by logminer (used in streams),
it requires -i <sid> and also -g for Oracle 8i
This program list, delete or move half of all file whose extention is given [ or default 'arc']
It check the size of the archive directory and if the percentage occupancy is above the given limit
then it performs the action on the half older files.
How to use this prg :
run this file from the crontab, say, each hour.
example
1) Delete archive that is sharing common arch disk, when you are at 85% of 2500 mega perform delete half of the files
whose extention is 'arc' using default affected file (default is -r 2)
0,30 * * * * /usr/local/bin/watch_arc.sh -e arc -t /arc/POLDEV -s 2500 -p 85 -d -v /var/tmp/watch_arc.POLDEV.log
2) Delete archive that is sharing common disk with oother DB in /archive, act when 90% of 140G, affect by deleting
a quater of all files (-r 4) whose extention is 'dbf' but connect before as sysdba in POLDEV db (-i) if they are
applied (-f is a dataguard option)
watch_arc.sh -e dbf -t /archive/standby/CITSPRD -s 140000 -p 90 -d -f -i POLDEV -r 4 -v /tmp/watch_arc.POLDEV.log
3) Delete archive of DB POLDEV when it reaches 75% affect 1/3 third of files, but connect in DB to check if
logminer do not need this archive (-z). this is usefull in 9iR2 when using Rman as rman do not support delete input
in connection to Logminer.
watch_arc.sh -e arc -t /archive/standby/CITSPRD -p 75 -d -z -i POLDEV -r 3 -v /tmp/watch_arc.POLDEV.log
EOF
#------------------------- Function section -----------------------------
if [ "x-$1" = "x-" ];then
usage
exit
fi
MAX_SIZE=-1 # disable this feature if it is not specificaly selected
while getopts c:e:p:m:r:s:i:t:v:dhlfgz ARG
do
case $ARG in
e ) EXT_ARC=$OPTARG ;;
f ) CHECK_APPLIED=YES ;;
g ) VERSION8=TRUE;;
i ) ORACLE_SID=$OPTARG;;
h ) usage
exit ;;
c ) COMPRESS_PRG=$OPTARG ;;
p ) MAX_PERC=$OPTARG ;;
d ) ACTION=delete ;;
l ) ACTION=list ;;
m ) ACTION=move
TARGET_DIR=$OPTARG
if [ ! -d $TARGET_DIR ] ;then
echo "Dir $TARGET_DIR does not exits"
exit
fi;;
r) PART=$OPTARG ;;
s) MAX_SIZE=$OPTARG ;;
t) ARC_DIR=$OPTARG ;;
v) VERBOSE=TRUE
LOG=$OPTARG
if [ ! -f $LOG ];then
> $LOG
fi ;;
z) LOGMINER=TRUE;;
esac
done
if [ "x-$ARC_DIR" = "x-" ];then
echo "NO ARC_DIR : aborting"
exit
fi
if [ "x-$EXT_ARC" = "x-" ];then
echo "NO EXT_ARC : aborting"
exit
fi
if [ "x-$ACTION" = "x-" ];then
echo "NO ACTION : aborting"
exit
fi
if [ ! "x-$COMPRESS_PRG" = "x-" ];then
if [ ! "x-$ACTION" = "x-move" ];then
ACTION=compress
fi
fi
if [ "$CHECK_APPLIED" = "YES" ];then
if [ -n "$ORACLE_SID" ];then
export PATH=$PATH:/usr/local/bin
export ORAENV_ASK=NO
export ORACLE_SID=$ORACLE_SID
. /usr/local/bin/oraenv
fi
if [ "$VERSION8" = "TRUE" ];then
ret=`svrmgrl <<EOF
connect internal
select max(sequence#) from v\\$log_history ;
EOF`
LAST_APPLIED=`echo $ret | sed 's/.*------ \([^ ][^ ]* \).*/\1/' | awk '{print $1}'`
else
ret=`sqlplus -s '/ as sysdba' <<EOF
set pagesize 0 head off pause off
select max(SEQUENCE#) FROM V\\$ARCHIVED_LOG where applied = 'YES';
EOF`
LAST_APPLIED=`echo $ret | awk '{print $1}'`
fi
elif [ "$LOGMINER" = "TRUE" ];then
if [ -n "$ORACLE_SID" ];then
export PATH=$PATH:/usr/local/bin
export ORAENV_ASK=NO
export ORACLE_SID=$ORACLE_SID
. /usr/local/bin/oraenv
fi
var=`sqlplus -s '/ as sysdba' <<EOF
set pagesize 0 head off pause off serveroutput on
DECLARE
hScn number := 0;
lScn number := 0;
sScn number;
ascn number;
alog varchar2(1000);
begin
select min(start_scn), min(applied_scn) into sScn, ascn from dba_capture ;
DBMS_OUTPUT.ENABLE(2000);
for cr in (select distinct(a.ckpt_scn)
from system.logmnr_restart_ckpt\\$ a
where a.ckpt_scn <= ascn and a.valid = 1
and exists (select * from system.logmnr_log\\$ l
where a.ckpt_scn between l.first_change# and l.next_change#)
order by a.ckpt_scn desc)
loop
if (hScn = 0) then
hScn := cr.ckpt_scn;
else
lScn := cr.ckpt_scn;
exit;
end if;
end loop;
if lScn = 0 then
lScn := sScn;
end if;
select min(sequence#) into alog from v\\$archived_log where lScn between first_change# and next_change#;
dbms_output.put_line(alog);
end;
EOF`
# if there are no mandatory keep archive, instead of a number we just get the "PLS/SQL successfull"
ret=`echo $var | awk '{print $1}'`
if [ ! "$ret" = "PL/SQL" ];then
LAST_APPLIED=$ret
else
unset LOGMINER
fi
fi
PERC_NOW=`get_perc_occup`
if [ $PERC_NOW -gt $MAX_PERC ];then
cd $ARC_DIR
cpt=`ls -tr *.$EXT_ARC | wc -w`
if [ ! "x-$cpt" = "x-" ];then
MID=`expr $cpt / $PART`
cpt=0
ls -tr *.$EXT_ARC |while read ARC
do
cpt=`expr $cpt + 1`
if [ $cpt -gt $MID ];then
break
fi
if [ "$CHECK_APPLIED" = "YES" -o "$LOGMINER" = "TRUE" ];then
VAR=`echo $ARC | sed 's/.*_\([0-9][0-9]*\)\..*/\1/' | sed 's/[^0-9][^0-9].*//'`
if [ $VAR -gt $LAST_APPLIED ];then
continue
fi
fi
case $ACTION in
'compress' ) $COMPRESS_PRG $ARC_DIR/$ARC
if [ "x-$VERBOSE" = "x-TRUE" ];then
echo " `date +%d-%m-%Y' '%H:%M` : $ARC compressed using $COMPRESS_PRG" >> $LOG
fi ;;
'delete' ) rm $ARC_DIR/$ARC
if [ "x-$VERBOSE" = "x-TRUE" ];then
echo " `date +%d-%m-%Y' '%H:%M` : $ARC deleted" >> $LOG
fi ;;
'list' ) ls -l $ARC_DIR/$ARC ;;
'move' ) mv $ARC_DIR/$ARC $TARGET_DIR
if [ ! "x-$COMPRESS_PRG" = "x-" ];then
$COMPRESS_PRG $TARGET_DIR/$ARC
if [ "x-$VERBOSE" = "x-TRUE" ];then
echo " `date +%d-%m-%Y' '%H:%M` : $ARC moved to $TARGET_DIR and compressed" >> $LOG
fi
else
if [ "x-$VERBOSE" = "x-TRUE" ];then
echo " `date +%d-%m-%Y' '%H:%M` : $ARC moved to $TARGET_DIR" >> $LOG
fi
fi ;;
esac
done
else
echo "Warning : The filesystem is not full due to archive logs !"
exit
fi
elif [ "x-$VERBOSE" = "x-TRUE" ];then
echo "Nothing to do at `date +%d-%m-%Y' '%H:%M`" >> $LOG
fi -
Missing NoClassDefFoundError if Commons Logging missing
hi
If you create a project in JDeveloper with a simple jspx page, you end up with the "Commons Logging 1.0.3" library in that project.
If you remove this "Commons Logging 1.0.3" library from the project (for an unknown reason we ended up having such a project with that library missing) and you run the jspx page you get "no output".
With "no output" I mean:
- no response in the browser to the request
- no error messages in the "Embedded OC4J Server - Log" panel
If you get "no output" it is very hard to find out what is going wrong. We lost a lot of time on this issue an only found it almost by accident.
- my questions:
Is there an explanation why there is "no output"? I would expect something like a NoClassDefFoundError.
What should have been our approach to find out what was going on?
(using JDeveloper 10.1.3.1.0.3984)
many thanks
Jan VerveckenThanks for your reply Frank.
If you refer to "application.log" and "<x>-oc4j-app.log", they showed no errors, only "Started" messages.
Yes, this is reproducible.
regards
Jan -
"com.tssap.sap.libs.logging" missing in tutorial #11
Hello I try to run tutorial #11: Developing with tables.
Trying to deploy an run i get the error: library missing:
com.tssap.sap.libs.logging\lib\jarm.jar
Where can i get the plun-in?
Thanks, Mariohi mario,
btw the plugin is change to this already...
try to find it in
<b>C:\Program Files\SAP\IDE\IDE70\eclipse\plugins</b>
find this folder...
<b><u>com.tssap.sap.libs.logging_2.0.0</u></b> instead of this <b>com.tssap.sap.libs.logging</b>
then inside lib folder there is a file call jARM.jar
hope this reply help u...
Regard
Ng Jia Jun -
Hello,
I'm receiving this error while logging my ACL's. %SEC-6-IPACCESSLOGRL: access-list logging rate-limited or missed XX pacckets.
I know that this means the logging is not reporting some packets, but how would you resolve this issue? I'm logging to syslog, would using a buffer on the routers or switch with this issue resolve it?
ThanksI think you're just trying to log too much at once. The devices resources are limited and you're over working it.
You could try to be more selective as to what you want to log. I typically only log ACL entries for debugging purposes.
Other than that, maybe someone else can give a better technical solution. -
9300i will not log missed/dialled/received calls
My communicator does not want to log calls on the 'phone screen. It does log all details on the internal screen. If I had a missed call I would nver know as it does not state "Missed Call". My other Nokia 'phones have alays done this as a default. I wonder if it is a phone settings issue or something to do with SIM card settings (Orange).
try to backup your phone by a full backup,
format it by removing the battery and re-insert it back and press on ctrl+shift+f when nokia appears, and when prompt click on format.
then restore back the backup as partial restore.
this will work, check and let me know -
Audit log missing in message in Message Monitor
Hi,
I am facing a weird problem.
I found this in one of my scenario where we are using AS2 adapter and its an IDoc to file scenario.
When I go to details of messages in message monitor in RWB,sometimes the Audit log is empty.
It is happening randomly and not specific to any scenario as later on I found the same problem in some messages from other scenarios too.
I have never faced this problem till now and it was working fine before.
Can anyone please let me know what could be the reason for this as this is difficult for me in case I need to analyse a message and there is no audit log.
Thanks in advance.
Regards,
ShwetaHi Rajesh,
Doesnt work for me :(((
404 Not Found
The requested resource /messagingsystem/monitor/monitor.jsp is not available
Details: File [messagingsystem/monitor/monitor.jsp] not found in application root of alias [/] of J2EE application [sap.com/com.sap.engine.docs.examples].
Thanks.
Regards,
Shweta
Maybe you are looking for
-
Hi Guys, I am passing the value through fnction is 'Animation' But in the database column of that value is metadata value like : |Animation|Family|Horror|Action| So from this I need to trim and pickhe value from metadata field which I have passed thr
-
Defaulting date 3 months from present date
HI! In my selection screen in my report I need to default a selection option to a future date which is 3 months from the present date. Can anyone tell me whats the way to do this so that I can add 3 montsh from the present date and default it in my s
-
Often I receive an e-mail that references an attached link. In responding I attach the original mail and link. While writing my reply, I try to reference the link for my answer. Guess what Out Going mail will not let you reference a hyperlink be it a
-
HT5312 Problem Resetting Security Questions
I have been trying for months now to rest my security questions, everytime i try click the link to send an email i dont get any email. is this just happening to me , or the same for other people
-
when I try synching my ipad 2 with my xps laptop i get the following message. "Attempting to copy to the disk os failed." How do I resolve the problem?