﻿{"id":1680,"date":"2023-10-19T06:48:58","date_gmt":"2023-10-18T21:48:58","guid":{"rendered":"https:\/\/f-kumazemi.org\/?p=1680"},"modified":"2023-10-19T06:48:59","modified_gmt":"2023-10-18T21:48:59","slug":"xserver-ssh","status":"publish","type":"post","link":"https:\/\/f-kumazemi.org\/?p=1680","title":{"rendered":"Xserver SSH"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\"><\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-medium wp-image-1721\" src=\"https:\/\/savetheplanet-fujisawa.org\/wp\/wp-content\/uploads\/2023\/10\/XSERVER-SSH\u63a5\u7d9a-300x169.jpg\" alt=\"\" width=\"300\" height=\"169\" \/><\/p>\n<p><span style=\"font-weight: 400;\">\u958b\u9375\u8a8d\u8a3c\u7528\u306e\u9375\u30da\u30a2\u3092\u4f5c\u6210\u3002\u79d8\u5bc6\u9375fkumazemi.key\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3002<\/span><span style=\"font-weight: 400;\"><br \/><\/span><span style=\"font-weight: 400;\">\u30d1\u30b9\u30d5\u30ec\u30fc\u30ba\u306f\u5fd8\u308c\u305a\u30e1\u30e2\u3092\u3002<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">\u79d8\u5bc6\u9375\u306e\u8a2d\u7f6e<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u305ffkumazemi.key\u3092\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3067\u79fb\u52d5<\/span><\/p>\n<p><span style=\"font-weight: 400;\">#.ssh\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306e\u4f5c\u6210<\/span><\/p>\n<p><span style=\"font-weight: 400;\">$ mkdir ~\/.ssh<\/span><\/p>\n<p><span style=\"font-weight: 400;\">#\u30d5\u30a1\u30a4\u30eb\u306e\u79fb\u52d5<\/span><\/p>\n<p><span style=\"font-weight: 400;\">$ mv ~\/Downloads\/fkumazemi.key ~\/.ssh\/<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">\u79d8\u5bc6\u9375\u306e\u30d5\u30a1\u30a4\u30eb\u540d\u306e\u5909\u66f4<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">\u79d8\u5bc6\u9375\u306e\u540d\u524d\u3092\u5909\u66f4\u3057\u307e\u3059\u3002\u3053\u306e\u6642\u901a\u5e38\u3060\u3068id_rsa\u3068\u3059\u308b\u306e\u3067\u3059\u304c\u3001<\/span><span style=\"font-weight: 400;\"><br \/><\/span><span style=\"font-weight: 400;\">\u305d\u306e\u4ed6\u306e\u79d8\u5bc6\u9375\u3082\u3042\u308b\u5834\u5408\u306f\u4efb\u610f\u306e\u540d\u524d\u3092\u3002\u4eca\u56de\u306fid_xserver_rsa\u3067\u8a2d\u5b9a<\/span><\/p>\n<p><span style=\"font-weight: 400;\">#.ssh\u306b\u79fb\u52d5<\/span><\/p>\n<p><span style=\"font-weight: 400;\">$cd ~\/.ssh\/<\/span><\/p>\n<p><span style=\"font-weight: 400;\">#\u540d\u524d\u306e\u5909\u66f4<\/span><\/p>\n<p><span style=\"font-weight: 400;\">$mv fkumazemi.key id_xserver_rsa<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">\u30d1\u30fc\u30df\u30c3\u30b7\u30e7\u30f3\u306e\u5909\u66f4<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">.ssh\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3068\u79d8\u5bc6\u9375\u306e\u30d1\u30fc\u30df\u30c3\u30b7\u30e7\u30f3\u3092\u5909\u66f4\u3002<\/span><\/p>\n<p><span style=\"font-weight: 400;\">$ chmod 700 ~\/.ssh<\/span><\/p>\n<p><span style=\"font-weight: 400;\">$ chmod 600 ~\/.ssh\/id_xserver_rsa<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">\u30ed\u30b0\u30a4\u30f3<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">\u4ee5\u4e0b\u30b3\u30de\u30f3\u30c9\u3067\u30ed\u30b0\u30a4\u30f3\u3067\u304d\u307e\u3059<\/span><\/p>\n<p><span style=\"font-weight: 400;\">$ ssh -l \u30b5\u30fc\u30d0\u30fcID -i id_xserver_rsa) \u30b5\u30fc\u30d0\u30fcID.xsrv.jp -p 10022<\/span><\/p>\n<p><span style=\"font-weight: 400;\">\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u30d1\u30b9\u30d5\u30ec\u30fc\u30ba\u3092\u6c42\u3081\u3089\u308c\u308b\u306e\u3067\u30a8\u30c3\u30af\u30b9\u30b5\u30fc\u30d0\u30fc\u306e\u516c\u958b\u9375\u4f5c\u6210\u3067\u4f7f\u3063\u305f\u30d1\u30b9\u30d5\u30ec\u30fc\u30ba\u3092\u5165\u529b\u3057Enter\u3002\u5165\u529b\u6587\u5b57\u304c\u8868\u793a\u3055\u308c\u306a\u3044\u5834\u5408\u304c\u3001\u305d\u306e\u307e\u307e\u5165\u529b\u3057\u3066Enter\u3067\u554f\u984c\u306a\u3057\u3002<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Enter passphrase for key &#8216;id_xserver_rsa&#8217;:\u00a0<\/span><\/p>\n<h2><span style=\"font-weight: 400;\">\u30ed\u30b0\u30a4\u30f3\u306e\u7c21\u7565\u5316<\/span><\/h2>\n<p><span style=\"font-weight: 400;\">\u3044\u3061\u3044\u3061\u4e0a\u8a18\u306e\u9577\u3044\u30b3\u30de\u30f3\u30c9\u6253\u3064\u306e\u304c\u5927\u5909\u306a\u306e\u3067\u3001.ssh\u306bconfig\u30d5\u30a1\u30a4\u30eb\u3092\u4f5c\u308a\u30ed\u30b0\u30a4\u30f3\u3092\u7c21\u7565\u5316\u3059\u308b<\/span><\/p>\n<p><span style=\"font-weight: 400;\">#config\u3092\u4f5c\u6210\u3057\u3066vim\u3067\u958b\u304f(\u30c6\u30ad\u30b9\u30c8\u30a8\u30c7\u30a3\u30bf\u3067\u3082\u53ef\uff09<\/span><\/p>\n<p><span style=\"font-weight: 400;\">$ vim ~\/.ssh\/config<\/span><\/p>\n<p><span style=\"font-weight: 400;\">\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u8a18\u8ff0<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Host xserver #\u4efb\u610f\u306e\u30b3\u30de\u30f3\u30c9\u540d<\/span><\/p>\n<p><span style=\"font-weight: 400;\">\u00a0\u00a0HostName \u30b5\u30fc\u30d0\u30fcsv8288.xsrv.jp<\/span><\/p>\n<p><span style=\"font-weight: 400;\">\u00a0\u00a0Port 10022<\/span><\/p>\n<p><span style=\"font-weight: 400;\">\u00a0\u00a0User \u30b5\u30fc\u30d0\u30fcID<\/span><\/p>\n<p><span style=\"font-weight: 400;\">\u00a0\u00a0IdentityFile ~\/.ssh\/id_xserver_rsa #\u79d8\u5bc6\u9375\u306e\u30d5\u30a1\u30a4\u30eb\u540d<\/span><\/p>\n<p><span style=\"font-weight: 400;\">\u00a0\u00a0ServerAliveInterval 60 #ssh\u306e\u81ea\u52d5\u5207\u65ad\u3092\u9632\u3050\u305f\u3081\u306b\u8a18\u8ff0<\/span><\/p>\n<p><span style=\"font-weight: 400;\">\u3053\u308c\u3067\u4ee5\u4e0b\u30b3\u30de\u30f3\u30c9\u3067\u30a2\u30af\u30bb\u30b9\u304c\u53ef\u80fd<\/span><\/p>\n<p><span style=\"font-weight: 400;\">$ ssh xserver<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u958b\u9375\u8a8d\u8a3c\u7528\u306e\u9375\u30da\u30a2\u3092\u4f5c\u6210\u3002\u79d8\u5bc6\u9375fkumazemi.key\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3002\u30d1\u30b9\u30d5\u30ec\u30fc\u30ba\u306f\u5fd8\u308c\u305a\u30e1\u30e2\u3092\u3002 \u79d8\u5bc6\u9375\u306e\u8a2d\u7f6e \u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3057\u305ffkumazemi.key\u3092\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3067\u79fb\u52d5 #.ssh\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u306e\u4f5c\u6210 $ m [&hellip;]<\/p>\n","protected":false},"author":20,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-1680","post","type-post","status-publish","format-standard","hentry","category-news"],"_links":{"self":[{"href":"https:\/\/f-kumazemi.org\/index.php?rest_route=\/wp\/v2\/posts\/1680","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/f-kumazemi.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/f-kumazemi.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/f-kumazemi.org\/index.php?rest_route=\/wp\/v2\/users\/20"}],"replies":[{"embeddable":true,"href":"https:\/\/f-kumazemi.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1680"}],"version-history":[{"count":1,"href":"https:\/\/f-kumazemi.org\/index.php?rest_route=\/wp\/v2\/posts\/1680\/revisions"}],"predecessor-version":[{"id":1681,"href":"https:\/\/f-kumazemi.org\/index.php?rest_route=\/wp\/v2\/posts\/1680\/revisions\/1681"}],"wp:attachment":[{"href":"https:\/\/f-kumazemi.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1680"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/f-kumazemi.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1680"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/f-kumazemi.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1680"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}