Conection aborted on when starting locally produced box

classic Classic list List threaded Threaded
16 messages Options
Reply | Threaded
Open this post in threaded view
|

Conection aborted on when starting locally produced box

john-2
Vagrant 2.0.0
VirtualBox 5.1.26 
host is windows 10 pro.

So this is what I have done

iso file for mint 18.2
create new VM in virtualbox using iso. Install mint with vagrant as user.
Run VM in virtualbox, log on as vagrant with password of vagrant. Create .ssh folder in vagrant home, copy insecure_private_key to authorized_keys.

vagrant package to create box file, vagrant add to add box

vagrant init -m box_name

vagrant up gives this 
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'mint182_vagrant'...
==> default: Matching MAC address for NAT networking...
==> default: Setting the name of the VM: mint182_base_default_1505291152265_43039
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
==> default: Forwarding ports...
    default: 22 (guest) => 2222 (host) (adapter 1)
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2222
    default: SSH username: vagrant
    default: SSH auth method: private key
    default: Warning: Connection aborted. Retrying...
    default: Warning: Connection reset. Retrying...
    default: Warning: Connection aborted. Retrying...
    default: Warning: Connection reset. Retrying...
    default: Warning: Connection aborted. Retrying...
    default: Warning: Connection reset. Retrying...
    default: Warning: Connection aborted. Retrying...
    default: Warning: Remote connection disconnect. Retrying...
    default: Warning: Connection aborted. Retrying...

The last two lines then repeat until control-C

Looking in virtualbox, the VM is running. So I tried vagrant ssh
ssh_exchange_identification: read: Software caused connection abort

PS> vagrant ssh-config
Host default
  HostName 127.0.0.1
  User vagrant
  Port 2222
  UserKnownHostsFile /dev/null
  StrictHostKeyChecking no
  PasswordAuthentication no
  IdentityFile D:/Vagrant/insecure_private_key
  IdentitiesOnly yes
  LogLevel FATAL


Normally when I connect to a VM via ssh, I use putty. And that is the only ssh I have on the PC. No ssh on command line. But I can open the Ubuntu on windows app which gives

/mnt/d/Vagrant_examples/mint182_base$ ssh -p2222 vagrant@127.0.0.1
ssh_exchange_identification: Connection closed by remote host

I believe this is supposed to ask for a password.

So I am obviously doing something wrong. Does anyone have any ideas?

Regards,
John


--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/949d2b40-f248-4f29-a18c-bc70eeed9ff3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

Alvaro Miranda Aguilera
hello

log in to the console using virtualbox, log into the vm as vagrant user and try to ssh

ssh vagrant@localhost

does that works?

Maybe there is no ssh server, or there is a firewall

there are some permissions to be set on .ssh directory (0700) and the files should be 0600

but check if you can ssh from the guest locally

On Wed, Sep 13, 2017 at 11:08 AM, <[hidden email]> wrote:
Vagrant 2.0.0
VirtualBox 5.1.26 
host is windows 10 pro.

So this is what I have done

iso file for mint 18.2
create new VM in virtualbox using iso. Install mint with vagrant as user.
Run VM in virtualbox, log on as vagrant with password of vagrant. Create .ssh folder in vagrant home, copy insecure_private_key to authorized_keys.

vagrant package to create box file, vagrant add to add box

vagrant init -m box_name

vagrant up gives this 
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'mint182_vagrant'...
==> default: Matching MAC address for NAT networking...
==> default: Setting the name of the VM: mint182_base_default_1505291152265_43039
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
==> default: Forwarding ports...
    default: 22 (guest) => 2222 (host) (adapter 1)
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2222
    default: SSH username: vagrant
    default: SSH auth method: private key
    default: Warning: Connection aborted. Retrying...
    default: Warning: Connection reset. Retrying...
    default: Warning: Connection aborted. Retrying...
    default: Warning: Connection reset. Retrying...
    default: Warning: Connection aborted. Retrying...
    default: Warning: Connection reset. Retrying...
    default: Warning: Connection aborted. Retrying...
    default: Warning: Remote connection disconnect. Retrying...
    default: Warning: Connection aborted. Retrying...

