/tmp directory does not exist (bash.exe) [Windows Guest & Mac Host]

1,040 views
Skip to first unread message

Geoff Low

unread,
Mar 20, 2012, 11:37:48 AM3/20/12
to vagra...@googlegroups.com
Hi all

First off, great tool.  Very much enjoying using it.

I have created a Windows 2008 R2 box using veewee and am trying to use this in vagrant.  Vagrant successfully creates the vm, and starts it up - but then it fails when trying to create /vagrant.  I'm assuming it's because of the trace shown here:

DEBUG ssh: stderr: "tty" option detected in CYGWIN environment variable.
CYGWIN=tty is no longer supported.  Please remove it from your
CYGWIN environment variable and use a terminal emulator like mintty,
xterm, or rxvt.

DEBUG ssh: Exit status: 0
DEBUG ssh: stderr: bash.exe: warning: could not find /tmp, please create!

DEBUG ssh: stdout: /vagrant
DEBUG linux: Shell expanded guest path: /vagrant
DEBUG ssh: Re-using SSH connection.
 INFO ssh: Execute: mkdir -p /vagrant (sudo=true)
DEBUG ssh: Exit status: 2
ERROR warden: Error occurred: The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!

If I ssh into the image (vagrant ssh app) I can see the /tmp directory.

Is my issue here with a) the veewee box I created or b) with the way I've configured my Vagrantfile

(for reference)
  config.vm.define :app do |app_config|
    app_config.vm.box = "winbase"
    app_config.vm.host_name = "app.mock"
    app_config.vm.provision :chef_solo do |chef|
      # use mdsol recipes (
      chef.provisioning_path = "/tmp/vagrant-chef"
      chef.roles_path = [File.join(__FILE__, "../chef-solo/roles")]
      chef.cookbooks_path = [File.join(__FILE__, "../chef-solo/cookbooks")]
      chef.add_role :app
    end
    app_config.vm.customize do |vm|
      vm.name = "com.mock.app"
    end
  end

Thanks in advance...

Geoff

Geoff Low

unread,
Mar 27, 2012, 10:24:20 AM3/27/12
to vagra...@googlegroups.com
Ok, I may have missed something using the full DEBUG, with INFO I get the following:

[default] Mounting shared folders...
 INFO interface: info: -- v-root: /vagrant
[default] -- v-root: /vagrant
 INFO subprocess: Starting process: ["VBoxManage", "showvminfo", "772c797c-41d3-4455-9972-26274256f140", "--machinereadable"]
 INFO ssh: Execute: cat /etc/debian_version (sudo=false)
 INFO ssh: Execute: cat /etc/gentoo-release (sudo=false)
 INFO ssh: Execute: grep 'Fedora release 16' /etc/redhat-release (sudo=false)
 INFO ssh: Execute: cat /etc/redhat-release (sudo=false)
 INFO ssh: Execute: cat /etc/SuSE-release (sudo=false)
 INFO ssh: Execute: cat /etc/arch-release (sudo=false)
 INFO vm: Loading guest: linux
 INFO ssh: Execute: printf /vagrant (sudo=false)
 INFO ssh: Execute: mkdir -p /vagrant (sudo=true)
ERROR warden: Error occurred: The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!

mkdir -p /vagrant
 INFO warden: Calling recover: #<Vagrant::Action::VM::Import:0x007ff65237e808>
 INFO subprocess: Starting process: ["VBoxManage", "showvminfo", "772c797c-41d3-4455-9972-26274256f140", "--machinereadable"]
ERROR warden: Error occurred: The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!

And then I check the ssh as being up using;

Kauri-Geoff-Low:simulation glow$ VAGRANT_LOG=INFO vagrant ssh
 INFO global: Vagrant version: 1.0.1
 INFO vagrant: `vagrant` invoked: ["ssh"]
 INFO environment: Environment initialized (#<Vagrant::Environment:0x007f8e6315cba8>)
 INFO environment:   - cwd: /Users/glow/vagrant/simulation
 INFO environment: Home path: /Users/glow/.vagrant.d
 INFO plugin: Searching and loading any available plugins...
 INFO plugin: Loading plugin: veewee (0.2.3)
 INFO plugin: Loaded 1 plugins.
 INFO environment: Loading configuration...
 INFO provisioner: Provisioner class: Vagrant::Provisioners::ChefSolo
 INFO cli: CLI: [] "ssh" []
 INFO datastore: Created: /Users/glow/vagrant/simulation/.vagrant
 INFO virtualbox_base: VBoxManage path: VBoxManage
 INFO subprocess: Starting process: ["VBoxManage", "--version"]
 INFO virtualbox: Using VirtualBox driver: Vagrant::Driver::VirtualBox_4_1
 INFO virtualbox_base: VBoxManage path: VBoxManage
 INFO subprocess: Starting process: ["VBoxManage", "showvminfo", "772c797c-41d3-4455-9972-26274256f140"]
 INFO vm: Loading guest: linux
 INFO subprocess: Starting process: ["VBoxManage", "showvminfo", "772c797c-41d3-4455-9972-26274256f140", "--machinereadable"]
 INFO subprocess: Starting process: ["VBoxManage", "showvminfo", "772c797c-41d3-4455-9972-26274256f140", "--machinereadable"]
 INFO subprocess: Starting process: ["VBoxManage", "showvminfo", "772c797c-41d3-4455-9972-26274256f140", "--machinereadable"]
 INFO subprocess: Starting process: ["VBoxManage", "showvminfo", "772c797c-41d3-4455-9972-26274256f140", "--machinereadable"]
 INFO ssh: Invoking SSH: ["-p", "2222", "-o", "UserKnownHostsFile=/dev/null", "-o", "StrictHostKeyChecking=no", "-o", "IdentitiesOnly=yes", "-o", "LogLevel=ERROR", "-i", "/Users/glow/.vagrant.d/insecure_private_key", "vag...@127.0.0.1"]
Last login: Thu Mar  1 14:41:13 2012 from 10.0.2.2
"tty" option detected in CYGWIN environment variable.
CYGWIN=tty is no longer supported.  Please remove it from your
CYGWIN environment variable and use a terminal emulator like mintty,
xterm, or rxvt.

vagrant@vagrant-2008R2 ~

Anyone got any ideas?

Thanks
Geoff

Mitchell Hashimoto

unread,
Mar 27, 2012, 1:00:31 PM3/27/12
to vagra...@googlegroups.com

I would try doing what this message says ^

Mitchell

Mitchell Hashimoto

unread,
Jun 6, 2012, 11:59:32 AM6/6/12
to vagra...@googlegroups.com
On Wed, Jun 6, 2012 at 8:56 AM, Alex Rodionov <p0d...@gmail.com> wrote:
> Hello Mitchell,
>
> Can you please explain what you mean "doing what message says". If it's
> about CYGWIN=tty, then I fixed this problem but still get the same error.
>

In the above case I meant manually running "mkdir -p /vagrant" and
seeing what was going wrong.

Alex Rodionov

unread,
Jun 6, 2012, 12:13:58 PM6/6/12
to vagra...@googlegroups.com
After "vagrant up" finishes, I can connect to th box with "vagrant ssh" without any errors - "mkdir -p /vagrant" works ok and returns zero exit code.
Reply all
Reply to author
Forward
0 new messages