ubuntu22.04 vnStat来监控网络流量

apt update -y

apt upgrade -y


apt-get install build-essential gcc make libsqlite3-dev -y


wget https://humdi.net/vnstat/vnstat-2.10.tar.gz

tar -xvzf vnstat-2.10.tar.gz


cd vnstat-2.10

./configure --prefix=/usr --sysconfdir=/etc


make

make install

使用systemctl 进行关联

cp -v vnstat-2.10/examples/systemd/vnstat.service /etc/systemd/system/

systemctl enable vnstat

systemctl start vnstat


vnstat

vnstat -i 具体的网卡信息

相关推荐
不像程序员的程序媛3 小时前
系统cpu内存负载资源分析
运维·服务器·数据库
Uncertainty!!5 小时前
Ubuntu 22.04 安装超好用中文输入法rime-ice(雾凇拼音)过程记录
linux·ubuntu·中文输入法
ShineWinsu6 小时前
对于Linux:网络基础的解析
linux·网络·面试·udp·笔试·ip·tcp
Asuicao6 小时前
centos7.9版本升级ssh OpenSSH 9.8p1 源码 OpenSSL 1.1.1w 源码包以及安装升级回滚文档
运维·ssh
耍酷的魔镜6 小时前
谈谈如何使用Netty开发实现高性能的RPC服务器
服务器·网络协议·rpc
志栋智能6 小时前
超自动化安全中的威胁狩猎
运维·安全·自动化
↘"LYong7 小时前
旧版 CentOS 安装 Docker 完整指南(附国内镜像加速)
linux·运维·docker
Zhang~Ling7 小时前
Vim 多模式详解:命令、插入、底行与插件配置
linux·编辑器·vim
Elastic 中国社区官方博客8 小时前
Elastic 在 Everest Group 企业搜索产品 PEAK Matrix® 评估 2026 中被评为领导者
大数据·运维·人工智能·elasticsearch·搜索引擎·ai·全文检索
程序员在囧途8 小时前
likeadmin-api API 中转站怎么做统一报价?从 /pricing、/user/balance 到 task_id 回执的落地方法
运维·服务器·数据库·likeadmin-api·api中转站·token计费