Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot create SMB share #3257

Closed
MatthieuLJ opened this issue Mar 18, 2014 · 10 comments
Closed

Cannot create SMB share #3257

MatthieuLJ opened this issue Mar 18, 2014 · 10 comments
Labels

Comments

@MatthieuLJ
Copy link

I try to setup my Vagrantfile to use a SMB on Windows. It always gets stuck after asking my credentials.
I turned the logging on (debug level) and it never returns from:

 INFO subprocess: Starting process: ["C:\\Windows\\System32\\WindowsPowerShell\\
v1.0\\/powershell.EXE", "-NoProfile", "-ExecutionPolicy", "Bypass", "'C:/HashiCo
rp/Vagrant/embedded/gems/gems/vagrant-1.5.1/plugins/synced_folders/smb/scripts/s
et_share.ps1'", "-path", "C:\\deploy\\", "-share_name", "ef4f98d6-2736-4f5
d-a494-24dc2eead2cd--vagrant"]
DEBUG subprocess: Selecting on IO

I tried to run this command with all those arguments directly from the command line and it worked fine and create the share.
I am wondering if it is getting confused between the forward and double backward slashes.
I tried both in an MS-DOS prompt, the Windows PowerShell and a MINGW shell.

If ever this may cause trouble, my username does have a space and my password is empty.
My Vagrantfile does not have any modification from the default beside the

config.vm.synced_folder ".", "/vagrant", type: "smb"
@crankeye
Copy link

@MatthieuLJ what version of PowerShell are you using? When using PowerShell version 2 I've noticed vagrant will hang after typing in your Windows username and Password. Upgrading to PowerShell version 3 fixed the problem for me.

You can check your PowerShell version by typing:
$PSVersionTable.PSVersion

You can upgrade your PowerShell version using this windows update:
http://www.microsoft.com/en-us/download/details.aspx?id=34595

Windows6.1-KB2506143 is for Windows 7 SP1, Windows6.0-KB2506143 is for non SP1 Windows 7.

@MatthieuLJ
Copy link
Author

@crankeye thanks for the help.
When I check my current version, I get:

Major  Minor  Build  Revision
-----  -----  -----  --------
2      0      -1     -1

After the upgrade from your link, that seems to fix it.

I'm still not able to get something completely working (although it did not get stuck, seems like the share was not really created, it's not listed when I run 'net share'), but at least what I reported earlier is working. Not sure if anybody want to look at why it is getting stuck with an earlier version of Powershell or any other shell (mingw or DOS prompt) ?

@crankeye
Copy link

@MatthieuLJ you'll also need to apply the patch from /pull/3210 . Try that and see if it works.

@mitchellh
Copy link
Contributor

I need to verify that PS3 is running it appears for this. Tagged as bug.

@mitchellh
Copy link
Contributor

Fixed

@timtonk
Copy link

timtonk commented Apr 9, 2014

Hi, I have faced with this trouble too.
What should I do if I work on windows XP? I can't install powershell 3.0, even don't know way to do that "unofficially".
If PS3 is really required for that, so drop a corresponding line to your docs - Vagrant doesn't support winXP with SMB synced folders.

@timtonk
Copy link

timtonk commented May 29, 2014

@mitchellh I think you just didn't notice my message. Can you clarify what your position with windows XP now?

@mitchellh
Copy link
Contributor

Sorry. I believe @sneal has mentioned to me that Windows XP is not supported.

As Microsoft themselves officially doesn't support XP anymore, I don't see this being a hard ask.

@timtonk
Copy link

timtonk commented May 29, 2014

Ok, thx for explanation!

@sneal
Copy link
Contributor

sneal commented May 29, 2014

Win7+ is required for Windows guest support. I would make the same argument for host support too.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

5 participants