随笔分类 - linux
摘要:1 yum -y install telnet* 2 yum -y install xinetd* 3 vim /etc/securetty 添加如下:pts/1pts/2pts/3pts/4pts/5 4 vim /etc/xinetd.d/telnetservice telnet { flags
阅读全文
摘要:ps -ef | grep tomcat | awk '{print $2}' | grep '^3' | xargs kill -9 ps -ef | grep tomcat (查看tomcat 所有进程) awk '{print $2}' (打印输出第二行) grep '^3' (匹配以3 开头
阅读全文
摘要:https://blog.csdn.net/qq_32786873/article/details/82378925
阅读全文
摘要:netstat -tnlp | grep :22 ss -lntpd | grep :22 netstat -tnlp | grep :22
阅读全文
摘要:1 上传系统镜像并挂载 mount -o loop rhel-server-6.5-x86_64-dvd.iso /yum 2 配置repo文件 cd /etc/yum.repos.d 编辑rhel-source.repo文件,修改后的内容如下: [rhel-source] name=Red Hat
阅读全文
摘要:1 首先开启telnet远程连接 ,避免升级过程中服务挂掉,一般是更改/etc/securetty那个文件 在文件最后添加 pts/1 pts/11 yum -y install telnet* yum -y install xinetd* vim /etc/xinetd.d/telnet serv
阅读全文
摘要:rm -rf !(test.txt) 删除不等于test.txt 的文件
阅读全文
摘要:关闭防火墙 systemctl disable firewalld.service 查看 systemctl list-unit-files|grep firewalld.service
阅读全文
摘要:yum -y install net-tools 因为是最小化安装,所以缺少工具
阅读全文
摘要:systemctl stop firewalld.service #停止firewall systemctl disable firewalld.service #禁止firewall开机启动 firewall-cmd --state #查看默认防火墙状态(关闭后显示notrunning,开启后显示
阅读全文
摘要:git版本 git --versiongit version 1.8.3.1 maven 版本 mvn -vApache Maven 3.6.1 (d66c9c0b3152b2e69ee9bac180bb8fcc8e6af555; 2019-04-05T03:00:29+08:00)Maven ho
阅读全文
摘要:方法一: 在oracle的白名单里添加指定访问数据库的IP (请自行百度) 方法二:在linux的iptables 的白名单中添加指定主机的访问IP (请自行百度)
阅读全文
摘要:echo 3 > /proc/sys/vm/drop_caches 上面的echo 3 是清理所有缓存 echo 0 是不释放缓存 echo 1 是释放页缓存 ehco 2 是释放dentries和inodes缓存 echo 3 是释放 1 和 2 中说到的的所有缓存
阅读全文
摘要:systemctl list-unit-files (查看开机启动项) systemctl list-unit-files | grep 程序名称 (查看某些服务开机启动状态) systemctl list-unit-files | grep enable (查看哪些为开机启动服务)
阅读全文
摘要:systemctl enable (服务名称)
阅读全文
摘要:systemctl stop firewalld.service 关闭防火墙 systemctl start firewalld.service 开启防火墙 firewall-cmd --state 查看防火墙运行状态 systemctl disable firewalld.service 禁止开机
阅读全文
摘要:rpm -ivh 包名 --force --nodeps (强制安装)
阅读全文
摘要:#!/bin/bash auth=123456 echo " flushall " | redis-cli -a $auth wq (-a 指登陆Redis控制台输入的密码)
阅读全文
摘要:举个例子吧,要打包/usr/local/src/elasticsearch 但是排除elasticsearch下logs日志的目录 tar -zvcf elasticsearch.tar.gz --exclude=elasticsearch/logs elasticsearch 需要在/usr/lo
阅读全文

浙公网安备 33010602011771号