refinery / refinerycms

An extendable Ruby on Rails CMS that supports Rails 6.0+
https://www.refinerycms.com/
MIT License
3.9k stars 1.26k forks source link

Vagrant/rbenv + Windows = Errno::EPERM error #1862

Closed kvnlnt closed 12 years ago

kvnlnt commented 12 years ago

I set up a "default" RefineryCMS site on a debian box as a demo as a quick project at my company. It got approved and all was well until now. I went to set up a dev environment like we do all our rails apps with Vagrant (lucid32) running on Windows 7. However, the refinery administrator throws a permissions error when you try to create or update. I'm using rbenv to manage my ruby install...it seems to be related in some way. However, I don't receive these types of errors with my own rails apps with the exact same vagrant box.

ERROR: Errno::EPERM in Refinery::Admin::PagesController#create Operation not permitted - (/[siteroot]/tmp/index/development/refinery/page/116_101_115.ind.tmp)

/home/vagrant/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/fileutils.rb:519:in rename' /home/vagrant/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/fileutils.rb:519:inblock in mv' /home/vagrant/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/fileutils.rb:1515:in block in fu_each_src_dest' /home/vagrant/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/fileutils.rb:1531:infu_each_src_dest0' /home/vagrant/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/fileutils.rb:1513:in fu_each_src_dest' /home/vagrant/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/fileutils.rb:508:inmv' acts_as_indexed (0.7.8) lib/acts_as_indexed/storage.rb:169:in write_file' acts_as_indexed (0.7.8) lib/acts_as_indexed/storage.rb:95:inblock (2 levels) in operate' acts_as_indexed (0.7.8) lib/acts_as_indexed/storage.rb:180:in block in lock_file' acts_as_indexed (0.7.8) lib/acts_as_indexed/storage.rb:177:inopen' acts_as_indexed (0.7.8) lib/acts_as_indexed/storage.rb:177:in open' acts_as_indexed (0.7.8) lib/acts_as_indexed/storage.rb:177:inlock_file' acts_as_indexed (0.7.8) lib/acts_as_indexed/storage.rb:83:in block in operate' acts_as_indexed (0.7.8) lib/acts_as_indexed/storage.rb:80:ineach' acts_as_indexed (0.7.8) lib/acts_as_indexed/storage.rb:80:in operate' acts_as_indexed (0.7.8) lib/acts_as_indexed/storage.rb:23:inadd' acts_as_indexed (0.7.8) lib/acts_as_indexed/search_index.rb:28:in add_record' acts_as_indexed (0.7.8) lib/acts_as_indexed/class_methods.rb:64:inindex_add' acts_as_indexed (0.7.8) lib/acts_as_indexed/instance_methods.rb:16:in add_to_index' activesupport (3.2.3) lib/active_support/callbacks.rb:439:in_run891066548create206300346callbacks' activesupport (3.2.3) lib/active_support/callbacks.rb:405:in __run_callback' activesupport (3.2.3) lib/active_support/callbacks.rb:385:in_run_create_callbacks' activesupport (3.2.3) lib/active_support/callbacks.rb:81:in run_callbacks' activerecord (3.2.3) lib/active_record/callbacks.rb:268:increate' activerecord (3.2.3) lib/active_record/persistence.rb:344:in create_or_update' activerecord (3.2.3) lib/active_record/callbacks.rb:264:inblock in create_or_update' activesupport (3.2.3) lib/active_support/callbacks.rb:458:in _run__891066548__save__206300346__callbacks' activesupport (3.2.3) lib/active_support/callbacks.rb:405:inrun_callback' activesupport (3.2.3) lib/active_support/callbacks.rb:385:in _run_save_callbacks' activesupport (3.2.3) lib/active_support/callbacks.rb:81:inrun_callbacks' activerecord (3.2.3) lib/active_record/callbacks.rb:264:in create_or_update' activerecord (3.2.3) lib/active_record/persistence.rb:84:insave' activerecord (3.2.3) lib/active_record/validations.rb:50:in save' activerecord (3.2.3) lib/active_record/attribute_methods/dirty.rb:22:insave' activerecord (3.2.3) lib/active_record/transactions.rb:241:in block (2 levels) in save' activerecord (3.2.3) lib/active_record/transactions.rb:295:inblock in with_transaction_returning_status' activerecord (3.2.3) lib/active_record/connection_adapters/abstract/database_statements.rb:192:in transaction' activerecord (3.2.3) lib/active_record/transactions.rb:208:intransaction' activerecord (3.2.3) lib/active_record/transactions.rb:293:in with_transaction_returning_status' activerecord (3.2.3) lib/active_record/transactions.rb:241:inblock in save' activerecord (3.2.3) lib/active_record/transactions.rb:252:in rollback_active_record_state!' activerecord (3.2.3) lib/active_record/transactions.rb:240:insave' activerecord (3.2.3) lib/active_record/persistence.rb:45:in create' (eval):21:increate' actionpack (3.2.3) lib/action_controller/metal/implicit_render.rb:4:in send_action' actionpack (3.2.3) lib/abstract_controller/base.rb:167:inprocess_action' actionpack (3.2.3) lib/action_controller/metal/rendering.rb:10:in process_action' actionpack (3.2.3) lib/abstract_controller/callbacks.rb:18:inblock in process_action' activesupport (3.2.3) lib/active_support/callbacks.rb:492:in `block in _run193519476process_action718328319callbacks' activesupport (3.2.3) lib/active_support/callbacks.rb:215:inblock in _conditional_callback_around_305' activesupport (3.2.3) lib/active_support/callbacks.rb:326:inaround' activesupport (3.2.3) lib/active_support/callbacks.rb:310:in_callback_around_283' activesupport (3.2.3) lib/active_support/callbacks.rb:214:in_conditional_callback_around_305' activesupport (3.2.3) lib/active_support/callbacks.rb:480:in`_run193519476process_action718328319callbacks' activesupport (3.2.3) lib/active_support/callbacks.rb:405:in __run_callback' activesupport (3.2.3) lib/active_support/callbacks.rb:385:in_run_process_action_callbacks' activesupport (3.2.3) lib/active_support/callbacks.rb:81:in run_callbacks' actionpack (3.2.3) lib/abstract_controller/callbacks.rb:17:inprocess_action' actionpack (3.2.3) lib/action_controller/metal/rescue.rb:29:in process_action' actionpack (3.2.3) lib/action_controller/metal/instrumentation.rb:30:inblock in process_action' activesupport (3.2.3) lib/active_support/notifications.rb:123:in block in instrument' activesupport (3.2.3) lib/active_support/notifications/instrumenter.rb:20:ininstrument' activesupport (3.2.3) lib/active_support/notifications.rb:123:in instrument' actionpack (3.2.3) lib/action_controller/metal/instrumentation.rb:29:inprocess_action' actionpack (3.2.3) lib/action_controller/metal/params_wrapper.rb:205:in process_action' activerecord (3.2.3) lib/active_record/railties/controller_runtime.rb:18:inprocess_action' actionpack (3.2.3) lib/abstract_controller/base.rb:121:in process' actionpack (3.2.3) lib/abstract_controller/rendering.rb:45:inprocess' actionpack (3.2.3) lib/action_controller/metal.rb:203:in dispatch' actionpack (3.2.3) lib/action_controller/metal/rack_delegation.rb:14:indispatch' actionpack (3.2.3) lib/action_controller/metal.rb:246:in block in action' actionpack (3.2.3) lib/action_dispatch/routing/route_set.rb:73:incall' actionpack (3.2.3) lib/action_dispatch/routing/route_set.rb:73:in dispatch' actionpack (3.2.3) lib/action_dispatch/routing/route_set.rb:36:incall' journey (1.0.3) lib/journey/router.rb:68:in block in call' journey (1.0.3) lib/journey/router.rb:56:ineach' journey (1.0.3) lib/journey/router.rb:56:in call' actionpack (3.2.3) lib/action_dispatch/routing/route_set.rb:600:incall' railties (3.2.3) lib/rails/engine.rb:479:in call' railties (3.2.3) lib/rails/railtie/configurable.rb:30:inmethod_missing' journey (1.0.3) lib/journey/router.rb:68:in block in call' journey (1.0.3) lib/journey/router.rb:56:ineach' journey (1.0.3) lib/journey/router.rb:56:in call' actionpack (3.2.3) lib/action_dispatch/routing/route_set.rb:600:incall' warden (1.1.1) lib/warden/manager.rb:35:in block in call' warden (1.1.1) lib/warden/manager.rb:34:incatch' warden (1.1.1) lib/warden/manager.rb:34:in call' actionpack (3.2.3) lib/action_dispatch/middleware/best_standards_support.rb:17:incall' rack (1.4.1) lib/rack/etag.rb:23:in call' rack (1.4.1) lib/rack/conditionalget.rb:35:incall' actionpack (3.2.3) lib/action_dispatch/middleware/head.rb:14:in call' actionpack (3.2.3) lib/action_dispatch/middleware/params_parser.rb:21:incall' actionpack (3.2.3) lib/action_dispatch/middleware/flash.rb:242:in call' rack (1.4.1) lib/rack/session/abstract/id.rb:205:incontext' rack (1.4.1) lib/rack/session/abstract/id.rb:200:in call' actionpack (3.2.3) lib/action_dispatch/middleware/cookies.rb:338:incall' dragonfly (0.9.12) lib/dragonfly/cookie_monster.rb:9:in call' activerecord (3.2.3) lib/active_record/query_cache.rb:64:incall' activerecord (3.2.3) lib/active_record/connection_adapters/abstract/connection_pool.rb:467:in call' actionpack (3.2.3) lib/action_dispatch/middleware/callbacks.rb:28:inblock in call' activesupport (3.2.3) lib/active_support/callbacks.rb:405:in `_run669568892call206300346__callbacks' activesupport (3.2.3) lib/active_support/callbacks.rb:405:in__run_callback' activesupport (3.2.3) lib/active_support/callbacks.rb:385:in_run_call_callbacks' activesupport (3.2.3) lib/active_support/callbacks.rb:81:inrun_callbacks' actionpack (3.2.3) lib/action_dispatch/middleware/callbacks.rb:27:incall' dragonfly (0.9.12) lib/dragonfly/middleware.rb:13:incall' dragonfly (0.9.12) lib/dragonfly/middleware.rb:13:incall' rack-cache (1.2) lib/rack/cache/context.rb:136:inforward' rack-cache (1.2) lib/rack/cache/context.rb:143:inpass' rack-cache (1.2) lib/rack/cache/context.rb:155:ininvalidate' rack-cache (1.2) lib/rack/cache/context.rb:71:incall!' rack-cache (1.2) lib/rack/cache/context.rb:51:incall' rack-cache (1.2) lib/rack/cache/context.rb:136:inforward' rack-cache (1.2) lib/rack/cache/context.rb:143:inpass' rack-cache (1.2) lib/rack/cache/context.rb:155:ininvalidate' rack-cache (1.2) lib/rack/cache/context.rb:71:incall!' rack-cache (1.2) lib/rack/cache/context.rb:51:incall' actionpack (3.2.3) lib/action_dispatch/middleware/reloader.rb:65:incall' actionpack (3.2.3) lib/action_dispatch/middleware/remote_ip.rb:31:incall' actionpack (3.2.3) lib/action_dispatch/middleware/debug_exceptions.rb:16:incall' actionpack (3.2.3) lib/action_dispatch/middleware/show_exceptions.rb:56:incall' railties (3.2.3) lib/rails/rack/logger.rb:26:incall_app' railties (3.2.3) lib/rails/rack/logger.rb:16:incall' actionpack (3.2.3) lib/action_dispatch/middleware/request_id.rb:22:incall' rack (1.4.1) lib/rack/methodoverride.rb:21:incall' rack (1.4.1) lib/rack/runtime.rb:17:incall' activesupport (3.2.3) lib/active_support/cache/strategy/local_cache.rb:72:incall' rack (1.4.1) lib/rack/lock.rb:15:incall' actionpack (3.2.3) lib/action_dispatch/middleware/static.rb:62:incall' railties (3.2.3) lib/rails/engine.rb:479:incall' railties (3.2.3) lib/rails/application.rb:220:incall' rack (1.4.1) lib/rack/content_length.rb:14:incall' railties (3.2.3) lib/rails/rack/log_tailer.rb:14:incall' rack (1.4.1) lib/rack/handler/webrick.rb:59:inservice' /home/vagrant/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/webrick/httpserver.rb:138:inservice' /home/vagrant/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/webrick/httpserver.rb:94:inrun' /home/vagrant/.rbenv/versions/1.9.3-p194/lib/ruby/1.9.1/webrick/server.rb:191:inblock in start_thread'

Rendered /home/vagrant/.rbenv/versions/1.9.3-p194/lib/ruby/gems/1.9.1/gems/actionpack-3.2.3/lib/action_dispatch/middleware/templates/rescues/_trace.erb (5.8ms) Rendered /home/vagrant/.rbenv/versions/1.9.3-p194/lib/ruby/gems/1.9.1/gems/actionpack-3.2.3/lib/action_dispatch/middleware/templates/rescues/_request_and_response.erb (1.3ms) Rendered /home/vagrant/.rbenv/versions/1.9.3-p194/lib/ruby/gems/1.9.1/gems/actionpack-3.2.3/lib/action_dispatch/middleware/templates/rescues/diagnostics.erb within rescues/layout (27.7ms)

GEMS:

kvnlnt commented 12 years ago

This is a windows/virtualbox issue: see https://www.virtualbox.org/ticket/4890

ugisozols commented 12 years ago

Thanks @kvnlnt for link to the issue.

axsuul commented 12 years ago

I'm also having this issue.

@ugisozols Have you found a temporary workaround?

axsuul commented 12 years ago

I forked refinerycms and removed acts_as_indexed. https://github.com/Axsuul/refinerycms