当前位置: 首页 > news >正文

n9e categraf

#!/bin/bash
#Create by:zhangyongze
#为什么不问问神奇的海螺呢丶
# chkconfig: 2345 55 25
# description: categraf
#export ORACLE_HOME=/usr/lib/oracle/12.2/client64
export LD_LIBRARY_PATH=$ORACLE_HOME/lib
export PATH=$PATH:$ORACLE_HOME/binRETVAL=0
#程序名
PROG="categraf"  
#程序执行文件
EXEC="/monitor/categraf-v0.3.45-linux-amd64-with-cgo-plugin/categraf"
#锁文件
LOCKFILE="/var/lock/subsys/$PROG"
#参数
OPTIONS="-configs /monitor/categraf-v0.3.45-linux-amd64-with-cgo-plugin/conf"# Source function library.
if [ -f /etc/rc.d/init.d/functions ]; then. /etc/rc.d/init.d/functions
elseecho "/etc/rc.d/init.d/functions does not exist"exit 0
fistart() {if [ -f $LOCKFILE ]thenecho "$PROG is already running!"elseecho -n "Starting $PROG: "nohup $EXEC $OPTIONS >/monitor/categraf-v0.3.45-linux-amd64-with-cgo-plugin/crunlog.log 2>&1 &RETVAL=$?[ $RETVAL -eq 0 ] && touch $LOCKFILE && success || failureechoreturn $RETVALfi
}stop() {echo -n "Stopping $PROG: "killproc $EXECRETVAL=$?[ $RETVAL -eq 0 ] && rm -r $LOCKFILE && success || failureecho
}restart ()
{stopsleep 1start
}case "$1" instart)start;;stop)stop;;status)status $PROG;;restart)restart;;*)echo "Usage: $0 {start|stop|restart|status}"exit 1
esac
exit $RETVAL
#!/bin/bash
#Create by:zhangyongze
#为什么不问问神奇的海螺呢丶
# chkconfig: 2345 55 25
# description: n9e-server
#RETVAL=0
#程序名
PROG="n9e"  
#程序执行文件
EXEC="/monitor/n9e/n9e"
#锁文件
LOCKFILE="/var/lock/subsys/$PROG"
#参数
OPTIONS="-configs /monitor/n9e/etc"# Source function library.
if [ -f /etc/rc.d/init.d/functions ]; then. /etc/rc.d/init.d/functions
elseecho "/etc/rc.d/init.d/functions does not exist"exit 0
fistart() {if [ -f $LOCKFILE ]thenecho "$PROG is already running!"elseecho -n "Starting $PROG: "nohup $EXEC $OPTIONS >/monitor/n9e/n9e.log 2>&1 &RETVAL=$?[ $RETVAL -eq 0 ] && touch $LOCKFILE && success || failureechoreturn $RETVALfi
}stop() {echo -n "Stopping $PROG: "killproc $EXECRETVAL=$?[ $RETVAL -eq 0 ] && rm -r $LOCKFILE && success || failureecho
}restart ()
{stopsleep 1start
}case "$1" instart)start;;stop)stop;;status)status $PROG;;restart)restart;;*)echo "Usage: $0 {start|stop|restart|status}"exit 1
esac
exit $RETVAL```bash[[instances]]
agents = [ "udp://xxx.xxx.xx.xxx:161"]
labels = { region="办公", lable="[办公]深信服(备)AC_MGT" }
version = 2
community = "xxxxx"
agent_host_tag = "ip"
timeout = "5s"
retries = 1
interval_times = 4[[instances.field]]
oid = "SNMPv2-MIB::sysUpTime.0"
name = "uptime"[[instances.field]]
oid = "SNMPv2-MIB::sysName.0"
name = "source"
is_tag = true[[instances.table]]
oid = "IF-MIB::ifTable"
name = "interface"
index_as_tag = true
inherit_tags = ["source"][[instances.table.field]]
oid = "IF-MIB::ifDescr"
name = "ifDescr"
is_tag = true


http://www.mrgr.cn/news/55331.html

相关文章:

  • 关于Qt中进行输出的方式及对比分析
  • 【MySQL】提高篇—事务管理:事务隔离级别的介绍
  • QT中中文显示乱码问题
  • 设计模式,面试级别的详解(持续更新中)
  • 数据库、数据仓库、数据湖和数据中台有什么区别
  • Django框架介绍
  • 操作系统最后错题本-cc
  • 代码工具箱:18个实用的 JavaScript 函数
  • 伦敦金和现货黄金值得区别的地方
  • 深度解析RAG技术在大模型时代的原理与实践
  • Linux进程间通信
  • repo 命令大全详解(第二十二篇 repo upload)
  • Adobe的反击,传统大厂全面AI化,正面激战OpenAI!
  • TF卡长期不用会丢失数据吗?TF卡数据恢复容易吗?
  • Stable Diffusion模型资源合集(附整合包)
  • 【小白学机器学习19】什么是量化分析(草稿)
  • CRM系统有哪些功能
  • 皮具发霉怎么处理 发霉的原因分析及防霉方案
  • ThisisaTestforBehavior
  • 浅谈高标准农田智慧设备之土壤墒情监测站
  • 【中草药识别系统】Python+卷积神经网络算法+深度学习项目+人工智能项目+TensorFlow+图像识别+Django网页界面+CNN算法
  • 【多类别分类中的准确率召回率平均策略】
  • 论文研读 | End-to-End Object Detection with Transformers
  • UE(其他)
  • 基于STM32的宿舍防火防盗系统设计
  • 双十一购物节有哪些好物值得入手?2024双十一好物清单合集分享