LoginSignup
21
20

More than 5 years have passed since last update.

UbuntuでSSHをインストールする手順

Posted at

GNOMEデスクトップでUbuntuをインストールするとsshdがインストールされていない。
インストールする手順をまとめています。

sudo apt-get install ssh
systemctl start sshd

以下、実行ログ

ubuntu-18@ubuntu-18:~$ sudo apt-get install ssh
[sudo] ubuntu-18 のパスワード:
パッケージリストを読み込んでいます... 完了
依存関係ツリーを作成しています
状態情報を読み取っています... 完了
以下のパッケージが新たにインストールされます:
  ssh
アップグレード: 0 個、新規インストール: 1 個、削除: 0 個、保留: 5 個。
5,188 B 中 0 B のアーカイブを取得する必要があります。
この操作後に追加で 106 kB のディスク容量が消費されます。
以前に未選択のパッケージ ssh を選択しています。
(データベースを読み込んでいます ... 現在 153167 個のファイルとディレクトリがインストールされています。)
.../ssh_1%3a7.6p1-4_all.deb を展開する準備をしています ...
ssh (1:7.6p1-4) を展開しています...
ssh (1:7.6p1-4) を設定しています ...
ubuntu-18@ubuntu-18:~$ systemctl start sshd
==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-units ===
'ssh.service'を開始するには認証が必要です。
Authenticating as: ubuntu-18,,, (ubuntu-18)
Password:
==== AUTHENTICATION COMPLETE ===
ubuntu-18@ubuntu-18:~$ ps -ef | grep sshd
root      3341     1  0 11:18 ?        00:00:00 /usr/sbin/sshd -D
root      4754  3341  0 12:00 ?        00:00:00 sshd: ubuntu-18 [priv]
ubuntu-+  4825  4754  0 12:00 ?        00:00:00 sshd: ubuntu-18@pts/1
ubuntu-+  5023  4826  0 12:23 pts/1    00:00:00 grep --color=auto sshd
21
20
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
21
20