OpenSSH : Password Authentication2026/04/24 |
|
Configure SSH Server to manage a server from the remote computer. SSH uses 22/TCP. |
|
| [1] | Password Authentication for OpenSSH Server on Ubuntu is enabled by default, so it's possible to login without changing any settings. Furthermore, root account is prohibited Password Authentication by default with [PermitRootLogin prohibit-password], so default setting is good for use. But if you prohibit root login all, change like follows. |
|
root@dlp:~#
apt -y install openssh-server
root@dlp:~#
vi /etc/ssh/sshd_config # line 54 : uncomment and change to [no] PermitRootLogin no
systemctl restart ssh |
| [2] | If UFW is enabled, allow SSH service. SSH uses [22/TCP]. |
|
root@dlp:~# ufw allow ssh Rule added Rule added (v6) |
SSH Client : Ubuntu |
|
Configure SSH Client for Ubuntu. |
|
| [3] | Install SSH Client. |
|
root@client:~# apt -y install openssh-client
|
| [4] | Connect to the SSH server with a common user. |
|
# ssh [username@hostname or IP address] root@client:~# ssh ubuntu@dlp.srv.world
The authenticity of host 'dlp.srv.world (10.0.0.30)' can't be established.
ED25519 key fingerprint is: SHA256:IVyoxi4scRBpsoAV/lqnusuP8JQMIBOHYqM/RVdkvVM
This key is not known by any other names.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added 'dlp.srv.world' (ED25519) to the list of known hosts.
ubuntu@dlp.srv.world's password:
Welcome to Ubuntu 26.04 LTS (GNU/Linux 7.0.0-14-generic x86_64)
.....
.....
ubuntu@dlp:~$ # just logined |
| [5] | It's possible to execute commands on remote Host with adding commands to ssh command. |
|
# for example, open [/etc/passwd] on remote host ubuntu@client:~$ ssh ubuntu@dlp.srv.world "cat /etc/passwd" ubuntu@dlp.srv.world's password: root:x:0:0:root:/root:/bin/bash daemon:x:1:1:daemon:/usr/sbin:/usr/sbin/nologin bin:x:2:2:bin:/bin:/usr/sbin/nologin sys:x:3:3:sys:/dev:/usr/sbin/nologin sync:x:4:65534:sync:/bin:/bin/sync games:x:5:60:games:/usr/games:/usr/sbin/nologin man:x:6:12:man:/var/cache/man:/usr/sbin/nologin lp:x:7:7:lp:/var/spool/lpd:/usr/sbin/nologin mail:x:8:8:mail:/var/mail:/usr/sbin/nologin news:x:9:9:news:/var/spool/news:/usr/sbin/nologin ..... ..... |
SSH Client : Windows#1 |
|
Configure SSH Client for Windows. |
|
| [6] |
Get a SSH Client for Windows. This example shows to use Putty like follows. Input your server's IP address and Click [Open] button. |
|
| [7] | After authentication on SSH server, it's possible to login remotely with SSH. |
|
SSH Client : Windows #2 |
| [8] | OpenSSH Client has been implemented as an Windows feature, so it's possible to use ssh command on PowerShell or Command Prompt without Putty and other SSH software. |
|
| Sponsored Link |
|
|