The last two lines then repeat until control-C

Looking in virtualbox, the VM is running. So I tried vagrant ssh
ssh_exchange_identification: read: Software caused connection abort

PS> vagrant ssh-config
Host default
  HostName 127.0.0.1
  User vagrant
  Port 2222
  UserKnownHostsFile /dev/null
  StrictHostKeyChecking no
  PasswordAuthentication no
  IdentityFile D:/Vagrant/insecure_private_key
  IdentitiesOnly yes
  LogLevel FATAL


Normally when I connect to a VM via ssh, I use putty. And that is the only ssh I have on the PC. No ssh on command line. But I can open the Ubuntu on windows app which gives

/mnt/d/Vagrant_examples/mint182_base$ ssh -p2222 [hidden email]
ssh_exchange_identification: Connection closed by remote host

I believe this is supposed to ask for a password.

So I am obviously doing something wrong. Does anyone have any ideas?

Regards,
John


--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/949d2b40-f248-4f29-a18c-bc70eeed9ff3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0ez6hvFTOSQ7wNoheVwfPB%3DhHxWpC1jqXrDBvOi1XTbCaw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

john-2
Hi Alvaro,
so yes - I needed to install the ssh server - thought that was part of default build.
Added that to the base, repackaged, added the box and vagrant up.

Different result. 
Until timeout, get "Warning: Authentication failure. Retrying..." messages. VM is up and running.
If I try to use vagrant ssh, then I get a password prompt.

Which suggests that my key is not working. I have the .ssh and authorized_keys permissions correct. Could it be end of line problems? Looking at authorized_keys in vi, there are no control characters. So don't think that is a problem.

Therefore my insecure_private_key does not appear to be working.

As part of making my own box, do I need to add a /vagrant directory for shared folders? Reading the notes. I did wonder if vagrant added this but I do not have a /vagrant folder.

Regards,
John


--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/08f4941e-5b5c-436d-b4a1-a2b7aa04bdb2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

Alvaro Miranda Aguilera
Hello

Share the scripts you are using so we can review.

Whats the OS you are using there?



also have a look at packer.io that can be used to build vms.

ie:


On Wed, Sep 13, 2017 at 3:07 PM, <[hidden email]> wrote:
Hi Alvaro,
so yes - I needed to install the ssh server - thought that was part of default build.
Added that to the base, repackaged, added the box and vagrant up.

Different result. 
Until timeout, get "Warning: Authentication failure. Retrying..." messages. VM is up and running.
If I try to use vagrant ssh, then I get a password prompt.

Which suggests that my key is not working. I have the .ssh and authorized_keys permissions correct. Could it be end of line problems? Looking at authorized_keys in vi, there are no control characters. So don't think that is a problem.

Therefore my insecure_private_key does not appear to be working.

As part of making my own box, do I need to add a /vagrant directory for shared folders? Reading the notes. I did wonder if vagrant added this but I do not have a /vagrant folder.

Regards,
John


--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/08f4941e-5b5c-436d-b4a1-a2b7aa04bdb2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0exn-%3DiYc6Tmg-3tKayDTYstpOnqkp66bBExMJDh-%2BP5KA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

john-2
There are no scripts. The host is windows, the guest is mint.
I did not use packer because I wanted to try it manually to understand what needed to be done and what can go wrong. (Certainly get the "wrong" bit!).
My Vagrantfile is basic
PS D:\Vagrant_examples\mint182_base> cat Vagrantfile
Vagrant.configure("2") do |config|
  config.vm.box = "mint182_vagrant"
        config.vm.provider "virtualbox" do |v|
                v.gui = true
        end
end


--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/42b72881-6166-4bd8-afc9-44d74688ec90%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

Alvaro Miranda Aguilera
sorry, maybe i wasn't clear

can you share the commands you are doing in he guest for the ssh key please.

Alvaro

