- さくらのVPS(SSD 30GB/MEM 1GB)
- Ubuntu 14.04 LTS
Ubuntu 14.04 LTSのインストールについて
VNCコンソールを利用してさくらのVPSにUbuntu14.04をインストールする。
インストール方法は割愛。
ココに詳しく書いてある。
1点だけ、VNCコンソール(HTML5版)でインストール対話を進める中で、
キーボード入力が効かなくなる場面があった。
(ググる為にブラウザ間を行ったり来たりしてると起こった)
その場合Ctrl+Alt+Del
を送って最初からやり直せば一応はうまくいく。
インストールの流れについて
基本的にはドキュメント通りに進めていく。
手順の中で省略したり方法を置き換えたりしているところもある。
全てroot権限でやった方がハマることが少なくて無難。
と、思ったけどOSインストールしたら、
標準でインストールされている上にちゃんとsshdも立ち上がっている。
一応rootユーザによるSSHログインは拒否しておく。
$ ssh [email protected]
Are you sure you want to continue connecting (yes/no)? yes
[email protected]'s password:xxxx
$ vim /etc/ssh/sshd_config
The program 'vim' can be found in the following packages:
* vim
* vim-gnome
* vim-tiny
* vim-athena
* vim-gtk
* vim-nox
Try: sudo apt-get install <selected package>
( ´ω´)
# $ apt-get install vim
$ vim /etc/ssh/sshd_config
- PermitRootLogin without-password
+ PermitRootLogin no
$ sudo /etc/init.d/ssh restart
ドキュメント通り。
$ wget http://ubuntu.bigbluebutton.org/bigbluebutton.asc -O- | apt-key add -
ドキュメント通り。
$ echo "deb http://ubuntu.bigbluebutton.org/lucid_dev_08/ bigbluebutton-lucid main" | tee /etc/apt/sources.list.d/bigbluebutton.list
$ echo "deb http://us.archive.ubuntu.com/ubuntu/ lucid multiverse" | tee -a /etc/apt/sources.list
ドキュメント通りにやるとlibffi5が無いと言われる。
rbenvで指定バージョンを入れる。
これは絶対rootでやること!
$ sudo su
$ git clone https://github.com/sstephenson/rbenv.git ~/.rbenv
$ git clone https://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build
$ echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bash_profile
$ echo 'eval "$(rbenv init -)"' >> ~/.bash_profile
$ source ~/.bash_profile
$ rbenv --version
rbenv 0.4.0-153-g3b6faa8
$ rbenv install 1.9.2-p290
$ rbenv global 1.9.2-p290
$ ruby --version
ruby 1.9.2p290 (2011-07-09 revision 32553) [x86_64-linux]
ここはドキュメント通り。
何に使うのかわからないけど刃向うと損をするので従う。
$ wget http://bigbluebutton.googlecode.com/files/openoffice.org_1.0.4_all.deb
$ dpkg -i openoffice.org_1.0.4_all.deb
$ apt-get install python-software-properties
$ apt-add-repository ppa:libreoffice/libreoffice-4-0
$ apt-get update
$ apt-get install libreoffice-common
$ apt-get install libreoffice
インストールスクリプトが公開されている。
$ vim ffmpeg_install
+ #!/bin/sh
+ sudo apt-get install build-essential git-core checkinstall yasm texi2html libvorbis-dev libx11-dev libvpx-dev libxfixes-dev zlib1g-dev pkg-config netcat libncurses5-dev
+ cd /usr/local/src
+ if [ ! -d "/usr/local/src/ffmpeg-${FFMPEG_VERSION}" ]; then
+ sudo wget "http://ffmpeg.org/releases/ffmpeg-${FFMPEG_VERSION}.tar.bz2"
+ sudo tar -xjf "ffmpeg-${FFMPEG_VERSION}.tar.bz2"
+ fi
+ cd "ffmpeg-${FFMPEG_VERSION}"
+ sudo ./configure --enable-version3 --enable-postproc --enable-libvorbis --enable-libvpx
+ sudo make
+ sudo checkinstall --pkgname=ffmpeg --pkgversion="5:${FFMPEG_VERSION}" --backup=no --deldoc=yes --default
$ chmod 777 ffmpeg_install
$ ./ffmpeg_install
₍₍ (ง ˙ω˙)ว ⁾⁾コンパイルー
$ ffmpeg -version
ffmpeg version 2.3.3 Copyright (c) 2000-2014 the FFmpeg developers
built on Aug 20 2015 11:25:09 with gcc 4.8 (Ubuntu 4.8.4-2ubuntu1~14.04)
configuration: --enable-version3 --enable-postproc --enable-libvorbis --enable-libvpx
libavutil 52. 92.100 / 52. 92.100
libavcodec 55. 69.100 / 55. 69.100
libavformat 55. 48.100 / 55. 48.100
libavdevice 55. 13.102 / 55. 13.102
libavfilter 4. 11.100 / 4. 11.100
libswscale 2. 6.100 / 2. 6.100
libswresample 0. 19.100 / 0. 19.100
ここからが大変かも。
- 依存パッケージがリポジトリから消え去ってる
- ドキュメントにはない手順が必要になる
エラーをよく確認しながらStackOverFlowあたりとにらめっこする。
以下も見たり。
# apt-get install bigbluebuttonでswftools-0.9.1が解決できないと出る
# さらにswftoolsはlibgmp3c2とlibmpfr1ldb1に依存しているし
# パッケージがリポジトリにないので別途ダウンロードして入れる
$ wget http://launchpadlibrarian.net/70575439/libgmp3c2_4.3.2%2Bdfsg-2ubuntu1_amd64.deb
$ dpkg -i libgmp3c2_4.3.2%2Bdfsg-2ubuntu1_amd64.deb
$ wget http://free.nchc.org.tw/ubuntu//pool/main/m/mpfr/libmpfr1ldbl_2.4.2-3ubuntu1_amd64.deb
$ dpkg -i libmpfr1ldbl_2.4.2-3ubuntu1_amd64.deb
$ apt-get install swftools-0.9.1
# 後述するサーバの起動時に共有ライブラリが見つからないエラーになる
# いまのうちに入れておく
$ apt-get install libssl0.9.8
# これも後述するサーバの起動時にnginxの50x.htmlがないよって言われる
# いまのうちに対応
$ mkdir -p /var/www/nginx-default
$ touch /var/www/nginx-default/50x.html
# 日本語を正しく表示するためのフォント
$ apt-get install -y xfonts-intl-japanese-big xfonts-intl-japanese
# これはドキュメントに書いてあるトラブルシューティング
# 必要ないかもしれない
$ wget http://ubuntu.bigbluebutton.org/files/bbb-deskshare-applet-0.8.1.jar
$ cp bbb-deskshare-applet-0.8.1.jar /var/www/bigbluebutton/client/bbb-deskshare-applet-0.8.1.jar
# jdkが必要だと言われる
# JAVA_HOMEを見てるようなので設定までする
$ apt-get install openjdk-7-jdk
$ vim ~/.bash_profile
+ JAVA_HOME=$(readlink -f /usr/bin/javac | sed "s:/bin/javac::")
+ export JAVA_HOME
+ PATH=$PATH:$JAVA_HOME/bin
+ export PATH
$ source ~/.bash_profile
# bundleコマンドが見つからないと出る
# 内部的にsudoしていてそこからbundle参照できなくても出る
# その場合はlnでリンクつくる
$ gem install bundler
$ ln -s /root/.rbenv/shims/bundle /usr/local/bin
# gherkinがインストールできないと出る
# http://www.ramuda.co.jp/techlabo/archives/811
$ gem install gherkin -v '2.2.9' -- --with-cflags=-w
$ apt-get install bigbluebutton
# => 利用規約とライセンス条項が出る
# APIデモは不要
# $ apt-get install bbb-demo
# nginxを立ち上げる
$ /etc/init.d/nginx start
# bigbluebuttonを起動させる
$ bbb-conf --clean
Doing a clean restart of BigBlueButton ...
* Stopping Red5 Server red5
...done.
* Stopping Tomcat servlet engine tomcat6
...done.
Openoffice headless server is not running.
Record and Playback monitoring stopped not running
Cleaning Log Files ...
* nginx is not running
* Red5 Server is not running.
* Tomcat servlet engine is not running.
Starting FreeSWITCH
Error: stacksize -1 is too large: run ulimit -s 240 or run /opt/freeswitch/bin/freeswitch -waste.
auto-adjusting stack size for optimal performance...
5132 Backgrounding.
Waiting for FreeSWITCH to start: ...........................
Starting OpenOffice headless server
* Starting Red5 Server red5
...done.
* Starting Tomcat servlet engine tomcat6
...done.
Record and Playback monitoring started
Waiting for BigBlueButton to finish starting up (this may take a minute):
done
** Potential problems described below **
# Not Running: OpenOffice
# Warning: You are running BigBlueButton on a server with less than 2G of memory. Your
# performance may suffer.
# Warning: The API demos are installed and accessible from:
#
# http://xxx.xxx.xxx.xxx/
#
# Use the API demos test your BigBlueButton setup. To remove
#
# sudo apt-get purge bbb-demo