zoukankan      html  css  js  c++  java
  • 【Linux】常用命令

    查找文件
      find /usr/local -name CstmInfoServiceImpl*

    mount、umount
      注意:没有 unmount

    uname
    可以列出目前系统的核心版本、主要硬件平台、CPU类型 等等的信息。
      [root@study ~]#  uname -a
      Linux study.centos.vbird 3.10.0-229.el7.x86_64 #1 SMP Fri Mar 6 11:36:42 UTC 2015
      说明:我的 Linux 主机使用的核心名称为 Linux,而主机名study.centos.vbird核心的版本3.10.0-229.el7.x86_64 ,该核心版本建立的日期2015-3-6适用的硬件平台x86_64 以上等级的硬件平台
      

    关机、重启参考1参考2
      [关机]shutdown -h now(推荐)、poweroff、halt
      [重启]shutdown -r now(推荐)、reboot

    vim 命令合集
      https://www.cnblogs.com/softwaretesting/archive/2011/07/12/2104435.html  

    查看资源占用情况
      
    htop命令查看(推荐)
      或
      
    https://www.cnblogs.com/chengJAVA/p/6115061.html

    查看历史操作
    (默认保存1000行,文件位置 ~/.bash_history) history 查看系统信息 cat /etc/redhat-release uname -a cat /etc/issue #这个好像7以上看不了 cat /proc/version #这个是和内核有关的数据 git安装 https://www.cnblogs.com/shaosks/p/9257563.html 1、下载git wget https://github.com/git/git/archive/v2.14.1.zip 2、安装依赖 yum -y install zlib-devel openssl-devel cpio expat-devel gettext-devel curl-devel perl-ExtUtils-CBuilder perl-ExtUtils-MakeMaker 3、解压git unzip v2.14.1.zip 4、将git安装到/usr/local/git上,先进入git-2.14.1文件夹, 编译,安装 cd git-2.14.1 make prefix=/usr/local all make prefix=/usr/local install 5、验证是否安装完成 git --version 说明安装成功 测网速 wget https://raw.githubusercontent.com/sivel/speedtest-cli/master/speedtest.py chmod +rx speedtest.py sudo mv speedtest.py /usr/local/bin/speedtest-cli sudo chown root:root /usr/local/bin/speedtest-cli speedtest-cli

    修改权限(chmod 命令的2种修改方式。可参考 我的另一篇博客《文件属性、权限介绍》
        1.数字方式修改
            1)读、写、可执行数字对应关系  
                r:4  
                w:2  
                x:1  
            
            2)每种身份(owner/group/others)权限加和  
                owner : rwx = 4+2+1 = 7  
                group : rwx = 4+2+1 = 7  
                others: --- = 0+0+0 = 0  
            
            3)chmod [-R] *** 文件或目录  
                例:修改.bashrc文件权限为-rwxrwxrwx  
                chmod [-R] 777  .bashrc

        2、符号方式修改  
            命令格式:
          chmode u/g/o/a +(加入)/-(除去)/=(设定) r/w/x 文件或目录    
            例:
            1)修改权限为 -rwxr-xr--
                chmod u=rwx,g=rx,o=r filename
            2)所有身份 添加读 权限
                chmod a+w .bashrc
            3)所有身份 取消可执行 权限
                chmod a- - x .bashrc
  • 相关阅读:
    android29
    android28
    android27
    android26
    Dynamics CRM2011 MspInstallAction failed when installing an Update Rollup
    Dynamics CRM Import Solution Attribute Display Name description is null or empty
    The service cannot be activated because it does not support ASP.NET compatibility
    IIS部署WCF报 无法读取配置节“protocolMapping”,因为它缺少节声明
    Unable to access the IIS metabase.You do not have sufficient privilege
    LM算法与非线性最小二乘问题
  • 原文地址:https://www.cnblogs.com/humor-bin/p/12752042.html
Copyright © 2011-2022 走看看