On Wed, Sep 13, 2017 at 3:48 PM, <[hidden email]> wrote:
There are no scripts. The host is windows, the guest is mint.
I did not use packer because I wanted to try it manually to understand what needed to be done and what can go wrong. (Certainly get the "wrong" bit!).
My Vagrantfile is basic
PS D:\Vagrant_examples\mint182_base> cat Vagrantfile
Vagrant.configure("2") do |config|
  config.vm.box = "mint182_vagrant"
        config.vm.provider "virtualbox" do |v|
                v.gui = true
        end
end


--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/42b72881-6166-4bd8-afc9-44d74688ec90%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0ey3OaG%3DsrDsgpDovOE8jHz%2B3RqPFLNJe%2Bmmv4tGuAECcA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

john-2
I think I have realised what I have done. I put the insecure_private_key (on host) in authorized_keys file (on guest). And normally I would put the public key in that file.
In which case, how does the public key get there. And where is the public key?
I suppose this is the value in doing this from scratch by hand. It throws up these fundamental questions.

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/b584c5fb-2fa9-4606-9568-89a5ded2be13%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

Alvaro Miranda Aguilera
This is the key that need to go to .ssh/authorized_keys


Alvaro

On Wed, Sep 13, 2017 at 4:15 PM, <[hidden email]> wrote:
I think I have realised what I have done. I put the insecure_private_key (on host) in authorized_keys file (on guest). And normally I would put the public key in that file.
In which case, how does the public key get there. And where is the public key?
I suppose this is the value in doing this from scratch by hand. It throws up these fundamental questions.

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/b584c5fb-2fa9-4606-9568-89a5ded2be13%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0ewjvVtTczw92%2Bkb%3DSmh9n1CFzu3XnacskyVMvFp6eSCZQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

john-2
Many thanks Alvaro. My book certainly did not cover that and I would not have found it.

Going back to a previous question on shared drives. Is it up to me to create a /vagrant folder on the guest?


--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/f2195868-3c51-4bf5-8647-25b2340cd7d0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

Alvaro Miranda Aguilera
/vagrant is the default shared folder, so if your guest is virtualbox, and virtualbox additions is installed on host/guest then will work

vagrant will create /vagrant on guest.

please, feel free to share questions, and if you think something should be easily available on the website but is not, or its not where you think should be, please say so, we can review and update documentation if required.

My personal involvement with Vagrant was in the very same way, and now after some time i know more, but is always good have the documentation up to date

:)

Alvaro.

On Wed, Sep 13, 2017 at 4:34 PM, <[hidden email]> wrote:
Many thanks Alvaro. My book certainly did not cover that and I would not have found it.

Going back to a previous question on shared drives. Is it up to me to create a /vagrant folder on the guest?


--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/f2195868-3c51-4bf5-8647-25b2340cd7d0%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Alvaro

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0ezP1to_HEx_CV3F0H2oVRCAxDE18vn8sVxEfYwxbFC1tw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

john-2
Thank you so much for your help Alvaro.
I did actually try creating the /vagrant directory in the VM from which I made the box and when I run it, there was a complaint when it made /vagrant.
Not sure if this is a bug because though the output lists the command, it gives no output.

==> default: Machine booted and ready!
==> default: Checking for guest additions in VM...
==> default: Mounting shared folders...
    default: /vagrant => D:/Vagrant_examples/mint182_base
The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!
mkdir -p /vagrant
Stdout from the command:

Stderr from the command:
PS D:\Vagrant_examples\mint182_base>

So I am guessing that when it created /vagrant, the output (either stdout or stderr) was "already exists" but this is not displayed.
No problems though, I can remove /vagrant in the original VM and create a new box.

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/c61e810f-def0-4639-95a5-ec3dbdd7d9ce%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

Alvaro Miranda Aguilera
mkdir -p will exit zero if dir exists so not an issue

try this

vagrant ssh
sudo su -


mkdir -p /thisdir ; echo $?
mkdir -p /thisdir ; echo $?

