1、查看缓存中使用的命令和命令路径

 [wskwskwsk@localhost /]$ hash
 命中     命令
          /usr/bin/printenv
        /usr/bin/ls
          /usr/bin/clear

2、查看系统时间

 [wskwskwsk@localhost /]$ date
 2015年 07月 28日 星期二 :: CST

3、查看ls命令手册

 [wskwskwsk@localhost /]$ man ls
 LS()                                                                                            User Commands                                                                                            LS()

 NAME
        ls - list directory contents

 SYNOPSIS
        ls [OPTION]... [FILE]...

 DESCRIPTION
        List information about the FILEs (the current directory by default).  Sort entries alphabetically if none of -cftuvSUX nor --sort is specified.

        Mandatory arguments to long options are mandatory for short options too.

        -a, --all
               do not ignore entries starting with .

        -A, --almost-all
               do not list implied . and ..

        --author
               with -l, print the author of each file

        -b, --escape
               print C-style escapes for nongraphic characters

        --block-size=SIZE
               scale sizes by SIZE before printing them; e.g., ,, bytes; see SIZE format below

        -B, --ignore-backups
               do not list implied entries ending with ~

        -c     with -lt: sort by, and show, ctime (time of last modification of file status information); with -l: show ctime and sort by name; otherwise: sort by ctime, newest first

        -C     list entries by columns

        --color[=WHEN]
               colorize the output; WHEN can be 'never', 'auto', or 'always' (the default); more info below

        -d, --directory
               list directories themselves, not their contents

        -D, --dired
               generate output designed for Emacs' dired mode

        -f     do not sort, enable -aU, disable -ls --color

        -F, --classify
               append indicator (one of */=>@|) to entries

        --file-type
               likewise, except do not append '*'

        --format=WORD
               across -x, commas -m, horizontal -x, , verbose -l, vertical -C

        --full-time
               like -l --time-style=full-iso

        -g     like -l, but do not list owner

        --group-directories-first
               group directories before files;

               can be augmented with a --sort option, but any use of --sort=none (-U) disables grouping

        -G, --no-group
               in a long listing, don't print group names

4、获得命令的使用帮助。

内部命令:例如(help cd)

