Search Exchange
Search All Sites
Nagios Live Webinars
Let our experts show you how Nagios can help your organization.Login
Directory Tree
Directory
Hulskamp
byHulskamp, November 6, 2013
The script works if there are multiple datafiles. With one datafile and autoextension enabled, for some reason the creator opted to default to 0 for the total percentage used by a tablespace. I have no idea why.
If you apply this patch, everything seems to work:
--- check_oracle_tablespace.sh 2012-01-16 14:06:38.000000000 +0100
+++ check_oracle_tablespace.sh 2013-11-06 14:40:44.000000000 +0100
@@ -259,7 +259,7 @@
select df.TABLESPACE_NAME,
round(((df.BYTES - fs.BYTES) / df.BYTES) * 100) usage_pct,
- round(decode(df.MAXBYTES, 34359721984, 0, (df.BYTES - fs.BYTES) / df.MAXBYTES * 100)) max_pct,
+ round(((df.BYTES - fs.BYTES) / df.MAXBYTES) * 100) max_pct,
df.AUTOEXTENSIBLE
from
(
If you apply this patch, everything seems to work:
--- check_oracle_tablespace.sh 2012-01-16 14:06:38.000000000 +0100
+++ check_oracle_tablespace.sh 2013-11-06 14:40:44.000000000 +0100
@@ -259,7 +259,7 @@
select df.TABLESPACE_NAME,
round(((df.BYTES - fs.BYTES) / df.BYTES) * 100) usage_pct,
- round(decode(df.MAXBYTES, 34359721984, 0, (df.BYTES - fs.BYTES) / df.MAXBYTES * 100)) max_pct,
+ round(((df.BYTES - fs.BYTES) / df.MAXBYTES) * 100) max_pct,
df.AUTOEXTENSIBLE
from
(