Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7519863
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T01:58:19+00:00 2026-05-30T01:58:19+00:00

I have a Windows 7 machine with an Ubuntu 11.10 vm running inside it

  • 0

I have a Windows 7 machine with an Ubuntu 11.10 vm running inside it with VirtualBox. On my Windows 7 machine I have SQL Server 2008 installed which I am trying to access from my Ubuntu vm using rails 3.2 and the tiny_tds gem.

When I try to start my rails application I get the following:

/home/user/.rvm/gems/ruby-1.9.3-p0/gems/tiny_tds-0.5.1/lib/tiny_tds/client.rb:68:in `connect': Unable to open socket (TinyTds::Error)
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/tiny_tds-0.5.1/lib/tiny_tds/client.rb:68:in `initialize'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-sqlserver-adapter-3.2.0/lib/active_record/connection_adapters/sqlserver_adapter.rb:415:in `new'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-sqlserver-adapter-3.2.0/lib/active_record/connection_adapters/sqlserver_adapter.rb:415:in `connect'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-sqlserver-adapter-3.2.0/lib/active_record/connection_adapters/sqlserver_adapter.rb:203:in `initialize'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-sqlserver-adapter-3.2.0/lib/active_record/connection_adapters/sqlserver_adapter.rb:40:in `new'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-sqlserver-adapter-3.2.0/lib/active_record/connection_adapters/sqlserver_adapter.rb:40:in `sqlserver_connection'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-3.2.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:277:in `new_connection'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-3.2.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:287:in `checkout_new_connection'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-3.2.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:235:in `block (2 levels) in checkout'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-3.2.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:230:in `loop'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-3.2.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:230:in `block in checkout'
from /home/user/.rvm/rubies/ruby-1.9.3-p0/lib/ruby/1.9.1/monitor.rb:211:in `mon_synchronize'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-3.2.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:229:in `checkout'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-3.2.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:95:in `connection'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-3.2.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:374:in `retrieve_connection'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-3.2.1/lib/active_record/connection_adapters/abstract/connection_specification.rb:168:in `retrieve_connection'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-3.2.1/lib/active_record/connection_adapters/abstract/connection_specification.rb:142:in `connection'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-3.2.1/lib/active_record/model_schema.rb:308:in `clear_cache!'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activerecord-3.2.1/lib/active_record/railtie.rb:91:in `block (2 levels) in <class:Railtie>'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activesupport-3.2.1/lib/active_support/callbacks.rb:418:in `_run__855141609__prepare__585695355__callbacks'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activesupport-3.2.1/lib/active_support/callbacks.rb:405:in `__run_callback'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activesupport-3.2.1/lib/active_support/callbacks.rb:385:in `_run_prepare_callbacks'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activesupport-3.2.1/lib/active_support/callbacks.rb:81:in `run_callbacks'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/actionpack-3.2.1/lib/action_dispatch/middleware/reloader.rb:74:in `prepare!'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/actionpack-3.2.1/lib/action_dispatch/middleware/reloader.rb:48:in `prepare!'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.2.1/lib/rails/application/finisher.rb:47:in `block in <module:Finisher>'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.2.1/lib/rails/initializable.rb:30:in `instance_exec'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.2.1/lib/rails/initializable.rb:30:in `run'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.2.1/lib/rails/initializable.rb:55:in `block in run_initializers'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.2.1/lib/rails/initializable.rb:54:in `each'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.2.1/lib/rails/initializable.rb:54:in `run_initializers'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.2.1/lib/rails/application.rb:136:in `initialize!'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.2.1/lib/rails/railtie/configurable.rb:30:in `method_missing'
from /home/user/RubymineProjects/myapp/config/environment.rb:5:in `<top (required)>'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activesupport-3.2.1/lib/active_support/dependencies.rb:251:in `require'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activesupport-3.2.1/lib/active_support/dependencies.rb:251:in `block in require'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activesupport-3.2.1/lib/active_support/dependencies.rb:236:in `load_dependency'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/activesupport-3.2.1/lib/active_support/dependencies.rb:251:in `require'
from /home/user/RubymineProjects/myapp/config.ru:4:in `block in <main>'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/rack-1.4.1/lib/rack/builder.rb:51:in `instance_eval'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/rack-1.4.1/lib/rack/builder.rb:51:in `initialize'
from /home/user/RubymineProjects/myapp/config.ru:1:in `new'
from /home/user/RubymineProjects/myapp/config.ru:1:in `<main>'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/rack-1.4.1/lib/rack/builder.rb:40:in `eval'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/rack-1.4.1/lib/rack/builder.rb:40:in `parse_file'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/rack-1.4.1/lib/rack/server.rb:200:in `app'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.2.1/lib/rails/commands/server.rb:46:in `app'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/rack-1.4.1/lib/rack/server.rb:301:in `wrapped_app'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/rack-1.4.1/lib/rack/server.rb:252:in `start'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.2.1/lib/rails/commands/server.rb:70:in `start'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.2.1/lib/rails/commands.rb:55:in `block in <top (required)>'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.2.1/lib/rails/commands.rb:50:in `tap'
from /home/user/.rvm/gems/ruby-1.9.3-p0/gems/railties-3.2.1/lib/rails/commands.rb:50:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'

I can verify that SQL Server is accessible to the vm by running telnet to my host ip on port 1433 and I am able to connect successfully, but for whatever reason I can’t connect via ruby or TinyTds. My network adapter for my vm is using NAT. Furthermore, if I run that same rails application from my Windows machine I can connect to SQL Server. TCP/IP connections are enabled for SQL Server.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T01:58:20+00:00Added an answer on May 30, 2026 at 1:58 am

    I ended up changing the dataserver setting to host instead and that fixed it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We have a Windows machine running SQL Server 2005, and we need to be
I have a Windows XP machine and a Linux machine running Ubuntu. I share
I am running a windows machine have installed Python 2.5. I also used the
I have an access database on a windows machine, which I must import into
I have an ApacheFriends XAMPP running on my windows machine and i am trying
I am running Linux Ubuntu 10.04 and I have a Windows 7 machine and
I have to scan a Ubuntu server (installed as a virtual machine on my
Can any one help me set-up APE Server on windows machine... I have installed
I have a Windows 7 machine with Visual Studio 2005 SP1 installed. Using this,
I have a Windows 7 machine on which I am using VS2005. .Net 2.0

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.