- Notifications
You must be signed in to change notification settings - Fork0
ECIAP/Linux-Beginner-Guide-and-One-click-script
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
本文可能非常长,请妥善运用页面搜索功能(Ctrl + F) / 前往Wiki
查看当前Linux系统
lsb_release -a
正常情况下可看见
Distributor ID: Debian 此处Debian可以为其他系统运行此命令出现 -bash: lsb_release: command not found 时
Debian:apt-get -y install wget Ubuntu:apt-get -y install wget Centos:yum -y install wget
查看VPS虚拟化技术
安装virt-what
Debian:apt -y install virt-whatUbuntu:apt -y install virt-whatCentos:yum -y install virt-what- 输入virt-what等待输出 输出内容通常为:kvm/openvz/xen/Hyper-v/... 代表意义请自行Google / Baidu / Bing
简单查看内存(包含Mem 与 Swap)
free -h等待输出 通常为以下格式
total(总量) used(已占用)free(空闲) shared buff/cache available
Mem: 1G 0M 1G 0K 0M 0MSwap: 2G 0M 2G简单查看硬盘
df -h等待输出
硬盘与实际大小不符时可运行(参考:https://mengniuge.com/vps-resize2fs.html)
resize2fs /dev/vda1 /dev/vda1替换为你要修正的硬盘
简单查看磁盘分区
fdisk -l- 等待输出
简单查看CPU
lscpu- 等待输出
一键添加swap脚本 (from:https://www.moerats.com/archives/722/)
wget https://raw.githubusercontent.com/ECIAP/Linux-novice-one-click-script-summary/master/swap.sh && bash swap.sh运行此脚本出现 -bash: wget: command not found时
Debian:apt-get -y install wget Ubuntu:apt-get -y install wget Centos:yum -y install wget
bbr 原版/魔改/plus+锐速 四合一脚本 (from:https://github.com/chiakge/Linux-NetSpeed)
wget -N --no-check-certificate "https://raw.githubusercontent.com/chiakge/Linux-NetSpeed/master/tcp.sh" chmod +x tcp.sh ./tcp.sh如果运行此脚本出现证书错误时
Debian: apt-get -y install ca-certificatesUbuntu: apt-get -y install ca-certificatesCentos: yum -y install ca-certificates
About
减少敲指令的繁琐
Topics
Resources
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Releases
No releases published
Packages0
No packages published
Uh oh!
There was an error while loading.Please reload this page.