重庆思庄Oracle、Redhat认证学习论坛

 找回密码
 注册

QQ登录

只需一步,快速开始

搜索
查看: 127|回复: 0
打印 上一主题 下一主题

[Oracle] ORACLE 19c RAC防火墙设置

[复制链接]
跳转到指定楼层
楼主
发表于 2024-7-24 19:41:35 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式


--1.最核心的部分

--增加公网
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="192.168.133.0/24" accept'
--增加私网
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="10.0.0.0/16" accept'
--增加haip
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="169.254.0.0/16" accept'



--2.可以缩小范围,具体的IP
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="192.168.133.203/32" accept'
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="192.168.133.204/32" accept'
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="192.168.133.254/32" accept'
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="192.168.133.253/32" accept'

firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="10.0.0.203/32" accept'
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="10.0.1.203/32" accept'
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="10.0.2.203/32" accept'
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="10.0.0.204/32" accept'
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="10.0.1.204/32" accept'
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="10.0.2.204/32" accept'

firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="169.254.0.0/16" accept'

--3.取消规则
firewall-cmd --permanent --remove-rich-rule='rule family="ipv4" source address="10.0.0.203/32" accept'
firewall-cmd --permanent --remove-rich-rule='rule family="ipv4" source address="10.0.1.203/32" accept'
firewall-cmd --permanent --remove-rich-rule='rule family="ipv4" source address="10.0.2.203/32" accept'
firewall-cmd --permanent --remove-rich-rule='rule family="ipv4" source address="10.0.0.204/32" accept'
firewall-cmd --permanent --remove-rich-rule='rule family="ipv4" source address="10.0.1.204/32" accept'
firewall-cmd --permanent --remove-rich-rule='rule family="ipv4" source address="10.0.2.204/32" accept'

--4.生效

firewall-cmd --reload



#在主机防火墙上添加漏扫设备地址10.100.109.225为白名单
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="10.100.109.225" accept
#允许备份服务器ssh访问数据库
firewallcmd --permanent -add-rich-rule='rule family="ipv4" source address="10.100.109.148/32" port protocol="tcp" port="22" accept
#允许深信服堡垒机ssh访问数据库
firewa-cmd --permanent --add-rich-rule='rule family="ipv4" source address="10.101.140.253/32" port protocol="tcp" port="22" accept
#允许应用服务器访问
firewall-cmd --permanent --add-rich-rule='rule family="ipv4" source address="10.100.194.0/24" accept

分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
收藏收藏 支持支持 反对反对
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|手机版|小黑屋|重庆思庄Oracle、Redhat认证学习论坛 ( 渝ICP备12004239号-4 )

GMT+8, 2024-9-8 08:25 , Processed in 0.092273 second(s), 20 queries .

重庆思庄学习中心论坛-重庆思庄科技有限公司论坛

© 2001-2020

快速回复 返回顶部 返回列表