8000 CentOS 6.5でインストールが失敗する · Issue #165 · alminium/alminium · GitHub
[go: up one dir, main page]

Skip to content
< 10000 link rel="modulepreload" href="https://github.githubassets.com/assets/hz-58a3150c6d7d55cc.js" crossorigin="anonymous" />

CentOS 6.5でインストールが失敗する #165

Open

Description

@huideyeren

CentOS6.5(ConoHa標準のディスクイメージ)でインストールに失敗します。
どうも、mysqlやRuby周りでインストールに失敗しているようです。
なお、Jenkinsは入れる方向で、MailはGMailで設定しています。
(ただし、アカウントに2段階認証がかかっています)

お手数ですが、エラー原因の解析お願いできますか?

Activity

  1. tkmtmkt commented on Feb 8, 2015

    @tkmtmkt

    まずは、以下のようにインストール実行して、インストール時のログ出力をファイルに残します。

    sudo ./smelt 2>&1 | tee smelt.log
    

    ログ出力ファイルからエラー関連のメッセージを抽出して、内容を確認します。

    grep -Hne '\(error\|fail\|not\)' smelt.log
    

    メッセージ量を絞り込めば、自分でも内容が分かって対処できるものがあると思いますが、分からないものがあれば、そこで初めて人に質問すればよいです。 
    メッセージを示して、これはどういう意味か教えてほしいという形で質問しないと、誰も何も回答できないです。

    【エラーメッセージ例】
    Ubuntu 14.04でmasterブランチを取得してインストールすると、以下のようなエラーが記録されます。

    smelt.log:1159:An error occurred while installing rmagick (2.13.4), and Bundler cannot continue.
    
  2. huideyeren commented on Feb 8, 2015

    @huideyeren
    Author

    失礼いたしました。
    ひとまず、

    grep -Hne '\(error\|fail\|not\)' smelt.log

    を実行したところ、以下のようなエラーログになりました。

    smelt.log:223:--> Processing Dependency: libgpg-error-devel for package: libgcrypt-devel-1.4.5-11.el6_4.x86_64
    smelt.log:308:---> Package libgpg-error-devel.x86_64 0:1.7-4.el6 will be installed
    smelt.log:441:            dependency that another package requires. Yum is trying to
    smelt.log:446:            --exclude libyaml.otherarch ... this should give you an error
    smelt.log:456:            You can use "yum check" to get yum show these errors.
    smelt.log:583:      Error: Cannot find the `curl-config` command.
    smelt.log:611:Some required software is not installed.
    smelt.log:744:An error occurred while installing i18n (0.7.0), and Bundler cannot continue.
    smelt.log:746:/usr/lib/ruby/gems/1.8/gems/bundler-1.7.12/lib/bundler/resolver.rb:368:in `resolve': Could not find gem 'rails (= 3.2.19) ruby' in the gems available on this machine. (Bundler::GemNotFound)
    smelt.log:757:/usr/lib/ruby/gems/1.8/gems/bundler-1.7.12/lib/bundler/resolver.rb:368:in `resolve': Could not find gem 'rails (= 3.2.19) ruby' in the gems available on this machine. (Bundler::GemNotFound)
    smelt.log:768:/usr/lib/ruby/gems/1.8/gems/bundler-1.7.12/lib/bundler/resolver.rb:368:in `resolve': Could not find gem 'rails (= 3.2.19) ruby' in the gems available on this machine. (Bundler::GemNotFound)
    smelt.log:785:state without impacting any branches by performing another checkout.
    smelt.log:809:cp: cannot stat `cache/redmine_code_review': そのようなファイルやディレクトリはありません
    smelt.log:813:cp: cannot stat `cache/redmine_hudson': そのようなファイルやディレクトリはありません
    smelt.log:820:error: pathspec 'master' did not match any file(s) known to git.
    smelt.log:838:mv: cannot stat `plugins/redmine_hudson/Gemfile': そのようなファイルやディレクトリはありません
    smelt.log:848:An error occurred while installing i18n (0.7.0), and Bundler cannot continue.
    smelt.log:850:/usr/lib/ruby/gems/1.8/gems/bundler-1.7.12/lib/bundler/resolver.rb:368:in `resolve': Could not find gem 'rails (= 3.2.19) ruby' in the gems available on this machine. (Bundler::GemNotFound)
    smelt.log:861:/usr/lib/ruby/gems/1.8/gems/bundler-1.7.12/lib/bundler/resolver.rb:368:in `resolve': Could not find gem 'rails (= 3.2.19) ruby' in the gems available on this machine. (Bundler::GemNotFound)
    smelt.log:872:/usr/lib/ruby/gems/1.8/gems/bundler-1.7.12/lib/bundler/resolver.rb:368:in `resolve': Could not find gem 'rails (= 3.2.19) ruby' in the gems available on this machine. (Bundler::GemNotFound)
    smelt.log:883:/usr/lib/ruby/gems/1.8/gems/bundler-1.7.12/lib/bundler/resolver.rb:368:in `resolve': Could not find gem 'rails (= 3.2.19) ruby' in the gems available on this machine. (Bundler::GemNotFound)
    smelt.log:894:/usr/lib/ruby/gems/1.8/gems/bundler-1.7.12/lib/bundler/resolver.rb:368:in `resolve': Could not find gem 'rails (= 3.2.19) ruby' in the gems available on this machine. (Bundler::GemNotFound)
    smelt.log:905:/usr/lib/ruby/gems/1.8/gems/bundler-1.7.12/lib/bundler/resolver.rb:368:in `resolve': Could not find gem 'rails (= 3.2.19) ruby' in the gems available on this machine. (Bundler::GemNotFound)
    smelt.log:916:/usr/lib/ruby/gems/1.8/gems/bundler-1.7.12/lib/bundler/resolver.rb:368:in `resolve': Could not find gem 'rails (= 3.2.19) ruby' in the gems available on this machine. (Bundler::GemNotFound)
    smelt.log:931:cp: cannot copy a directory, `etc/opt', into itself, `/etc/opt/alminium/opt'
    smelt.log:932:cp: cannot stat `hooks': そのようなファイルやディレクトリはありません
    

    なお、「見つかりません」、「ありません」でgrepかけても以下のようなエラーが出ていました。

    smelt.log:15:SSLの証明書は認証機関により署名されたものではありません。通信の暗号化のみ
    smelt.log:528:サービス mysqld に関する情報の読み込み中にエラーが発生しました: そのようなファイルやディレクトリはありません
    smelt.log:529:サービス mysqld に関する情報の読み込み中にエラーが発生しました: そのようなファイルやディレクトリはありません
    smelt.log:645:./smelt: line 212: /etc/init.d/mysqld: そのようなファイルやディレクトリはありません
    smelt.log:646:./smelt: line 223: mysql: コマンドが見つかりません
    smelt.log:806:inst-script/redmine-plugins: line 57: hg: コマンドが見つかりません
    smelt.log:807:inst-script/redmine-plugins: line 58: cd: cache/redmine_code_review: そのようなファイルやディレクトリはありません
    smelt.log:808:inst-script/redmine-plugins: line 59: hg: コマンドが見つかりません
    smelt.log:809:cp: cannot stat `cache/redmine_code_review': そのようなファイルやディレクトリはありません
    smelt.log:810:inst-script/redmine-plugins: line 57: hg: コマンドが見つかりません
    smelt.log:811:inst-script/redmine-plugins: line 58: cd: cache/redmine_hudson: そのようなファイルやディレクトリはありません
    smelt.log:812:inst-script/redmine-plugins: line 59: hg: コマンドが見つかりません
    smelt.log:813:cp: cannot stat `cache/redmine_hudson': そのようなファイルやディレクトリはありません
    smelt.log:838:mv: cannot stat `plugins/redmine_hudson/Gemfile': そのようなファイルやディレクトリはありません
    smelt.log:927:cp: ディレクトリ `public/plugin_assets/open_flash_chart' を作成できません: そのようなファイルやディレクトリはありません
    smelt.log:930:./smelt: line 284: config/init.mysql: そのようなファイルやディレクトリはありません
    smelt.log:932:cp: cannot stat `hooks': そのようなファイルやディレクトリはありません
    smelt.log:933:./smelt: line 301: inst-script/gen-email-config.sh: そのようなファイルやディレクトリはありません
    smelt.log:934:./smelt: line 306: inst-script/rhel6/jenkins-install: そのようなファイルやディレクトリはありません
    smelt.log:935:./smelt: line 309: inst-script/rhel6/post-install: そのようなファイルやディレクトリはありません
    

    MySQL関連でも以下のようなメッセージが残ります。

    smelt.log:138:---> Package mod_auth_mysql.x86_64 1:3.0.0-11.el6_0.1 will be installed
    smelt.log:143:---> Package mysql.x86_64 0:5.1.73-3.el6_5 will be installed
    smelt.log:144:---> Package mysql-devel.x86_64 0:5.1.73-3.el6_5 will be installed
    smelt.log:145:---> Package mysql-server.x86_64 0:5.1.73-3.el6_5 will be installed
    smelt.log:146:--> Processing Dependency: perl-DBI for package: mysql-server-5.1.73-3.el6_5.x86_64
    smelt.log:147:--> Processing Dependency: perl-DBD-MySQL for package: mysql-server-5.1.73-3.el6_5.x86_64
    smelt.log:148:--> Processing Dependency: perl(DBI) for package: mysql-server-5.1.73-3.el6_5.x86_64
    smelt.log:528:サービス mysqld に関する情報の読み込み中にエラーが発生しました: そのようなファイルやディレクトリはありません
    smelt.log:529:サービス mysqld に関する情報の読み込み中にエラーが発生しました: そのようなファイルやディレクトリはありません
    smelt.log:530:mysqld: 認識されていないサービスです。
    smelt.log:645:./smelt: line 212: /etc/init.d/mysqld: そのようなファイルやディレクトリはありません
    smelt.log:646:./smelt: line 223: mysql: コマンドが見つかりません
    smelt.log:930:./smelt: line 284: config/init.mysql: そのようなファイルやディレクトリはありません
    

    ちなみに、インストール環境は以下のとおりです。
    VPS : ConoHa
    OS : CentOS 6.5 (ConoHa Default)
    メモリ : 4GB
    パーティション : 20GB + 380GB

    ご教授いただければ幸いです。

  3. tkmtmkt commented on Feb 8, 2015

    @tkmtmkt

    インストールの最初の方でOSのパッケージのインストールがうまくいっていないようです。

    smelt.log:441:            dependency that another package requires. Yum is trying to
    smelt.log:446:            --exclude libyaml.otherarch ... this should give you an error
    smelt.log:456:            You can use "yum check" to get yum show these errors.
    smelt.log:583:      Error: Cannot find the `curl-config` command.
    smelt.log:611:Some required software is not installed.
    

    以下のコマンドの結果はどのようになっているでしょうか?

    yum repolist
    yum info curl
    

    ちなみに、こちらの環境(skaura/CentOS 6.6)では以下のようになっています。

    $ yum repolist
    リポジトリー ID                          リポジトリー名                                                           状態
    base                                     CentOS-6 - Base                                                           6,518
    epel                                     Extra Packages for Enterprise Linux 6 - x86_64                           11,148
    extras                                   CentOS-6 - Extras                                                            36
    jenkins                                  Jenkins                                                                     271
    rpmforge                                 RHEL 6 - RPMforge.net - dag                                               4,718
    updates                                  CentOS-6 - Updates                                                          727
    repolist: 23,418
    $ yum list -q curl
    インストール済みパッケージ
    curl.x86_64                                          7.19.7-40.el6_6.4                                          @updates
    

    以下のログを見ると、rubyのバージョンが1.8となっているようですが、正常にインストールが進んでいればrubyのバージョンは2.1になっているはずです。

    smelt.log:746:/usr/lib/ruby/gems/1.8/gems/bundler-1.7.12/lib/bundler/resolver.rb:368:in `resolve': Could not find gem 'rails (= 3.2.19) ruby' in the gems available on this machine. (Bundler::GemNotFound)
    

    ログに以下のようなruby2.1.2のインストール処理の記録があるかどうか確認してみてください。
    「Starting mysqld」と「Submodule 'theme/gitmike'」の間にあるはずです。

    Starting mysqld:                                           [  OK  ]
    which: no ruby in (/sbin:/bin:/usr/sbin:/usr/bin)
    https://github.com/hansode/ruby-rpm/blob/master/6/x86_64/ruby-2.1.2-2.el6.x86_64.rpm?raw=true を取得中
    準備中...                ##################################################
    ruby                        ##################################################
    Submodule 'theme/gitmike' (https://github.com/makotokw/redmine-theme-gitmike) registered for path 'theme/gitmike'
    Submodule 'theme/railsgun' (https://github.com/alminium/redmine_railsgun_theme) registered for path 'theme/railsgun'
    

    【おまけ】
    ログファイルを閲覧する場合、エスケープシーケンスが見辛いので less -r smelt.log を使うと見やすいです。
    あと、エラー関連のログの検索はこちらのほうが良かったです。

    grep -Hine '\(error\|fail\|warn\|could not\)' smelt.log
    
  4. huideyeren commented on Feb 8, 2015

    @huideyeren
    Author

    ご指示の通り、yum repolistを実行してみました。
    rpmforgeやJenkinsの関連パッケージがインストールされていないようです。

    # yum repolist
    
    Loaded plugins: fastestmirror, security
    Loading mirror speeds from cached hostfile
    epel/metalink                                            | 6.1 kB     00:00     
     * base: ftp.tsukuba.wide.ad.jp
     * epel: ftp.kddilabs.jp
     * extras: ftp.tsukuba.wide.ad.jp
     * updates: ftp.tsukuba.wide.ad.jp
    base                                                     | 3.7 kB     00:00     
    cr                                                       | 3.3 kB     00:00     
    epel                                                     | 4.4 kB     00:00     
    extras                                                   | 3.4 kB     00:00     
    updates                                                  | 3.4 kB     00:00     
    repo id          repo name                                                status
    base             CentOS-6 - Base                                           6,518
    cr               CentOS-6 - CR                                                 0
    *epel            Extra Packages for Enterprise Linux 6 - x86_64           11,148
    extras           CentOS-6 - Extras                                            36
    updates          CentOS-6 - Updates                                          727
    repolist: 18,429
    

    ちなみに、curlのパッケージ情報は以下のとおりです。

    # yum info curl
    Loaded plugins: fastestmirror, security
    Loading mirror speeds from cached hostfile
     * base: ftp.tsukuba.wide.ad.jp
     * epel: ftp.kddilabs.jp
     * extras: ftp.tsukuba.wide.ad.jp
     * updates: ftp.tsukuba.wide.ad.jp
    Installed Packages
    Name        : curl
    Arch        : x86_64
    Version     : 7.19.7
    Release     : 37.el6_4
    Size        : 347 k
    Repo        : installed
    From repo   : anaconda-CentOS-201311272149.x86_64
    Summary     : A utility for getting files from remote servers (FTP, HTTP, and
                : others)
    URL         : http://curl.haxx.se/
    License     : MIT
    Description : cURL is a tool for getting files from HTTP, FTP, FILE, LDAP,
                : LDAPS, DICT, TELNET and TFTP servers, using any of the supported
                : protocols. cURL is designed to work without user interaction or
                : any kind of interactivity. cURL offers many useful capabilities,
                : like proxy support, user authentication, FTP upload, HTTP post,
                : and file transfer resume.
    
    Available Packages
    Name        : curl
    Arch        : x86_64
    Version     : 7.19.7
    Release     : 40.el6_6.4
    Size        : 194 k
    Repo        : updates
    Summary     : A utility for getting files from remote servers (FTP, HTTP, and
                : others)
    URL         : http://curl.haxx.se/
    License     : MIT
    Description : cURL is a tool for getting files from HTTP, FTP, FILE, LDAP,
                : LDAPS, DICT, TELNET and TFTP servers, using any of the supported
                : protocols. cURL is designed to work without user interaction or
                : any kind of interactivity. cURL offers many useful capabilities,
                : like proxy support, user authentication, FTP upload, HTTP post,
                : and file transfer resume.
    

    Rubyのインストール情報も以下のとおりです。
    ご指摘の通り、1.8.7からバージョンが上がっていません。

    # yum info ruby
    Loaded plugins: fastestmirror, security
    Loading mirror speeds from cached hostfile
     * base: ftp.tsukuba.wide.ad.jp
     * epel: ftp.kddilabs.jp
     * extras: ftp.tsukuba.wide.ad.jp
     * updates: ftp.tsukuba.wide.ad.jp
    Installed Packages
    Name        : ruby
    Arch        : x86_64
    Version     : 1.8.7.352
    Release     : 13.el6
    Size        : 1.8 M
    Repo        : installed
    From repo   : updates
    Summary     : An interpreter of object-oriented scripting language
    URL         : http://www.ruby-lang.org/
    License     : Ruby or GPLv2
    Description : Ruby is the interpreted scripting language for quick and easy
                : object-oriented programming.  It has many features to process text
                : files and to do system management tasks (as in Perl).  It is
                : simple, straight-forward, and extensible.
    
    Available Packages
    Name        : ruby
    Arch        : x86_64
    Version     : 1.8.7.374
    Release     : 3.el6_6
    Size        : 538 k
    Repo        : updates
    Summary     : An interpreter of object-oriented scripting language
    URL         : http://www.ruby-lang.org/
    License     : Ruby or GPLv2
    Description : Ruby is the interpreted scripting language for quick and easy
                : object-oriented programming.  It has many features to process text
                : files and to do system management tasks (as in Perl).  It is
                : simple, straight-forward, and extensible.
    

    以上、ご報告までに。

  5. tkmtmkt commented on Feb 9, 2015

    @tkmtmkt

    正常にインストールできた場合のログでmysql を検索すると以下のようになりますが、そちらの検索結果を見るとインストールするパッケージのリストがないので、依存関係のチェックまでで止まってパッケージが何もインストールされていないものと考えられます。

    試しに sudo yum install mercurial を実行して、パッケージインストール可能かどうか確認してみてください。smeltの実行でインストールしているはずのものですが、インストールできていないようです。(ログに「hg: コマンドが見つかりません」が出力されている)

    エラーの検索を grep -Hine '\(error\|fail\|warn\|could not\)' smelt.log で行ってみてください。
    最初に貼り付けたコマンドラインは -i のオプションが抜けていたので、小文字のerrorだけしか検出せず、「Error」や「ERROR」を拾えていないです。(コピペミスしていました・・・)

    $ grep -Hine mysql smelt_20140731.log
    
    ≪依存関係のチェック≫
    smelt_20140731.log:134:---> Package mod_auth_mysql.x86_64 1:3.0.0-11.el6_0.1 will be installed
    smelt_20140731.log:140:---> Package mysql.x86_64 0:5.1.73-3.el6_5 will be installed
    smelt_20140731.log:141:---> Package mysql-devel.x86_64 0:5.1.73-3.el6_5 will be installed
    smelt_20140731.log:142:---> Package mysql-server.x86_64 0:5.1.73-3.el6_5 will be installed
    smelt_20140731.log:143:--> Processing Dependency: perl-DBD-MySQL for package: mysql-server-5.1.73-3.el6_5.x86_64
    smelt_20140731.log:205:---> Package perl-DBD-MySQL.x86_64 0:4.013-3.el6 will be installed
    ≪インストールするパッケージのリスト≫
    smelt_20140731.log:277: mod_auth_mysql             x86_64    1:3.0.0-11.el6_0.1       base        24 k
    smelt_20140731.log:281: mysql                      x86_64    5.1.73-3.el6_5           updates    894 k
    smelt_20140731.log:282: mysql-devel                x86_64    5.1.73-3.el6_5           updates    129 k
    smelt_20140731.log:283: mysql-server               x86_64    5.1.73-3.el6_5           updates    8.6 M
    smelt_20140731.log:345: perl-DBD-MySQL             x86_64    4.013-3.el6              base       134 k
    ≪パッケージのインストール≫
      Installing : mysql-5.1.73-3.el6_5.x86_64                                 7/91
      Installing : perl-DBD-MySQL-4.013-3.el6.x86_64                          39/91
      Installing : 1:mod_auth_mysql-3.0.0-11.el6_0.1.x86_64                   72/91
      Installing : mysql-devel-5.1.73-3.el6_5.x86_64                          77/91
      Installing : mysql-server-5.1.73-3.el6_5.x86_64                         80/91
    ≪インストール結果の検証≫
      Verifying  : 1:mod_auth_mysql-3.0.0-11.el6_0.1.x86_64                    8/91
      Verifying  : perl-DBD-MySQL-4.013-3.el6.x86_64                          47/91
      Verifying  : mysql-5.1.73-3.el6_5.x86_64                                49/91
      Verifying  : mysql-devel-5.1.73-3.el6_5.x86_64                          55/91
      Verifying  : mysql-server-5.1.73-3.el6_5.x86_64                         59/91
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      0