Instance Resolution: SSH cannot be started in Linux

Source: Internet
Author: User
& Nbsp; log on directly to the machine. The problem is as follows:/var/empty/sshdmustbeownedbyrootandnotgrouporworld-writable. problem: Linux SSH cannot be started. Report/var/empty-w  

Log on to the ECS instance directly. The problem is as follows:

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

Problem:

Linux SSH cannot be started

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

Solution:

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

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

Sshd is stopped

Manually start the service and report permission errors.

-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 #

Run the rpm-V command to check that the ssh software package is normal, but the owner of a directory is incorrect.

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

S.5...... c/etc/ssh/sshd_config

... U.../var/empty/sshd

-Bash-2.05b #

It is found that the owner of this directory is not root, so an error is reported when the ssh service is started.

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

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

-Bash-2.05b #

Changed 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 #

Now the problem is fixed.

In addition, you can try:

This is a permission issue.

You can take the following two steps 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.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.