外部命令:例如(ls --help)

 [wskwskwsk@localhost /]$ ls --help
 用法:ls [选项]... [文件]...
 List information about the FILEs (the current directory by default).
 Sort entries alphabetically if none of -cftuvSUX nor --sort is specified.

 Mandatory arguments to long options are mandatory for short options too.
   -a, --all                     不隐藏任何以. 开始的项目
   -A, --almost-all              列出除. 及.. 以外的任何项目
       --author                  与-l 同时使用时列出每个文件的作者
   -b, --escape                  以八进制溢出序列表示不可打印的字符
       --block-size=SIZE      scale sizes by SIZE before printing them; e.g.,
                                '--block-size=M' prints sizes in units of
                                ,, bytes; see SIZE format below
   -B, --ignore-backups       do not list implied entries ending with ~
   -c                         with -lt: sort by, and show, ctime (time of last
                                modification of file status information);
                                with -l: show ctime and sort by name;
                                otherwise: sort by ctime, newest first
   -C                         list entries by columns
       --color[=WHEN]         colorize the output; WHEN can be 'never', 'auto',
                                or 'always' (the default); more info below
   -d, --directory            list directories themselves, not their contents
   -D, --dired                generate output designed for Emacs' dired mode
   -f                         do not sort, enable -aU, disable -ls --color
   -F, --classify             append indicator (one of */=>@|) to entries
       --file-type            likewise, except do not append '*'
       --format=WORD          across -x, commas -m, horizontal -x, long -l,
                                single-column -, verbose -l, vertical -C
       --full-time            like -l --time-style=full-iso
   -g                            类似-l,但不列出所有者
       --group-directories-first
                              group directories before files;
                                can be augmented with a --sort option, but any
                                use of --sort=none (-U) disables grouping
   -G, --no-group                以一个长列表的形式,不输出组名
   -h, --human-readable          与-l 一起,以易于阅读的格式输出文件大小
                                 (例如 1K 234M 2G)
       --si                      同上面类似,但是使用1000 为基底而非1024
   -H, --dereference-command-line
                              follow symbolic links listed on the command line
       --dereference-command-line-symlink-to-dir
                              follow each command line symbolic link
                                that points to a directory
       --hide=PATTERN         do not list implied entries matching shell PATTERN
                                (overridden by -a or -A)
       --indicator-style=WORD  append indicator with style WORD to entry names:
                                none (default), slash (-p),
                                file-type (--file-type), classify (-F)
   -i, --inode                print the index number of each file
   -I, --ignore=PATTERN       do not list implied entries matching shell PATTERN
   -k, --kibibytes            -byte blocks for disk usage
   -l                            使用较长格式列出信息
   -L, --dereference             当显示符号链接的文件信息时,显示符号链接所指示
                                 的对象而并非符号链接本身的信息
   -m                            所有项目以逗号分隔,并填满整行行宽
   -n, --numeric-uid-gid         类似 -l,但列出UID 及GID 号
   -N, --literal                 输出未经处理的项目名称 (如不特别处理控制字符)
   -o                            类似 -l,但不列出有关组的信息
   -p,  --indicator-style=slash  对目录加上表示符号"/"
   -q, --hide-control-chars   print ? instead of nongraphic characters
       --show-control-chars   show nongraphic characters as-is (the default,
                                unless program is 'ls' and output is a terminal)
   -Q, --quote-name           enclose entry names in double quotes
       --quoting-style=WORD   use quoting style WORD for entry names:
                                literal, locale, shell, shell-always, c, escape
   -r, --reverse                 逆序排列
   -R, --recursive               递归显示子目录
   -s, --size                    以块数形式显示每个文件分配的尺寸
   -S                         sort by file size
       --sort=WORD            sort by WORD instead of name: none (-U), size (-S),
                                time (-t), version (-v), extension (-X)
       --time=WORD            with -l, show time as WORD instead of default
                                modification time: atime or access or use (-u)
                                ctime or status (-c); also use specified time
                                as sort key if --sort=time
       --time-style=STYLE     with -l, show times using style STYLE:
                                full-iso, long-iso, iso, locale, or +FORMAT;
                                FORMAT is interpreted like in 'date'; if FORMAT
                                is FORMAT1<newline>FORMAT2, then FORMAT1 applies
                                to non-recent files and FORMAT2 to recent files;
                                if STYLE is prefixed with 'posix-', STYLE
                                takes effect only outside the POSIX locale
   -t                         sort by modification time, newest first
   -T, --tabsize=COLS         assume tab stops at each COLS instead of
   -u                         with -lt: sort by, and show, access time;
                                with -l: show access time and sort by name;
                                otherwise: sort by access time
   -U                         do not sort; list entries in directory order
   -v                         natural sort of (version) numbers within text
   -w, --width=COLS           assume screen width instead of current value
   -x                         list entries by lines instead of by columns
   -X                         sort alphabetically by entry extension
   -                         list one file per line

 SELinux options:

   --lcontext                 Display security context.   Enable -l. Lines
                              will probably be too wide for most displays.
   -Z, --context              Display security context so it fits on most
                              displays.  Displays only mode, user, group,
                              security context and file name.
   --scontext                 Display only security context and file name.
       --help            显示此帮助信息并退出
       --version         显示版本信息并退出

 SIZE **).  Units
 are K, M, G, T, P, E, Z, Y (powers of ) or KB, MB, ... (powers of ).

 使用色彩来区分文件类型的功能已被禁用,默认设置和 --color=never 同时禁用了它。
 使用 --color=auto 选项,ls 只在标准输出被连至终端时才生成颜色代码。
 LS_COLORS 环境变量可改变此设置,可使用 dircolors 命令来设置。

 退出状态:
    正常
    一般问题 (例如:无法访问子文件夹)
    严重问题 (例如:无法使用命令行参数)

 GNU coreutils online help: <http://www.gnu.org/software/coreutils/>
 请向<http://translationproject.org/team/zh_CN.html> 报告ls 的翻译错误
 要获取完整文档,请运行:info coreutils 'ls invocation'

