Update from Sync Service
This commit is contained in:
@@ -1,49 +1,106 @@
|
|||||||
---
|
---
|
||||||
title: Linux 索引
|
title: Linux 索引
|
||||||
tags:
|
tags:
|
||||||
|
- Linux
|
||||||
|
- CentOS
|
||||||
|
- Ubuntu
|
||||||
- 索引
|
- 索引
|
||||||
created: 2026-04-21
|
created: 2026-04-21
|
||||||
|
updated: 2026-04-21
|
||||||
---
|
---
|
||||||
|
|
||||||
# Linux
|
# Linux 知识索引
|
||||||
|
|
||||||
> 自动生成的索引文件
|
> Linux 系统学习笔记汇总
|
||||||
|
|
||||||
## 文件列表
|
## 📚 目录
|
||||||
|
|
||||||
| 文件名 | 大小 | 说明 |
|
### 快速命令
|
||||||
|--------|------|------|
|
| 笔记 | 说明 |
|
||||||
| [[CentOS_CentOS7防火墙设置]] | 9KB | |
|
|------|------|
|
||||||
| [[CentOS_Centos7安装搭建NTP服务器和NTP客户端同步时间]] | 3KB | |
|
| [[常用命令]] | Linux 常用命令汇总 |
|
||||||
| [[CentOS_Harbor 开启https 认证]] | 15KB | |
|
| [[常用命令2]] | 更多常用命令 |
|
||||||
| [[CentOS_Jenkins是开源的,使用Java编写的持续集成的工具,在Centos上可以通过yum命令行直接安装。记录下安装的过程,方便以后查找。]] | 1KB | |
|
| [[Vim命令合集]] | Vim 编辑器命令 |
|
||||||
| [[CentOS_SELinux]] | 10KB | |
|
| [[查看目录大小]] | du/df/ncdu 使用 |
|
||||||
| [[CentOS_centos支持rz、sz命令]] | 388B | |
|
| [[查看CentOS版本]] | 查看系统版本信息 |
|
||||||
| [[CentOS_查看CentOS版本方法]] | 1KB | |
|
|
||||||
| [[CentOS_用户管理]] | 479B | |
|
### CentOS / RHEL
|
||||||
| [[CentOS_调整 home分区 扩大 root分区]] | 1KB | |
|
| 笔记 | 说明 |
|
||||||
| [[CentOS_软件到底安装在哪里-opt or -usr or -usr-local]] | 1KB | |
|
|------|------|
|
||||||
| [[Ubuntu 16.04 64bit 系统的根目录下有这些文件夹]] | 2KB | |
|
| [[CentOS7防火墙设置]] | firewalld 防火墙配置 |
|
||||||
| [[Vim命令合集]] | 8KB | |
|
| [[CentOS7 SELinux配置]] | SELinux 安全管理 |
|
||||||
| [[ubuntu中管理用户和用户组]] | 512B | |
|
| [[CentOS7搭建NTP服务器]] | NTP 时间同步服务 |
|
||||||
| [[ubuntu查看进程]] | 355B | |
|
| [[CentOS安装Jenkins]] | Jenkins 持续集成部署 |
|
||||||
| [[前言]] | 1KB | |
|
| [[CentOS安装Harbor并开启HTTPS]] | Harbor 私有镜像仓库 |
|
||||||
| [[常用命令]] | 11KB | |
|
| [[CentOS使用rz和sz命令]] | 文件上传下载命令 |
|
||||||
| [[常用命令2]] | 23KB | |
|
| [[CentOS用户管理]] | 用户和用户组管理 |
|
||||||
| [[更改所有子文件和子目录所有者权限]] | 1012B | |
|
| [[CentOS调整分区大小]] | 分区扩容/调整 |
|
||||||
| [[查看目录大小]] | 405B | |
|
|
||||||
| [[百度云_百度云一年]] | 166B | |
|
### Ubuntu
|
||||||
| [[给双系统的ubuntu挂载windows的硬盘]] | 1KB | |
|
| 笔记 | 说明 |
|
||||||
| [[阿里云_Php]] | 1KB | |
|
|------|------|
|
||||||
| [[阿里云_Ubuntu 16.04 wordpress环境搭建]] | 182B | |
|
| [[Ubuntu目录结构]] | Ubuntu 系统目录说明 |
|
||||||
| [[阿里云_Ubuntu ftp使用]] | 4KB | |
|
| [[Ubuntu用户管理]] | Ubuntu 用户管理 |
|
||||||
| [[阿里云_Ubuntu管理apache2]] | 4KB | |
|
| [[Ubuntu查看进程]] | 进程查看与管理 |
|
||||||
| [[阿里云_Ubuntu管理mysql]] | 13KB | |
|
| [[Ubuntu挂载Windows硬盘]] | 双系统挂载配置 |
|
||||||
| [[阿里云_Ubuntu管理php]] | 592B | |
|
|
||||||
| [[阿里云_Ubuntu管理wordpress]] | 2KB | |
|
### 通用 Linux
|
||||||
| [[阿里云_Untitled-20260407231646]] | 0B | |
|
| 笔记 | 说明 |
|
||||||
| [[阿里云_mysql用户权限设置]] | 3KB | |
|
|------|------|
|
||||||
| [[阿里云_远程实例]] | 351B | |
|
| [[Linux软件安装位置]] | /opt /usr /usr/local 区别 |
|
||||||
|
| [[修改文件所有者]] | chown/chmod 使用 |
|
||||||
|
|
||||||
|
### 阿里云服务器
|
||||||
|
| 笔记 | 说明 |
|
||||||
|
|------|------|
|
||||||
|
| [[阿里云远程连接]] | SSH 连接阿里云 |
|
||||||
|
| [[阿里云管理MySQL]] | 阿里云 MySQL 配置 |
|
||||||
|
| [[阿里云管理PHP]] | 阿里云 PHP 配置 |
|
||||||
|
| [[阿里云管理WordPress]] | 阿里云 WordPress |
|
||||||
|
| [[阿里云配置Apache]] | Apache Web 服务器 |
|
||||||
|
| [[阿里云使用FTP]] | FTP 服务配置 |
|
||||||
|
| [[阿里云PHP配置]] | PHP 环境配置 |
|
||||||
|
| [[阿里云搭建WordPress]] | WordPress 部署 |
|
||||||
|
|
||||||
|
### MySQL
|
||||||
|
| 笔记 | 说明 |
|
||||||
|
|------|------|
|
||||||
|
| [[MySQL用户权限设置]] | 用户权限管理 |
|
||||||
|
|
||||||
---
|
---
|
||||||
*共 31 个文件*
|
|
||||||
|
## 🔧 常用命令速查
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# 系统信息
|
||||||
|
uname -a # 内核信息
|
||||||
|
cat /etc/os-release # 发行版信息
|
||||||
|
free -h # 内存使用
|
||||||
|
df -h # 磁盘使用
|
||||||
|
|
||||||
|
# 文件操作
|
||||||
|
ls -la # 列出文件
|
||||||
|
cd /path # 切换目录
|
||||||
|
cp -r src dst # 复制
|
||||||
|
mv src dst # 移动
|
||||||
|
rm -rf dir # 删除
|
||||||
|
|
||||||
|
# 进程管理
|
||||||
|
ps aux | grep name # 查看进程
|
||||||
|
top # 任务管理器
|
||||||
|
kill -9 pid # 强制终止
|
||||||
|
|
||||||
|
# 网络
|
||||||
|
netstat -tlnp # 查看端口
|
||||||
|
curl http://url # 测试请求
|
||||||
|
ping host # 测试连通性
|
||||||
|
|
||||||
|
# 服务管理
|
||||||
|
systemctl start service # 启动服务
|
||||||
|
systemctl enable service # 开机自启
|
||||||
|
journalctl -u service # 查看日志
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
*共 30 篇笔记*
|
||||||
|
|||||||
@@ -1,5 +1,57 @@
|
|||||||
## du -sh /*
|
# 查看目录大小
|
||||||
## 可以列出你整个VPS所有文件夹的大小。其中“/*”是控制分析哪个目录的,你根据上面的结果,然后灵活变化后面的路径就行了,例如:
|
|
||||||
## du -sh /usr/*
|
## du 命令
|
||||||
## 用这个命令来分析usr目录下的文件夹大小,最后定位到大文件,直接删除就行了。
|
|
||||||
> 来自 <[https://www.hack520.com/504.html](https://www.hack520.com/504.html)>
|
```bash
|
||||||
|
# 查看当前目录总大小
|
||||||
|
du -sh
|
||||||
|
|
||||||
|
# 查看当前目录下各子目录大小
|
||||||
|
du -h --max-depth=1
|
||||||
|
|
||||||
|
# 查看指定目录大小
|
||||||
|
du -sh /path/to/dir
|
||||||
|
|
||||||
|
# 查看目录下各子目录大小
|
||||||
|
du -sh /path/to/dir/*
|
||||||
|
|
||||||
|
# 按大小排序显示(当前目录)
|
||||||
|
du -sh * | sort -rh
|
||||||
|
|
||||||
|
# 查看隐藏目录
|
||||||
|
du -sh .[!.]* 2>/dev/null
|
||||||
|
|
||||||
|
# 查找大于 100M 的文件
|
||||||
|
find . -type f -size +100M -exec du -h {} \;
|
||||||
|
```
|
||||||
|
|
||||||
|
## df 命令(查看磁盘使用情况)
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# 查看磁盘使用情况
|
||||||
|
df -h
|
||||||
|
|
||||||
|
# 查看 inode 使用情况
|
||||||
|
df -i
|
||||||
|
|
||||||
|
# 查看特定文件系统
|
||||||
|
df -h /home
|
||||||
|
```
|
||||||
|
|
||||||
|
## ncdu(更友好的交互式工具)
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# 安装
|
||||||
|
yum install ncdu # CentOS
|
||||||
|
apt install ncdu # Ubuntu
|
||||||
|
|
||||||
|
# 交互式查看(按大小排序)
|
||||||
|
ncdu /
|
||||||
|
|
||||||
|
# 只显示大于 100MB
|
||||||
|
ncdu --max-size 100M /
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
> 参考:[du 命令详解](https://www.hack520.com/504.html)
|
||||||
|
|||||||
Reference in New Issue
Block a user