Home System Tutorial LINUX Linux performance monitoring tool: pyDash

Linux performance monitoring tool: pyDash

Dec 28, 2023 pm 10:21 PM
linux linux tutorial Red Hat linux system linux command linux certification red hat linux linux video

pyDash is a lightweight, web-based Linux performance monitoring tool written in Python and Django plus Chart.js. After testing, it can run on the following mainstream Linux distributions: CentOS, Fedora, Ubuntu, Debian, Raspbian and Pidora.

pyDash : Linux 性能监测工具

You can use this tool to monitor your Linux PC/Server resources such as CPU, memory, network statistics, processes including online users and more. The dashboard is developed entirely with Python libraries provided by major Python distributions, so it has very few dependencies and you don't need to install many packages or libraries to run it.

In this article, I will show you how to install pyDash to monitor Linux server performance.

How to install pyDash under Linux system

1. First, install the required software packages git and Python pip as follows:

-------------- 在 Debian/Ubuntu 上 --------------
$ sudo apt-get install git python-pip
-------------- 在 CentOS/RHEL 上 --------------
# yum install epel-release
# yum install git python-pip
-------------- 在 Fedora 22+ 上 --------------
# dnf install git python-pip
Copy after login

2. If git and Python pip are installed, then install virtualenv as follows, which helps to handle dependencies for Python projects:

# pip install virtualenv
或
$ sudo pip install virtualenv
Copy after login

3. Now, use the git command as follows to clone the pyDash warehouse to the home directory:

# git clone https://github.com/k3oni/pydash.git
# cd pydash
Copy after login

4. Next, use the following virtualenv command to create a virtual environment called pydashtest for the project:

$ virtualenv pydashtest #give a name for your virtual environment like pydashtest
Copy after login

pyDash : Linux 性能监测工具

Create virtual environment

Important: Please note that in the screenshot above, the bin directory of the virtual environment is highlighted, yours may be different depending on where you clone the pyDash directory.

5. After creating the virtual environment (pydashtest), you need to activate it before use as follows:

$ source /home/aaronkilik/pydash/pydashtest/bin/activate
Copy after login

pyDash : Linux 性能监测工具

Activate virtual environment

From the screenshot above, you can notice that prompt string 1 (PS1) has changed, which indicates that the virtual environment has been activated and can be used.

6. Now, install the pydash project requirements; if you are curious, you can use the cat command to view the contents of requirements.txt, and then install it as shown below:

$ cat requirements.txt
$ pip install -r requirements.txt
Copy after login

7. Now, enter the pydash directory, which contains a file named settings.py. You can also directly run the following command to open this file, and then SECRET_KEY Change to a specific value:

$ vi pydash/settings.py
Copy after login

pyDash : Linux 性能监测工具

Set the key

Save the file and exit.

8. After that, run the following commands to create a project database and install Django’s authentication system, and create a superuser for the project:

$ python manage.py syncdb
Copy after login

Answer the following questions based on your situation:

Would you like to create one now? (yes/no): yes
Username (leave blank to use 'root'): admin
Email address: [email protected]
Password: ###########
Password (again): ############
Copy after login

pyDash : Linux 性能监测工具

Create project database

9、这个时候,一切都设置好了,然后,运行下面的命令来启用 Django 开发服务器:

$ python manage.py runserver
Copy after login

10、接下来,打开你的 web 浏览器,输入网址:http://127.0.0.1:8000/ 进入 web 控制台登录界面,输入你在第 8 步中创建数据库和安装 Django 身份验证系统时创建的超级用户名和密码,然后点击登录。

pyDash : Linux 性能监测工具

pyDash 登录界面

11、登录到 pydash 主页面以后,你将会可以看到监测系统的基本信息,包括 CPU、内存和硬盘使用量以及系统平均负载。

向下滚动便可查看更多部分的信息。

pyDash : Linux 性能监测工具

pydash 服务器性能概述

12、下一个屏幕截图显示的是一段 pydash 的跟踪界面,包括 IP 地址、互联网流量、硬盘读/写、在线用户以及 netstats 。

pyDash : Linux 性能监测工具

pyDash 网络概述

13、下一个 pydash 主页面的截图显示了一部分系统中被监视的活跃进程。

pyDash : Linux 性能监测工具

pyDash 监视活跃 Linux 进程

如果想了解更多信息,请在 GitHub 上查看 pydash:https://github.com/k3oni/pydash

这就是全部内容了。在这篇文章中,我们展示了在 Linux 中如何安装 pyDash 并测试它的主要特性。


The above is the detailed content of Linux performance monitoring tool: pyDash. For more information, please follow other related articles on the PHP Chinese website!

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Hot Topics

Java Tutorial
1658
14
PHP Tutorial
1257
29
C# Tutorial
1231
24
Linux Architecture: Unveiling the 5 Basic Components Linux Architecture: Unveiling the 5 Basic Components Apr 20, 2025 am 12:04 AM

The five basic components of the Linux system are: 1. Kernel, 2. System library, 3. System utilities, 4. Graphical user interface, 5. Applications. The kernel manages hardware resources, the system library provides precompiled functions, system utilities are used for system management, the GUI provides visual interaction, and applications use these components to implement functions.

How to check the warehouse address of git How to check the warehouse address of git Apr 17, 2025 pm 01:54 PM

To view the Git repository address, perform the following steps: 1. Open the command line and navigate to the repository directory; 2. Run the "git remote -v" command; 3. View the repository name in the output and its corresponding address.

vscode Previous Next Shortcut Key vscode Previous Next Shortcut Key Apr 15, 2025 pm 10:51 PM

VS Code One-step/Next step shortcut key usage: One-step (backward): Windows/Linux: Ctrl ←; macOS: Cmd ←Next step (forward): Windows/Linux: Ctrl →; macOS: Cmd →

How to run sublime after writing the code How to run sublime after writing the code Apr 16, 2025 am 08:51 AM

There are six ways to run code in Sublime: through hotkeys, menus, build systems, command lines, set default build systems, and custom build commands, and run individual files/projects by right-clicking on projects/files. The build system availability depends on the installation of Sublime Text.

How to run java code in notepad How to run java code in notepad Apr 16, 2025 pm 07:39 PM

Although Notepad cannot run Java code directly, it can be achieved by using other tools: using the command line compiler (javac) to generate a bytecode file (filename.class). Use the Java interpreter (java) to interpret bytecode, execute the code, and output the result.

What is the main purpose of Linux? What is the main purpose of Linux? Apr 16, 2025 am 12:19 AM

The main uses of Linux include: 1. Server operating system, 2. Embedded system, 3. Desktop operating system, 4. Development and testing environment. Linux excels in these areas, providing stability, security and efficient development tools.

laravel installation code laravel installation code Apr 18, 2025 pm 12:30 PM

To install Laravel, follow these steps in sequence: Install Composer (for macOS/Linux and Windows) Install Laravel Installer Create a new project Start Service Access Application (URL: http://127.0.0.1:8000) Set up the database connection (if required)

How to use VSCode How to use VSCode Apr 15, 2025 pm 11:21 PM

Visual Studio Code (VSCode) is a cross-platform, open source and free code editor developed by Microsoft. It is known for its lightweight, scalability and support for a wide range of programming languages. To install VSCode, please visit the official website to download and run the installer. When using VSCode, you can create new projects, edit code, debug code, navigate projects, expand VSCode, and manage settings. VSCode is available for Windows, macOS, and Linux, supports multiple programming languages ​​and provides various extensions through Marketplace. Its advantages include lightweight, scalability, extensive language support, rich features and version

See all articles