<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000099">
My apologies... didn't mean to come across as rude. I figured that
others may have tools like Cacti along with NDOutils on the same server
and thus might find that they have multiple database types as well...
hence my email to the Nagios list instead of the mysql list. In my
case, I learned the hard way that mysqlhotcopy doesn't backup InnoDB
databases... hence my need to determine the DB type so I knew how to
properly backup the various DB's.<br>
<br>
In any case, your original reply pointed me in the right direction. I
just wrote up the script below. It first shows all the databases, then
determines the database type for each, making it easy to parse out:<br>
<br>
#!/bin/bash<br>
<br>
DATABASES=`mysql -uroot -p<password> -e "show databases;"|awk -F
"|" '{print $1}'|grep -vE "Database|information_schema|test|nagdb"`<br>
<br>
for x in $DATABASES<br>
do<br>
    DATABASE_TYPE=`mysql -uroot -p<password> -e "show table
status;" $x|awk '{print $2}'|uniq|grep -v Engine`<br>
    echo $x:$DATABASE_TYPE<br>
done<br>
<br>
exit 0<br>
<br>
Of course, I've also learned its possible to mix engines within a
database, so this isn't exactly foolproof. The output looks something
like this:<br>
<br>
# /root/test.sh <br>
cacti:MyISAM<br>
mysql:MyISAM<br>
nagios:InnoDB<br>
<br>
Thanks for pointing me in the right direction...<br>
<pre class="moz-signature" cols="72">
  A. Davis
  Email:     <a class="moz-txt-link-abbreviated" href="mailto:nccomp@gmail.com">nccomp@gmail.com</a>

  "There is no limit to what a man can accomplish
   if he doesn't care who gets the credit." - Ronald Reagan
</pre>
<br>
<br>
Marc Powell wrote:
<blockquote cite="mid:E93BE14F-836D-4C98-9C96-DF26112FB592@ena.com"
 type="cite">
  <pre wrap="">On Aug 7, 2009, at 3:15 PM, Andrew Davis wrote:

  </pre>
  <blockquote type="cite">
    <pre wrap="">Really? You sure about that? I'm pretty confident that mysql  
supports different types of databases (myISAM and InnoDB as two of  
them) as well as different table types within a database.
    </pre>
  </blockquote>
  <pre wrap=""><!---->
If you really wanted to be sure about that and not question the  
answers you receive, shouldn't you be asking on mysql-users instead of  
the unrelated nagios-users? That would be the forum for definitive  
answers about mysql database types, don't you agree?

--
Marc


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  <a class="moz-txt-link-freetext" href="http://p.sf.net/sfu/bobj-july">http://p.sf.net/sfu/bobj-july</a>
_______________________________________________
Nagios-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Nagios-users@lists.sourceforge.net">Nagios-users@lists.sourceforge.net</a>
<a class="moz-txt-link-freetext" href="https://lists.sourceforge.net/lists/listinfo/nagios-users">https://lists.sourceforge.net/lists/listinfo/nagios-users</a>
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null
  </pre>
</blockquote>
</body>
</html>