Merge pull request #5116 from geekpi/master

translated
This commit is contained in:
geekpi 2017-02-10 09:58:58 +08:00 committed by GitHub
commit 1813073d87
2 changed files with 111 additions and 113 deletions

View File

@ -1,113 +0,0 @@
translating---geekpi
rtop An Interactive Tool to Monitor Remote Linux Server Over SSH
============================================================
rtop is a straightforward and interactive, [remote system monitoring tool][2] based on SSH that collects and shows important system performance values such as CPU, disk, memory, network metrics.
It is written in [Go Language][3] and does not require any extra programs to be installed on the server that you want to monitor except SSH server and working credentials.
rtop basically functions by launching an SSH session, and [executing certain commands on the remote server][4] to gather various system performance information.
Once an SSH session is been established, it keeps refreshing the information collected from the remote server every few seconds (5 seconds by default), similar to all other [top-like utilities (like htop)][5] in Linux.
#### Prerequisites:
Make sure you have installed Go (GoLang) 1.2 or higher on your Linux system in order to install rtop, otherwise click on the link below to follow the GoLang installation steps:
1. [Install GoLang (Go Programming Language) in Linux][1]
### How to Install rtop in Linux Systems
If you have Go installed, run the command below to build rtop:
```
$ go get github.com/rapidloop/rtop
```
The rtop executable binary will be saved in $GOPATH/bin or $GOBIN once the command completes executing.
[
![Build rtop in Linux](http://www.tecmint.com/wp-content/uploads/2017/02/Build-rtop-Tool.png)
][6]
Build rtop in Linux
Note: You do not need any runtime dependencies or configurations to start using rtop.
### How to Use rtop in Linux Systems
Try to run rtop without any flags and arguments as below, it will display a usage message:
```
$ $GOBIN/rtop
```
##### Sample Output
```
rtop 1.0 - (c) 2015 RapidLoop - MIT Licensed - http://rtop-monitor.org
rtop monitors server statistics over an ssh connection
Usage: rtop [-i private-key-file] [user@]host[:port] [interval]
-i private-key-file
PEM-encoded private key file to use (default: ~/.ssh/id_rsa if present)
[user@]host[:port]
the SSH server to connect to, with optional username and port
interval
refresh interval in seconds (default: 5)
```
Now lets monitor the remote Linux server using rtop as follows, while refreshing the information gathered after an interval of 5 seconds by default:
```
$ $GOBIN/rtop aaronkilik@10.42.0.1
```
[
![rtop - Monitor Remote Linux Server](http://www.tecmint.com/wp-content/uploads/2017/02/Monitor-Remote-Linux-Server.png)
][7]
rtop Monitor Remote Linux Server
The command below will refresh the system performance metrics collected after every 10 seconds:
```
$ $GOBIN/rtop aaronkilik@10.42.0.1 10
```
rtop can also connect using ssh-agent, [private keys][8] or password authentication.
Visit rtop Github repository: [https://github.com/rapidloop/rtop][9]
As a concluding remark, rtop is a simple and easy-to-use remote server monitoring tool, it uses very few and direct options. You can as well read about several other [command line tools to monitor your system][10] so as to improve your [Linux performance monitoring][11] skills.
Lastly, get in touch with us via the comment section below for any questions or remarks.
--------------------------------------------------------------------------------
作者简介:
Aaron Kili is a Linux and F.O.S.S enthusiast, an upcoming Linux SysAdmin, web developer, and currently a content creator for TecMint who loves working with computers and strongly believes in sharing knowledge.
--------------------------------------------------------------------------------
via: http://www.tecmint.com/rtop-monitor-remote-linux-server-over-ssh/
作者:[Aaron Kili][a]
译者:[译者ID](https://github.com/译者ID)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]:http://www.tecmint.com/author/aaronkili/
[1]:http://www.tecmint.com/install-go-in-linux/
[2]:http://www.tecmint.com/command-line-tools-to-monitor-linux-performance/
[3]:http://www.tecmint.com/install-go-in-linux/
[4]:http://www.tecmint.com/execute-commands-on-multiple-linux-servers-using-pssh/
[5]:http://www.tecmint.com/install-htop-linux-process-monitoring-for-rhel-centos-fedora/
[6]:http://www.tecmint.com/wp-content/uploads/2017/02/Build-rtop-Tool.png
[7]:http://www.tecmint.com/wp-content/uploads/2017/02/Monitor-Remote-Linux-Server.png
[8]:http://www.tecmint.com/ssh-passwordless-login-using-ssh-keygen-in-5-easy-steps/
[9]:https://github.com/rapidloop/rtop
[10]:http://www.tecmint.com/command-line-tools-to-monitor-linux-performance/
[11]:http://www.tecmint.com/linux-performance-monitoring-tools/

View File

@ -0,0 +1,111 @@
rtop - 一个通过 SSH 监控远程主机的交互式工具
============================================================
rtop 是一个基于 SSH 的直接和交互式的[远程系统监控工具][2],它收集并显示重要的系统性能值,如 CPU、磁盘、内存和网络指标。
它用[ Go 语言][3]编写,不需要在要监视的服务器上安装任何额外的程序,除了 SSH 服务器和工作凭据。
rtop 基本上通过启动 SSH 会话和[在远程服务器上执行某些命令][4]来收集各种系统性能信息。
一旦 SSH 会话建立,它每隔几秒(默认情况下为 5 秒)刷新来自远程服务器收集的信息,类似于 Linux 中的所有其他[类似 top 的使用程序如htop][5]。
#### 安装要求:
要安装 rtop 确保你已经在 Linux 中安装了 GoGoLang1.2 或更高版本,不然点击下面的链接根据步骤安装 GoLang
1. [在 Linux 中安装 GoLang Go 编程语言)][1]
### 如何在 Linux 系统中安装 rtop
如果你已经安装了 Go运行下面的命令构建 rtop
```
$ go get github.com/rapidloop/rtop
```
命令完成后 rtop 可执行程序会保存在 $GOPATH/bin 或者 $GOBIN 中。
[
![Build rtop in Linux](http://www.tecmint.com/wp-content/uploads/2017/02/Build-rtop-Tool.png)
][6]
在 Linux 中构建 rtop
注意:开始使用 rtop 不需要任何运行时或配置。
### 如何在 Linux 系统中使用 rtop
尝试不用任何标志或参数运行 rtop 会显示如下信息:
```
$ $GOBIN/rtop
```
##### 示例输出
```
rtop 1.0 - (c) 2015 RapidLoop - MIT Licensed - http://rtop-monitor.org
rtop monitors server statistics over an ssh connection
Usage: rtop [-i private-key-file] [user@]host[:port] [interval]
-i private-key-file
PEM-encoded private key file to use (default: ~/.ssh/id_rsa if present)
[user@]host[:port]
the SSH server to connect to, with optional username and port
interval
refresh interval in seconds (default: 5)
```
现在让我们用 rtop 监控远程 Linux 服务器,默认每 5 秒刷新收集到的信息:
```
$ $GOBIN/rtop aaronkilik@10.42.0.1
```
[
![rtop - Monitor Remote Linux Server](http://www.tecmint.com/wp-content/uploads/2017/02/Monitor-Remote-Linux-Server.png)
][7]
rtop 监控远程 Linux 主机
命令会每隔 10 秒刷新系统性能指标:
```
$ $GOBIN/rtop aaronkilik@10.42.0.1 10
```
rtop 同样可以使用 ssh-agent、[密钥][8]或者密码授权连接。
访问 rtop 的 Github 仓库:[https://github.com/rapidloop/rtop][9]
总结一下rtop 是一个简单易于使用的远程服务器监控工具,它使用非常少且直接的选项。你可以阅读服务器中其他[监控系统的命令行工具][10]来提高你的[ Linux 性能监控][11]技能。
最后,在下面的评论栏中留下你的任何问题和想法。
--------------------------------------------------------------------------------
作者简介:
Aaron Kili 是 Linux 和 F.O.S.S 爱好者,将来的 Linux SysAdmin 和 web 开发人员,目前是 TecMint 的内容创建者,他喜欢用电脑工作,并坚信分享知识。
--------------------------------------------------------------------------------
via: http://www.tecmint.com/rtop-monitor-remote-linux-server-over-ssh/
作者:[Aaron Kili][a]
译者:[geekpi](https://github.com/geekpi)
校对:[校对者ID](https://github.com/校对者ID)
本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译,[Linux中国](https://linux.cn/) 荣誉推出
[a]:http://www.tecmint.com/author/aaronkili/
[1]:http://www.tecmint.com/install-go-in-linux/
[2]:http://www.tecmint.com/command-line-tools-to-monitor-linux-performance/
[3]:http://www.tecmint.com/install-go-in-linux/
[4]:http://www.tecmint.com/execute-commands-on-multiple-linux-servers-using-pssh/
[5]:http://www.tecmint.com/install-htop-linux-process-monitoring-for-rhel-centos-fedora/
[6]:http://www.tecmint.com/wp-content/uploads/2017/02/Build-rtop-Tool.png
[7]:http://www.tecmint.com/wp-content/uploads/2017/02/Monitor-Remote-Linux-Server.png
[8]:http://www.tecmint.com/ssh-passwordless-login-using-ssh-keygen-in-5-easy-steps/
[9]:https://github.com/rapidloop/rtop
[10]:http://www.tecmint.com/command-line-tools-to-monitor-linux-performance/
[11]:http://www.tecmint.com/linux-performance-monitoring-tools/