大网数据广告活动
服务器运维问答

vagrant synced_folders and VBoxInternal2/SharedFoldersEnableSymlinksCreate

· 52CE 我爱测

ok here's the deal I'm running vagrant(ubunttu 12.10) on top of windows 8 but everytime I try to create a virtualenv (python) from within my non nfs shared folder I get a 'Protocol error', turns out that virtualbox does not allow…

问题原文

原帖链接 · Hertzel Armengol · CC BY-SA 4.0

ok here's the deal

I'm running vagrant(ubunttu 12.10) on top of windows 8 but everytime I try to create a virtualenv (python) from within my non nfs shared folder I get a 'Protocol error', turns out that virtualbox does not allow sym-linking by default but one can use this to enable it per share

"VBoxInternal2/SharedFoldersEnableSymlinksCreate/SHARE_NAME", "1"

the thing is that the latest vagrant no longer accepts a 'name/alias' for my shares, how am I supposed to refer to it from that setting? if my share is /var/www ?

  #   # Use VBoxManage to customize the VM. For example to change memory:
  #   vb.customize ["modifyvm", :id, "--memory", "1024"]
  # end
  #
  # View the documentation for the provider you're using for more
  # information on available options.
  
  vb.customize ["setextradata", :id, "VBoxInternal2/SharedFoldersEnableSymlinksCreate/SHARE_NAME", "1"]

any help will be appreciated.

已采纳解答

原帖链接 · Bryan · CC BY-SA 3.0

I answered this question in a different context on Stackoverflow: https://stackoverflow.com/a/21450513/1867779

Here's the summary, assuming Vagrant is making /vagrant the shared folder:

config.vm.provider :virtualbox do |vb|
  vb.customize ["setextradata", :id, "VBoxInternal2/SharedFoldersEnableSymlinksCreate//vagrant","1"]
end

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2013-04-22)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 4.0 / CC BY-SA 3.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。