{"id":50970,"date":"2024-08-22T07:23:12","date_gmt":"2024-08-21T23:23:12","guid":{"rendered":"http:\/\/lrxjmw.cn\/?p=50970"},"modified":"2024-08-22T07:23:12","modified_gmt":"2024-08-21T23:23:12","slug":"rtop-ssh","status":"publish","type":"post","link":"https:\/\/lrxjmw.cn\/rtop-ssh.html","title":{"rendered":"rtop \u901a\u8fc7 SSH \u76d1\u63a7\u8fdc\u7a0b\u4e3b\u673a"},"content":{"rendered":"
rtop<\/a>\u00a0\u662f\u4e00\u4e2a\u57fa\u4e8e SSH \u7684\u76f4\u63a5\u7684\u4ea4\u4e92\u5f0f\u8fdc\u7a0b\u7cfb\u7edf\u76d1\u63a7\u5de5\u5177<\/a>\uff0c\u5b83\u6536\u96c6\u5e76\u663e\u793a\u91cd\u8981\u7684\u7cfb\u7edf\u6027\u80fd\u6307\u6807\uff0c\u5982 CPU\u3001\u78c1\u76d8\u3001\u5185\u5b58\u548c\u7f51\u7edc\u6307\u6807\u3002<\/p>\n \u5b83\u7528 Go \u8bed\u8a00<\/a>\u7f16\u5199\uff0c\u4e0d\u9700\u8981\u5728\u8981\u76d1\u89c6\u7684\u670d\u52a1\u5668\u4e0a\u5b89\u88c5\u4efb\u4f55\u989d\u5916\u7684\u7a0b\u5e8f\uff0c\u9664\u4e86 SSH \u670d\u52a1\u5668\u548c\u767b\u5f55\u51ed\u636e\u3002<\/p>\n rtop \u57fa\u672c\u4e0a\u662f\u901a\u8fc7\u542f\u52a8 SSH \u4f1a\u8bdd\u548c\u5728\u8fdc\u7a0b\u670d\u52a1\u5668\u4e0a\u6267\u884c\u67d0\u4e9b\u547d\u4ee4<\/a>\u6765\u6536\u96c6\u5404\u79cd\u7cfb\u7edf\u6027\u80fd\u4fe1\u606f\u3002<\/p>\n \u4e00\u65e6 SSH \u4f1a\u8bdd\u5efa\u7acb\uff0c\u5b83\u6bcf\u9694\u51e0\u79d2\uff08\u9ed8\u8ba4\u60c5\u51b5\u4e0b\u4e3a 5 \u79d2\uff09\u5237\u65b0\u6765\u81ea\u8fdc\u7a0b\u670d\u52a1\u5668\u6536\u96c6\u7684\u4fe1\u606f\uff0c\u7c7b\u4f3c\u4e8e Linux \u4e2d\u7684\u6240\u6709\u5176\u5b83\u7c7b\u4f3c top \u7684\u4f7f\u7528\u7a0b\u5e8f\uff08\u5982 htop\uff09<\/a>\u3002<\/p>\n \u8981\u5b89\u88c5 rtop \u786e\u4fdd\u4f60\u5df2\u7ecf\u5728 Linux \u4e2d\u5b89\u88c5\u4e86 Go\uff08GoLang\uff091.2 \u6216\u66f4\u9ad8\u7248\u672c\uff0c\u5426\u5219\u8bf7\u70b9\u51fb\u4e0b\u9762\u7684\u94fe\u63a5\u6839\u636e\u6b65\u9aa4\u5b89\u88c5 GoLang\uff1a<\/p>\n \u5982\u679c\u4f60\u5df2\u7ecf\u5b89\u88c5\u4e86 Go\uff0c\u8fd0\u884c\u4e0b\u9762\u7684\u547d\u4ee4\u6784\u5efa rtop\uff1a<\/p>\n \u547d\u4ee4\u5b8c\u6210\u540e rtop \u53ef\u6267\u884c\u7a0b\u5e8f\u4f1a\u4fdd\u5b58\u5728 $GOPATH\/bin \u6216\u8005 $GOBIN \u4e2d\u3002<\/p>\n <\/p>\n \u5728 Linux \u4e2d\u6784\u5efa rtop<\/em><\/p>\n \u6ce8\u610f\uff1a\u4f7f\u7528 rtop \u4e0d\u9700\u8981\u4efb\u4f55\u8fd0\u884c\u65f6\u73af\u5883\u6216\u914d\u7f6e\u3002<\/p>\n \u5c1d\u8bd5\u4e0d\u7528\u4efb\u4f55\u6807\u5fd7\u6216\u53c2\u6570\u8fd0\u884c rtop\uff0c \u4f1a\u663e\u793a\u5982\u4e0b\u4fe1\u606f\uff1a<\/p>\n \u793a\u4f8b\u8f93\u51fa\uff1a<\/p>\n \u73b0\u5728\u8ba9\u6211\u4eec\u7528 rtop \u76d1\u63a7\u8fdc\u7a0b Linux \u670d\u52a1\u5668\uff0c\u9ed8\u8ba4\u6bcf 5 \u79d2\u5237\u65b0\u6536\u96c6\u5230\u7684\u4fe1\u606f\uff1a<\/p>\n <\/p>\n rtop \u2013 \u76d1\u63a7\u8fdc\u7a0b Linux \u4e3b\u673a<\/em><\/p>\n \u547d\u4ee4\u4f1a\u6bcf\u9694 10 \u79d2\u5237\u65b0\u7cfb\u7edf\u6027\u80fd\u6307\u6807\uff1a<\/p>\n rtop \u540c\u6837\u53ef\u4ee5\u4f7f\u7528 ssh-agent\u3001\u5bc6\u94a5<\/a>\u6216\u8005\u5bc6\u7801\u6388\u6743\u8fde\u63a5\u3002<\/p>\n \u603b\u7ed3\u4e00\u4e0b\uff0crtop \u662f\u4e00\u4e2a\u7b80\u5355\u6613\u7528\u7684\u8fdc\u7a0b\u670d\u52a1\u5668\u76d1\u63a7\u5de5\u5177\uff0c\u5b83\u4f7f\u7528\u975e\u5e38\u5c11\u4e14\u76f4\u767d\u7684\u9009\u9879\u3002\u4f60\u53ef\u4ee5\u9605\u8bfb\u670d\u52a1\u5668\u4e2d\u5176\u4ed6\u76d1\u63a7\u7cfb\u7edf\u7684\u547d\u4ee4\u884c\u5de5\u5177<\/a>\u6765\u63d0\u9ad8\u4f60\u7684 Linux \u6027\u80fd\u76d1\u63a7<\/a>\u6280\u80fd\u3002<\/p>\n via: http:\/\/www.tecmint.com\/rtop-monitor-remote-linux-server-over-ssh\/<\/a><\/p>\n \u4f5c\u8005\uff1aAaron Kili<\/a> \u8bd1\u8005\uff1ageekpi<\/a> \u6821\u5bf9\uff1awxy<\/a><\/p>\n \u672c\u6587\u7531 LCTT<\/a> \u539f\u521b\u7f16\u8bd1\uff0cLinux\u4e2d\u56fd<\/a> \u8363\u8a89\u63a8\u51fa<\/p>\n \u539f\u6587\u6765\u81ea\uff1ahttps:\/\/linux.cn\/article-8199-1.html<\/a><\/p>\n\n
$ go get github.com\/rapidloop\/rtop\r\n<\/pre>\n
$ $GOBIN\/rtop\r\n<\/pre>\n
rtop 1.0 - (c) 2015 RapidLoop - MIT Licensed - http:\/\/rtop-monitor.org\r\nrtop monitors server statistics over an ssh connection\r\nUsage: rtop [-i private-key-file] [user@]host[:port] [interval]\r\n-i private-key-file\r\nPEM-encoded private key file to use (default: ~\/.ssh\/id_rsa if present)\r\n[user@]host[:port]\r\nthe SSH server to connect to, with optional username and port\r\ninterval\r\nrefresh interval in seconds (default: 5)\r\n<\/pre>\n
$ $GOBIN\/rtop aaronkilik@10.42.0.1 \r\n<\/pre>\n
$ $GOBIN\/rtop aaronkilik@10.42.0.1 10\r\n<\/pre>\n
\n
\n\n