0℃
2019年10月25日
⁄ LNMP
⁄ 被围观 24,049次+
必会知识:
CentOS 8.0.1905系统安装配置图解教程
https://www.osyunwei.com/archives/10256.html
准备篇
一、防火墙配置
CentOS 从7.x开始默认使用的是firewall作为防火墙,这里改为iptables防火墙。
1、关闭firewall:
systemctl stop firewalld.service #停止firewall
systemctl disable firewalld.service #禁止firewall开机启动
systemctl mask firewalld
systemctl stop firewalld
yum -y remove firewalld
2、安装iptables防火墙
yum install iptables-services #安装
vi /etc/sysconfig/iptables #编辑防...
CentOS, lnmp, mysql, php阅读全文
0℃
2019年09月30日
⁄ MySQL
⁄ 被围观 12,594次+
本文CentOS版本:CentOS 8.0.1905
MySQL版本:mysql-8.0.18
前传:
CentOS 8.0.1905系统安装配置图解教程
https://www.osyunwei.com/archives/10256.html
准备篇
一、防火墙配置
CentOS 从7.x开始默认使用的是firewall作为防火墙,这里改为iptables防火墙。
1、关闭firewall:
systemctl stop firewalld.service #停止firewall
systemctl disable firewalld.service #禁止firewall开机启动
systemctl mask firewalld
systemctl stop firewalld
yum remove firewalld
2、安装iptables防火墙
yum install iptables-...
CentOS, mysql阅读全文
0℃
2017年03月18日
⁄ Web服务器
⁄ 被围观 29,300次+
本文档最后更新于2019年6月29日
前传:
1、CentOS 7.3.1611系统安装配置图解教程
http://www.osyunwei.com/archives/10003.html
2、CentOS服务器初始化设置
http://www.osyunwei.com/archives/9034.html
准备篇
一、防火墙配置
CentOS 7.x默认使用的是firewall作为防火墙,这里改为iptables防火墙。
1、关闭firewall:
systemctl stop firewalld.service #停止firewall
systemctl disable firewalld.service #禁止firewall开机启动
systemctl mask firewalld
systemctl stop firewalld
yum remove firewalld
2、...
CentOS, lnmp, php阅读全文
0℃
2017年03月03日
⁄ LNMP
⁄ 被围观 24,878次+
前传:
1、CentOS 7.3.1611系统安装配置图解教程
http://www.osyunwei.com/archives/10003.html
2、CentOS服务器初始化设置
http://www.osyunwei.com/archives/9034.html
准备篇
一、防火墙配置
CentOS 7.x默认使用的是firewall作为防火墙,这里改为iptables防火墙。
1、关闭firewall:
systemctl stop firewalld.service #停止firewall
systemctl disable firewalld.service #禁止firewall开机启动
2、安装iptables防火墙
yum install iptables-services #安装
vi /etc/sysconfig/iptables #编辑防火墙配置文件
...
CentOS, lnmp, mysql, php7阅读全文
0℃
2017年02月27日
⁄ CentOS
⁄ 被围观 51,490次+
说明:
截止目前CentOS 7.x最新版本为CentOS 7.3.1611,下面介绍CentOS 7.3.1611的具体安装配置过程
服务器相关设置如下:
操作系统:CentOS 7.3.1611
IP地址:192.168.21.130
网关:192.168.21.2
DNS:8.8.8.8 8.8.4.4
备注:
CentOS 7.x系列只有64位系统,没有32位。生产服务器建议安装CentOS-7-x86_64-Minimal-1611.iso版本
一、安装CentOS 7.3.1611
成功引导系统后,会出现下面的界面
界面说明:
Install CentOS 7 #安装CentOS 7
Test this media & install CentOS 7 #测试安装文件并安装CentOS 7
Tro...
CentOS, CentOS 安装阅读全文
0℃
2017年01月30日
⁄ CentOS
⁄ 被围观 15,586次+
操作系统:CentOS 7.x 64位
实现目的:安装部署Memcached服务器
一、防火墙设置
CentOS 7.x默认使用的是firewall作为防火墙,这里改为iptables防火墙。
1、关闭firewall:
systemctl stop firewalld.service #停止firewall
systemctl disable firewalld.service #禁止firewall开机启动
2、安装iptables防火墙
yum install iptables-services #安装
vi /etc/sysconfig/iptables #编辑防火墙配置文件
# sample configuration for iptables service
# you can edit this manually or use system-config-firewall
# p...
CentOS, memcached阅读全文
0℃
2016年10月11日
⁄ LNMP
⁄ 被围观 16,153次+
准备篇
一、防火墙配置
CentOS 7.x默认使用的是firewall作为防火墙,这里改为iptables防火墙。
1、关闭firewall:
systemctl stop firewalld.service #停止firewall
systemctl disable firewalld.service #禁止firewall开机启动
2、安装iptables防火墙
yum install iptables-services #安装
vi /etc/sysconfig/iptables #编辑防火墙配置文件
# sample configuration for iptables service
# you can edit this manually or use system-config-firewall
# please do not ask us to add additional ports/services ...
CentOS, lnmp阅读全文
0℃
2016年10月09日
⁄ LNMP
⁄ 被围观 12,427次+
准备篇
一、防火墙配置
CentOS 7.x默认使用的是firewall作为防火墙,这里改为iptables防火墙。
1、关闭firewall:
systemctl stop firewalld.service #停止firewall
systemctl disable firewalld.service #禁止firewall开机启动
2、安装iptables防火墙
yum install iptables-services #安装
vi /etc/sysconfig/iptables #编辑防火墙配置文件
# sample configuration for iptables service
# you can edit this manually or use system-config-firewall
# please do not ask us to add additional ports/services ...
CentOS, lnmp阅读全文
0℃
2016年10月08日
⁄ CentOS
⁄ 被围观 14,502次+
CentOS 7.x系统中网卡命名规则被重新定义,可能会是”eno167777xx”等,下面我们把网卡名称改为eth0这种。
一、cd /etc/sysconfig/network-scripts/ #进入网卡配置目录
mv eno16777736 ifcfg-eth0 #修改名称
vi eth0 #编辑
NAME=eth0 #修改
DEVICE=eth0 #修改
:wq! #保持退出
二、vi /etc/sysconfig/grub #编辑
在”GRUB_CMDLINE_LINUX“变量中添加一句”net.ifnames=0 biosdevname=0“
:wq! #保存退出
三、运行命令:grub2-mkconfig -o /boot/grub2/grub.cfg #重新生成grub配置并更新内核参数
四、添加u...
CentOS, CentOS网卡名称, eno16777736, eth0阅读全文
0℃
2016年10月08日
⁄ CentOS
⁄ 被围观 16,342次+
说明:
截止目前CentOS 7.x最新版本为CentOS 7.2.1511,下面介绍CentOS 7.2.1511的具体安装配置过程
服务器相关设置如下:
操作系统:CentOS 7.2.1511
IP地址:192.168.21.130
网关:192.168.21.2
DNS:8.8.8.8 8.8.4.4
备注:
CentOS 7.x系列只有64位系统,没有32位。生产服务器建议安装CentOS-7-x86_64-Minimal-1511.iso版本
一、安装CentOS 7.2.1511
成功引导系统后,会出现下面的界面
界面说明:
Install CentOS 7 #安装CentOS 7
Test this media & install CentOS 7 #测试安装文件并安装CentOS 7
Tro...
CentOS, linux阅读全文
0℃
2016年06月03日
⁄ CentOS
⁄ 被围观 88,349次+
说明:
截止目前CentOS 6.x最新版本为CentOS 6.8,下面介绍CentOS 6.8的具体安装配置过程
服务器相关设置如下:
操作系统:CentOS 6.8 64位
IP地址:192.168.21.129
网关:192.168.21.2
DNS:8.8.8.8 8.8.4.4
备注:
CentOS 6.8系统镜像有32位和64位两个版本,并且还有专门针对服务器优化过的minimal版本
生产服务器如果是大内存(4G以上内存),建议安装CentOS-6.8-x86_64-minimal.iso版本
附:CentOS 6.8下载地址
32位minimal版本:
http://mirrors.aliyun.com/centos/6.8/isos/i386/CentOS-6.8-i386-minimal....
CentOS, CentOS安装阅读全文
0℃
2015年10月27日
⁄ CentOS
⁄ 被围观 17,722次+
问题:
部分Dell服务器在安装Linux操作系统之后,发现网卡名称变成em1了。
解决办法:
修改网卡名称为eth0,这里以CentOS操作系统为例。
一:修改系统grub
vi /boot/grub/grub.conf #在内核参数后面添加biosdevname=0
kernel /vmlinuz-2.6.32-573.7.1.el6.x86_64 ro root=/dev/mapper/VolGroup-lv_root rd_NO_LUKS LANG=en_US.UTF-8 rd_NO_MD rd_LVM_LV=VolGroup/lv_swap SYSFONT=latarcyrheb-sun16 crashkernel=auto rd_LVM_LV=VolGroup/lv_root KEYBOARDTYPE=pc KEYTABLE=us rd_NO_DM biosdevname=0 rhgb quiet...
CentOS, em1, eth0, linux, 网卡阅读全文
0℃
2015年06月15日
⁄ 安全优化
⁄ 被围观 24,542次+
说明:
1、一般ssh登录服务器,只需要输入账号和密码。
2、本教程的目的:在账号和密码之间再增加一个
验证码,只有输入正确的验证码之后,再输入
密码才能登录。这样就增强了ssh登录的安全性。
3、账号、验证码、密码三者缺一个都不能登录,即使账号和密码正确,验证码错误,同样登录失败。
4、验证码:是动态验证码,并且是通过手机客户端自动获取(默认每隔30秒失效一次)。
5、最终目的:远程ssh登录一台服务器,需要正确的账号、密码、及一个可以获取到动态验证码的手机
(目前支持Android和i...
Authenticator, CentOS, Google, linux, ssh, 动态验证码阅读全文
0℃
2015年05月22日
⁄ 安全优化
⁄ 被围观 24,953次+
以阿里云服务器为例
一、挂载硬盘
1、磁盘分区
fdisk -l #查看设备,一般可以看到设备名为/dev/xvdb,或者为/dev/vdb(阿里云io优化型)
fdisk /dev/xvdb #对磁盘进行分区,或者fdisk /dev/vdb
输入n #创建新分区
输入p #创建主分区
输入1 #创建第一个主分区,默认回车
输入w #保存并执行以上命令,创建分区
待上面的命令执行完成之后,使用fdisk -l查看,会看到类似
/dev/xvdb1的分区
或者为
/dev/vdb1的分区(下面的步骤类似,注意xvdb1和vdb1的区分)
说明分区成功。
2、磁盘格式化
mkfs.ext4 /dev/xvdb1 #对...
CentOS, 初始化, 安全优化阅读全文
0℃
2015年03月31日
⁄ FTP
⁄ 被围观 41,277次+
本文档最后更新于2020年3月18日
一、配置防火墙,开启FTP服务器需要的端口
CentOS 7.x 8.x 默认使用的是firewall作为防火墙,这里改为iptables防火墙。
1、关闭firewall:
systemctl stop firewalld.service #停止firewall
systemctl disable firewalld.service #禁止firewall开机启动
2、安装iptables防火墙
yum install iptables-services #安装
vi /etc/sysconfig/iptables #编辑防火墙配置文件
# Firewall configuration written by system-config-firewall
# Manual customization of this file is not reco...
CentOS, FTP, Vsftpd阅读全文
0℃
2014年12月16日
⁄ LNMP
⁄ 被围观 17,154次+
准备篇:
CentOS 5.x系统安装配置图解教程
http://www.osyunwei.com/archives/7002.html
一、配置防火墙,开启80端口、3306端口
vi /etc/sysconfig/iptables #编辑防火墙配置文件
# Firewall configuration written by system-config-securitylevel
# Manual customization of this file is not recommended.
*filter
:INPUT ACCEPT [0:0]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [0:0]
:RH-Firewall-1-INPUT - [0:0]
-A INPUT -j RH-Firewall-1-INPUT
-A FORWARD -j RH-Firewall-1-INPUT
-A RH-Firewall-1-INPUT ...
CentOS, lnmp, nginx, php阅读全文
0℃
2014年12月16日
⁄ LAMP
⁄ 被围观 16,400次+
准备篇:
CentOS 5.x系统安装配置图解教程
http://www.osyunwei.com/archives/7002.html
1、配置防火墙,开启80端口、3306端口
vi /etc/sysconfig/iptables
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 80 -j ACCEPT
-A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 3306 -j ACCEPT
:wq! #保存退出
添加好规则后的防火墙配置文件如下图所示:
/etc/init.d/iptables restart #重启防火墙使配置生效
2、关闭SELINUX
vi /etc/selinux/config
#SELINUX=enforcing #注释...
Apache, CentOS, LAMP, mysql, php阅读全文