一命令提示符号
[root@localhost ~]#
root:代表登录用户
localhost:主机名
~:当前所在目录(家目录)
#:超级用户提示符
$:普通用户提示符
二 命令格式
命令 [选项] [参数]
注意:
1、个别命令使用不遵循此格式。
2、当有多个选项时,可以写在一起。
3、简化选项与完整选项,选项是用来调整命令功能。
-a 等于 --all
三 查询目录中的内容:ls
ls [选项] [文件或目录]
选项:
-a:显示所有的文件,包括隐藏文件
-l:显示详细信息
-d:查看目录属性
-h:个性化显示文件大小
-i:显示inode
四 文件权限介绍
五 Linux文件类型
普通文件,目录文件、链接文件,块设备文件,字符设备文件,套接字文件和管道文件。
六 实战
[root@localhost ~]# ls
anaconda-ks.cfg gobin Music
ChangeLog-2.6.0 goc2p Pictures
Desktop golib Public
Documents goproject Templates
Downloads initial-setup-ks.cfg Videos
go1.8.3.linux-amd64.tar.gz linux-2.6.39.tar.bz2
[root@localhost ~]# ls -l
total 89300
-rw-------.1 root root 1579Oct262016 anaconda-ks.cfg
-rw-r--r--.1 root root 12777Dec182003ChangeLog-2.6.0
drwxr-xr-x.2 root root 6Oct282016Desktop
drwxr-xr-x.2 root root 6Oct282016Documents
drwxr-xr-x.2 root root 6Oct282016Downloads
-rw-r--r--.1 root root 90029041Jul815:13 go1.8.3.linux-amd64.tar.gz
drwxr-xr-x.2 root root 15Jul819:26 gobin
drwxr-xr-x.6 root root 4096Jul818:11 goc2p
drwxr-xr-x.4 root root 26Jul819:46 golib
drwxr-xr-x.2 root root 6Jul818:10 goproject
-rw-------.1 root root 1627Oct262016 initial-setup-ks.cfg
-rw-r--r--.1 root root 1383989Nov122016 linux-2.6.39.tar.bz2
drwxr-xr-x.2 root root 6Oct282016Music
drwxr-xr-x.2 root root 6Oct282016Pictures
drwxr-xr-x.2 root root 6Oct282016Public
drwxr-xr-x.2 root root 6Oct282016Templates
drwxr-xr-x.2 root root 6Oct282016Videos
[root@localhost ~]# ls -l /etc/
total 1432
drwxr-xr-x.3 root root 97Oct262016 abrt
-rw-r--r--.1 root root 16Oct262016 adjtime
-rw-r--r--.1 root root 1518Jun72013 aliases
-rw-r--r--.1 root root 12288Oct262016 aliases.db
drwxr-xr-x.2 root root 49Oct262016 alsa
drwxr-xr-x.2 root root 4096Nov122016 alternatives
-rw-------.1 root root 541Jul272015 anacrontab
-rw-r--r--.1 root root 55Mar62015 asound.conf
-rw-r--r--.1 root root 1Nov202015 at.deny
drwxr-xr-x.2 root root 20Oct262016 xml
drwxr-xr-x.6 root root 4096Oct262016 yum
-rw-r--r--.1 root root 970Dec32015 yum.conf
drwxr-xr-x.2 root root 4096Dec32015 yum.repos.d
[root@localhost ~]# ls /dev/
autofs mqueue stdout tty35 tty63
block net tty tty36 tty7
bsg network_latency tty0 tty37 tty8
btrfs-control network_throughput tty1 tty38 tty9
bus null tty10 tty39 ttyS0
cdrom nvram tty11 tty4 ttyS1
char oldmem tty12 tty40 ttyS2
console port tty13 tty41 ttyS3
core ppp tty14 tty42 uhid
cpu ptmx tty15 tty43 uinput
cpu_dma_latency pts tty16 tty44 urandom
crash random tty17 tty45 usbmon0
disk raw tty18 tty46 usbmon1
fd rtc tty19 tty47 vcs
full rtc0 tty2 tty48 vcs1
fuse sda tty20 tty49 vcs2
hidraw0 sda1 tty21 tty5 vcs3
hpet sda2 tty22 tty50 vcs4
hugepages sda3 tty23 tty51 vcs5
initctl sda4 tty24 tty52 vcs6
input sda5 tty25 tty53 vcsa
kmsg sda6 tty26 tty54 vcsa1
log sda7 tty27 tty55 vcsa2
loop-control sg0 tty28 tty56 vcsa3
lp0 sg1 tty29 tty57 vcsa4
lp1 shm tty3 tty58 vcsa5
lp2 snapshot tty30 tty59 vcsa6
lp3 snd tty31 tty6 vfio
mapper sr0 tty32 tty60 vga_arbiter
mcelog stderr tty33 tty61 vhost-net
mem stdin tty34 tty62 zero
[root@localhost ~]# ls -lh
total 88M
-rw-------.1 root root 1.6KOct262016 anaconda-ks.cfg
-rw-r--r--.1 root root 13KDec182003ChangeLog-2.6.0
drwxr-xr-x.2 root root 6Oct282016Desktop
drwxr-xr-x.2 root root 6Oct282016Documents
drwxr-xr-x.2 root root 6Oct282016Downloads
-rw-r--r--.1 root root 86MJul815:13 go1.8.3.linux-amd64.tar.gz
drwxr-xr-x.2 root root 15Jul819:26 gobin
drwxr-xr-x.6 root root 4.0KJul818:11 goc2p
drwxr-xr-x.4 root root 26Jul819:46 golib
drwxr-xr-x.2 root root 6Jul818:10 goproject
-rw-------.1 root root 1.6KOct262016 initial-setup-ks.cfg
-rw-r--r--.1 root root 1.4MNov122016 linux-2.6.39.tar.bz2
drwxr-xr-x.2 root root 6Oct282016Music
drwxr-xr-x.2 root root 6Oct282016Pictures
drwxr-xr-x.2 root root 6Oct282016Public
drwxr-xr-x.2 root root 6Oct282016Templates
drwxr-xr-x.2 root root 6Oct282016Videos
[root@localhost ~]# ls -lh go1.8.3.linux-amd64.tar.gz
-rw-r--r--.1 root root 86MJul815:13 go1.8.3.linux-amd64.tar.gz
[root@localhost ~]# ls -a
.Desktop initial-setup-ks.cfg
..Documents linux-2.6.39.tar.bz2
anaconda-ks.cfg Downloads.local
.bash_history .elinks .mozilla
.bash_logout .esd_auth Music
.bash_profile go1.8.3.linux-amd64.tar.gz Pictures
.bashrc gobin .pki
.cache goc2p Public
ChangeLog-2.6.0 golib .tcshrc
.config goproject Templates
.cshrc .ICEauthorityVideos
[root@localhost ~]# ls -ld /etc/
drwxr-xr-x.130 root root 8192Jul1021:08/etc/
[root@localhost ~]# ls -i
33559702 anaconda-ks.cfg 100738328 goproject
33559705ChangeLog-2.6.033559704 initial-setup-ks.cfg
33575838Desktop33559703 linux-2.6.39.tar.bz2
33575846Documents67163627Music
67163626Downloads100691831Pictures
33559706 go1.8.3.linux-amd64.tar.gz 327Public
33576732 gobin 100691824Templates
371 goc2p 328Videos
67161955 golib
相关推荐
linux基本命令linux基本命令linux基本命令linux基本命令
linux基本命令 linux基本命令
linux基本命令大全, linux下vi命令大全
Linux上执行的基本命令说明及java安装和tomcat安装方法
1. 关於档案/目录处理的命令 ls——列目录 这是最基本的档案指令。 ls 的意义为 "list",也就是将某一个目录或是 某一个档案的内容显示出来。 格式:ls -1ACFLRabcdfgilmnopqrstux -W[sv] [files] 例: #ls (不跟...
LINUX基本命令LINUX基本命令LINUX新手入门必备
linux学习资料,包括linux基本命令,新手入门,高级技巧。
红旗linux基本命令练习
Linux基本命令大全.doc 喜欢的欢迎下载哦
Linux常用命令Linux常用命令Linux常用命令Linux常用命令
linux基本命令大全.pdf
linux基本命令练习讲解分析 一些常用的基本命令,压缩命令,vi一般用法,认识SHELL,帐号管理,开机流程简介
第三章 Linux 基本命令操作 Linux 终端介绍、 Shell 提示符、 Bash 基本诧法 3.1.1 登彔 Linux 终端 认识终端: 在 Linux 系统中,计算机显示器通常被称为控制台终端(Console)。它仺真了类型为 Linux 的一种终 端...
Linux常见命令总结 、基本命令、目录操作命令、文件操作命令、压缩文件操作、查找命令、权限命令、其他命令 Linux常见命令总结 、基本命令、目录操作命令、文件操作命令、压缩文件操作、查找命令、权限命令、其他...
最新-Linux常用命令大全-非常实用 Linux基本命令-随堂笔记
linux基本命令表,不大,但是很实用!!
Linux基本命令和工具参考文档。
本人归纳的所有Linux基本命令操作,并有详细操作截图和思路。适合初学者下载学习。
LINUX 基本 操作 命令LINUX基本命令
01 Linux基本命令.ppt