查看当前命令的第几节

 [wskwskwsk@localhost /]$ man  read
 READ()                                                                                    Linux Programmer's Manual                                                                                    READ(2)

 NAME
        read - read from a file descriptor

 SYNOPSIS
        #include <unistd.h>

        ssize_t read(int fd, void *buf, size_t count);

 DESCRIPTION
        read() attempts to read up to count bytes from file descriptor fd into the buffer starting at buf.

        On  files  that  support seeking, the read operation commences at the current file offset, and the file offset is incremented by the number of bytes read.  If the current file offset is at or past the
        end of file, no bytes are read, and read() returns zero.

        If count  returns zero and has no other effects.

        If count is greater than SSIZE_MAX, the result is unspecified.

 RETURN VALUE
        On success, the number of bytes read is returned (zero indicates end of file), and the file position is advanced by this number.  It is not an error if this number is smaller than the number of  bytes
        requested;  this may happen for example because fewer bytes are actually available right now (maybe because we were close to end-of-file, or because we are reading from a pipe, or from a terminal), or
        because read() was interrupted by a signal.  On error, - is returned, and errno is set appropriately.  In this case it is left unspecified whether the file position (if any) changes.

 ERRORS
        EAGAIN The file descriptor fd refers to a file other than a socket and has been marked nonblocking (O_NONBLOCK), and the read would block.

        EAGAIN or EWOULDBLOCK
               The file descriptor fd refers to a socket and has been marked nonblocking (O_NONBLOCK), and the read would block.  POSIX.- allows either error to be returned for this case,  and  does  not
               require these constants to have the same value, so a portable application should check for both possibilities.

        EBADF  fd is not a valid file descriptor or is not open for reading.

        EFAULT buf is outside your accessible address space.

        EINTR  The call was interrupted by a signal before any data was read; see signal().

        EINVAL fd is attached to an object which is unsuitable for reading; or the file was opened with the O_DIRECT flag, and either the address specified in buf, the value specified in count, or the current
               file offset is not suitably aligned.

        EINVAL fd was created via a call to timerfd_create() and the wrong size buffer was given to read(); see timerfd_create() for further information.

        EIO    I/O error.  This will happen for example when the process is in a background process group, tries to read from its controlling terminal, and either it is ignoring or  blocking  SIGTTIN  or  its
               process group is orphaned.  It may also occur when there is a low-level I/O error while reading from a disk or tape.

        EISDIR fd refers to a directory.

        Other  errors  may  occur, depending on the  (with errno set to EINTR) or to return the number of
        bytes already read.

 CONFORMING TO
        SVr4, .3BSD, POSIX.-.

 NOTES
        On NFS file systems, reading small amounts of data will update the timestamp only the first time, subsequent calls may not do so.  This is caused by client side attribute caching, because most if  not
        all  NFS  clients  leave  st_atime  (last  file access time) updates to the server and client side reads satisfied from the client's cache will not cause st_atime updates on the server as there are no
        server side reads.  UNIX semantics can be obtained by disabling client side attribute caching, but in most situations this will substantially increase server load and decrease performance.

 SEE ALSO
        close(), fcntl(), ioctl(), lseek(), open(), pread(), readdir(), readlink(), readv(), ), write(), fread()

 COLOPHON
        This page is part of release 3.53 of the Linux man-pages project.  A description of the project, and information about reporting bugs, can be found at http://www.kernel.org/doc/man-pages/.

 Linux                                                                                              --             

5、光标快速定位快捷键

6、给命令起一个别名,快速执行简单命令

1

