惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

P
Privacy & Cybersecurity Law Blog
人人都是产品经理
人人都是产品经理
The Cloudflare Blog
B
Blog RSS Feed
罗磊的独立博客
V
V2EX
V
Visual Studio Blog
博客园 - 叶小钗
W
WeLiveSecurity
小众软件
小众软件
K
Kaspersky official blog
美团技术团队
雷峰网
雷峰网
阮一峰的网络日志
阮一峰的网络日志
Martin Fowler
Martin Fowler
Recorded Future
Recorded Future
Project Zero
Project Zero
Hugging Face - Blog
Hugging Face - Blog
Engineering at Meta
Engineering at Meta
Security Latest
Security Latest
Microsoft Azure Blog
Microsoft Azure Blog
V
Vulnerabilities – Threatpost
月光博客
月光博客
博客园 - 三生石上(FineUI控件)
Help Net Security
Help Net Security
博客园 - Franky
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
F
Fortinet All Blogs
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
Forbes - Security
Forbes - Security
M
MIT News - Artificial intelligence
H
Hacker News: Front Page
大猫的无限游戏
大猫的无限游戏
Vercel News
Vercel News
Spread Privacy
Spread Privacy
The Register - Security
The Register - Security
H
Hackread – Cybersecurity News, Data Breaches, AI and More
量子位
Google Online Security Blog
Google Online Security Blog
PCI Perspectives
PCI Perspectives
The Last Watchdog
The Last Watchdog
AI
AI
N
News | PayPal Newsroom
D
DataBreaches.Net
Cloudbric
Cloudbric
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
博客园 - 司徒正美
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
T
Tailwind CSS Blog

博客园 - 拓子

.net编码规则 tensorflow mnist The tensorflow simplest calculate python opencv english opencv 图片识别 随机概率 从excel 导入数据绘制 散点图 tensor flow 线性回归 一些搞笑,但有意义的图片 基于python玩转人工智能最火框架之TensorFlow人工智能&深度学习介绍 win10 64下anaconda4.2.0(python3.5) PYTHON 爬虫 baidu美女图片 falkonry python hadoop wordcout测试 CENTOS重新安装JDK 搭建Hadoop的环境 目录和权限
centos基本命令
拓子 · 2018-12-30 · via 博客园 - 拓子

$>ls
$>ls --help //查看命令帮助
$>man ls //查看命令帮助

$>clear //清屏
$>cd /home //切换目录
$>cd . //进入当前目录
$>cd .. //进入上级目录
$>cd /home/admin//进入绝对路径

$>pwd //显式当前目录
$>whoami //显式当前用户名

$>su root //切换用户,输入密码,swith user
$>passwd //修改当前用户的密码

$>ifconfig //查看ip地址
$>ping localhost //查看网络连通情况
$>ping www.163.com //查看网络连通情况


$>su admin //切换用户
$>cd /home/admin //到用户目录
$>cd ~ //回到主目录
$>cd - //回到上次的目录
$>ll //别名,ls -l --autocolor...
$>alias //查看所有的别名
$>ls -a -l -h //查看当前目录-h:人性化 -l:列表 -a:显式.开头
$>mkdir ~/Downloads/a //创建目录
$>touch ~/Downloads/a/1.txt //创建文件
$>echo helloworld > 1.txt //重定向输出(覆盖)
$>echo helloworld >> 1.txt //重定向输出(追加模式)
$>cat 1.txt //查看文件
$>cp 1.txt 2.txt //复制文件
$>rm 1.txt //删除文件
$>rm -rf / //强行递归删除
$>mv a.txt tmp/ //强行递归删除


[centos client中切换模式]
ctrl + alt + f6 //切换到文本模式
ctrl + alt //切换鼠标
ctrl + alt + f1 //切换桌面模式.
ctrl + alt + f5 //切换到新的文本模式


$>more a.txt //分屏显式
q:退出
h:帮助
$>more -5 a.txt //显式前5行内容
$>tail a.txt //最后10行内容

$>find . | more // | 是管道符,前面的命令的输出作为后面命令输入。
$>find ~
$>ls -aR ~ //递归显式主目录所有的文件.(a表示包含.开头的文件)
$>head a.txt //显式前10行
$>head -n 10 a.txt //显式前10行
$>head -10 a.txt //显式前10行

$>tail a.txt
$>tail -n 20 a.txt
$>tail -20 a.txt
$>tail --lines=20 a.txt

$>wc -c -l -w a.txt //统计文本信息,
//显式统计信息-c:字节 -l:line -w:word

$>hostname //查看主机名称
$>uname -a //查看系统内核

$>file xxx.xx //查看文件类型
$>gzip a.txt //原地压缩
$>gzip -d a.txt //原地压缩
$>gzip -dr tmp //递归操纵文件夹下的文件
$>gunzip a.txt.gz //等价于gzip -d a.txt

$>tar -cvf my.tar 1.txt tmp //创建归档文件
$>tar -vxf my.tar //解档文件
$>find . | grep txt | cp `xargs` temp //xargs是多行变单行,使用空格替换回车换行符.
//`` : 是强制命令解析。
$>ping `cat a.txt` //命令嵌套
$>which echo //查看命令的文件路径