MySQLの場合: create database redmine character set utf8; create user 'redmine'@'localhost' identified by 'password'; grant all privileges on redmine.* to 'redmine'@'localhost'; chmod -R 777 db これをしておかないと、db:migrationの最後でエラーが出る [fujii@centos redmine-0.8.4]$ rake db:migrate RAILS_ENV=production (in /home/fujii/redmine-0.8.4) [fujii@centos redmine-0.8.4]$ rake redmine:load_default_data RAILS_ENV=production (in /home/fujii/redmine-0.8.4) Select language: bg, ca, cs, da, de, en, es, fi, fr, he, hu, it, ja, ko, lt, nl, no, pl, pt, pt-br, ro, ru, sk, sr, sv, th, tr, uk, vn, zh, zh-tw [en] ja ==================================== Some configuration data is already loaded. chown -R 1000:1000 files log tmp public/plugin_assets chmod -R 755 files log tmp public/plugin_assets [fujii@centos redmine-0.8.4]$ ruby script/server -e production => Booting Mongrel (use 'script/server webrick' to force WEBrick) => Rails 2.1.2 application starting on http://0.0.0.0:3000 => Call with -d to detach => Ctrl-C to shutdown server ** Starting Mongrel listening at 0.0.0.0:3000 ** Starting Rails with production environment... ** Rails loaded. ** Loading any Rails specific GemPlugins ** Signals ready. TERM => stop. USR2 => restart. INT => stop (no restart). ** Rails signals registered. HUP => reload (without restart). It might not work well. ** Mongrel 1.1.5 available at 0.0.0.0:3000 ** Use CTRL-C to stop. Processing WelcomeController#index (for 172.21.21.16 at 2009-09-11 11:02:03) [GET] Session ID: 6aaa4ee22a582451b0df2acf706e0b24 Parameters: {"action"=>"index", "controller"=>"welcome"} DEPRECATION WARNING: You're using the Ruby-based MySQL library that ships with Rails. This library will be REMOVED FROM RAILS 2.2. Please switch to the offical mysql gem: `gem install mysql` See http://www.rubyonrails.org/deprecation for details. (called from mysql_connection at /home/fujii/redmine-0.8.4/vendor/rails/activerecord/lib/active_record/connection_adapters/mysql_adapter.rb:81) Rendering template within layouts/base Rendering welcome/index Completed in 0.35780 (2 reqs/sec) | Rendering: 0.21654 (60%) | DB: 0.05216 (14%) | 200 OK [http://172.21.44.142/] Processing AccountController#show (for 172.21.21.16 at 2009-09-11 11:02:15) [GET] Session ID: 6aaa4ee22a582451b0df2acf706e0b24 Parameters: {"action"=>"show", "id"=>"1", "controller"=>"account"} Rendering template within layouts/base Rendering account/show Completed in 0.56074 (1 reqs/sec) | Rendering: 0.06001 (10%) | DB: 0.10128 (18%) | 200 OK [http://172.21.44.142/account/show/1] Processing MyController#account (for 172.21.21.16 at 2009-09-11 11:02:19) [GET] Session ID: 6aaa4ee22a582451b0df2acf706e0b24 Parameters: {"action"=>"account", "controller"=>"my"} Rendering template within layouts/base Rendering my/account Completed in 0.11306 (8 reqs/sec) | Rendering: 0.08408 (74%) | DB: 0.01449 (12%) | 200 OK [http://172.21.44.142/my/account] ** INT signal received. Exiting [fujii@centos redmine-0.8.4]$ ruby script/server -e production -d => Booting Mongrel (use 'script/server webrick' to force WEBrick) => Rails 2.1.2 application starting on http://0.0.0.0:3000 [fujii@centos redmine-0.8.4]$ |
PHPパッケージ(5.2の例) php-cli-5.2.8-1dino1.i386.rpm php-gd-5.2.8-1dino1.i386.rpm php-mysql-5.2.8-1dino1.i386.rpm php-bcmath-5.2.8-1dino1.i386.rpm php-common-5.2.8-1dino1.i386.rpm php-mbstring-5.2.8-1dino1.i386.rpm php-pdo-5.2.8-1dino1.i386.rpm -------------- php.ini mbstring.language = Japanese auto_detect_line_endings = on output_handler = mb_output_handler mbstring.internal_encoding = UTF-8 mbstring.encoding_translation = on mbstring.detect_order = auto mbstring.substitute_character = none magic_quotes_gpc off ----------- /etc/httpd/conf/httpd.conf # |
[fujii@centos ~]$ gem install mongrel Building native extensions. This could take a while... Successfully installed gem_plugin-0.2.3 Successfully installed daemons-1.0.10 Successfully installed cgi_multipart_eof_fix-2.5.0 Successfully installed mongrel-1.1.5 4 gems installed Installing ri documentation for gem_plugin-0.2.3... Installing ri documentation for daemons-1.0.10... Installing ri documentation for cgi_multipart_eof_fix-2.5.0... Installing ri documentation for mongrel-1.1.5... Installing RDoc documentation for gem_plugin-0.2.3... Installing RDoc documentation for daemons-1.0.10... Installing RDoc documentation for cgi_multipart_eof_fix-2.5.0... Installing RDoc documentation for mongrel-1.1.5... [fujii@centos ~]$ruby script/server -p 4000 |
[root@centos fujii]# passenger-install-apache2-module Welcome to the Phusion Passenger Apache 2 module installer, v2.2.5. This installer will guide you through the entire installation process. It shouldn't take more than 3 minutes in total. Here's what you can expect from the installation process: 1. The Apache 2 module will be installed for you. 2. You'll learn how to configure Apache. 3. You'll learn how to deploy a Ruby on Rails application. Don't worry if anything goes wrong. This installer will advise you on how to solve any problems. Press Enter to continue, or Ctrl-C to abort. -------------------------------------------- Checking for required software... * GNU C++ compiler... not found * Ruby development headers... found * OpenSSL support for Ruby... found * RubyGems... found * Rake... found at /home/fujii/bin/rake * Apache 2... found at /usr/sbin/httpd * Apache 2 development headers... found at /usr/sbin/apxs * fastthread... found * Apache Portable Runtime (APR) development headers... found at /usr/bin/apr-1-config * Apache Portable Runtime Utility (APU) development headers... found at /usr/bin/apu-1-config Some required software is not installed. But don't worry, this installer will tell you how to install them. Press Enter to continue, or Ctrl-C to abort. -------------------------------------------- Installation instructions for required software * To install GNU C++ compiler: Please run yum install gcc-c++ as root. If the aforementioned instructions didn't solve your problem, then please take a look at the Users Guide: /home/fujii/lib/ruby/gems/1.8/gems/passenger-2.2.5/doc/Users guide Apache.html うまく導入できなかった様子、再度gcc-c++を導入して挑戦 [root@centos fujii]# yum install gcc-c++ -------------------------------------------------------------------------------- Total 1.3 MB/s | 6.3 MB 00:04 Running rpm_check_debug Running Transaction Test Finished Transaction Test Transaction Test Succeeded Running Transaction Installing : libstdc++-devel [1/2] Installing : gcc-c++ [2/2] Installed: gcc-c++.i386 0:4.1.2-44.el5 Dependency Installed: libstdc++-devel.i386 0:4.1.2-44.el5 Complete! [root@centos fujii]# passenger-install-apache2-module Welcome to the Phusion Passenger Apache 2 module installer, v2.2.5. This installer will guide you through the entire installation process. It shouldn't take more than 3 minutes in total. Here's what you can expect from the installation process: 1. The Apache 2 module will be installed for you. 2. You'll learn how to configure Apache. 3. You'll learn how to deploy a Ruby on Rails application. Don't worry if anything goes wrong. This installer will advise you on how to solve any problems. Press Enter to continue, or Ctrl-C to abort. -------------------------------------------- Checking for required software... * GNU C++ compiler... found at /usr/bin/g++ * Ruby development headers... found * OpenSSL support for Ruby... found * RubyGems... found * Rake... found at /home/fujii/bin/rake * Apache 2... found at /usr/sbin/httpd * Apache 2 development headers... found at /usr/sbin/apxs * fastthread... found * Apache Portable Runtime (APR) development headers... found at /usr/bin/apr-1-config * Apache Portable Runtime Utility (APU) development headers... found at /usr/bin/apu-1-config -------------------------------------------- Compiling and installing Apache 2 module... cd /home/fujii/lib/ruby/gems/1.8/gems/passenger-2.2.5 /home/fujii/bin/ruby -S /home/fujii/bin/rake clean apache2 # /home/fujii/bin/ruby -S /home/fujii/bin/rake clean apache2 (in /home/fujii/lib/ruby/gems/1.8/gems/passenger-2.2.5) rm -rf ext/apache2/libboost_oxt.a ext/apache2/libboost_oxt rm -rf ext/apache2/libpassenger_common.a ext/apache2/ApplicationPoolServerExecutable ext/apache2/libpassenger_common rm -rf ext/apache2/Configuration.o ext/apache2/Bucket.o ext/apache2/Hooks.o ext/apache2/mod_passenger.o ext/apache2/mod_passenger.so rm -rf ext/nginx/libboost_oxt.a ext/nginx/libboost_oxt rm -rf ext/nginx/libpassenger_common.a ext/nginx/libpassenger_common rm -rf ext/nginx/HelperServer rm -rf test/libboost_oxt.a test/libboost_oxt rm -rf test/libpassenger_common.a test/ApplicationPoolServerExecutable test/libpassenger_common rm -rf test/oxt/oxt_test_main test/oxt/*.o test/CxxTests test/*.o rm -r pkg cd ext/phusion_passenger && make clean rm -f ext/phusion_passenger/Makefile mkdir -p ext/apache2/libpassenger_common g++ -Iext -Iext/common -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/libpassenger_common/Utils.o -c ext/common/Utils.cpp g++ -Iext -Iext/common -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/libpassenger_common/Logging.o -c ext/common/Logging.cpp g++ -Iext -Iext/common -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/libpassenger_common/SystemTime.o -c ext/common/SystemTime.cpp g++ -Iext -Iext/common -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/libpassenger_common/CachedFileStat.o -c ext/common/CachedFileStat.cpp g++ -Iext -Iext/common -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/libpassenger_common/Base64.o -c ext/common/Base64.cpp mkdir -p ext/apache2/libpassenger_common rm -rf ext/apache2/libpassenger_common.a ar cru ext/apache2/libpassenger_common.a ext/apache2/libpassenger_common/*.o ranlib ext/apache2/libpassenger_common.a mkdir -p ext/apache2/libboost_oxt/boost g++ -Iext -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/libboost_oxt/boost/once.o -c ext/boost/src/pthread/once.cpp g++ -Iext -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/libboost_oxt/boost/thread.o -c ext/boost/src/pthread/thread.cpp g++ -Iext -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/libboost_oxt/boost/exceptions.o -c ext/boost/src/pthread/exceptions.cpp mkdir -p ext/apache2/libboost_oxt/oxt g++ -Iext -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/libboost_oxt/oxt/backtrace.o -c ext/oxt/backtrace.cpp g++ -Iext -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/libboost_oxt/oxt/thread.o -c ext/oxt/thread.cpp g++ -Iext -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/libboost_oxt/oxt/tracable_exception.o -c ext/oxt/tracable_exception.cpp g++ -Iext -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/libboost_oxt/oxt/system_calls.o -c ext/oxt/system_calls.cpp mkdir -p ext/apache2/libboost_oxt/boost ext/apache2/libboost_oxt/oxt rm -rf ext/apache2/libboost_oxt.a ar cru ext/apache2/libboost_oxt.a ext/apache2/libboost_oxt/boost/*.o ext/apache2/libboost_oxt/oxt/*.o ranlib ext/apache2/libboost_oxt.a g++ ext/common/ApplicationPoolServerExecutable.cpp -o ext/apache2/ApplicationPoolServerExecutable -Iext -Iext/common -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS ext/apache2/libpassenger_common.a ext/apache2/libboost_oxt.a -lpthread gcc -Iext -Iext/common -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/mod_passenger.o -c ext/apache2/mod_passenger.c g++ -Iext -Iext/common -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/Configuration.o -c ext/apache2/Configuration.cpp g++ -Iext -Iext/common -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/Bucket.o -c ext/apache2/Bucket.cpp g++ -Iext -Iext/common -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -o ext/apache2/Hooks.o -c ext/apache2/Hooks.cpp g++ -shared ext/apache2/Configuration.o ext/apache2/Bucket.o ext/apache2/Hooks.o ext/apache2/mod_passenger.o -fPIC -o ext/apache2/mod_passenger.so -fPIC -DLINUX=2 -D_REENTRANT -D_GNU_SOURCE -D_LARGEFILE64_SOURCE -I/usr/include/apr-1 -I/usr/include/apr-1 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic -fasynchronous-unwind-tables -fno-strict-aliasing -I/usr/include/httpd -D_REENTRANT -I/usr/local/include -Wall -g -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS ext/apache2/libpassenger_common.a ext/apache2/libboost_oxt.a -fPIC -lapr-1 -laprutil-1 -lpthread cd ext/phusion_passenger && /home/fujii/bin/ruby extconf.rb creating Makefile cd ext/phusion_passenger && make gcc -I. -I/home/fujii/lib/ruby/1.8/i686-linux -I/home/fujii/lib/ruby/1.8/i686-linux -I. -D_FILE_OFFSET_BITS=64 -fPIC -g -O2 -c native_support.c gcc -shared -o native_support.so native_support.o -L. -L/home/fujii/lib -Wl,-R/home/fujii/lib -L. -rdynamic -Wl,-export-dynamic -------------------------------------------- The Apache 2 module was successfully installed. Please edit your Apache configuration file, and add these lines: LoadModule passenger_module /home/fujii/lib/ruby/gems/1.8/gems/passenger-2.2.5/ext/apache2/mod_passenger.so PassengerRoot /home/fujii/lib/ruby/gems/1.8/gems/passenger-2.2.5 PassengerRuby /home/fujii/bin/ruby After you restart Apache, you are ready to deploy any number of Ruby on Rails applications on Apache, without any further Ruby on Rails-specific configuration! Press ENTER to continue. -------------------------------------------- Deploying a Ruby on Rails application: an example Suppose you have a Ruby on Rails application in /somewhere. Add a virtual host to your Apache configuration file, and set its DocumentRoot to /somewhere/public, like this: |
login as: edps edps@172.21.20.140's password: Linux ubuntu910 2.6.31-14-generic-pae #48-Ubuntu SMP Fri Oct 16 15:22:42 UTC 2009 i686 To access official Ubuntu documentation, please visit: http://help.ubuntu.com/ Ubuntu Enterprise Cloud Administration and Documentation https://172.21.20.140:8443/ http://www.ubuntu.com/cloud Last login: Wed Nov 4 11:20:43 2009 edps@ubuntu910:~$ sudo apt-get install phpmyadmin パッケージリストを読み込んでいます... 完了 依存関係ツリーを作成しています 状態情報を読み取っています... 完了 phpmyadmin はすでに最新バージョンです。 アップグレード: 0 個、新規インストール: 0 個、削除: 0 個、保留: 3 個。 1 個のパッケージが完全にインストールまたは削除されていません。 この操作後に追加で 0B のディスク容量が消費されます。 phpmyadmin (4:3.2.2.1-1) を設定しています ... dbconfig-common: writing config to /etc/dbconfig-common/phpmyadmin.conf Replacing config file /etc/phpmyadmin/config-db.php with new version granting access to database phpmyadmin for phpmyadmin@localhost: success. verifying access for phpmyadmin@localhost: success. creating database phpmyadmin: success. verifying database phpmyadmin exists: success. populating database via sql... done. dbconfig-common: flushing administrative password * Reloading web server config apache2 [ OK ] edps@ubuntu910:~$ sudo apt-get install build-essential パッケージリストを読み込んでいます... 完了 依存関係ツリーを作成しています 状態情報を読み取っています... 完了 以下の特別パッケージがインストールされます: dpkg-dev fakeroot g++ g++-4.4 libstdc++6-4.4-dev patch 提案パッケージ: debian-keyring debian-maintainers g++-multilib g++-4.4-multilib gcc-4.4-doc libstdc++6-4.4-dbg libstdc++6-4.4-doc diff-doc 以下のパッケージが新たにインストールされます: build-essential dpkg-dev fakeroot g++ g++-4.4 libstdc++6-4.4-dev patch アップグレード: 0 個、新規インストール: 7 個、削除: 0 個、保留: 3 個。 6,999kB のアーカイブを取得する必要があります。 この操作後に追加で 23.5MB のディスク容量が消費されます。 続行しますか [Y/n]? Y 取得:1 http://jp.archive.ubuntu.com karmic/main libstdc++6-4.4-dev 4.4.1-4ubuntu8 [1,490kB] 取得:2 http://jp.archive.ubuntu.com karmic/main g++-4.4 4.4.1-4ubuntu8 [4,701kB] 取得:3 http://jp.archive.ubuntu.com karmic/main g++ 4:4.4.1-1ubuntu2 [1,446B] 取得:4 http://jp.archive.ubuntu.com karmic/main patch 2.5.9-5 [100kB] 取得:5 http://jp.archive.ubuntu.com karmic/main dpkg-dev 1.15.4ubuntu2 [573kB] 取得:6 http://jp.archive.ubuntu.com karmic/main build-essential 11.4 [7,172B] 取得:7 http://jp.archive.ubuntu.com karmic/main fakeroot 1.12.4ubuntu1 [126kB] 6,999kB を 4s で取得しました (1,549kB/s) 未選択パッケージ libstdc++6-4.4-dev を選択しています。 (データベースを読み込んでいます ... 現在 59790 個のファイルとディレクトリがインストールされています。) (.../libstdc++6-4.4-dev_4.4.1-4ubuntu8_i386.deb から) libstdc++6-4.4-dev を展開しています... 未選択パッケージ g++-4.4 を選択しています。 (.../g++-4.4_4.4.1-4ubuntu8_i386.deb から) g++-4.4 を展開しています... 未選択パッケージ g++ を選択しています。 (.../g++_4%3a4.4.1-1ubuntu2_i386.deb から) g++ を展開しています... 未選択パッケージ patch を選択しています。 (.../patch_2.5.9-5_i386.deb から) patch を展開しています... 未選択パッケージ dpkg-dev を選択しています。 (.../dpkg-dev_1.15.4ubuntu2_all.deb から) dpkg-dev を展開しています... 未選択パッケージ build-essential を選択しています。 (.../build-essential_11.4_i386.deb から) build-essential を展開しています... 未選択パッケージ fakeroot を選択しています。 (.../fakeroot_1.12.4ubuntu1_i386.deb から) fakeroot を展開しています... man-db のトリガを処理しています ... patch (2.5.9-5) を設定しています ... dpkg-dev (1.15.4ubuntu2) を設定しています ... fakeroot (1.12.4ubuntu1) を設定しています ... update-alternatives: using /usr/bin/fakeroot-sysv to provide /usr/bin/fakeroot (fakeroot) in auto mode. libstdc++6-4.4-dev (4.4.1-4ubuntu8) を設定しています ... g++-4.4 (4.4.1-4ubuntu8) を設定しています ... g++ (4:4.4.1-1ubuntu2) を設定しています ... update-alternatives: using /usr/bin/g++ to provide /usr/bin/c++ (c++) in auto mode. build-essential (11.4) を設定しています ... edps@ubuntu910:~$ sudo apt-get install ruby ruby1.8-dev irb rdoc ri edps@ubuntu910:~$ sudo apt-get install mysql-server edps@ubuntu910:~$ sudo apt-get install php5 edps@ubuntu910:~$ ruby -v ruby 1.8.7 (2009-06-12 patchlevel 174) [i486-linux] edps@ubuntu910:~$ edps@ubuntu910:~$ cd rubygems-1.3.5/ edps@ubuntu910:~/rubygems-1.3.5$ sudo ruby setup.rb [sudo] password for edps: RubyGems 1.3.5 installed === 1.3.5 / 2009-07-21 Bug fixes: * Fix use of prerelease gems. * Gem.bin_path no longer escapes path with spaces. Bug #25935 and #26458. Deprecation Notices: * Bulk index update is no longer supported (the code currently remains, but not the tests) * Gem::manage_gems was removed in 1.3.3. * Time::today was removed in 1.3.3. ------------------------------------------------------------------------------ RubyGems installed the following executables: /usr/bin/gem1.8 edps@ubuntu910:~/rubygems-1.3.5$ gem install rails WARNING: Installing to ~/.gem since /usr/lib/ruby/gems/1.8 and /usr/bin aren't both writable. WARNING: You don't have /home/edps/.gem/ruby/1.8/bin in your PATH, gem executables will not run. Successfully installed rake-0.8.7 Successfully installed activesupport-2.3.4 Successfully installed activerecord-2.3.4 Successfully installed rack-1.0.1 Successfully installed actionpack-2.3.4 Successfully installed actionmailer-2.3.4 Successfully installed activeresource-2.3.4 Successfully installed rails-2.3.4 8 gems installed Installing ri documentation for rake-0.8.7... Installing ri documentation for activesupport-2.3.4... Installing ri documentation for activerecord-2.3.4... Installing ri documentation for rack-1.0.1... Installing ri documentation for actionpack-2.3.4... Installing ri documentation for actionmailer-2.3.4... Installing ri documentation for activeresource-2.3.4... Installing ri documentation for rails-2.3.4... Installing RDoc documentation for rake-0.8.7... Installing RDoc documentation for activesupport-2.3.4... Installing RDoc documentation for activerecord-2.3.4... Installing RDoc documentation for rack-1.0.1... Installing RDoc documentation for actionpack-2.3.4... Installing RDoc documentation for actionmailer-2.3.4... Installing RDoc documentation for activeresource-2.3.4... Installing RDoc documentation for rails-2.3.4... edps@ubuntu910:~/rubygems-1.3.5$ sudo apt-get install libmysql-ruby パッケージリストを読み込んでいます... 完了 依存関係ツリーを作成しています 状態情報を読み取っています... 完了 以下の特別パッケージがインストールされます: libmysql-ruby1.8 libmysqlclient15off 以下のパッケージが新たにインストールされます: libmysql-ruby libmysql-ruby1.8 libmysqlclient15off アップグレード: 0 個、新規インストール: 3 個、削除: 0 個、保留: 3 個。 1,899kB のアーカイブを取得する必要があります。 この操作後に追加で 4,317kB のディスク容量が消費されます。 続行しますか [Y/n]? Y 取得:1 http://jp.archive.ubuntu.com karmic/universe libmysqlclient15off 5.1.30really5.0.83-0ubuntu3 [1,839kB] 取得:2 http://jp.archive.ubuntu.com karmic/universe libmysql-ruby1.8 2.8.1-1 [55.1kB] 取得:3 http://jp.archive.ubuntu.com karmic/universe libmysql-ruby 2.8.1-1 [5,266B] 1,899kB を 1s で取得しました (1,119kB/s) 未選択パッケージ libmysqlclient15off を選択しています。 (データベースを読み込んでいます ... 現在 60761 個のファイルとディレクトリがインストールされています。) (.../libmysqlclient15off_5.1.30really5.0.83-0ubuntu3_i386.deb から) libmysqlclient15off を展開しています... 未選択パッケージ libmysql-ruby1.8 を選択しています。 (.../libmysql-ruby1.8_2.8.1-1_i386.deb から) libmysql-ruby1.8 を展開しています... 未選択パッケージ libmysql-ruby を選択しています。 (.../libmysql-ruby_2.8.1-1_all.deb から) libmysql-ruby を展開しています... libmysqlclient15off (5.1.30really5.0.83-0ubuntu3) を設定しています ... libmysql-ruby1.8 (2.8.1-1) を設定しています ... libmysql-ruby (2.8.1-1) を設定しています ... libc-bin のトリガを処理しています ... ldconfig deferred processing now taking place edps@ubuntu910:~/rubygems-1.3.5$ sudo apt-get install mysql-client libmysqlclient15-dev パッケージリストを読み込んでいます... 完了 依存関係ツリーを作成しています 状態情報を読み取っています... 完了 以下の特別パッケージがインストールされます: zlib1g-dev 提案パッケージ: mysql-doc-5.0 以下のパッケージが新たにインストールされます: libmysqlclient15-dev mysql-client zlib1g-dev アップグレード: 0 個、新規インストール: 3 個、削除: 0 個、保留: 3 個。 7,500kB のアーカイブを取得する必要があります。 この操作後に追加で 21.5MB のディスク容量が消費されます。 続行しますか [Y/n]? Y 取得:1 http://jp.archive.ubuntu.com karmic/main zlib1g-dev 1:1.2.3.3.dfsg-13ubuntu3 [163kB] 取得:2 http://jp.archive.ubuntu.com karmic/universe libmysqlclient15-dev 5.1.30really5.0.83-0ubuntu3 [7,273kB] 取得:3 http://jp.archive.ubuntu.com karmic/main mysql-client 5.1.37-1ubuntu5 [63.7kB] 7,500kB を 5s で取得しました (1,487kB/s) 未選択パッケージ zlib1g-dev を選択しています。 (データベースを読み込んでいます ... 現在 60783 個のファイルとディレクトリがインストールされています。) (.../zlib1g-dev_1%3a1.2.3.3.dfsg-13ubuntu3_i386.deb から) zlib1g-dev を展開しています... 未選択パッケージ libmysqlclient15-dev を選択しています。 (.../libmysqlclient15-dev_5.1.30really5.0.83-0ubuntu3_i386.deb から) libmysqlclient15-dev を展開しています... 未選択パッケージ mysql-client を選択しています。 (.../mysql-client_5.1.37-1ubuntu5_all.deb から) mysql-client を展開しています... man-db のトリガを処理しています ... zlib1g-dev (1:1.2.3.3.dfsg-13ubuntu3) を設定しています ... libmysqlclient15-dev (5.1.30really5.0.83-0ubuntu3) を設定しています ... mysql-client (5.1.37-1ubuntu5) を設定しています ... libc-bin のトリガを処理しています ... ldconfig deferred processing now taking place edps@ubuntu910:~/rubygems-1.3.5$ gem install mysql WARNING: Installing to ~/.gem since /usr/lib/ruby/gems/1.8 and /usr/bin aren't both writable. WARNING: You don't have /home/edps/.gem/ruby/1.8/bin in your PATH, gem executables will not run. Building native extensions. This could take a while... Successfully installed mysql-2.8.1 1 gem installed Installing ri documentation for mysql-2.8.1... No definition for next_result No definition for field_name No definition for field_table No definition for field_def No definition for field_type No definition for field_length No definition for field_max_length No definition for field_flags No definition for field_decimals No definition for time_inspect No definition for time_to_s No definition for time_get_year No definition for time_get_month No definition for time_get_day No definition for time_get_hour No definition for time_get_minute No definition for time_get_second No definition for time_get_neg No definition for time_get_second_part No definition for time_set_year No definition for time_set_month No definition for time_set_day No definition for time_set_hour No definition for time_set_minute No definition for time_set_second No definition for time_set_neg No definition for time_set_second_part No definition for time_equal No definition for error_errno No definition for error_sqlstate Installing RDoc documentation for mysql-2.8.1... No definition for next_result No definition for field_name No definition for field_table No definition for field_def No definition for field_type No definition for field_length No definition for field_max_length No definition for field_flags No definition for field_decimals No definition for time_inspect No definition for time_to_s No definition for time_get_year No definition for time_get_month No definition for time_get_day No definition for time_get_hour No definition for time_get_minute No definition for time_get_second No definition for time_get_neg No definition for time_get_second_part No definition for time_set_year No definition for time_set_month No definition for time_set_day No definition for time_set_hour No definition for time_set_minute No definition for time_set_second No definition for time_set_neg No definition for time_set_second_part No definition for time_equal No definition for error_errno No definition for error_sqlstate edps@ubuntu910:~/rubygems-1.3.5$ sudo yum install rubygems パッケージリストを読み込んでいます... 完了 依存関係ツリーを作成しています 状態情報を読み取っています... 完了 以下のパッケージが新たにインストールされます: rubygems アップグレード: 0 個、新規インストール: 1 個、削除: 0 個、保留: 3 個。 2,684B のアーカイブを取得する必要があります。 この操作後に追加で 98.3kB のディスク容量が消費されます。 取得:1 http://jp.archive.ubuntu.com karmic/universe rubygems 1.3.5-1ubuntu2 [2,684B] 2,684B を 0s で取得しました (7,500B/s) 未選択パッケージ rubygems を選択しています。 (データベースを読み込んでいます ... 現在 65110 個のファイルとディレクトリがインストールされています。) (.../rubygems_1.3.5-1ubuntu2_all.deb から) rubygems を展開しています... rubygems (1.3.5-1ubuntu2) を設定しています ... edps@ubuntu910:~/rails$ sudo gem install rails -v 2.3.4 Successfully installed rails-2.3.4 1 gem installed Installing ri documentation for rails-2.3.4... Installing RDoc documentation for rails-2.3.4... edps@ubuntu910:~/rails$ rails -v Rails 2.3.4 edps@ubuntu910:~/rubygems-1.3.5$ sudo apt-get install libopenssl-ruby パッケージリストを読み込んでいます... 完了 依存関係ツリーを作成しています 状態情報を読み取っています... 完了 以下の特別パッケージがインストールされます: libopenssl-ruby1.8 以下のパッケージが新たにインストールされます: libopenssl-ruby libopenssl-ruby1.8 アップグレード: 0 個、新規インストール: 2 個、削除: 0 個、保留: 3 個。 137kB のアーカイブを取得する必要があります。 この操作後に追加で 598kB のディスク容量が消費されます。 続行しますか [Y/n]? Y 取得:1 http://jp.archive.ubuntu.com karmic/main libopenssl-ruby1.8 1.8.7.174-1 [132kB] 取得:2 http://jp.archive.ubuntu.com karmic/main libopenssl-ruby 4.2 [5,008B] 137kB を 0s で取得しました (236kB/s) 未選択パッケージ libopenssl-ruby1.8 を選択しています。 (データベースを読み込んでいます ... 現在 60906 個のファイルとディレクトリがインストールされています。) (.../libopenssl-ruby1.8_1.8.7.174-1_i386.deb から) libopenssl-ruby1.8 を展開しています... 未選択パッケージ libopenssl-ruby を選択しています。 (.../libopenssl-ruby_4.2_all.deb から) libopenssl-ruby を展開しています... libopenssl-ruby1.8 (1.8.7.174-1) を設定しています ... libopenssl-ruby (4.2) を設定しています ... edps@ubuntu910:~/rubygems-1.3.5$ edps@ubuntu910:~/rails$ rails -d mysql asagao create create app/controllers create app/helpers create app/models create app/views/layouts create config/environments create config/initializers create config/locales create db create doc create lib create lib/tasks create log create public/images create public/javascripts create public/stylesheets create script/performance create test/fixtures create test/functional create test/integration create test/performance create test/unit create vendor create vendor/plugins create tmp/sessions create tmp/sockets create tmp/cache create tmp/pids create Rakefile create README create app/controllers/application_controller.rb create app/helpers/application_helper.rb create config/database.yml create config/routes.rb create config/locales/en.yml create db/seeds.rb create config/initializers/backtrace_silencers.rb create config/initializers/inflections.rb create config/initializers/mime_types.rb create config/initializers/new_rails_defaults.rb create config/initializers/session_store.rb create config/environment.rb create config/boot.rb create config/environments/production.rb create config/environments/development.rb create config/environments/test.rb create script/about create script/console create script/dbconsole create script/destroy create script/generate create script/runner create script/server create script/plugin create script/performance/benchmarker create script/performance/profiler create test/test_helper.rb create test/performance/browsing_test.rb create public/404.html create public/422.html create public/500.html create public/index.html create public/favicon.ico create public/robots.txt create public/images/rails.png create public/javascripts/prototype.js create public/javascripts/effects.js create public/javascripts/dragdrop.js create public/javascripts/controls.js create public/javascripts/application.js create doc/README_FOR_APP create log/server.log create log/production.log create log/development.log create log/test.log edps@ubuntu910:~/rails$ ls asagao edps@ubuntu910:~/rails$ cd asagao edps@ubuntu910:~/rails/asagao$ ruby script/server => Booting WEBrick => Rails 2.3.4 application starting on http://0.0.0.0:3000 => Call with -d to detach => Ctrl-C to shutdown server [2009-11-05 14:16:08] INFO WEBrick 1.3.1 [2009-11-05 14:16:08] INFO ruby 1.8.7 (2009-06-12) [i486-linux] [2009-11-05 14:16:14] INFO WEBrick::HTTPServer#start: pid=19206 port=3000 |
[root@centos orca]# tar zxvf euca2ools-1.1-centos-i386.tar.gz euca2ools-1.1-centos-i386/ euca2ools-1.1-centos-i386/euca2ools-1.1-1.i386.rpm euca2ools-1.1-centos-i386/python25-2.5.1-bashton1.i386.rpm euca2ools-1.1-centos-i386/python25-libs-2.5.1-bashton1.i386.rpm [root@centos orca]# cd euca2ools-1.1-centos-i386 [root@centos euca2ools-1.1-centos-i386]# ls euca2ools-1.1-1.i386.rpm python25-libs-2.5.1-bashton1.i386.rpm python25-2.5.1-bashton1.i386.rpm [root@centos euca2ools-1.1-centos-i386]# rpm -Uvh euca2ools-1.1-1.i386.rpm python25-libs-2.5.1-bashton1.i386.rpm python25-2.5.1-bashton1.i386.rpm エラー: 依存性の欠如: swig は euca2ools-1.1-1.i386 に必要とされています [root@centos euca2ools-1.1-centos-i386]# yum install swig Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * base: ftp.nara.wide.ad.jp * updates: ftp.nara.wide.ad.jp * addons: ftp.nara.wide.ad.jp * extras: ftp.nara.wide.ad.jp git | 1.2 kB 00:00 primary.xml.gz | 133 kB 00:00 http://www.kernel.org/pub/software/scm/git/RPMS/i386/repodata/primary.xml.gz: [Errno -3] Error performing checksum Trying other mirror. base | 2.1 kB 00:00 updates | 1.9 kB 00:00 primary.sqlite.bz2 | 222 kB 00:00 addons | 951 B 00:00 extras | 1.1 kB 00:00 Setting up Install Process Parsing package install arguments Resolving Dependencies --> Running transaction check ---> Package swig.i386 0:1.3.29-2.el5 set to be updated --> Finished Dependency Resolution Dependencies Resolved ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: swig i386 1.3.29-2.el5 base 2.9 M Transaction Summary ================================================================================ Install 1 Package(s) Update 0 Package(s) Remove 0 Package(s) Total download size: 2.9 M Is this ok [y/N]: y Downloading Packages: swig-1.3.29-2.el5.i386.rpm | 2.9 MB 00:03 Running rpm_check_debug Running Transaction Test Finished Transaction Test Transaction Test Succeeded Running Transaction Installing : swig [1/1] Installed: swig.i386 0:1.3.29-2.el5 Complete! [root@centos euca2ools-1.1-centos-i386]# rpm -Uvh euca2ools-1.1-1.i386.rpm python25-libs-2.5.1-bashton1.i386.rpm python25-2.5.1-bashton1.i386.rpm 準備中... ########################################### [100%] 1:python25 ########################################### [ 33%] 2:python25-libs ########################################### [ 67%] 3:euca2ools ########################################### [100%] [root@centos euca2ools-1.1-centos-i386]# euca2ools-1.1は 使い道が当面はなし、次に接続用のカギを作りに行くが エラー [orca@centos bin]$ ./ec2-add-keypair ubuntu_test | sed -e "1d" > ubuntu_test.id -bash: ubuntu_test.id: 許可がありません Client.InvalidClientTokenId: The X509 Certificate you provided does not exist in our records. どうしてだろう、Amazonへ行っているのかな、EC2_URLの設定を入れていなかった。 再度 環境ファイル確認 # User specific aliases and functions export S3_URL=http://XX.XX.XX.XX:8773/services/Walrus export EC2_URL=http://XX.XX.XX.XX:8773/services/Eucalyptus export JAVA_HOME=/usr/java/jdk1.6.0_06 export CATALINA_HOME=/usr/java/apache-tomcat-5.5.28 export EC2_HOME=/home/orca/ec2-api-tools-1.3-36506 PATH=$PATH:$JAVA_HOME/bin:$EC2_HOME/bin export EUCALYPTUS_CERT=/home/orca/ec2-api-tools-1.3-36506/cloud-cert.pem export EC2_PRIVATE_KEY=/home/orca/ec2-api-tools-1.3-36506/euca2-admin--pk.pem export EC2_CERT=/home/orca/ec2-api-tools-1.3-36506/euca2-admin--cert.pem export AWS_SECRET_ACCESS_KEY='XXXXXXXXXXXXX' export AWS_ACCESS_KEY_ID='XXXXXXXXXXXXXX' export EC2_USER_ID='000XXXXXXXXX' alias ec2-bundle-image="ec2-bundle-image --cert ${EC2_CERT} --privatekey ${EC2_PRIVATE_KEY} --user 000100729354 --ec2cert ${EUCALYPTUS_CERT}" alias ec2-upload-bundle="ec2-upload-bundle -a ${EC2_ACCESS_KEY} -s ${EC2_SECRET_KEY} --url ${S3_URL} --ec2cert ${EUCALYPTUS_CERT}" 再度実行 [orca@centos ~]$ ec2-add-keypair ubuntu_test | sed -e "1d" > ubuntu_test.id 今度は成功、ubuntu_test.idが出来た。 |