linux
linux相关操作笔记
gmj53
这个作者很懒,什么都没留下…
展开
-
linux防火墙配置
开放端口firewall-cmd --permanent --zone=public --add-port=8080/tcp#批量开发端口firewall-cmd --permanent --zone=public --add-port=8080-8083/tcp删除某个端口firewall-cmd --permanent --zone=public --remove-port=81/tcp针对某个 IP开放端口firewall-cmd --permanent --add-rich-rul原创 2021-09-03 17:51:45 · 303 阅读 · 0 评论 -
linux使用grep过滤行
-v是grep排除的参数,例如查询除了包含ABC的行,例如cat a.txt|grep -v ‘ABC’^代表行首,KaTeX parse error: Expected group after '^' at position 7: 代表行尾。 ^̲是空行的意思^#表示首字母为#的行,linux里的文件,#号开头一般都是注释内容grep -v '^$' /etc/rsyslog.conf | grep -v '^#'查询/etc/rsyslog.conf文件,但是不包含空行和注释行...原创 2021-07-29 21:27:12 · 1720 阅读 · 0 评论 -
修改centos8时间格式为24小时制
1.使用tzselect命令[root@localhost ~]# tzselect请确定一个位置,以便正确设置时区规则。请选择大洲、海洋、“coord”或“TZ”。(“目标位置”或“时区”)Please identify a location so that time zone rules can be set correctly.Please select a continent, ocean, "coord", or "TZ". 1) Africa 2) Americas 3) An原创 2021-07-21 23:51:01 · 1412 阅读 · 0 评论