{"id":3609,"date":"2018-10-22T12:00:25","date_gmt":"2018-10-22T03:00:25","guid":{"rendered":"https:\/\/alb-owned-https-576747877.ap-northeast-1.elb.amazonaws.com\/?p=3609"},"modified":"2023-06-20T13:50:09","modified_gmt":"2023-06-20T04:50:09","slug":"ami-ubuntu-ec2-remote-desktop","status":"publish","type":"post","link":"https:\/\/alb-owned-https-576747877.ap-northeast-1.elb.amazonaws.com\/ami-ubuntu-ec2-remote-desktop","title":{"rendered":"Ubuntu\u306eAmazon EC2\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u306b\u30ea\u30e2\u30fc\u30c8\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u63a5\u7d9a\u3067\u304d\u308b\u3088\u3046\u306b\u3059\u308b\u3088"},"content":{"rendered":"
\u5c11\u3057\u524d\u306e\u3053\u3068\u306a\u306e\u3067\u3059\u304c\u3001AWS\u4e0a\u306bUbuntu\u30b5\u30fc\u30d0\u3092\u305f\u3066\u3066\u6b32\u3057\u3044\u3068\u3044\u3046\u8981\u671b\u3092\u53d7\u3051\u307e\u3057\u305f\u3002\u4f9d\u983c\u8005\u66f0\u304f\u300c\u4f5c\u696d\u7528PC\uff08Windows\uff09\u304b\u3089\u63a5\u7d9a\u3067\u304d\u308b\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u74b0\u5883\u304c\u6b32\u3057\u3044\u300d\u3068\u306e\u3053\u3068\u3067\u3057\u305f\u304c\u3001\u4f7f\u3046\u4e88\u5b9a\u306eAmazon AMI\u306b\u306f\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u74b0\u5883\u306f\u5165\u3063\u3066\u3044\u307e\u305b\u3093\u3067\u3057\u305f\u3002<\/p>\n
\u3068\u3044\u3046\u8a33\u3067\u3001Ubuntu\u306b\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u74b0\u5883\u3092\u69cb\u7bc9\u3057\u3001\u30ea\u30e2\u30fc\u30c8\u3067\u63a5\u7d9a\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u305f\u6642\u306e\u624b\u9806\u3092\u7d39\u4ecb\u3057\u307e\u3059\u3002<\/p>\n
\u4eca\u56de\u306fxrdp\u3092\u30b5\u30fc\u30d0\u306b\u5c0e\u5165\u3057\u3066\u3001Windows10\u306e\u30af\u30e9\u30a4\u30a2\u30f3\u30c8PC\u304b\u3089\u30ea\u30e2\u30fc\u30c8\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u63a5\u7d9a\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u307e\u3059\u3002Unix\u30e9\u30a4\u30afOS\u3067\u306f\u3001\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u74b0\u5883\u306b\u63a5\u7d9a\u3059\u308b\u969b\u306b\u306fVNC\uff08Virtual Network Computing\uff09\u3092\u4f7f\u3046\u3053\u3068\u304c\u591a\u3044\u3068\u601d\u3046\u306e\u3067\u3059\u304c\u3001xrdp\u3092\u4f7f\u3048\u3070\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u304cWindows\u306e\u5834\u5408\u306b\u306f\u8ffd\u52a0\u306e\u30bd\u30d5\u30c8\u30a6\u30a7\u30a2\u304c\u4e0d\u8981\uff08\u6a19\u6e96\u3067\u7528\u610f\u3055\u308c\u3066\u3044\u308b\u300c\u30ea\u30e2\u30fc\u30c8\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u63a5\u7d9a\u300d\u3092\u4f7f\u3048\u3070\u3044\u3044\uff09\u306a\u306e\u3067\u3001\u5229\u7528\u8005\u5074\u306e\u6e96\u5099\u304c\u3059\u3053\u3057\u697d\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n
\u52d5\u4f5c\u306b\u3064\u3044\u3066\u306f\u3001Ubuntu 16.04 LTS\u3067\u78ba\u8a8d\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n
\u30b5\u30fc\u30d0\u306f\u5229\u7528\u8005\u306b\u5f15\u304d\u6e21\u3059\u4e88\u5b9a\u306a\u306e\u3067\u3001\u4f5c\u696d\u306f\u3059\u3079\u3066AMI\u30c7\u30d5\u30a9\u30eb\u30c8\u306eubuntu\u30e6\u30fc\u30b6\u3067\u884c\u3044\u307e\u3059\u3002\u307e\u305f\u3001\u30e6\u30fc\u30b6\u304c\u30ea\u30e2\u30fc\u30c8\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u63a5\u7d9a\u306b\u4f7f\u3046\u30a2\u30ab\u30a6\u30f3\u30c8\u3082\u540c\u3058ubuntu\u30e6\u30fc\u30b6\u3068\u3057\u3066\u3044\u307e\u3059\u3002\u300c\u5229\u7528\u8005\u306b\u7ba1\u7406\u8005\u6a29\u9650\u3092\u6e21\u3057\u305f\u304f\u306a\u3044\u3088\u300d\u3068\u3044\u3046\u65b9\u306f\u9069\u5b9c\u5229\u7528\u8005\u7528\u306e\u30a2\u30ab\u30a6\u30f3\u30c8\u3092\u4f5c\u6210\u3059\u308b\u7b49\u3057\u3066\u304f\u3060\u3055\u3044\u3002\u307e\u305f\u3001AMI\u304b\u3089EC2\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u4f5c\u6210\u3059\u308b\u624b\u9806\u306f\u7701\u7565\u3057\u3066\u3044\u307e\u3059\u3002<\/p>\n
\u307e\u305a\u306f\u5c0e\u5165\u3055\u308c\u3066\u3044\u308b\u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u6700\u65b0\u5316\u3057\u3066\u304a\u304d\u307e\u3057\u3087\u3046\u3002\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3\u7684\u306b\u3082\u5927\u5207\u306a\u30b9\u30c6\u30c3\u30d7\u3067\u3059\u3002<\/p>\n
$ sudo apt-get update\r\n$ sudo apt-get upgrade<\/pre>\n\u65e5\u672c\u8a9e\u30d1\u30c3\u30b1\u30fc\u30b8\u306e\u69cb\u7bc9\u3068\u30ed\u30b1\u30fc\u30eb\u306e\u8a2d\u5b9a<\/h3>\n
\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u74b0\u5883\u3067\u65e5\u672c\u8a9e\u304c\u6271\u3048\u306a\u3044\u3068\u60b2\u3057\u3044\u306e\u3067\u3001\u5fc5\u8981\u306a\u30d1\u30c3\u30b1\u30fc\u30b8\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002\u307e\u305f\u3001\u30ed\u30b1\u30fc\u30eb\u3092\u65e5\u672c\u8a9e\u306b\u3057\u3066\u304a\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n
$ sudo apt install language-pack-ja-base language-pack-ja\r\n$ sudo localectl set-locale LANG=ja_JP.utf-8 LANGUAGE=\"ja_JP:ja\"<\/pre>\n\u3053\u3053\u3067\u4e00\u5ea6EC2\u30a4\u30f3\u30b9\u30bf\u30f3\u30b9\u3092\u518d\u8d77\u52d5\u3057\u3066\u304a\u304d\u307e\u3057\u3087\u3046\u3002<\/p>\n
SSH\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\u8a8d\u8a3c\u6709\u52b9\u5316\u3068\u30d1\u30b9\u30ef\u30fc\u30c9\u306e\u8a2d\u5b9a<\/h3>\n
ubuntu\u30e6\u30fc\u30b6\u3067\u30d1\u30b9\u30ef\u30fc\u30c9\u8a8d\u8a3c\u3092\u6709\u52b9\u5316\u3057\u307e\u3059\u3002\u307e\u305f\u3001\u30c7\u30d5\u30a9\u30eb\u30c8\u3067\u306fubuntu\u30e6\u30fc\u30b6\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\u304c\u8a2d\u5b9a\u3055\u308c\u3066\u3044\u306a\u3044\u306e\u3067\u8a2d\u5b9a\u3057\u307e\u3059\u3002<\/p>\n
$ sudo sed -i 's\/^PasswordAuthentication no\/PasswordAuthentication yes\/' \/etc\/ssh\/sshd_config\r\n$ sudo \/etc\/init.d\/ssh restart\r\n$ sudo passwd ubuntu<\/pre>\n\u30d1\u30c3\u30b1\u30fc\u30b8\u7ba1\u7406\u30bd\u30d5\u30c8\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/h3>\n
Ubuntu\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30e9\u3092\u52d5\u4f5c\u3055\u305b\u308b\u3068\u3001\u9014\u4e2d\u3067\u30b5\u30fc\u30d0\u4e0a\u3067\u52d5\u4f5c\u3055\u305b\u308b\u30b5\u30fc\u30d3\u30b9\u3092\u9078\u629e\u3055\u305b\u308b\u753b\u9762\u304c\u51fa\u307e\u3059\u304c\u3001\u305d\u308c\u3092\u5f8c\u304b\u3089\u4f7f\u3044\u305f\u3044\u5834\u5408\u306b\u306ftasksel\u30b3\u30de\u30f3\u30c9\u3092\u4f7f\u3044\u307e\u3059\u3002\u307e\u305a\u306f\u30b3\u30de\u30f3\u30c9\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n
$ sudo apt install tasksel<\/pre>\n\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u74b0\u5883\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/h3>\n
\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3067\u304d\u305f\u3089\u3001tasksel\u3092\u8d77\u52d5\u3057\u307e\u3059\u3002<\/p>\n
$ sudo tasksel<\/pre>\n\u30ea\u30b9\u30c8\u304b\u3089\u300cUbuntu MATE Cloudtop\u300d\u3092\u9078\u629e\u3057\u307e\u3059\u3002MATE\uff08\u30de\u30c6\uff09\u306fGNOME\u00a02\u306e\u30b3\u30fc\u30c9\u304b\u3089\u30d5\u30a9\u30fc\u30af\u3055\u308c\u305f\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u74b0\u5883\u3067\u3059\u3002Cloudtop\u306f\u30af\u30e9\u30a6\u30c9\u306b\u6700\u9069\u5316\u3055\u308c\u305f\u30bb\u30c3\u30c8\u3067\u3059\u3002<\/p>\n
\u65e5\u672c\u8a9e\u5165\u529b\u30b7\u30b9\u30c6\u30e0\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/h3>\n
\u65e5\u672c\u8a9e\u5165\u529b\u30b7\u30b9\u30c6\u30e0\u3067\u3042\u308bMozc\uff08\u30e2\u30ba\u30af\uff09\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n
$ sudo apt install ibus-mozc<\/pre>\n\u30ea\u30e2\u30fc\u30c8\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u63a5\u7d9a\u30b5\u30fc\u30d0(xrdp)\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/h3>\n
\u30ea\u30e2\u30fc\u30c8\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u63a5\u7d9a\u51fa\u6765\u308b\u3088\u3046\u306b\u3001xrdp\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n
$ sudo apt install xrdp<\/pre>\n\u30ad\u30fc\u30dc\u30fc\u30c9\u8a2d\u5b9a<\/h3>\n
\u30ad\u30fc\u30dc\u30fc\u30c9\u306e\u8a2d\u5b9a\u3092\u3057\u307e\u3059\u3002<\/p>\n
$ sudo dpkg-reconfigure keyboard-configuration<\/pre>\n\u5168\u3066\u30c7\u30d5\u30a9\u30eb\u30c8\u9078\u629e\u3067OK\u3067\u3059\u3002<\/p>\n
xrdp\u65e5\u672c\u8a9e\u914d\u5217\u306e\u30ad\u30fc\u30de\u30c3\u30d7\u306e\u4fee\u6b63<\/h3>\n
\u30ad\u30fc\u30de\u30c3\u30d7\u304cUS\u306e\u3082\u306e\u306b\u306a\u3063\u3066\u3044\u308b\u306e\u3067\u3001\u65e5\u672c\u8a9e\u914d\u5217\u7528\u306b\u5909\u66f4\u3057\u307e\u3059\u3002<\/p>\n
$ cd \/etc\/xrdp\r\n$ sudo wget\u00a0http:\/\/www.mail-archive.com\/xrdp-devel@lists.sourceforge.net\/msg00263\/km-e0010411.ini\r\n$ sudo mv km-e0010411.ini km-0411.ini\r\n$ sudo ln -s km-0411.ini km-e0010411.ini\r\n$ sudo ln -s km-0411.ini km-e0200411.ini\r\n$ sudo ln -s km-0411.ini km-e0210411.ini<\/pre>\n\u30ea\u30e2\u30fc\u30c8\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u63a5\u7d9a\u30b5\u30fc\u30d0\u306e\u518d\u8d77\u52d5<\/h3>\n
xrdp\u30b5\u30fc\u30d0\u3092\u518d\u8d77\u52d5\u3057\u307e\u3059\u3002<\/p>\n
$ sudo systemctl restart xrdp<\/pre>\n\u624b\u9806\uff08\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u5074\uff09<\/h2>\n
\u3055\u3066\u3001\u3053\u308c\u3067\u30ea\u30e2\u30fc\u30c8\u304b\u3089\u30c7\u30b9\u30af\u30c8\u30c3\u30d7\u74b0\u5883\u306b\u30a2\u30af\u30bb\u30b9\u3067\u304d\u308b\u3088\u3046\u306b\u306f\u306a\u3063\u305f\u306e\u3067\u3059\u304c\u3001\u3053\u306e\u72b6\u614b\u3067\u306f\u30a4\u30f3\u30bf\u30fc\u30cd\u30c3\u30c8\u4e0a\u306b\u6697\u53f7\u5316\u3055\u308c\u3066\u3044\u306a\u3044\u751f\u306e\u30c7\u30fc\u30bf\u304c\u6d41\u308c\u3066\u3057\u307e\u3046\u3053\u3068\u306b\u306a\u308a\u307e\u3059\u3002\u30bb\u30ad\u30e5\u30ea\u30c6\u30a3\u7684\u306b\u5927\u5909\u3088\u308d\u3057\u304f\u306a\u3044\u72b6\u614b\u3068\u306a\u308a\u307e\u3059\u306e\u3067\u3001\u901a\u4fe1\u3092\u6697\u53f7\u5316\u3059\u308b\u3053\u3068\u306b\u3057\u307e\u3057\u3087\u3046\u3002\u901a\u4fe1\u3092\u6697\u53f7\u5316\u3059\u308b\u306e\u306bSSH\u30dd\u30fc\u30c8\u30d5\u30a9\u30ef\u30fc\u30c7\u30a3\u30f3\u30b0\u3092\u5229\u7528\u3057\u307e\u3059\u3002\u305d\u308c\u306b\u306f\u5c11\u3057\u30af\u30e9\u30a4\u30a2\u30f3\u30c8PC\u5074\u306b\u6e96\u5099\u304c\u5fc5\u8981\u3067\u3059\u3002\u624b\u9806\u306b\u3064\u3044\u3066\u7c21\u5358\u306b\u8aac\u660e\u3055\u305b\u3066\u3044\u305f\u3060\u304d\u307e\u3059\u3002<\/p>\n
TeraTerm\u306e\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/h3>\n