当前位置:论坛首页 > Linux面板 > 求助

【已解答】ubuntu系统!出错了,面板运行时发生错误!

发表在 Linux面板2022-8-5 21:49 [复制链接] 6 4633

Screenshot 2022-08-05 at 21-48-15 宝塔Linux面板.png

这怎么处理阿


使用道具 举报 只看该作者 回复
发表于 2022-8-5 22:04:05 | 显示全部楼层
检查你的/etc/ssh/sshd_config文件是否正常,如果不正常可能要重装openssh
ubuntu重装oenssh的方法网上有,你可以先试试
使用道具 举报 回复 支持 反对
发表于 2022-8-5 22:07:16 | 显示全部楼层
堡塔安全木兰 发表于 2022-8-5 22:04
检查你的/etc/ssh/sshd_config文件是否正常,如果不正常可能要重装openssh
ubuntu重装oenssh的方法网上有, ...

怎么检查
使用道具 举报 回复 支持 反对
发表于 2022-8-5 22:14:30 | 显示全部楼层
堡塔安全木兰 发表于 2022-8-5 22:04
检查你的/etc/ssh/sshd_config文件是否正常,如果不正常可能要重装openssh
ubuntu重装oenssh的方法网上有, ...

Screenshot 2022-08-05 at 22-13-30 宝塔Linux面板.png 只有这些


使用道具 举报 回复 支持 反对
发表于 2022-8-5 22:20:06 | 显示全部楼层

这个目录
  1. /etc/ssh/
复制代码

找到sshd_config文件,然后打开看看是不是只有几段文字
QQ截图20220805221833.png

或者你将我下面的配置直接替换到文件里面去
  1. #        $OpenBSD: sshd_config,v 1.103 2018/04/09 20:41:22 tj Exp $

  2. # This is the sshd server system-wide configuration file.  See
  3. # sshd_config(5) for more information.

  4. # This sshd was compiled with PATH=/usr/bin:/bin:/usr/sbin:/sbin

  5. # The strategy used for options in the default sshd_config shipped with
  6. # OpenSSH is to specify options with their default value where
  7. # possible, but leave them commented.  Uncommented options override the
  8. # default value.

  9. Include /etc/ssh/sshd_config.d/*.conf

  10. #Port 22
  11. #AddressFamily any
  12. #ListenAddress 0.0.0.0
  13. #ListenAddress ::

  14. #HostKey /etc/ssh/ssh_host_rsa_key
  15. #HostKey /etc/ssh/ssh_host_ecdsa_key
  16. #HostKey /etc/ssh/ssh_host_ed25519_key

  17. # Ciphers and keying
  18. #RekeyLimit default none

  19. # Logging
  20. #SyslogFacility AUTH
  21. #LogLevel INFO

  22. # Authentication:

  23. #LoginGraceTime 2m
  24. #PermitRootLogin prohibit-password
  25. PermitRootLogin yes
  26. #StrictModes yes
  27. #MaxAuthTries 6
  28. #MaxSessions 10

  29. #PubkeyAuthentication yes

  30. # Expect .ssh/authorized_keys2 to be disregarded by default in future.
  31. #AuthorizedKeysFile        .ssh/authorized_keys .ssh/authorized_keys2

  32. #AuthorizedPrincipalsFile none

  33. #AuthorizedKeysCommand none
  34. #AuthorizedKeysCommandUser nobody

  35. # For this to work you will also need host keys in /etc/ssh/ssh_known_hosts
  36. #HostbasedAuthentication no
  37. # Change to yes if you don't trust ~/.ssh/known_hosts for
  38. # HostbasedAuthentication
  39. #IgnoreUserKnownHosts no
  40. # Don't read the user's ~/.rhosts and ~/.shosts files
  41. #IgnoreRhosts yes

  42. # To disable tunneled clear text passwords, change to no here!
  43. #PasswordAuthentication yes
  44. #PermitEmptyPasswords no

  45. # Change to yes to enable challenge-response passwords (beware issues with
  46. # some PAM modules and threads)
  47. ChallengeResponseAuthentication no

  48. # Kerberos options
  49. #KerberosAuthentication no
  50. #KerberosOrLocalPasswd yes
  51. #KerberosTicketCleanup yes
  52. #KerberosGetAFSToken no

  53. # GSSAPI options
  54. #GSSAPIAuthentication no
  55. #GSSAPICleanupCredentials yes
  56. #GSSAPIStrictAcceptorCheck yes
  57. #GSSAPIKeyExchange no

  58. # Set this to 'yes' to enable PAM authentication, account processing,
  59. # and session processing. If this is enabled, PAM authentication will
  60. # be allowed through the ChallengeResponseAuthentication and
  61. # PasswordAuthentication.  Depending on your PAM configuration,
  62. # PAM authentication via ChallengeResponseAuthentication may bypass
  63. # the setting of "PermitRootLogin without-password".
  64. # If you just want the PAM account and session checks to run without
  65. # PAM authentication, then enable this but set PasswordAuthentication
  66. # and ChallengeResponseAuthentication to 'no'.
  67. UsePAM yes

  68. #AllowAgentForwarding yes
  69. #AllowTcpForwarding yes
  70. #GatewayPorts no
  71. X11Forwarding yes
  72. #X11DisplayOffset 10
  73. #X11UseLocalhost yes
  74. #PermitTTY yes
  75. PrintMotd no
  76. #PrintLastLog yes
  77. #TCPKeepAlive yes
  78. #PermitUserEnvironment no
  79. #Compression delayed
  80. #ClientAliveInterval 0
  81. #ClientAliveCountMax 3
  82. #UseDNS no
  83. #PidFile /var/run/sshd.pid
  84. #MaxStartups 10:30:100
  85. #PermitTunnel no
  86. #ChrootDirectory none
  87. #VersionAddendum none

  88. # no default banner path
  89. #Banner none

  90. # Allow client to pass locale environment variables
  91. AcceptEnv LANG LC_*

  92. # override default of no subsystems
  93. Subsystem sftp        /usr/lib/openssh/sftp-server

  94. # Example of overriding settings on a per-user basis
  95. #Match User anoncvs
  96. #        X11Forwarding no
  97. #        AllowTcpForwarding no
  98. #        PermitTTY no
  99. #        ForceCommand cvs server
  100. PasswordAuthentication yes
复制代码

使用道具 举报 回复 支持 反对
发表于 2022-8-5 22:24:25 | 显示全部楼层
堡塔安全木兰 发表于 2022-8-5 22:20
这个目录

找到sshd_config文件,然后打开看看是不是只有几段文字

  etc/ssh  没有这文件,怎么下载
使用道具 举报 回复 支持 反对
发表于 2022-8-5 22:39:23 | 显示全部楼层
使用道具 举报 回复 支持 反对
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

企业版年付运维跟进群

普通问题处理

论坛响应时间:72小时

问题处理方式:排队(仅解答)

工作时间:白班:9:00 - 18:00

紧急问题处理

论坛响应时间:10分钟

问题处理方式:1对1处理(优先)

工作时间:白班:9:00 - 18:00

工作时间:晚班:18:00 - 24:00

立即付费处理
快速回复 返回顶部 返回列表