Unable to update vagrant dev install on Windows

I’m getting the following error when attempting to update my dev install on Windows. I first did a git pull, then vagrant up, vagrant ssh, and finally bundle install. The error occurs when trying to run bundle exec rake db:migrate

vagrant@discourse:/vagrant$ bundle exec rake db:migrate
rake aborted!
ln: failed to create symbolic link '/vagrant/public/plugins/discourse-narrative-bot': Protocol error
/vagrant/lib/discourse.rb:26:in `execute_command'
/vagrant/lib/plugin/instance.rb:368:in `activate!'
/vagrant/lib/discourse.rb:126:in `block in activate_plugins!'
/vagrant/lib/discourse.rb:123:in `each'
/vagrant/lib/discourse.rb:123:in `activate_plugins!'
/vagrant/config/application.rb:179:in `<class:Application>'
/vagrant/config/application.rb:27:in `<module:Discourse>'
/vagrant/config/application.rb:26:in `<top (required)>'
/vagrant/rakefile:5:in `require'
/vagrant/rakefile:5:in `<top (required)>'
/home/vagrant/.rvm/gems/ruby-2.3.1/gems/rake-12.0.0/exe/rake:27:in `<top (required)>'
/home/vagrant/.rvm/gems/ruby-2.3.1/bin/ruby_executable_hooks:15:in `eval'
/home/vagrant/.rvm/gems/ruby-2.3.1/bin/ruby_executable_hooks:15:in `<main>'
(See full trace by running task with --trace)
1 Like

Looks like its related to this line:

Did you already install the discobot plugin before this? Do we normally create symlinks or is that a vagrant thing?

Nope, haven’t updated in quite some time. Also never installed plugins in Vagrant.

I have no idea…

Can you just try creating a test symlink yourself and see if it works?

It does not appear to be working:

vagrant@discourse:/vagrant$ touch temp
vagrant@discourse:/vagrant$ ln -s temp temp-link
ln: failed to create symbolic link 'temp-link': Protocol error

check this out


I didn’t read the whole thing, but you might need to downgrade to a different version of vagrant if they haven’t fixed it yet.

I would recommend avoiding vagrant, if you need a “quick” setup just start an ubuntu VM and and use our docker dev env.


Sounds good Sam - will test that out later today.

you need special rights to create symbolic links with windows (inside virtual machines), the right goes by “SeCreateSymbolicLink”.
Administrator have this right by default. When you run vagrant up/ssh, you need to run it with a user that has this right.

I avoided this error by starting a powershell as administrator (since I didn’t want to bother with granting rights to my user) and discourse is up and running