Module: check_mk
Branch: master
Commit: c4c4c23efb925bb40a52a4b6dc52979fdb07751f
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=c4c4c23efb925b…
Author: Marcel Arentz <ma(a)mathias-kettner.de>
Date: Mon Sep 18 10:50:10 2017 +0200
5015 FIX mk_oracle.bat: Removed deprecated plugin
Removed obsolete plugin which is deprecated since 1.2.6. Please use
mk_oracle.ps1 instead.
Change-Id: Ia146ab34d72a2e99be259bd99bf43f270a1b02f5
---
.werks/5015 | 11 +++++++
agents/windows/plugins/mk_oracle.bat | 58 ------------------------------------
agents/windows/plugins/mk_oracle.ps1 | 2 --
3 files changed, 11 insertions(+), 60 deletions(-)
diff --git a/.werks/5015 b/.werks/5015
new file mode 100644
index 0000000..db578fa
--- /dev/null
+++ b/.werks/5015
@@ -0,0 +1,11 @@
+Title: mk_oracle.bat: Removed deprecated plugin
+Level: 1
+Component: checks
+Compatible: compat
+Edition: cre
+Version: 1.5.0i1
+Date: 1505724422
+Class: fix
+
+Removed obsolete plugin which is deprecated since 1.2.6. Please use
+mk_oracle.ps1 instead.
diff --git a/agents/windows/plugins/mk_oracle.bat b/agents/windows/plugins/mk_oracle.bat
deleted file mode 100644
index 255d758..0000000
--- a/agents/windows/plugins/mk_oracle.bat
+++ /dev/null
@@ -1,58 +0,0 @@
-@echo off
-REM Old deprecated ORACLE plugin (Batch)
-REM ; If you not run this plugin with the environment variable ORACLE_SID set,
-REM ; you can uncomment (Remove the "REM " prefix) the line below to
-REM ; use e.g. "localhost" as oracle sid.
-REM SET ORACLE_SID=localhost
-
-REM ; If you like to use a special auth parameter please change the line below
-SET AUTH=/ as sysdba
-
-echo ^<^<^<oracle_version^>^>^>
-(echo.|set /p x=%ORACLE_SID% )
-(
-echo set cmdsep on
-echo set cmdsep '"'; --"
-echo "set pages 0"
-echo "set feedback off"
-echo "set head off"
-echo "select banner from v$version where banner like 'Oracle%%';"
-) | sqlplus -S %AUTH%
-
-echo ^<^<^<oracle_sessions^>^>^>
-(echo.|set /p x=%ORACLE_SID%)
-(
-echo set cmdsep on
-echo set cmdsep '"'; --"
-echo "set pages 0"
-echo "set feedback off"
-echo "set head off"
-echo "select count(*) from v$session where status = 'ACTIVE';"
-) | sqlplus -S %AUTH%
-
-echo ^<^<^<oracle_logswitches^>^>^>
-(echo.|set /p x=%ORACLE_SID%)
-(
-echo set cmdsep on
-echo set cmdsep '"'; --"
-echo "set pages 0"
-echo "set feedback off"
-echo "set head off"
-echo "select count(*) from v$loghist where first_time > sysdate - 1/24;"
-) | sqlplus -S %AUTH%
-
-REM ; This is nearly the same query as in the linux agent. With the exception that the
-REM ; column th.instance is fetched as first column to get the SID
-echo ^<^<^<oracle_tablespaces^>^>^>
-(
-echo set cmdsep on
-echo set cmdsep '"'; --"
-echo "set pages 0"
-echo "set linesize 900"
-echo "set tab off"
-echo "set feedback off"
-echo "set head off"
-echo "column instance format a10"
-echo "column file_name format a100"
-echo "select th.instance, f.file_name, f.tablespace_name, f.status,
f.AUTOEXTENSIBLE, f.blocks, f.maxblocks, f.USER_BLOCKS, f.INCREMENT_BY, f.ONLINE_STATUS,
t.BLOCK_SIZE, t.status, decode(sum(fs.blocks), NULL, 0, sum(fs.blocks)) free_blocks from
v$thread th, dba_data_files f, dba_tablespaces t, dba_free_space fs where
f.tablespace_name = t.tablespace_name and f.file_id = fs.file_id(+) group by th.instance,
f.file_name, f.tablespace_name, f.status, f.autoextensible, f.blocks, f.maxblocks,
f.user_blocks, f.increment_by, f.online_status, t.block_size, t.status UNION SELECT
th.instance, f.file_name, f.tablespace_name, f.status, f.AUTOEXTENSIBLE, f.blocks,
f.maxblocks, f.USER_BLOCKS, f.INCREMENT_BY, 'TEMP', t.BLOCK_SIZE, t.status,
sum(sh.blocks_free) free_blocks FROM v$thread th, dba_temp_files f, dba_tablespaces t,
v$temp_space_header sh WHERE f.tablespace_name = t.tablespace_name and f.file_id =
sh.file_id GROUP BY th.instance, f.file_name, f.tablespace_name, f.status,
f.autoextensible, f.blocks, f.maxblocks, f.user_blocks, f.increment_by, 'TEMP',
t.block_size, t.status;"
-) | sqlplus -S %AUTH%
diff --git a/agents/windows/plugins/mk_oracle.ps1 b/agents/windows/plugins/mk_oracle.ps1
index c983b34..2fa230f 100644
--- a/agents/windows/plugins/mk_oracle.ps1
+++ b/agents/windows/plugins/mk_oracle.ps1
@@ -27,13 +27,11 @@
# and Mathias Kettner. Thorsten is responsible for the ORACLE
# stuff, Mathias for the shell hacking, Andrew for the powershell...
-# NOTE: This plugin is still EXPERIMENTAL!
###############################################################################
# open issues
###############################################################################
# 1. error connection to instance, old async still shown is this ok?
-# 2. login to database using Oracle wallet (nice to have, currently not planned)
###############################################################################
# usage