Fedora ssh服务,防火墙服务设置

Fedora26 ssh设置

ssh:connection to host 127,0.0.1 port22: Connection refused

  1. 首先安装openssh-server     yum install openssh-server

  2. systemctl start sshd.service

  • 查看服务状态:systemctl status sshd.service

 

  • 停止服务  systemctl start sshd.service  

 

 

  • 设置开机自启–方式1

    systemctl enable sshd.service 

 

  • 设置开机自启–方式2

    chkconfig --level 3 sshd on 
    
  • 停止开机自启动

    systemctl disable sshd.service

 

防火墙设置firewalld

开启firewall: systemctl start firewalld

查看状态:systemctl status firewalld  

停止:    systemctl disable firewalld

禁用:    systemctl stop firewalld

 

iptables:

  • 停止防火墙: service iptables stop
  • 启动防火墙: service iptables start
posted @   zhaocundang  阅读(320)  评论(0编辑  收藏  举报
编辑推荐:
· 如何编写易于单元测试的代码
· 10年+ .NET Coder 心语,封装的思维:从隐藏、稳定开始理解其本质意义
· .NET Core 中如何实现缓存的预热?
· 从 HTTP 原因短语缺失研究 HTTP/2 和 HTTP/3 的设计差异
· AI与.NET技术实操系列:向量存储与相似性搜索在 .NET 中的实现
阅读排行:
· 地球OL攻略 —— 某应届生求职总结
· 周边上新:园子的第一款马克杯温暖上架
· Open-Sora 2.0 重磅开源!
· 提示词工程——AI应用必不可少的技术
· .NET周刊【3月第1期 2025-03-02】
历史上的今天:
2016-02-10 Qt5.5.0使用mysql编写小软件源码讲解---顾客信息登记表
点击右上角即可分享
微信分享提示