in both cases echo $? should be zero

does the vm have guest additions installed?

you can test adding shared folder over virtualbox gui and rebooting the vm


On Wed, Sep 13, 2017 at 8:24 PM, <[hidden email]> wrote:
Thank you so much for your help Alvaro.
I did actually try creating the /vagrant directory in the VM from which I made the box and when I run it, there was a complaint when it made /vagrant.
Not sure if this is a bug because though the output lists the command, it gives no output.

==> default: Machine booted and ready!
==> default: Checking for guest additions in VM...
==> default: Mounting shared folders...
    default: /vagrant => D:/Vagrant_examples/mint182_base
The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!
mkdir -p /vagrant
Stdout from the command:

Stderr from the command:
PS D:\Vagrant_examples\mint182_base>

So I am guessing that when it created /vagrant, the output (either stdout or stderr) was "already exists" but this is not displayed.
No problems though, I can remove /vagrant in the original VM and create a new box.

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/c61e810f-def0-4639-95a5-ec3dbdd7d9ce%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0ey8V32WOkWfghn6-RzzDM4yeX85izgbvt6wDnZtZu4BmQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

john-2
Hi Alvaro,
sorry for the delay in getting back.
So after vagrant up which leaves the VM in a running state but with the message
              ==> default: Mounting shared folders...
                      default: /vagrant => D:/Vagrant_examples/mint182_base
                     The following SSH command responded with a non-zero exit status.
                     Vagrant assumes that this means the command failed!
                            mkdir -p /vagrant
                            Stdout from the command:

                            Stderr from the command:

I then run vagrant ssh. /vagrant was missing (just to add, I removed it from base and re-packaged, re-boxed). 
Running mkdir -p /vagrant gave
           mkdir: cannot create directory ‘/vagrant’: Permission denied

Which makes sense because root directory is 755. When I created it on the base, I used sudo.
So vagrant is trying to create /vagrant but not using sudo so how does it actually work. Or how can it expect it to work?

Regards,
John 





--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/6c3e1427-9a3c-4c60-a9c8-e7c9b0dfaa68%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

Alvaro Miranda Aguilera
when you created your box, did you add Vagrant user to the sudoer file so can run commands as root without a password?

Can you share the box?

On Fri, Sep 15, 2017 at 3:54 PM, <[hidden email]> wrote:
Hi Alvaro,
sorry for the delay in getting back.
So after vagrant up which leaves the VM in a running state but with the message
              ==> default: Mounting shared folders...
                      default: /vagrant => D:/Vagrant_examples/mint182_base
                     The following SSH command responded with a non-zero exit status.
                     Vagrant assumes that this means the command failed!
                            mkdir -p /vagrant
                            Stdout from the command:

                            Stderr from the command:

I then run vagrant ssh. /vagrant was missing (just to add, I removed it from base and re-packaged, re-boxed). 
Running mkdir -p /vagrant gave
           mkdir: cannot create directory ‘/vagrant’: Permission denied

Which makes sense because root directory is 755. When I created it on the base, I used sudo.
So vagrant is trying to create /vagrant but not using sudo so how does it actually work. Or how can it expect it to work?

Regards,
John 





--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/6c3e1427-9a3c-4c60-a9c8-e7c9b0dfaa68%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0ey3w3CO9KYCry0OvpgvA8TLJpd_RtYrj6uDiV59Ahh3cg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

john-2
OK, vagrant is added to the sudo file as a user that does not require a password to run as root.
But the mkdir vagrant command still requires sudo to proceed it. And, according to the output, vagrant up is running "mkdir -p /vagrant", not "sudo mkdir -p /vagrant". Or does the output just leave off sudo?


--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/c86e9622-6367-4119-9e7d-009e486ada72%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Conection aborted on when starting locally produced box

john-2
And having done the above, still get exactly the same problem. So I guess that when it gets the non zero exit code, it exits the vagrantfile and does not complete any subsequent lines?



--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/7cb5ac25-c3a4-43a3-9730-f72da4ef7244%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.