<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Linux infrastructure support and bash scripting, Unix/Linux System administration &#187; Uncategorized</title>
	<atom:link href="http://sysadminupdates.com/blog/category/uncategorized/feed/" rel="self" type="application/rss+xml" />
	<link>http://sysadminupdates.com/blog</link>
	<description>Linux infrastructure support and bash scripting, Unix/Linux System administration</description>
	<lastBuildDate>Fri, 03 Sep 2010 03:12:26 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>how to check oracle client version on linux</title>
		<link>http://sysadminupdates.com/blog/2010/09/02/how-to-check-oracle-client-version-on-lunux/</link>
		<comments>http://sysadminupdates.com/blog/2010/09/02/how-to-check-oracle-client-version-on-lunux/#comments</comments>
		<pubDate>Fri, 03 Sep 2010 03:11:51 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://sysadminupdates.com/blog/?p=75</guid>
		<description><![CDATA[You can try by which is not the correct way..
strings $ORACLE_HOME/bin/oracle&#124;grep "XML Schema Processor version"
but thats not the correct way because some of the client installs don't have an Oracle binary, just a client
library shared object.  A similar method to the above for client-only installs would be:
The command for it is locate correct libclntsh.so [...]]]></description>
			<content:encoded><![CDATA[<p>You can try by which is not the correct way..</p>
<pre>strings $ORACLE_HOME/bin/oracle|grep "XML Schema Processor version"</pre>
<pre>but thats not the correct way because some of the client installs don't have an Oracle binary, just a client
<pre>library shared object.  A similar method to the above for client-only installs would be:</pre>
<pre>The command for it is locate correct libclntsh.so file that you are using.</pre>
<pre>
<pre><strong>#strings $ORACLE_HOME/lib/libclntsh.so | grep '^Version [0-9]'</strong></pre>
<pre>
<pre>One challenge is that even if you find all copies of libclntsh.so on a
host, there is no guarantee that they are each part of a complete
install.  The only real way to make sure is to try using each one (set
ORACLE_HOME &amp; LD_LIBRARY_PATH)

Each install that has been completed to installer standard should have
a line in the file /etc/oraInst.loc that says where the
oraInventory(s) are located on the host.  IIRC, Opatch.pl has some
code you could probably crib to query any given oraInventory.

Of course, the existence of an oraInventory that says there is a
client install somewhere does not guarantee that one exists and works.</pre>
</pre>
</pre>
</pre>
]]></content:encoded>
			<wfw:commentRss>http://sysadminupdates.com/blog/2010/09/02/how-to-check-oracle-client-version-on-lunux/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>What is SNMP? how to use SNMP?</title>
		<link>http://sysadminupdates.com/blog/2010/03/04/what-is-snmp-how-to-use-snmp/</link>
		<comments>http://sysadminupdates.com/blog/2010/03/04/what-is-snmp-how-to-use-snmp/#comments</comments>
		<pubDate>Thu, 04 Mar 2010 11:54:58 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://sysadminupdates.com/blog/2010/03/04/what-is-snmp-how-to-use-snmp/</guid>
		<description><![CDATA[This is a brief documentation on using the google-provided MIBs for GSA (Google Search Appliance). This can also be used as a reference to monitor any SNMP enabled device.
Terminologies:
&#8212;&#8212;&#8212;&#8212;&#8212;
SNMP: SNMP stands for Simple Network Management Protocol and consists of three key components: managed devices, agents, and network-management systems (NMSs). A managed device is a node [...]]]></description>
			<content:encoded><![CDATA[<p>This is a brief documentation on using the google-provided MIBs for GSA (Google Search Appliance). This can also be used as a reference to monitor any SNMP enabled device.</p>
<p>Terminologies:<br />
&#8212;&#8212;&#8212;&#8212;&#8212;<br />
SNMP: SNMP stands for Simple Network Management Protocol and consists of three key components: managed devices, agents, and network-management systems (NMSs). A managed device is a node that has an SNMP agent and resides on a managed network. These devices can be routers and access server, switches and bridges, hubs, computer hosts, or printers. An agent is a software module residing within a device. This agent translates information into a compatible format with SNMP. An NMS runs monitoring applications. They provide the bulk of processing and memory resources required for network management.</p>
<p>MIB: MIB stands for Management Information Base and is a collection of information organized hierarchically. These are accessed using a protocol such as SNMP. There are two types of MIBs: scalar and tabular. Scalar objects define a single object instance whereas tabular objects define multiple related object instances grouped in MIB tables.</p>
<p>OID: OIDs or Object Identifiers uniquely identify manged objects in a MIB hierarchy. This can be depicted as a tree, the levels of which are assigned by different organizations. Top level MIB object IDs (OIDs) belong to different standard organizations. Vendors define private branches including managed objects for their own products.</p>
<p>Tools required:<br />
&#8212;&#8212;&#8212;&#8212;&#8212;-<br />
In order to get more information on the OID, or to get list of all available params/OID from a device, or to get OID from MIB or vice-versa, it would help if we have access to a linux box with snmp-utils installed. This can be checked using:<br />
$ rpm -qa |grep -i snmp<br />
net-snmp-5.1.2-13.el4<br />
net-snmp-libs-5.1.2-13.el4<br />
net-snmp-utils-5.1.2-13.el4</p>
<p>And if not available, installed from yum. You need to copy the vendor provided MIB file to you home directory under:<br />
/home/username/.snmp/mibs/</p>
<p>For example:<br />
[jayesh@MY_SERVER mibs]# pwd<br />
/home/ram/.snmp/mibs<br />
[jayesh@MY_SERVER mibs]# ls -la<br />
total 24<br />
drwxr-xr-x  2 jayesh jayesh 4096 Oct 28 18:04 .<br />
drwxr-xr-x  3 jayesh jayesh 4096 Oct 28 18:03 ..<br />
-rw-r&#8211;r&#8211;  1 jayesh jayesh 702 Oct 28 17:56 GOOGLE-MIB.txt<br />
-rw-r&#8211;r&#8211;  1 jayesh jayesh 5032 Oct 28 17:56 GSA-MIB.txt</p>
<p>Setting up the monitor:<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br />
Your monitoring tool (sitescope) is normally capable of monitoring the usual/standard metrics from an SNMP capable device. The more famous and widely used the device is, the better support. (Cisco, Linux etc).</p>
<p>In case the OIDs are not available to the monitoring system, they can always be imported from the manufacturer provided MIBs.</p>
<p>Monitor can be setup using the MIB or OID for that particular system. In case of GSA, the MIBs that we need to monitor are:<br />
system.temperature.temperatureHealth.0<br />
system.gsaDisk.diskHealth.0<br />
system.machine.machineHealth.0</p>
<p>Or (in terms of complete MIBs)<br />
.iso.org.dod.internet.private.enterprises.google.gsa.system.temperature.temp<br />
eratureHealth<br />
.iso.org.dod.internet.private.enterprises.google.gsa.system.gsaDisk.diskHeal<br />
th<br />
.iso.org.dod.internet.private.enterprises.google.gsa.system.machine.machineH<br />
ealth</p>
<p>Now, we can use the MIB directly to use for our monitoring or we can use the corresponding OID.</p>
<p>In order to get the list of OIDs corresponding to the MIBs, we can use the tools provided by the net-snmp-utils package.</p>
<p>Command:snmptranslate -m GSA-MIB -Ts<br />
Function: to get the list of MIB trees</p>
<p>Command:snmptranslate -m GSA-MIB -To<br />
Function: to get the list of OID</p>
<p>Using both the commands for GSA, we can get the following information:</p>
<p>OID                MIB<br />
.1.3                .iso.org<br />
.1.3.6                .iso.org.dod<br />
.1.3.6.1            .iso.org.dod.internet<br />
.1.3.6.1.1            .iso.org.dod.internet.directory<br />
.1.3.6.1.2            .iso.org.dod.internet.mgmt<br />
.1.3.6.1.2.1            .iso.org.dod.internet.mgmt.mib-2<br />
.1.3.6.1.2.1.10<br />
.iso.org.dod.internet.mgmt.mib-2.transmission<br />
.1.3.6.1.3            .iso.org.dod.internet.experimental<br />
.1.3.6.1.4            .iso.org.dod.internet.private<br />
.1.3.6.1.4.1            .iso.org.dod.internet.private.enterprises<br />
.1.3.6.1.4.1.11129<br />
.iso.org.dod.internet.private.enterprises.google<br />
.1.3.6.1.4.1.11129.1<br />
.iso.org.dod.internet.private.enterprises.google.gsa<br />
.1.3.6.1.4.1.11129.1.1<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl<br />
.1.3.6.1.4.1.11129.1.1.1<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl.crawlRunning<br />
.1.3.6.1.4.1.11129.1.1.2<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl.status<br />
.1.3.6.1.4.1.11129.1.1.2.1<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl.status.docsServed<br />
.1.3.6.1.4.1.11129.1.1.2.2<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl.status.crawlingRa<br />
te<br />
.1.3.6.1.4.1.11129.1.1.2.3<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl.status.docBytes<br />
.1.3.6.1.4.1.11129.1.1.2.4<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl.status.todayDocsC<br />
rawled<br />
.1.3.6.1.4.1.11129.1.1.2.5<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl.status.docErrors<br />
.1.3.6.1.4.1.11129.1.1.2.6<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl.status.docsFound<br />
.1.3.6.1.4.1.11129.1.1.2.7<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl.status.batchCrawl<br />
Running<br />
.1.3.6.1.4.1.11129.1.1.2.8<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl.status.batchCrawl<br />
StartTime<br />
.1.3.6.1.4.1.11129.1.1.2.9<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl.status.batchCrawl<br />
EndTime<br />
.1.3.6.1.4.1.11129.1.1.2.10<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl.status.batchCrawl<br />
EndReason<br />
.1.3.6.1.4.1.11129.1.1.3<br />
.iso.org.dod.internet.private.enterprises.google.gsa.crawl.diagnostics<br />
.1.3.6.1.4.1.11129.1.2<br />
.iso.org.dod.internet.private.enterprises.google.gsa.serving<br />
.1.3.6.1.4.1.11129.1.2.1<br />
.iso.org.dod.internet.private.enterprises.google.gsa.serving.qpm<br />
.1.3.6.1.4.1.11129.1.3<br />
.iso.org.dod.internet.private.enterprises.google.gsa.system<br />
.1.3.6.1.4.1.11129.1.3.1<br />
.iso.org.dod.internet.private.enterprises.google.gsa.system.gsaDisk<br />
.1.3.6.1.4.1.11129.1.3.1.1<br />
.iso.org.dod.internet.private.enterprises.google.gsa.system.gsaDisk.diskHeal<br />
th<br />
.1.3.6.1.4.1.11129.1.3.1.2<br />
.iso.org.dod.internet.private.enterprises.google.gsa.system.gsaDisk.diskErro<br />
rs<br />
.1.3.6.1.4.1.11129.1.3.2<br />
.iso.org.dod.internet.private.enterprises.google.gsa.system.temperature<br />
.1.3.6.1.4.1.11129.1.3.2.1<br />
.iso.org.dod.internet.private.enterprises.google.gsa.system.temperature.temp<br />
eratureHealth<br />
.1.3.6.1.4.1.11129.1.3.2.2<br />
.iso.org.dod.internet.private.enterprises.google.gsa.system.temperature.temp<br />
eratureErrors<br />
.1.3.6.1.4.1.11129.1.3.3<br />
.iso.org.dod.internet.private.enterprises.google.gsa.system.machine<br />
.1.3.6.1.4.1.11129.1.3.3.1<br />
.iso.org.dod.internet.private.enterprises.google.gsa.system.machine.machineH<br />
ealth<br />
.1.3.6.1.4.1.11129.1.3.3.2<br />
.iso.org.dod.internet.private.enterprises.google.gsa.system.machine.machineE<br />
rrors<br />
.1.3.6.1.4.1.11129.1.4<br />
.iso.org.dod.internet.private.enterprises.google.gsa.search<br />
.1.3.6.1.4.1.11129.1.4.1<br />
.iso.org.dod.internet.private.enterprises.google.gsa.search.reports<br />
.1.3.6.1.4.1.11129.1.4.2<br />
.iso.org.dod.internet.private.enterprises.google.gsa.search.logs<br />
.1.3.6.1.4.1.11129.1.5<br />
.iso.org.dod.internet.private.enterprises.google.gsa.eventLogs<br />
.1.3.6.1.5            .iso.org.dod.internet.security<br />
.1.3.6.1.6            .iso.org.dod.internet.snmpV2<br />
.1.3.6.1.6.1            .iso.org.dod.internet.snmpV2.snmpDomains<br />
.1.3.6.1.6.2            .iso.org.dod.internet.snmpV2.snmpProxys<br />
.1.3.6.1.6.3            .iso.org.dod.internet.snmpV2.snmpModules<br />
.0.0                .ccitt.zeroDotZero</p>
<p>Now, we can use this information, to setup the monitor for the system. (we would need the IP address of the device, the community string, and of course, access to SNMP-readonly)</p>
<p>I would guess, SiteScope needs the OID, community string, and the IP address of the device to monitor.</p>
<p>Here is an example shell script, that uses snmp-utils (snmpget) and the GSA<br />
MIBS:</p>
<p>#!/bin/bash<br />
#set -o xtrace<br />
DEVICE=&#8221;Yur_IP_HERE&#8221;<br />
MIBS=&#8221;system.temperature.temperatureHealth.0 system.gsaDisk.diskHealth.0 system.machine.machineHealth.0&#8243;<br />
# GSA-MIB::diskHealth.0 = INTEGER: green(0) for MIB in ${MIBS} do</p>
<p>RESULT=`snmpget -m GSA-MIB -v 2c -c public -t 5 ${DEVICE} ${MIB}| cut -f4 -d&#8221;:&#8221; | grep -E -o &#8220;[0-9]&#8220;`</p>
<p>case ${RESULT} in<br />
0) STATUS=&#8221;Good&#8221;;;<br />
1) STATUS=&#8221;Warning&#8221;;;<br />
2) STATUS=&#8221;Critical&#8221;;;<br />
*) STATUS=&#8221;Unreachable/Unknown&#8221;;;<br />
esac</p>
<p>if [ ${STATUS} != "Good" ]<br />
then<br />
(<br />
PARAM=`echo ${MIB}|cut -f3 -d&#8221;.&#8221;`<br />
echo &#8220;From: MY_EMAIL_FROM@DOMAIN.COM&#8221;<br />
echo &#8220;To: MY_EMAIL@DOMAIN.COM&#8221;<br />
echo &#8220;Subject: [GSA] ${PARAM} ${STATUS}&#8221;<br />
echo &#8220;GSA Device ${DEVICE} is in ${STATUS} state for ${PARAM}. Please investigate.&#8221;<br />
)| sendmail -t<br />
fi<br />
Done</p>
]]></content:encoded>
			<wfw:commentRss>http://sysadminupdates.com/blog/2010/03/04/what-is-snmp-how-to-use-snmp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hello world!</title>
		<link>http://sysadminupdates.com/blog/2010/02/19/hello-world/</link>
		<comments>http://sysadminupdates.com/blog/2010/02/19/hello-world/#comments</comments>
		<pubDate>Fri, 19 Feb 2010 13:17:10 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http:/?p=1</guid>
		<description><![CDATA[Welcome to WordPress. This is your first post. Edit or delete it, then start blogging!
]]></description>
			<content:encoded><![CDATA[<p>Welcome to WordPress. This is your first post. Edit or delete it, then start blogging!</p>
]]></content:encoded>
			<wfw:commentRss>http://sysadminupdates.com/blog/2010/02/19/hello-world/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
