openssh-server 패키지 설치
$ sudo apt update
$ sudo apt install openssh-server
확인~
$ sudo systemctl status ssh
만약 ufw사용중이라면 ssh를 허용해준다
$ sudo ufw allow ssh
접속 시도
$ root@ipaddress
* ip주소 확인하는 방법 (웬만하면 고정 IP설정하는 것을 추천)
더이상.. ifconfig는 쓰지 않는다 합니다... 띠로리
$ ip a
+) 고정 IP설정하는 법
ubuntu netplan 으로 고정 ip 설정하기(static ip config)
고정 IP 설정시 dhcp4: no 를 꼭 추가
www.lesstif.com
안되면.. 설정을 바꿔준다
$ sudo vi /etc/ssh/sshd_config
PermitRootLogin설정 값을 yes로 변경!
PermitRootLogin yes
그리고 ssh 재시작
$ sudo systemctl restart ssh
$ sudo systemctl status ssh
근데 막 이런 오류가 뜨면...
@ WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED! @
/usr/[유저명]/.ssh/known_hosts를 삭제해주고 다시 시도해보세요..
How to Enable SSH on Ubuntu 20.04
This tutorial explains how to enable SSH on an Ubuntu machine. Enabling SSH will allow you to connect to your system remotely, and perform administrative tasks.
linuxize.com
'STUDY > ECT' 카테고리의 다른 글
IntelliJ IPv4 설정 (0) | 2021.04.08 |
---|---|
Ubuntu(20.04LTS) UFW설정 (0) | 2021.04.01 |
Ubuntu(20.04 LTS) vsftpd 설치 ( + FileZilla ) (0) | 2021.03.30 |
Ubuntu(20.04 LTS)에 MySQL 설치하기 (0) | 2021.03.30 |
Ubuntu(20.04 LTS)에 Java 11 설치, 환경변수 설정 ( + Java 8 설치) (0) | 2021.03.30 |