Azrael的运维备忘录


秋日暖阳

CentOS 7 firewalld 使用简介

学习apache安装的时候需要打开80端口,由于centos 7版本以后默认使用firewalld后,网上关于iptables的设置方法已经不管用了。 官方文档地址: https://access.redhat.com/documentation/en-US/Red_Hat_Enterpr...

CentOS 7 提示'cannot find a valid baseurl for repo'处理办法

问题: 用的是最小化安装的CentOS 7,当运行 yum update 时,提示 “cannot find a valid baseurl for repo” 错误提示。 处理办法: 网上搜索后说是 dns 的问题,可能没有自动到 IP 地址导致。 运行: dhclient

centos 7 使用 163 yum 源

一般是下载 .repo 源即可,但有时候我们需要安装一些额外的包,就需要下载 Extra Packages for Enterprise Linux (EPEL) 源, 比如我们需要用 yum 安装 ansible ,就需要安装 epel 。 下载 repo 源 repo 源一般包括 ba...

CentOS7 配置静态 IP 地址和 DNS

为你的 CentOS7 服务器配置静态 IP 地址、路由以及 DNS,我们会 使用 ip 命令代替 ifconfig 命令。 当然,ifconfig 命令对于大部分 Linux 发行版来说还是可用的,还能从默认库安装。 # yum install net-tools [它提供 ifcon...

linuxshell 中 '2>&1' 含义

shell中可能经常能看到: echo log > /dev/null 2>&1 命令的结果可以通过 %> 的形式来定义输出 /dev/null :代表空设备文件 > :代表重定向到哪里,例如:echo "123" > /home/123.txt ...

Archlinux 的 pacman 常用命令

Arch的包管理器 pacman 还是比较好用的, 一、常用的 pacman 命令: 系统更新: pacman -Syu 安装软件: pacman -S 软件包名 查询软件: pacman -Ss 软件包名 卸载软件: pacman -R 软件包名 系统清理: pacman -Sc...

Ubuntu Linux 下设置 IP 的配置命令

一、使用命令设置ubuntu的ip地址 (1.修改配置文件blacklist.conf禁用IPV6:) sudo vi /etc/modprobe.d/blacklist.conf (2.在文档最后添加 blacklist ipv6,然后查看修改结果:) cat /etc/modpro...

Ubuntu 出现 xxx is not in the sudoers file 解决方法

Ubuntu 系统里,在一般用户下执行 sudo 命令提示: xxx is not in the sudoers file. This incident will be reported 解决方法: 一、找出文件所在的位置 $whereis sudoers 默认都是 /etc/sud...