hiratake55 の作業メモ

R, Javascript, Python, Linux and Hadoop

Amazon Linux に R をインストールする

Amazon EC2 上の Amazon Linux (2012.03 64bit) に R 2.15.0 をインストールする方法をメモ。

1. Yum レポジトリCentOS-Base を追加。

Amazon Linux 標準のレポジトリ (amzn-main, amzn-updates) には、R のインストールに必要な tk-devel xdg-utils パッケージが登録されていないため、CentOSレポジトリを追加します。

root で 以下ファイルを作成。

# vi /etc/yum.repos.d/CentOS-Base.repo

[base]
name=CentOS-6 - Base
mirrorlist=http://mirrorlist.centos.org/?release=6&arch=x86_64&repo=os
enabled=0
gpgcheck=1
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

2. CentOS-Base レポジトリから、tk-devel xdg-utils パッケージをダウンロード。

root で以下コマンドを実行。

# yum install --enablerepo=base tk-devel xdg-utils

2. epel レポジトリから、R パッケージをダウンロード。

root で以下コマンドを実行。epel レポジトリからダウンロードします。

# yum --enablerepo=epel install R