1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

rails serverでエラーになる非エンジニアです。

Posted at

#サーバーが起動しない
rails serverでサーバーを起動しようとすると・・。

さっきまで何事もなく起動できたのに、読み込みが長時間続き結局エラーに。

ターミナルに表示されたのは、こちら。

=> Booting WEBrick
=> Rails 4.1.0 application starting in development on http://0.0.0.0:3000
=> Run `rails server -h` for more startup options
=> Notice: server is listening on all interfaces (0.0.0.0). Consider using 127.0.0.1 (--binding option)
=> Ctrl-C to shutdown server
Exiting
/Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/activesupport-4.1.0/lib/active_support/dependencies.rb:241:in `load': /Users/shimizutakuya/.Trash/mitakalab-twitter/config/routes.rb:9: syntax error, unexpected ..., expecting keyword_end (SyntaxError)
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/activesupport-4.1.0/lib/active_support/dependencies.rb:241:in `block in load'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/activesupport-4.1.0/lib/active_support/dependencies.rb:232:in `load_dependency'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/activesupport-4.1.0/lib/active_support/dependencies.rb:241:in `load'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/application/routes_reloader.rb:40:in `block in load_paths'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/application/routes_reloader.rb:40:in `each'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/application/routes_reloader.rb:40:in `load_paths'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/application/routes_reloader.rb:16:in `reload!'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/application/routes_reloader.rb:26:in `block in updater'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/activesupport-4.1.0/lib/active_support/file_update_checker.rb:75:in `call'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/activesupport-4.1.0/lib/active_support/file_update_checker.rb:75:in `execute'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/application/routes_reloader.rb:27:in `updater'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/application/routes_reloader.rb:7:in `execute_if_updated'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/application/finisher.rb:71:in `block in <module:Finisher>'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/initializable.rb:30:in `instance_exec'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/initializable.rb:30:in `run'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/initializable.rb:55:in `block in run_initializers'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/2.1.0/tsort.rb:226:in `block in tsort_each'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/2.1.0/tsort.rb:348:in `block (2 levels) in each_strongly_connected_component'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/2.1.0/tsort.rb:427:in `each_strongly_connected_component_from'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/2.1.0/tsort.rb:347:in `block in each_strongly_connected_component'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/2.1.0/tsort.rb:345:in `each'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/2.1.0/tsort.rb:345:in `call'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/2.1.0/tsort.rb:345:in `each_strongly_connected_component'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/2.1.0/tsort.rb:224:in `tsort_each'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/2.1.0/tsort.rb:205:in `tsort_each'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/initializable.rb:54:in `run_initializers'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/application.rb:288:in `initialize!'
	from /Users/shimizutakuya/.Trash/mitakalab-twitter/config/environment.rb:5:in `<top (required)>'
	from /Users/shimizutakuya/.Trash/mitakalab-twitter/config.ru:3:in `require'
	from /Users/shimizutakuya/.Trash/mitakalab-twitter/config.ru:3:in `block in <main>'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/rack-1.5.2/lib/rack/builder.rb:55:in `instance_eval'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/rack-1.5.2/lib/rack/builder.rb:55:in `initialize'
	from /Users/shimizutakuya/.Trash/mitakalab-twitter/config.ru:in `new'
	from /Users/shimizutakuya/.Trash/mitakalab-twitter/config.ru:in `<main>'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/rack-1.5.2/lib/rack/builder.rb:49:in `eval'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/rack-1.5.2/lib/rack/builder.rb:49:in `new_from_string'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/rack-1.5.2/lib/rack/builder.rb:40:in `parse_file'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/rack-1.5.2/lib/rack/server.rb:277:in `build_app_and_options_from_config'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/rack-1.5.2/lib/rack/server.rb:199:in `app'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/commands/server.rb:50:in `app'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/rack-1.5.2/lib/rack/server.rb:314:in `wrapped_app'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/commands/server.rb:130:in `log_to_stdout'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/commands/server.rb:67:in `start'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/commands/commands_tasks.rb:81:in `block in server'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/commands/commands_tasks.rb:76:in `tap'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/commands/commands_tasks.rb:76:in `server'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/commands/commands_tasks.rb:40:in `run_command!'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/railties-4.1.0/lib/rails/commands.rb:17:in `<top (required)>'
	from /Users/shimizutakuya/.Trash/mitakalab-twitter/bin/rails:8:in `require'
	from /Users/shimizutakuya/.Trash/mitakalab-twitter/bin/rails:8:in `<top (required)>'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/spring-1.1.3/lib/spring/client/rails.rb:27:in `load'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/spring-1.1.3/lib/spring/client/rails.rb:27:in `call'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/spring-1.1.3/lib/spring/client/command.rb:7:in `call'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/spring-1.1.3/lib/spring/client.rb:26:in `run'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/spring-1.1.3/bin/spring:48:in `<top (required)>'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/spring-1.1.3/lib/spring/binstub.rb:11:in `load'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/gems/2.1.0/gems/spring-1.1.3/lib/spring/binstub.rb:11:in `<top (required)>'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
	from /Users/shimizutakuya/.rbenv/versions/2.1.0/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
	from /Users/shimizutakuya/.Trash/mitakalab-twitter/bin/spring:16:in `<top (required)>'
	from bin/rails:3:in `load'
	from bin/rails:3:in `<main>'

#なにがいけなかったのか?
色々と調べてみたのですが、Javascriptのランタイムが無い訳でもないし、原因が分かりません。なぜこうなったのか?どうすれば起動できるようになるのか?

教えていただけますと幸いです。何卒、よろしくお願いいたします。

1
1
3

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?