# tcp_exporter **Repository Path**: AchoGit/tcp_exporter ## Basic Information - **Project Name**: tcp_exporter - **Description**: No description available - **Primary Language**: Python - **License**: Apache-2.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2024-09-14 - **Last Updated**: 2024-09-14 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # tcp_exporter #### 软件架构 结合prometheus SDK 开发监控tcp端口插件 #### 安装教程 yum install tcp_exporter_xxx.rpm #### 使用说明 1. 修改配置 vim config.yaml ``` --- servers: - name: ssh description: ssh连接端口 src: - "127.0.0.1" dst: - "172.16.11.22" dstport: - 22 #ssh_user: root # 尽量使用地权限用户,源地址为程序运行的当前主机,可以不用配置 #ssh_key: /root/.ssh/id_rsa # 免密的私钥文件 ssh_port: 22 - name: db description: 数据库 src: - "127.0.0.1" dst: - "172.16.11.22" dstport: - 3306 - 3307 #ssh_user: root # 尽量使用地权限用户,源地址为程序运行的当前主机,可以不用配置 #ssh_key: /root/.ssh/id_rsa # 免密的私钥文件 ssh_port: 22 ``` 2、启动程序 ``` ./tcp_exporter --config config.yaml --port 8000 --config 指定配置文件 --port 指定监听端口 ``` #### 参与贡献 #### 特技 1. 使用 Readme\_XXX.md 来支持不同的语言,例如 Readme\_en.md, Readme\_zh.md 2. Gitee 官方博客 [blog.gitee.com](https://blog.gitee.com) 3. 你可以 [https://gitee.com/explore](https://gitee.com/explore) 这个地址来了解 Gitee 上的优秀开源项目 4. [GVP](https://gitee.com/gvp) 全称是 Gitee 最有价值开源项目,是综合评定出的优秀开源项目 5. Gitee 官方提供的使用手册 [https://gitee.com/help](https://gitee.com/help) 6. Gitee 封面人物是一档用来展示 Gitee 会员风采的栏目 [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/)