马哥教育视频笔记:01(Linux常用命令)的更多相关文章

  1. linux学习笔记2 - linux常用命令

    转载请标注原链接:http://www.cnblogs.com/xczyd/p/5543731.html 第一篇博客:linux学习笔记1-ubuntu的安装与基本设置 之中,已经介绍了如何安装lin ...

  2. Linux学习笔记之五————Linux常用命令之用户、权限管理

    一.引言 用户是Unix/Linux系统工作中重要的一环,用户管理包括用户与组账号的管理. 在Unix/Linux系统中,不论是由本机或是远程登录系统,每个系统都必须拥有一个账号,并且对于不同的系统资 ...

  3. Linux学习笔记之四————Linux常用命令之文件管理

    Linux命令——文件管理相关命令 <1>查看文件信息:ls ls是英文单词list的简写,其功能为列出目录的内容,是用户最常用的命令之一,它类似于DOS下的dir命令. Linux文件或 ...

  4. linux笔记:linux常用命令-权限管理命令

    一个文件的权限只有root和所有者可以更改. 权限管理命令:chmod(改变文件或目录的权限) 权限的数字表示: 用权限加减的方式改变权限(u代表所有者,g代表所属组,o代表其他人,a代表所有人): ...

  5. linux笔记:linux常用命令-目录和文件处理命令

    命令格式: 命令 [-选项] [参数] 例: ls -la /etc 注意:个别命令的使用不遵循此格式. 目录处理命令:ls(列目录) 更多选项: -h 以kb等利于人阅读的方式取代字节显示文件大小 ...

  6. Linux学习笔记之七————Linux常用命令之编辑器、服务器

    <1>gedit编辑器 gedit是一个Linux环境下的文本编辑器,类似windows下的写字板程序,在不需要特别复杂的编程环境下,作为基本的文本编辑器比较合适.   <2> ...

  7. Linux学习笔记之六————Linux常用命令之系统管理

    <1>查看当前日历:cal cal命令用于查看当前日历,-y显示整年日历: <2>显示或设置时间:date 设置时间格式(需要管理员权限): date [MMDDhhmm[[C ...

  8. Linux笔记:linux常用命令

    文件目录操作 1.展示目录命令 ls # 展示当前目录下的可见文件 ls -a # 展示当前目录下所有的文件(包括隐藏的文件) ls -l # 展示当前目录下文件的详细信息 ll # 展示当前目录下文 ...

  9. Linux学习笔记之Linux常用命令剖析-cat/chmod/cd

    1.cat:用于连接文件并打印到标准输出设备上.(使用权限:所有使用者) 语法格式:cat [-AbeEnstTuv] [--help] [--version] fileName 参数说明: -n 或 ...

随机推荐

  1. 1047. Student List for Course (25)

    Zhejiang University has 40000 students and provides 2500 courses. Now given the registered course li ...

  2. PS教程1000例

    http://www.missyuan.com/thread-446934-1-1.html Photoshop绘制逼真头发发丝效果http://www.missyuan.com/thread-446 ...

  3. 学习使用vim,熟悉Linux

    随着对vim一步一步的熟悉,对Linux的资料查阅,在加上今天阅读了王垠的文章,更加的觉得学习vim是正确的选择.抛弃Windows思维,进入Linux的世界,才发现是思维上的转变,如学习英语一样,是 ...

  4. jQuery的常用事件

    1.$(document).ready() $(document).ready()是jQuery中响应JavaScript内置的onload事件并执行任务的一种典型方式.它和onload具有类似的效果 ...

  5. Android 图片轮播(最简单的)

    布局文件 <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" android ...

  6. hadoop-1.2.1安装配置

    1.准备三台节点 hnd1  hnd2  hnd3 下载 hadoop 下载地址:http://apache.fayea.com/hadoop/common/ API文档:http://hadoop. ...

  7. BizTalk开发系列(十) ESB Guidance安装笔记

    ESB指导工具包(ESB Guidance)是一个运行于BizTalk Server 2006 R2之上的一个框架.详细信息访问ESB指导工具包社区网站 .源码下载 ESB Guidance的安装过程 ...

  8. NPOI简单操作excel

    本文仅当是个记录文件,仅供初学者参考. 首先得using几个npoi的空间名如下: using NPOI.HSSF.UserModel;using NPOI.HSSF.Util;using NPOI. ...

  9. NEC学习 ---- 模块 - 带点文字链接列表

    带点文字链接列表, 实现的效果是, 调整字体大小, 点的位置不会跟着变动. HTML如下: <div class="container"> <div class= ...

  10. 浏览器中Javascript的加载和执行

    在刚学习Javascript时曾对该问题在小组内做个一次StudyReport,发现其中的基础还是值得分析的. 从标题分析,可以加个Javascript的加载和执行分为两个阶段:加载.执行.而加载即浏 ...