title: How to fix `require': cannot load such file -- nokogiri/2.1/nokogiri (LoadError)
body: <p>I see many answers for this error when ruby version is =>2.2, but in my computer installed ruby version is [ruby 2.1.8p440]
  I get this error when starting a server ( rails server ). </p>
  
  <p>Gemfile</p>
  
  <pre><code>    source 'http://rubygems.org'
  
  
  # Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
  gem 'rails', '4.1.8'
  # Use sqlite3 as the database for Active Record
  #gem 'sqlite3'
  gem 'pg', '0.18.2'
  # Use SCSS for stylesheets
  #gem 'sass-rails', '~&gt; 4.0.3'
  
  gem 'rails_12factor', group: :production
  
  
  # Use Uglifier as compressor for JavaScript assets
  gem 'uglifier', '&gt;= 1.3.0'
  # Use CoffeeScript for .js.coffee assets and views
  gem 'coffee-rails', '~&gt; 4.0.0'
  # See https://github.com/sstephenson/execjs#readme for more supported runtimes
  # gem 'therubyracer',  platforms: :ruby
  
  # Use jquery as the JavaScript library
  gem 'jquery-rails'
  # Turbolinks makes following links in your web application faster. Read more: https://github.com/rails/turbolinks
  gem 'turbolinks'
  # Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
  gem 'jbuilder', '~&gt; 2.0'
  # bundle exec rake doc:rails generates the API under doc/api.
  gem 'sdoc', '~&gt; 0.4.0',          group: :doc
  
  # Use ActiveModel has_secure_password
  gem 'bcrypt', '~&gt; 3.1.7'
  
  # Use unicorn as the app server
  # gem 'unicorn'
  
  # Use Capistrano for deployment
  # gem 'capistrano-rails', group: :development
  
  # Use debugger
  # gem 'debugger', group: [:development, :test]
  gem 'sass-rails', '&gt;= 3.3.4'
  gem 'bootstrap-sass', '~&gt; 3.3.6'
  
  gem 'ckeditor', '4.1.6'
  gem 'carrierwave', '0.10.0'
  gem 'fog', '~&gt; 1.3.1'
  gem 'mini_magick', '4.5.1'
  gem 'will_paginate', '3.1.0'
  gem 'nokogiri', '&gt;= 1.5.0'
  
  
  # Windows does not include zoneinfo files, so bundle the tzinfo-data gem
  gem 'tzinfo-data', platforms: [:mingw, :mswin]
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/DYN8a.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/DYN8a.png" alt="Error when starting server"></a></p>