Closed Bug 1169522 Opened 10 years ago Closed 10 years ago

I'm unable to get Treeherder running locally with Vagrant

Categories

(Tree Management :: Treeherder, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INVALID

People

(Reporter: KWierso, Unassigned)

Details

I'm planning on doing some more treeherder patching in the next few weeks, and I'm wanting to basically start from scratch to make sure things are working after treeherder-ui got merged into treeherder-service. So I cloned https://github.com/mozilla/treeherder on my Windows computer and then ran | vagrant up | After it finished provisioning things, I ran | vagrant ssh | and signed into the vagrant VM. The first thing I see when it signs in is the following: C:\Users\wkocher\Documents\GitHub\treeherder [master]> vagrant ssh Welcome to Ubuntu 12.04 LTS (GNU/Linux 3.2.0-23-generic-pae i686) * Documentation: https://help.ubuntu.com/ New release '14.04.2 LTS' available. Run 'do-release-upgrade' to upgrade to it. Welcome to your Vagrant-built virtual machine. Last login: Fri Sep 14 06:22:31 2012 from 10.0.2.2 : command not found (venv)vagrant@local:~$ ----------------------------------------------------------------- I then do | cd treeherder | and proceed to attempt to run | ./setup.py build_ext --inplace | (as per the readthedocs page) but get the following response: : No such file or directory I see setup.py in the folder. Same error happens when I try to run | ./manage.py init_master_db | I'm guessing something with the VM's .bashrc file, but I have no idea what to even look for in there. Or maybe some of the recent puppet changes?
Or possibly something screwy with my host system, I guess. ni?ed for talking about the puppet changes.
Flags: needinfo?(emorley)
I've just done a destroy and up locally on Windows (though from an msys2 shell, not sure if that makes any difference) using vagrant version 1.7.2 and virtualbox version 4.3.22. I can't see how my recent changes would have broken anything (particularly on some machines but not others), but to at least eliminate that could you try again using revision 797eb1431eb9788c481389bc895656fe802a0341 Also, are you using cmd.exe? Could you try using an msys shell? Are there are spaces in the path? (Presume not, and the " [master]" in comment 0, is just a prompt modification for the Git branch)
Flags: needinfo?(emorley)
Component: Treeherder → Treeherder: Docs & Development
Also in cases like these it's essential to have the log of the initial up/provision, since without it it's hard to see what happened. Could you also try a 'date' or any other command, just to see if the bash environment is screwed?
I've just tried again with virtualbox 4.3.28 (the latest) and that works too - perhaps update to that?
Here's what I get through the whole process: https://pastebin.mozilla.org/8835182 'date' works just fine, as you can see in that pastebin. No spaces in my host system's path. "[master]" is just from the git branch. This is using Git for Windows's git shell through powershell. I have Virtualbox 4.3.28. I'll try this through mozilla-build's shell sometime and see if that's any different.
The git msys environment does some awful things with paths iirc; I'd recommend using something else. Also I'm not sure why your output is listing virtualbox 4.3? ie: default: Guest Additions Version: 4.2.0 default: VirtualBox Version: 4.3 Perhaps clear out the vagrant/virtualbox folders in your user directory? (to force it to re-download the precise32 image.
In comparison, my vagrant up output looks like: https://emorley.pastebin.mozilla.org/8835185
Switching to a plain msys2 shell still had the same errors. Wiping out .vagrant.d to see if that helps.
Could you try again with latest master? The Vagrant base image has since been updated from the ancient Ubuntu 12.04 LTS to the slightly less ancient Ubuntu 14.04 LTS - which may either help you directly, or at least force vagrant to not use anything it has cached from before :-)
Flags: needinfo?(wkocher)
I'll give it a shot later. I know for a fact that my Surface Pro 3 was always able to (and still can with current master) get Vagrant running properly, so it's something on my main work laptop that's not set up right or something.
Flags: needinfo?(wkocher)
Same problem happens on my main system on current master. I have no idea why this particular machine is giving me so much trouble.
Re-reading the comments above, I wonder if this is an issue with virtualbox shared folders or file/folder permissions on that machine? On the non-working machine, try: $ echo "hello" > foo $ cat foo $ cat setup.py (Note: you should no longer need to do the "cd treeherder", the login script should put you in ~/treeherder already) Also perhaps compare an |ls -al| of the treeherder directory on your main machine with that on the one that is working. Also perhaps uninstall virtualbox+vagrant, restart, then reinstall them?
Also check the line endings on the machine that doesn't work - perhaps the git setting is still set to autoconvert the files to CRLF?
Did you have any luck with the suggestions above? :-)
Unsure exactly what fixed it, but I think working through things last week(?) with camd on IRC while I was recovering from reverting from Windows10 on one of my machines got things working for me. I think I had to blow everything away and start from scratch. Or something. Dunno.
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → INVALID
Glad it's working anyway :-)
Component: Treeherder: Docs & Development → TreeHerder
You need to log in before you can comment on or make changes to this bug.