Raspberry Pi ubuntu16.04 Install SSH configuration ssh power On self-start SSH

Source: Internet
Author: User

Start a Raspberry Pi 3B installed ubuntu 16.04 need to use the SSH record

0. Get the Raspberry Pi IP first

Raspberry Pi uses a network cable to connect the router and Raspberry Pi in the Router Settings page (typically 192.168.1.1 specific look at the router's model and settings) to get the Raspberry Pi IP address the MAC address of the Raspberry Pi is very characteristic

or enter the system after connecting WiFi in terminal input ifconfig view IP address

The Raspberry Pi IP address, which is connected using the Putty connection, shows connect refuse, generally because the new Linux system default SSH service is turned off, so either the link is rejected or the SSH is not installed manually.

1. Determine if the system has SSH installed

Enter in the terminal

SSH localhost

If prompted:
Ssh:connect to host localhost Port 22:connection refused

This means that no SSH has been installed.

2. Installing the SSH Service

  Install command: sudo apt-get install Openssh-server

Uninstall command: sudo apt-get remove openssh-server

3. Check if the SSH service is properly installed and turned on  

Ps-e | grep ssh

See there are similar to 1688? 00:00:00 sshd

This sshd means that the SSH service is turned on, but this is not the boot automatically start the SSH service, each reboot (restart) after the SSH will be shut down, the following to configure the boot SSH and open ssh after the default Do not allow login to root user

Or

sudo NETSTART-TLP

command to detect if you see: TCP6 0 0 [::]:ssh [::]:*

It means that sshserver starts up normally.

4. Start, stop, and restart the SSH service

Sudo/etc/init.d/ssh Start #开始服务

Sudo/etc/init.d/ssh Stop #停止服务

Sudo/etc/init.d/ssh Restart #重启服务

The Ssh-server configuration file is:/etc/ssh/sshd_config, changing the configuration requires the SSH service to be restarted.

5. Start-up SSH Service

Configure Openssh-server boot automatically in Ubuntu

sudo nano/etc/rc.local file, before exit 0 statement join:/ETC/INIT.D/SSH start

Ctrl+o Save

Ctrl+x exit

Raspberry Pi ubuntu16.04 Install SSH configuration ssh power On self-start SSH

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.