zoukankan      html  css  js  c++  java
  • Linux Shell

    Shell

    • Shell 是Linux系统的用户界面,提供了用户与内核进行交互操作的一种接口。它接收用户输入的命令并把它送入内核去执行
    • shell也被称为LINUX的命令解释器(command interpreter)
    • shell是一种高级程序设计语言
      应用程序 - Shell - 系统调用 - 内核 - 硬件

    各种Shell

    • sh:Steve Bourne
    • bash:Bourne-Again Shell,GPL,CentOS 和 Ubuntu 默认使用
    • csh:c shell , C 语言风格
    • tcsh
    • ksh :Korn Shell, AIX 默认 shell
    • zsh: MacOS默认shell

    主流bash 由Bourne开发的遵循GPL协议的sh的增强版

    Linux命令

    查看当前使用shell

    [root@C8 ~]# echo $SHELL
    /bin/bash
    

    查看系统支持的shell

    [root@C8 ~]# cat /etc/shells
    /bin/sh
    /bin/bash
    /usr/bin/sh
    /usr/bin/bash
    

    查看系统正在运行的bash

    [root@C8 ~]# ps aux | grep bash
    root       1726  0.0  0.2  26544  5120 pts/0    Ss+  08:52   0:00 -bash
    root       2018  0.0  0.2  26412  5008 pts/1    Ss   10:46   0:00 -bash
    root       2150  0.0  0.0  12108   968 pts/1    R+   11:28   0:00 grep --color=auto bash
    

    ps aux 相当于Windows中的任务管理器

    * * * 胖并快乐着的死肥宅 * * *
  • 相关阅读:
    Baskets of Gold Coins_暴力
    Inversion_树状数组***
    萌新的旅行-
    KI的斐波那契_DFS
    牛吃草_二分法
    See you~_树状数组
    Bellovin_树状数组
    Bubble Sort_树状数组
    [Python] numpy.ndarray.shape
    [Python] numpy.sum
  • 原文地址:https://www.cnblogs.com/bpzblog/p/12609615.html
Copyright © 2011-2022 走看看