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 7070847
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T05:36:56+00:00 2026-05-28T05:36:56+00:00

I try to launch really simple Ruby on Rails app on VDS. I use

  • 0

I try to launch really simple Ruby on Rails app on VDS. I use Nginx, Phusion Passenger and Sqlite3. I have root rights.

Code of creating project:

$ rails new myapplication
$ cd /rails_apps/myapplication
$ bundle install
$ rails generate scaffold Post name:string title:string content:text
$ RAILS_ENV=production rake db:migrate

I can visit main page, it shows ok. But when i try insert data into DB, i get next:

SQLite3::ReadOnlyException: attempt to write a readonly database: INSERT INTO "posts" ("content", "created_at", "name", "title", "updated_at") VALUES (?, ?, ?, ?, ?)

How can i fix that?

UPD:

chmod 777 \db

Helped me.

  • 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-28T05:36:57+00:00Added an answer on May 28, 2026 at 5:36 am

    Still sounds like a privileges issue to me. Make sure that the user that you’re running rails as has permission to edit the file. For instance, if you’re running rails under phusion, I believe that the rails effective user and group are the user and group that nginx runs as. To test if it is permissions. I would start with chmod 777 on your sqlite db file, and see if that helps. If so, follow up to see if you can set the permissions more reasonably and ownership of the db file to your nginx user.

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

Sidebar

Related Questions

I have wanted to try GAE since launch, but coming from ASP .NET and
My app force closes when I try to launch the same MapActivity from the
I try to launch another app inside a bash script, but the app seems
I try to launch internet explorer, So I use the below code QProcess *
i have problems with ajax requests and simple <input type=submit/> . i use to
I have this really simple c++ function I wrote myself. It should just strip
When I try to launch my rails project using rails server thin it starts
When ever I try to launch my eclipse I am getting the following exception
When I launch perfmon and try to add a counter, the displayed performance objects
I've just get a new machine and try to checkout, build and launch my

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.