群晖dsm7安装哪吒监控 简易教程

[复制链接]
查看: 8666   回复: 1
发表于 2023-11-25 10:01:54 | 显示全部楼层 |阅读模式
研究了下 其实挺简单

dsm7的群晖 启动项管理 变成了 systemd

路径在 /usr/lib/systemd/system/

那么就简单了


  1. // ssh登陆群晖 然后切换成rootsudo -scd  /volume1/@apphomemkdir NezhaAgent// 这里得注意 下载你群晖对应架构的agentwget https://github.com/naiba/nezha/releases/download/v0.12.3/nezha-agent_linux_amd64.tar.gztar -zxvf nezha-agent_linux_amd64.tar.gzchmod +x nezha-agent//下面就设置systemd脚本vim /usr/lib/systemd/system/nezha-agent.service[Unit]Description=Nezha AgentAfter=syslog.target#After=network.target#After=nezha-dashboard.service[Service]# Modify these two values and uncomment them if you have# repos with lots of files and get an HTTP error 500 because# of that####LimitMEMLOCK=infinity#LimitNOFILE=65535Type=simpleUser=rootGroup=rootWorkingDirectory=/volume1/@apphome/NezhaAgentExecStart=/volume1/@apphome/NezhaAgent/nezha-agent --report-delay 3 --disable-command-execute --skip-conn --skip-procs -s 你自己的服务器:443 -p 你自己的密钥 --tlsRestart=always#Environment=DEBUG=true# Some distributions may not support these hardening directives. If you cannot start the service due# to an unknown option, comment out the ones not supported by your version of systemd.#ProtectSystem=full#PrivateDevices=yes#PrivateTmp=yes#NoNewPrivileges=true[Install]WantedBy=multi-user.target//然后启用就行了systemctl daemon-reloadsystemctl enable nezha-agentsystemctl start nezha-agent// 看下状态systemctl status nezha-agent
复制代码

就这么简单
回复

使用道具 举报

 楼主| 发表于 2023-11-25 10:02:23 | 显示全部楼层
不好意思,鄙人看不懂
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则