随笔分类 - CentOS
摘要:yum install epel-release yum install -y supervisor systemctl enable supervisord # 开机自启动 systemctl start supervisord # 启动supervisord服务
阅读全文
摘要:yum install -y gcc gcc-c++ ncurses-devel make wget wget http://www.roland-riegel.de/nload/nload-0.7.4.tar.gz tar zxvf nload-0.7.4.tar.gz cd nload-0.7.
阅读全文
摘要:cd /etc/yum.repos.d/ wget https://download.opensuse.org/repositories/shells:fish:release:2/CentOS_7/shells:fish:release:2.repo yum install fish
阅读全文
摘要:安装 1、装依赖 yum install -y java-1.8.0-openjdk 2、安装elasticsearch 下载url:https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-5.6.3.tar.gz #目录
阅读全文
摘要:https://blog.csdn.net/c359719435/article/details/80300433 查看max conn:
阅读全文
摘要:hostnamectl set-hostname XXX
阅读全文
摘要:Linux /var/log下各种日志文件:
阅读全文
摘要:yum install libxml2-devel xmlsec1-devel xmlsec1-openssl-devel libtool-ltdl-devel
阅读全文
摘要:Linux下的压缩解压缩命令详解及实例 实例:压缩服务器上当前目录的内容为xxx.zip文件 zip -r xxx.zip ./* 解压zip文件到当前目录 unzip filename.zip 另:有些服务器没有安装zip包执行不了zip命令,但基本上都可以用tar命令的,实例如下: tar -z
阅读全文
摘要:cat /etc/redhat-release
阅读全文
摘要:标准unix/linux下的grep通过下面参数控制上下文grep -C 5 foo file 显示file文件里匹配foo字串那行以及上下5行grep -B 5 foo file 显示foo及前5行grep -A 5 foo file 显示foo及后5行 标准unix/linux下的grep通过下
阅读全文
摘要:PATH改错了找不到命令 解决方法: 重新定义PATH export PATH=/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin 🌼!🌼
阅读全文
摘要:对于 RHEL, CentOS or Fedora 系统,Node.js v8 LTS版本命令: curl –silent –location https://rpm.nodesource.com/setup_8.x | sudo bash - 而 Node.js 10 的命令: curl –sil
阅读全文
摘要:grep "mafeng" xxx.txt | wc -l -o 指示grep显示所有匹配的地方,并且每一个匹配单独一行输出。这样只要统计输出的行数就可以知道这个字符出现的次数了。
阅读全文
摘要:我们对service和chkconfig两个命令都不陌生,systemctl 是管制服务的主要工具, 它整合了chkconfig 与 service功能于一体。 systemctl is-enabled iptables.servicesystemctl is-enabled servicename
阅读全文
摘要:如果只是添加一条开机启动的命令: 1. chmod +x /etc/rc.d/rc.local 2. 将命令写到 /etc/rc.d/rc.local 这个文件中 3. reboot 🌼 一、添加开机自启服务 在CentOS 7中添加开机自启服务非常方便,只需要两条命令(以Jenkins为例):s
阅读全文
摘要:Ubuntu 查看磁盘空间大小命令 df -h Df命令是linux系统以磁盘分区为单位查看文件系统,可以加上参数查看磁盘剩余空间信息, 命令格式: df -hl 显示格式为: 文件系统 容量 已用 可用 已用% 挂载点 Filesystem Size Used Avail Use% Mounted
阅读全文
摘要:有以下命令可以查看: rpm -q centos-release # lsb_release -aLSB Version: :core-3.1-ia32:core-3.1-noarch:graphics-3.1-ia32:graphics-3.1-noarchDistributor ID: Cent
阅读全文
摘要:交互式登陆shell 对于交互式的登陆shell而言,CentOS规定了startup文件的加载顺序如下: 登陆过程: 1. 读取并执行/etc/profile文件; 2. 读取并执行~/.bash_profile文件; - 若文件不存在,则读取并执行~/.bash_login文件; - 若文件不存
阅读全文
摘要:如图: 使用 less -r xxx.log 即可显示如下
阅读全文