3
votes

I am newbie trying to learn some code. I am following the tutorial on http://guides.rubyonrails.org/getting_started.html

I am up to the point where I've gotten the welcome aboard message at localhost:3000, the last command I typed into my OSX terminal was "rails server"

The server spit out some info and at the end I got this...

Started GET "/assets/rails.png" for 127.0.0.1 at Fri Jan 27 12:44:36 -0500 2012 Served asset /rails.png - 304 Not Modified (2ms)

Started GET "/assets/rails.png" for 127.0.0.1 at Fri Jan 27 12:48:29 -0500 2012 Served asset /rails.png - 304 Not Modified (0ms)

Now the terminal prompt is not coming up...not sure how to fix or what I should do? Thanks to anyone who can help!

2
304 Not Modified is a good thing... usually. I don't think it's the source of your problem.Ry-
That normal, the server is running, you won't have command prompt until you stop the server...Baldrick

2 Answers

3
votes

When you type in rails server (or rails s for short) the server starts running in that terminal window. This is a good thing. It means that there was no critical error at start up and rails will proceed by showing you a log of what's happening in your app - what resources it's serving, how long does it take, what views is it rendering, what database queries is it running, etc.

To proceed you can either kill the server by pressing control-C or simply open up a new terminal tab by pressing command-T and work from there and you can always switch to the first tab to look at the log if needed. With rails you usually don't need to restart the server so you can usually just keep it running in a tab in your terminal (an exception to that is when editing stuff in config or your Gemfile).

3
votes

The server runs until you end it by typing Control+C. What it does is turns your computer in to a web server, and allows you to look at your website by going to http://localhost:3000 (by default this is the webport). There is nothing wrong with your computer or program. The server will show you a log of what it's doing while you navigate your website.

The 304 Not Modified is just telling you that when it went to fetch something, it knows it's done it before and the file was not modified. This is usually true of static assets, like images.