Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What if SSH fails to start on the Linux operating system

2025-02-22 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

This article focuses on "what to do if SSH cannot be started on the Linux operating system". Interested friends may wish to take a look. The method introduced in this paper is simple, fast and practical. Let's let the editor take you to learn "what if SSH can't start on the Linux operating system"!

Log in directly on the machine, and the question is shown as follows:

/ var/empty/sshd must be owned by root and not group or world-writable.

Question:

SSH on Linux cannot be started

Report / var/empty/sshd must be owned by root and not group or world-writable.

Solution:

First, enter the linux through the physical terminal, and manually check the ssh to find that it is not running.

-bash-2.05b# / etc/init.d/sshd status

Sshd is stopped

The service was started manually and reported permission errors were found.

-bash-2.05b# / etc/init.d/sshd start

Starting sshd:/var/empty/sshd must be owned by root and not group or world-writable.

[FAILED]

-bash-2.05b#

Using the rpm-V command, you can check that the package for ssh is fine, but the owner of a directory is wrong.

-bash-2.05b# rpm-V openssh-server

S.5. C/ etc/ssh/sshd_config

.U.. / var/empty/sshd

-bash-2.05b#

After checking, it is found that the owner of this directory is not root, so start ssh to report an error

-bash-2.05b# ls-ld / var/empty/sshd/

D--x--x--x 2 vu00106 root 1024 Feb 2 2005 / var/empty/sshd/

-bash-2.05b#

Modified to root owner, started successfully

-bash-2.05b# chown root / var/empty/sshd/

-bash-2.05b# / etc/init.d/sshd start

Starting sshd: [OK]

-bash-2.05b#

So far, the problem has been fixed.

Alternatively, you can try:

It's a matter of authority.

The following two steps can be taken to solve the problem

Chown-R root.root / var/empty/sshd

Chmod 744 / var/empty/sshd

Service sshd restart

The above problems can be solved.

At this point, I believe you have a deeper understanding of "what if SSH cannot be started on the Linux operating system". You might as well do it in practice. Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report