[openstreetmap/openstreetmap-website] Could not open library 'libarchive.so.13': libarchive.so.13: cannot open shared object file: No such file or directory. (#2343)

YuriiNskyi notifications at github.com
Wed Aug 7 14:58:18 UTC 2019


I'm trying to run my own `openstreetmap-website` on `Ubuntu 18.04 LTS` system.

Here are the commands to reproduce an issue:

```
sudo apt-get update
sudo apt-get -y install git
sudo apt-get -y install virtualbox
sudo apt-get -y install vagrant
git clone  https://github.com/openstreetmap/openstreetmap-website.git
cd openstreetmap-website/
vagrant up
```

A problem with `example.application.yml` file occurs here - it is required while it is not provided.
This is OK and file from [here](https://github.com/SEL-Columbia/osm-devops/blob/master/example.application.yml) is perfectly valid.

Let's again try `vagrant up`.
Here's the new error:

```
 default: /srv/openstreetmap-website /home/vagrant
    default: rake aborted!
    default: Gem::LoadError: You have already activated rake 12.3.3, but your Gemfile requires rake 12.3.2. Prepending `bundle exec` to your command may solve this.
    default: /var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/runtime.rb:313:in `check_for_activated_spec!'
    default: /var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/runtime.rb:31:in `block in setup'
    default: /var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/runtime.rb:26:in `map'
    default: /var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/runtime.rb:26:in `setup'
    default: /var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler.rb:107:in `setup'
    default: /var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/setup.rb:20:in `<top (required)>'
    default: /srv/openstreetmap-website/config/boot.rb:3:in `<top (required)>'
    default: /srv/openstreetmap-website/config/application.rb:1:in `require_relative'
    default: /srv/openstreetmap-website/config/application.rb:1:in `<top (required)>'
    default: /srv/openstreetmap-website/Rakefile:4:in `require_relative'
    default: /srv/openstreetmap-website/Rakefile:4:in `<top (required)>'
    default: /var/lib/gems/2.5.0/gems/rake-12.3.3/exe/rake:27:in `<top (required)>'
    default: 
    default: Caused by:
    default: LoadError: cannot load such file -- bundler/setup
    default: /srv/openstreetmap-website/config/boot.rb:3:in `<top (required)>'
    default: /srv/openstreetmap-website/config/application.rb:1:in `require_relative'
    default: /srv/openstreetmap-website/config/application.rb:1:in `<top (required)>'
    default: /srv/openstreetmap-website/Rakefile:4:in `require_relative'
    default: /srv/openstreetmap-website/Rakefile:4:in `<top (required)>'
    default: /var/lib/gems/2.5.0/gems/rake-12.3.3/exe/rake:27:in `<top (required)>'
    default: (See full trace by running task with --trace)
```

I did nothing to activate rake 12.3.3 previously and I don't even bother what is it, but it is OK, we can successfully enter Vagrant virtual machine with the help of `vagrant ssh` command.


Finally, we are executing `bundler exec rails server` using SSH and get the following error:

```
Traceback (most recent call last):
	52: from bin/rails:4:in `<main>'
	51: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'
	50: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'
	49: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `block in require'
	48: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	47: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require_with_bootsnap_lfi'
	46: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
	45: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `block in require_with_bootsnap_lfi'
	44: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require'
	43: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/railties-5.2.3/lib/rails/commands.rb:18:in `<top (required)>'
	42: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/railties-5.2.3/lib/rails/command.rb:46:in `invoke'
	41: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/railties-5.2.3/lib/rails/command/base.rb:65:in `perform'
	40: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/thor-0.20.3/lib/thor.rb:387:in `dispatch'
	39: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/thor-0.20.3/lib/thor/invocation.rb:126:in `invoke_command'
	38: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/thor-0.20.3/lib/thor/command.rb:27:in `run'
	37: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/railties-5.2.3/lib/rails/commands/server/server_command.rb:142:in `perform'
	36: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/railties-5.2.3/lib/rails/commands/server/server_command.rb:142:in `tap'
	35: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/railties-5.2.3/lib/rails/commands/server/server_command.rb:145:in `block in perform'
	34: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'
	33: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'
	32: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `block in require'
	31: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	30: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require_with_bootsnap_lfi'
	29: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
	28: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `block in require_with_bootsnap_lfi'
	27: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require'
	26: from /srv/openstreetmap-website/config/application.rb:19:in `<top (required)>'
	25: from /var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler.rb:114:in `require'
	24: from /var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/runtime.rb:65:in `require'
	23: from /var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/runtime.rb:65:in `each'
	22: from /var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/runtime.rb:76:in `block in require'
	21: from /var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/runtime.rb:76:in `each'
	20: from /var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/runtime.rb:81:in `block (2 levels) in require'
	19: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	18: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require_with_bootsnap_lfi'
	17: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
	16: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `block in require_with_bootsnap_lfi'
	15: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require'
	14: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/ffi-libarchive-0.4.10/lib/ffi-libarchive.rb:55:in `<top (required)>'
	13: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `require'
	12: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:257:in `load_dependency'
	11: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/activesupport-5.2.3/lib/active_support/dependencies.rb:291:in `block in require'
	10: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	 9: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require_with_bootsnap_lfi'
	 8: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
	 7: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `block in require_with_bootsnap_lfi'
	 6: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/bootsnap-1.4.4/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require'
	 5: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/ffi-libarchive-0.4.10/lib/ffi-libarchive/archive.rb:3:in `<top (required)>'
	 4: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/ffi-libarchive-0.4.10/lib/ffi-libarchive/archive.rb:4:in `<module:Archive>'
	 3: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/ffi-libarchive-0.4.10/lib/ffi-libarchive/archive.rb:11:in `<module:C>'
	 2: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/ffi-1.11.1/lib/ffi/library.rb:99:in `ffi_lib'
	 1: from /srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/ffi-1.11.1/lib/ffi/library.rb:99:in `map'
/srv/openstreetmap-website/vendor/cache/ruby/2.5.0/gems/ffi-1.11.1/lib/ffi/library.rb:145:in `block in ffi_lib': Could not open library 'libarchive.so.13': libarchive.so.13: cannot open shared object file: No such file or directory. (LoadError)
Could not open library 'libarchive.13': libarchive.13: cannot open shared object file: No such file or directory.
Could not open library 'libarchive.13.so': libarchive.13.so: cannot open shared object file: No such file or directory.
Could not open library 'libarchive-13': libarchive-13: cannot open shared object file: No such file or directory.
Could not open library 'libarchive-13.so': libarchive-13.so: cannot open shared object file: No such file or directory.
Could not open library 'libarchive.so': libarchive.so: cannot open shared object file: No such file or directory.
Could not open library 'libarchive': libarchive: cannot open shared object file: No such file or directory.
Could not open library 'archive': archive: cannot open shared object file: No such file or directory
```

I have only two questions.

1. Why it is so hard to simply run my own `openstreetmap-website` ?
2. How can I solve this error?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/issues/2343
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20190807/a4a99427/attachment.html>


More information about the rails-dev mailing list