<?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>惜分飞 &#187; oswprvtnet</title>
	<atom:link href="https://www.xifenfei.com/tag/oswprvtnet/feed" rel="self" type="application/rss+xml" />
	<link>https://www.xifenfei.com</link>
	<description>提供7*24专业数据库(Oracle,SQL Server,MySQL,PostgreSQL等)恢复和技术支持@Tel:17813235971</description>
	<lastBuildDate>Thu, 29 Oct 2026 15:31:46 +0000</lastBuildDate>
	<language>zh-CN</language>
		<sy:updatePeriod>hourly</sy:updatePeriod>
		<sy:updateFrequency>1</sy:updateFrequency>
	
	<item>
		<title>osw配置私网监控(oswprvtnet)</title>
		<link>https://www.xifenfei.com/2018/01/osw-oswprvtnet.html</link>
		<comments>https://www.xifenfei.com/2018/01/osw-oswprvtnet.html#comments</comments>
		<pubDate>Tue, 30 Jan 2018 17:00:10 +0000</pubDate>
		<dc:creator><![CDATA[惜分飞]]></dc:creator>
				<category><![CDATA[Oracle]]></category>
		<category><![CDATA[oswprvtnet]]></category>

		<guid isPermaLink="false">https://www.xifenfei.com/?p=7301</guid>
		<description><![CDATA[联系：手机/微信(+86 17813235971) QQ(107644445)  &#8230; <a href="https://www.xifenfei.com/2018/01/osw-oswprvtnet.html">继续阅读 <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<div id="xifenfeicopyright">
<p>联系：<a href="https://www.xifenfei.com/about_xifenfei" target="_blank">手机/微信(+86 17813235971)   QQ(107644445)</a><a target="_blank" href="http://wpa.qq.com/msgrd?v=3&#038;uin=107644445&#038;site=qq&#038;menu=yes"><img src="https://www.xifenfei.com/wp-content/themes/img/site_qq.jpg" alt="QQ咨询惜分飞" title="QQ咨询惜分飞"/></a></p>
<p>标题：<a href="https://www.xifenfei.com/2018/01/osw-oswprvtnet.html" target="_blank">osw配置私网监控(oswprvtnet)</a></p>
<p>作者：<a href="https://www.xifenfei.com" target="_blank">惜分飞</a>©版权所有[未经本人同意,不得以任何形式转载,否则有进一步追究法律责任的权利.]</p>
</div>
<p>OS Watcher Black Box (OSWbb) 是一种 UNIX shell 脚本的集合，主要用于收集和归档操作系统和网络的度量，以便为诊断性能问题提供支持。OSWbb 作为服务器上的一组后台进程来运行，定期收集OS 数据，其调用 Unix 实用程序，如 vmstat、netstat 和 iostat 等。在最近的gi psu中已经把osw包含在tfa中了，但是默认不启用私网的监控，如果需要可以进行人工配置<br />
OSWbb 使用 traceroute 命令获取这些私有网络的状态。每个操作系统对 traceroute 命令使用的参数都略有不同。基本 oswbb 目录中的示例Exampleprivate.net 文件中包含每个操作系统使用的语法。因此，这将导致在 UNIX 平台中的输出显示有所不同。OSWbb 按指定间隔运行 private.net 文件，并在归档目录下的 oswprvtnet 子目录中存储数据。数据存储在每小时归档的文件中。文件中的每个条目都包含一个时间戳，前缀为 ***，嵌入在顶部输出中。<br />
<strong>tfa中含osw</strong></p>
<pre class="brush: bash; title: ; notranslate">
[root@xifenfei01 ~]# ps -ef|grep osw
grid      17673      1  0 Jan30 ?        00:00:07 /bin/sh ./OSWatcher.sh 30 48 NONE /u01/app/grid/tfa/repository/suptools/xifenfei01/oswbb/grid/archive
grid      17841  17673  0 Jan30 ?        00:00:01 /bin/sh ./OSWatcherFM.sh 48 /u01/app/grid/tfa/repository/suptools/xifenfei01/oswbb/grid/archive
root      64159  64120  0 00:30 pts/0    00:00:00 grep osw
</pre>
<p><strong>测试prvtnet.sh</strong></p>
<pre class="brush: bash; title: ; notranslate">
[root@xifenfei01 oswbb]# cd /u01/app/grid/tfa/repository/suptools/xifenfei01/oswbb/grid/oswbb
[root@xifenfei01 oswbb]# more prvtnet.sh
echo &quot;zzz ***&quot;`date`
traceroute -r -F xifenfei01-priv
traceroute -r -F xifenfei02-priv
######################################################################
# DO NOT DELETE THE FOLLOWING LINE!!!!!!!!!!!!!!!!!!!!!
######################################################################
rm locks/lock.file
[root@xifenfei01 oswbb]# ./prvtnet.sh 
zzz ***Tue Jan 30 18:02:49 CST 2018
traceroute to xifenfei01-priv (192.168.102.11), 30 hops max, 60 byte packets
 1  xifenfei01-priv (192.168.102.11)  0.010 ms  0.003 ms  0.002 ms
traceroute to xifenfei02-priv (192.168.102.14), 30 hops max, 60 byte packets
 1  xifenfei02-priv (192.168.102.14)  0.081 ms  0.076 ms  0.087 ms
rm: cannot remove `locks/lock.file': No such file or directory
</pre>
<p><strong>配置private.net正式收集私网信息</strong></p>
<pre class="brush: bash; title: ; notranslate">
[root@xifenfei01 oswbb]# find . -name OSWatcher.sh | xargs grep -i &quot;private&quot;
# Run traceroute for private networks if file private.net exists
if [ -x private.net ]; then
   ./private.net &gt;&gt; $OSWBB_ARCHIVE_DEST/oswprvtnet/${hostn}_prvtnet_$hour 2&gt;&amp;1 &amp;
</pre>
<p>这里重要的是：<br />
./OSWatcher.sh:# Run traceroute for private networks if file private.net exists<br />
表示，在OSWatcher.sh中调用的文件名称是private.net<br />
<strong>将prvtnet.sh复制为供OSWatcher.sh脚本调用的文件名称</strong></p>
<pre class="brush: bash; title: ; notranslate">
[root@xifenfei01 oswbb]# cp prvtnet.sh private.net
[root@xifenfei01 oswbb]# chown grid:oinstall prvtnet.net
[root@xifenfei01 oswbb]# chmod +x prvtnet.net
</pre>
<p><strong>关注内容</strong></p>
<pre class="brush: bash; title: ; notranslate">
示例 1： 接口处于启动和响应状态：
traceroute to X.X.X.X, (X.X.X.X) 30 hops max, 1492 byte packets
1 X.X.X.X 1.015 ms 0.766 ms 0.755 ms


示例 2： 目标接口不是在直接连接的网络上，所以需要验证地址
         是否正确或其插入的交换机是否位于相同的 VLAN 上（或其他问题）：
traceroute to X.X.X.X, (X.X.X.X) 30 hops max, 40 byte packets
traceroute: host X.X.X.X is not on a directly-attached network


示例 3： 网络无法访问：
traceroute to X.X.X.X, (X.X.X.X) 30 hops max, 40 byte packets 
Network is unreachable

示例 4： 网络无法访问：
xifenfei01_prvtnet_18.01.30.2000.dat-zzz ***Tue Jan 30 20:27:43 CST 2018
xifenfei01_prvtnet_18.01.30.2000.dat-traceroute to xifenfei01-priv (192.168.102.11), 30 hops max, 60 byte packets
xifenfei01_prvtnet_18.01.30.2000.dat- 1  xifenfei01-priv (192.168.102.11)  0.014 ms  0.004 ms  0.005 ms
xifenfei01_prvtnet_18.01.30.2000.dat-traceroute to xifenfei02-priv (192.168.102.14), 30 hops max, 60 byte packets
xifenfei01_prvtnet_18.01.30.2000.dat- 1  * * *
xifenfei01_prvtnet_18.01.30.2000.dat- 2  * * *
xifenfei01_prvtnet_18.01.30.2000.dat- 3  * * *
xifenfei01_prvtnet_18.01.30.2000.dat- 4  * * *
xifenfei01_prvtnet_18.01.30.2000.dat- 5  * * *
xifenfei01_prvtnet_18.01.30.2000.dat- 6  * * *
xifenfei01_prvtnet_18.01.30.2000.dat- 7  * * *
xifenfei01_prvtnet_18.01.30.2000.dat- 8  * * *
xifenfei01_prvtnet_18.01.30.2000.dat- 9  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-10  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-11  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-12  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-13  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-14  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-15  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-16  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-17  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-18  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-19  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-20  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-21  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-22  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-23  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-24  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-25  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-26  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-27  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-28  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-29  * * *
xifenfei01_prvtnet_18.01.30.2000.dat-30  * * *
xifenfei01_prvtnet_18.01.30.2000.dat:zzz ***Warning. Traceroute response is spanning snapshot intervals.
</pre>
<div id="crp_related"><ul><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2015/05/init-cssd-startcheck-hp-service-guard%e6%9c%aa%e5%90%af%e5%8a%a8%e5%af%bc%e8%87%b4crs%e6%97%a0%e6%b3%95%e6%ad%a3%e5%b8%b8%e5%90%af%e5%8a%a8.html" rel="bookmark" class="crp_title">init.cssd startcheck&#8212;HP Service Guard未启动导致CRS无法正常启动</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2014/12/hosts%e6%97%a0%e6%95%88%e5%86%85%e5%ae%b9%e6%9c%aa%e6%b3%a8%e9%87%8a%e5%af%bc%e8%87%b4rac%e5%ae%89%e8%a3%85oui%e7%9a%84network-interface-usage%e6%8a%a5ins-41112.html" rel="bookmark" class="crp_title">hosts无效内容未注释导致RAC安装OUI的Network Interface Usage报INS-41112</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2012/12/how-to-dump-the-contents-of-an-spfile-on-asm-when-asmgrid-is-down.html" rel="bookmark" class="crp_title">How to Get the Contents of an Spfile on ASM when ASM/GRID is down</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2014/12/%e4%b8%bb%e6%9c%ba%e6%96%ad%e7%94%b5%e7%b3%bb%e7%bb%9f%e5%9b%9e%e5%88%b0n%e5%b9%b4%e5%89%8d%e6%95%b0%e6%8d%ae%e5%ba%93%e6%8a%a5ora-600-kcm_headroom_warn_1%e9%94%99%e8%af%af.html" rel="bookmark" class="crp_title">主机断电系统回到N年前数据库报ORA-600 kcm_headroom_warn_1错误</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2011/05/mysql%e5%88%86%e5%8c%ba%e7%ae%a1%e7%90%86.html" rel="bookmark" class="crp_title">MySql分区表管理</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2019/04/traceroute-has-a-disk-hb-but-no-network-hb.html" rel="bookmark" class="crp_title">has a disk HB, but no network HB&#8212;-traceroute不通导致</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2016/06/losetup-asm-disk.html" rel="bookmark" class="crp_title">使用losetup实现linux普通文件做asm disk</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2017/06/rac-12-2-root-sh-clsrsc-400.html" rel="bookmark" class="crp_title">oracle rac 12.2 执行root.sh报CLSRSC-400</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2012/07/dul%e6%8c%96oracle-8-0%e6%95%b0%e6%8d%ae%e5%ba%93.html" rel="bookmark" class="crp_title">DUL挖ORACLE 8.0数据库</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2024/08/oracle-support-gb18030-2022.html" rel="bookmark" class="crp_title">Oracle 支持GB18030-2022</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2018/07/kfed-error-could-not-initialize-the-diag-context.html" rel="bookmark" class="crp_title">KFED &#8211; ERROR!!! could not initialize the diag context</a></li><li style="list-style-type:decimal;font-size:11px;" ><a href="https://www.xifenfei.com/2014/10/11-2-0-4-gi%e5%ae%89%e8%a3%85tfa.html" rel="bookmark" class="crp_title">11.2.0.4 GI单独安装tfa</a></li></ul></div>]]></content:encoded>
			<wfw:commentRss>https://www.xifenfei.com/2018/01/osw-oswprvtnet.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
