# Problem with starting Rails. Please help

**URL:** <https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839>\
**Category:** Rails\
**Created:** [June 28, 2011, 1:27pm UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839 "2011-06-28T13:27:18Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![luislavena](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/l/0ea827/32.png) [@luislavena](https://www.ruby-forum.com/u/luislavena)\
**Post date:** [June 28, 2011, 1:27pm UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/1 "2011-06-28T13:27:18Z")

</div>

Dear All:

I am new to Rails. This is my first day of using Rails.I have already  
installed Ruby and Rails on my computer.  
But in new application- script folder ‘server’ script is not getting  
created.  
In short I am not able to run- ruby script/server.  
Please help me or suggest another way to set up Rails on Windows.

I am using Windows XP.  
Thanks in advance.

---

<div class="post-metadata">

**Author:** ![amitbiradar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a87d85/32.png) [@amitbiradar](https://www.ruby-forum.com/u/amitbiradar)\
**Post date:** [June 28, 2011, 1:59pm UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/2 "2011-06-28T13:59:41Z")

</div>

If you have Rails 3 you say ‘rails s’ (from your Rails root) or if rails  
is not in your %PATH% ‘ruby script/rails server’.

---

<div class="post-metadata">

**Author:** ![amitbiradar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a87d85/32.png) [@amitbiradar](https://www.ruby-forum.com/u/amitbiradar)\
**Post date:** [June 28, 2011, 2:39pm UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/3 "2011-06-28T14:39:46Z")

</div>

You didn’t specify which Rails version you are using.  
Looks like you are on Rails 3, in that case, on of the following two  
should  
work:  
rails server (shorthand is rails s)  
or  
ruby script/rails server

You may also want to read up Rails guides, which is very good if you are  
a  
beginner and will address these basic issues -

> **[Getting Started with Rails — Ruby on Rails Guides](https://guides.rubyonrails.org/getting_started.html)**
>
> Getting Started with RailsThis guide covers getting up and running with Ruby on Rails.After reading this guide, you will know: How to install Rails, create a new Rails application, and connect your application to a database. The general layout of a...

---

<div class="post-metadata">

**Author:** ![amitbiradar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a87d85/32.png) [@amitbiradar](https://www.ruby-forum.com/u/amitbiradar)\
**Post date:** [June 29, 2011, 7:29am UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/4 "2011-06-29T07:29:04Z")

</div>

Thanks for your prompt replies. I am using Rails 3.0.9 version. I used  
‘ruby  
script/rails server’ command.  
But I am getting following error pop-up while running this command.

The procedure entry point sqlite3\_column\_database\_name could not be  
located  
in the dynamic link library sqlite3.dll

Please suggest some solution.

Thanks,  
Amit

On Tue, Jun 28, 2011 at 6:08 PM, Chirag S.  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)wrote:

> [http://groups.google.com/group/rubyonrails-talk?hl=en](http://groups.google.com/group/rubyonrails-talk?hl=en).

–  
Thanks and Regards,  
Amit

---

<div class="post-metadata">

**Author:** ![amitbiradar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a87d85/32.png) [@amitbiradar](https://www.ruby-forum.com/u/amitbiradar)\
**Post date:** [June 29, 2011, 7:40am UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/5 "2011-06-29T07:40:12Z")

</div>

Make sure that you have sqlite3 installed on your machine and sqlite3  
gem is  
also installed.  
If you don’t have sqlite3 installed on windows, then you can grab  
sqlite3.dll from here [SQLite Download Page](http://www.sqlite.org/download.html) and copy it to  
either your ruby bin directory or windows’ system32 directory. Open up a  
new  
console and run the server again.

As an aside, I have found that RailsInstaller works pretty well for all  
this  
default setup on windows. You may want to try it out -

> **[Install Ruby on Rails – Railsinstaller.org -](https://hotframeworks.com/railsinstaller-org/)**
>
> Hi everyone, in an effort to retain the information of railsinstaller.org we have decided to merge it with hotframeworks.com, this resource will always be live for everyone who needs it. Thanks to the team at Hot Frame Works for all their...

–  
Chirag  
[http://sumeruonrails.com](http://sumeruonrails.com)

---

<div class="post-metadata">

**Author:** ![amitbiradar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a87d85/32.png) [@amitbiradar](https://www.ruby-forum.com/u/amitbiradar)\
**Post date:** [June 29, 2011, 8:03am UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/6 "2011-06-29T08:03:41Z")

</div>

Thank you very much Chirag. It worked. Could you please tell me how to  
replace SQLite with MySQL?

On Wed, Jun 29, 2011 at 11:08 AM, Chirag S.  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)wrote:

> > But I am getting following error pop-up while running this command.
> > 
> > > wrote:  
> > > [Getting Started with Rails — Ruby on Rails Guides](http://guides.rubyonrails.org/getting_started.html)  
> > > For more options, visit this group at  
> > > You received this message because you are subscribed to the Google G.  
> > > –  
> > > You received this message because you are subscribed to the Google G.  
> > > “Ruby on Rails: Talk” group.  
> > > To post to this group, send email to [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > > To unsubscribe from this group, send email to  
> > > [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > > For more options, visit this group at  
> > > [http://groups.google.com/group/rubyonrails-talk?hl=en](http://groups.google.com/group/rubyonrails-talk?hl=en).

–  
Thanks and Regards,  
Amit

---

<div class="post-metadata">

**Author:** ![amitbiradar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a87d85/32.png) [@amitbiradar](https://www.ruby-forum.com/u/amitbiradar)\
**Post date:** [June 29, 2011, 8:24am UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/7 "2011-06-29T08:24:02Z")

</div>

Two ways:

1. You can specify that while creating your project - rails new myapp -d  
mysql
2. Manually modify your database.yml file to use mysql and update your  
Gemfile to use mysql gem

sample config for database.yml, you will need similar entries for  
production  
and test databases

development:  
adapter: mysql  
encoding: utf8  
reconnect: false  
database: myapp\_development  
pool: 5  
username: root  
password: password  
host: localhost

in your Gemfile, add:

gem ‘mysql’

–  
Chirag  
[http://sumeruonrails.com](http://sumeruonrails.com)

---

<div class="post-metadata">

**Author:** ![amitbiradar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a87d85/32.png) [@amitbiradar](https://www.ruby-forum.com/u/amitbiradar)\
**Post date:** [June 29, 2011, 8:39am UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/8 "2011-06-29T08:39:29Z")

</div>

It will be in your applications root folder. Along with the files like  
README, Rakefile, etc

–  
Chirag  
[http://sumeruonrails.com](http://sumeruonrails.com)

---

<div class="post-metadata">

**Author:** ![amitbiradar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a87d85/32.png) [@amitbiradar](https://www.ruby-forum.com/u/amitbiradar)\
**Post date:** [June 29, 2011, 8:35am UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/9 "2011-06-29T08:35:09Z")

</div>

Hi Chirag,

Thanks for your great help. I have one more question. It may be a silly  
one.  
You suggested that

in your Gemfile, add:  
gem ‘mysql’

I am not clear with the Gemfile. Please tell me where to find it.

On Wed, Jun 29, 2011 at 11:52 AM, Chirag S.  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)wrote:

> adapter: mysql  
> gem ‘mysql’
> 
> > > On Wed, Jun 29, 2011 at 10:57 AM, Amit B. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)wrote:
> > > 
> > > > Thanks,
> > > > 
> > > > > ruby script/rails server
> > > > 
> > > > –  
> > > > [http://groups.google.com/group/rubyonrails-talk?hl=en](http://groups.google.com/group/rubyonrails-talk?hl=en).  
> > > > For more options, visit this group at  
> > > > You received this message because you are subscribed to the Google G.  
> > > > –  
> > > > You received this message because you are subscribed to the Google G.  
> > > > “Ruby on Rails: Talk” group.  
> > > > To post to this group, send email to [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > > > To unsubscribe from this group, send email to  
> > > > [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > > > For more options, visit this group at  
> > > > [http://groups.google.com/group/rubyonrails-talk?hl=en](http://groups.google.com/group/rubyonrails-talk?hl=en).

–  
Thanks and Regards,  
Amit

---

<div class="post-metadata">

**Author:** ![amitbiradar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a87d85/32.png) [@amitbiradar](https://www.ruby-forum.com/u/amitbiradar)\
**Post date:** [July 28, 2011, 12:41pm UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/10 "2011-07-28T12:41:19Z")

</div>

looks like you have wrong entry in your Gemfile.

Can you attach or paste contents of your Gemfile?

Chirag  
[http://sumeruonrails.com](http://sumeruonrails.com)

---

<div class="post-metadata">

**Author:** ![amitbiradar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a87d85/32.png) [@amitbiradar](https://www.ruby-forum.com/u/amitbiradar)\
**Post date:** [July 28, 2011, 11:25am UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/11 "2011-07-28T11:25:10Z")

</div>

Hi Chirag,

I am still getting error while starting the rails.  
\<-[31mCould not find gem ‘mysql112 (~\> 0.2.6)’ in any of the gem sources  
listed in your Gemfile. \<-[0m

Please help on this, I found the gem file and added \*gem ‘mysql’ \*in to  
it  
but it still shows error. please help on this.

Thanks,  
Amit

On Wed, Jun 29, 2011 at 12:08 PM, Chirag S.  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)wrote:

> > Hi Chirag,  
> > [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)\> wrote:
> > 
> > > development:
> > > 
> > > > replace SQLite with MySQL?
> > > > 
> > > > > new console and run the server again.
> > > > > 
> > > > > > > or  
> > > > > > > [https://groups.google.com/d/msg/rubyonrails-talk/-/uKCg5GXX4o8J](https://groups.google.com/d/msg/rubyonrails-talk/-/uKCg5GXX4o8J).
> > > > > > 
> > > > > > [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > > > > > .  
> > > > > > Amit
> > 
> > To post to this group, send email to [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > “Ruby on Rails: Talk” group.  
> > To post to this group, send email to [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > To unsubscribe from this group, send email to  
> > [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > For more options, visit this group at  
> > [http://groups.google.com/group/rubyonrails-talk?hl=en](http://groups.google.com/group/rubyonrails-talk?hl=en).

–  
Thanks and Regards,  
Amit

---

<div class="post-metadata">

**Author:** ![amitbiradar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a87d85/32.png) [@amitbiradar](https://www.ruby-forum.com/u/amitbiradar)\
**Post date:** [July 28, 2011, 12:51pm UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/12 "2011-07-28T12:51:51Z")

</div>

mysql2 won’t install on windows, use mysql gem instead.

So, change this line  
gem ‘mysql2’, ‘~\> 0.2.6’  
to  
gem ‘mysql’

and in your config/database.yml file, change the adapter from _mysql2_  
to \*  
mysql\* for all 3 databases.

Chirag  
[http://sumeruonrails.com](http://sumeruonrails.com)

---

<div class="post-metadata">

**Author:** ![amitbiradar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a87d85/32.png) [@amitbiradar](https://www.ruby-forum.com/u/amitbiradar)\
**Post date:** [July 28, 2011, 12:45pm UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/13 "2011-07-28T12:45:38Z")

</div>

Hi,

Gem file is as follows:

source ‘[http://rubygems.org](http://rubygems.org)’

gem ‘rails’, ‘3.0.9’

# Bundle edge Rails instead:

# gem ‘rails’, :git =\> ‘git://github.com/rails/rails.git’

gem ‘mysql2’, ‘~\> 0.2.6’

# Use unicorn as the web server

# gem ‘unicorn’

# Deploy with Capistrano

# gem ‘capistrano’

# To use debugger (ruby-debug for Ruby 1.8.7+, ruby-debug19 for Ruby

1.9.2+)

# gem ‘ruby-debug’

# gem ‘ruby-debug19’, :require =\> ‘ruby-debug’

# Bundle the extra gems:

# gem ‘bj’

# gem ‘nokogiri’

# gem ‘sqlite3-ruby’, :require =\> ‘sqlite3’

# gem ‘aws-s3’, :require =\> ‘aws/s3’

# Bundle gems for the local environment. Make sure to

# put test-only gems in this group so their generators

# and rake tasks are available in development mode:

# group :development, :test do

# gem ‘webrat’

# end

On Thu, Jul 28, 2011 at 4:09 PM, Chirag S.  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)wrote:

> On Thu, Jul 28, 2011 at 2:53 PM, Amit B. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:
> 
> > Thanks,
> > 
> > > Chirag
> > > 
> > > > in your Gemfile, add:
> > > > 
> > > > > 1. Manually modify your database.yml file to use mysql and update your  
> > > > > pool: 5  
> > > > > Chirag
> > > > > 
> > > > > > > > But I am getting following error pop-up while running this command.  
> > > > > > > > [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)\> wrote:
> > > > > > > > 
> > > > > > > > > [Getting Started with Rails — Ruby on Rails Guides](http://guides.rubyonrails.org/getting_started.html)  
> > > > > > > > > [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > > > > > > > > –
> > > > > > 
> > > > > > To post to this group, send email to  
> > > > > > You received this message because you are subscribed to the Google
> > > > 
> > > > For more options, visit this group at  
> > > > [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > > > –  
> > > > You received this message because you are subscribed to the Google G.  
> > > > “Ruby on Rails: Talk” group.  
> > > > To post to this group, send email to [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > > > To unsubscribe from this group, send email to  
> > > > [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > > > For more options, visit this group at  
> > > > [http://groups.google.com/group/rubyonrails-talk?hl=en](http://groups.google.com/group/rubyonrails-talk?hl=en).

–  
Thanks and Regards,  
Amit

---

<div class="post-metadata">

**Author:** ![amitbiradar](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/a87d85/32.png) [@amitbiradar](https://www.ruby-forum.com/u/amitbiradar)\
**Post date:** [July 28, 2011, 12:57pm UTC](https://www.ruby-forum.com/t/problem-with-starting-rails-please-help/208839/14 "2011-07-28T12:57:26Z")

</div>

Hi Chirag,

It worked !!! Thank you very very much. 🙂

Thanks,  
-Amit.

On Thu, Jul 28, 2011 at 4:19 PM, Chirag S.  
[removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)wrote:

> > # gem ‘unicorn’
> > 
> > # gem ‘bj’
> > 
> > > > \<-[31mCould not find gem ‘mysql112 (~\> 0.2.6)’ in any of the gem sources  
> > > > [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)\> wrote:
> > > > 
> > > > > > On Wed, Jun 29, 2011 at 11:52 AM, Chirag S. \<
> > > > > > 
> > > > > > > in your Gemfile, add:
> > > > > > > 
> > > > > > > > Thank you very much Chirag. It worked. Could you please tell me how
> > > > > > > > 
> > > > > > > > > it to either your ruby bin directory or windows’ system32 directory.  
> > > > > > > > > Open up
> > > > > > > > > 
> > > > > > > > > > be located in the dynamic link library sqlite3.dll
> > > > > > > > > > 
> > > > > > > > > > > Looks like you are on Rails 3, in that case, on of the following  
> > > > > > > > > > > You received this message because you are subscribed to the
> > > > > > > > > > 
> > > > > > > > > > To post to this group, send email to  
> > > > > > > > > > You received this message because you are subscribed to the Google
> > > > > > > > 
> > > > > > > > [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > > > > > > > [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> > > > > > > > Amit
> > > > > 
> > > > > For more options, visit this group at  
> > > > > You received this message because you are subscribed to the Google  
> > > > > “Ruby on Rails: Talk” group.  
> > > > > Thanks and Regards,
> 
> –  
> You received this message because you are subscribed to the Google G.  
> “Ruby on Rails: Talk” group.  
> To post to this group, send email to [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> To unsubscribe from this group, send email to  
> [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid).  
> For more options, visit this group at  
> [http://groups.google.com/group/rubyonrails-talk?hl=en](http://groups.google.com/group/rubyonrails-talk?hl=en).

–  
Thanks and Regards,  
Amit
