0
点赞
收藏
分享

微信扫一扫

【TcaplusDB知识库】Tmonitor单机安装指引介绍(一)

【TcaplusDB知识库】Tmonitor单机安装指引介绍(一)

本节分别介绍Tmonitor web portal和后台进程的安装部署,web portal和后台最好能分别安装在不同的机器上。注意:所有操作均在root权限下执行。 安装需要3个包(以安装时最新的发布包为准):

  1. web_portal_2.2.18_05130ad9.tar.gz 主要是Tmonitor管理页面
  2. tmonitor_install_2.2.18_05130ad9.tar.gz 主要是Tmonitor后台进程

我们要把Tmonitor 与tcaplus center 安装在同一台机器上, 先把上面的3个包上传到/data 目录, 解压

1. Tmonitor Web Portal安装

  1. cd /data/web_portal/, 由于tcaplus OMS 已经占用80端口, 所以修改conf 文件, Listen 8080 端口. 修改server.php, set_httpd_port(8080)
  2. 检查数据库datadir 所在磁盘是否够用. 如果不够用就改到/data 盘下
  3. root 用户登陆mysql
  4. mysql> create database tmonitor_center_db; -- 特别注意, tmonitor前台的数据库和后台数据库是分开的, 前台数据库用这个名字, 后台用其他的名字
  5. mysql -uroot -pxxxx -Dtmonitor_center_db < *.sql 把/data/web_portal 目录下的所有sql 文件导入
  6. mysql> create user tmonitor;
  7. grant ALL on tmonitor_center_db.* to 'tmonitor'@'%' identified by 'xxxx'
  8. grant ALL on tmonitor_center_db.* to 'tmonitor'@'localhost' identified by 'xxxx'
  9. grant ALL on tmonitor_center_db.* to 'tmonitor'@'127.0.0.1' identified by 'xxxx'
  10. grant ALL on tmonitor_center_db.* to 'tmonitor'@'100.78.65.157' identified by 'xxxx'
  11. grant ALL on tmonitor_center_db.* to 'tmonitor'@'100_78_65_157' identified by 'xxxx- echo $HOSTNAME
  12. flush privileges
  13. 切换到root 用户, 执行 ./install_web_protal.sh 100.78.65.157 3306 tmonitor_center_db tmonitor xxxx PASSWORD 2.2.7 (倒数第二个参数是LoginType, 可以填OA 或者PASSWORD), 这个脚本会创建/data/monitor 目录, 前台页面会从这个目录下启动
  14. 然后netstat –lpn 检查8080 端口是否启动, 如果没有, 重装试试 , php server.php start -p 8080 启动, 停止的命令: php server.php stop
  15. 登陆到页面, 注册用户tmonitor, 如果无法登陆, telnet ip 端口看看 select * from tm_users_permission; 看看是不是管理员权限(role=1)
  16. 【TcaplusDB知识库】Tmonitor单机安装指引介绍(一)_数据库
  17. 点击”管理” 按钮, 把正在部署的tmonitor系统添加进来, 等后台进程起来后就可以提供服务了
  18. 【TcaplusDB知识库】Tmonitor单机安装指引介绍(一)_nosql_02
  19. 到这里前台安装完毕, 下面安装后台进程

2. Tmonitor Web Portal添加Tmonitor系统

  1. https://git.code.oa.com/gcloud_storage_group/tmonitor 代码及安装包在此, 可能需要申请git权限
  2. 上传web_portal_2.2.18_05130ad9.tar.gz 包到/data 目录下, 解压, cd /data/tmonitor_install
  3. vim tmonitor_conf.xml 修改以下内容
  4. 【TcaplusDB知识库】Tmonitor单机安装指引介绍(一)_数据库_03
  5. 告警发送使用下图所用的接口. 如果是IDC 机器, 使用tof 发送短信和微信, 使用uwork 打打电话
  6. 【TcaplusDB知识库】Tmonitor单机安装指引介绍(一)_腾讯游戏_04
  7. 如果是IDC 机器, 需要在tof 和uwork”服务ip” 列表中添加sasvr 的ip, 才能正常发送告警(tof 申请: http://tof.oa.com/application/views/, 或联系jasonlzhang, uwork 申请联系 yorkershi).
  8. 机器要能直接连tnm2, 需要安装agent 工具, 具体步骤在文档后面描述.
  9. 【TcaplusDB知识库】Tmonitor单机安装指引介绍(一)_tcaplusdb_05
  10. 上图中dcsvr 的business_id 默认改成1, 如果有多个dcsvr 就依次增加. dc_tconnd 的端口用7980, 保持默认不需更改
  11. 【TcaplusDB知识库】Tmonitor单机安装指引介绍(一)_tcaplusdb_06

更多信息请关注TcaplusDB微信公众号,风里雨里,我们一直在等你!

【TcaplusDB知识库】Tmonitor单机安装指引介绍(一)_nosql_07

TcaplusDB是腾讯出品的分布式NoSQL数据库,存储和调度的代码完全自研。具备缓存+落地融合架构、PB级存储、毫秒级时延、无损水平扩展和复杂数据结构等特性。同时具备丰富的生态、便捷的迁移、极低的运维成本和五个九高可用等特点。客户覆盖游戏、互联网、政务、金融、制造和物联网等领域。

举报

相关推荐

0 条评论