thats more related to the guest. add config.ssh.insert_key=false and try again from vagrant destroy as time permits.
Alvaro. On Fri, Jul 22, 2016 at 1:45 PM, <[email protected]> wrote: > Beauty !! Works like a treat !! > > Many thanks Alvaro > > Cheers, > Jim > > On Friday, July 22, 2016 at 5:27:52 AM UTC+10, Alvaro Miranda Aguilera > wrote: >> >> hello, >> >> the message is telling you that the box was already provisiones, so it >> wont run the commands again, >> >> you can run vagrant provision, or vagrant up --provision, or just destroy >> and create a new one. >> >> In that way you will be forcing a new provision. >> >> Thanks >> Alvaro. >> >> On Thu, Jul 21, 2016 at 1:05 PM, <[email protected]> wrote: >> >>> Hi Alvaro, >>> >>> Still it doesn't do any installation. I think the two adapters are >>> because of 1. default public network and 2 because I want private network >>> with static IP. >>> >>> Output from vagrant up is below. >>> >>> Bringing machine 'default' up with 'virtualbox' provider... >>> ==> default: Checking if box 'centos/7' is up to date... >>> ==> default: Clearing any previously set forwarded ports... >>> ==> default: Clearing any previously set network interfaces... >>> ==> default: Preparing network interfaces based on configuration... >>> default: Adapter 1: nat >>> default: Adapter 2: bridged >>> ==> 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: Remote connection disconnect. Retrying... >>> ==> default: Machine booted and ready! >>> [default] GuestAdditions versions on your host (5.0.26) and guest >>> (5.0.14) do not match. >>> Loaded plugins: fastestmirror >>> Loading mirror speeds from cached hostfile >>> * base: mirror.colocity.com >>> * extras: centos.mirror.crucial.com.au >>> * updates: centos.mirror.crucial.com.au >>> Package kernel-devel-3.10.0-327.22.2.el7.x86_64 already installed and >>> latest version >>> Package gcc-4.8.5-4.el7.x86_64 already installed and latest version >>> Package binutils-2.23.52.0.1-55.el7.x86_64 already installed and latest >>> version >>> Package 1:make-3.82-21.el7.x86_64 already installed and latest version >>> Package 4:perl-5.16.3-286.el7.x86_64 already installed and latest version >>> Package bzip2-1.0.6-13.el7.x86_64 already installed and latest version >>> Nothing to do >>> Copy iso file C:\Program Files\Oracle\VirtualBox\VBoxGuestAdditions.iso >>> into the box /tmp/VBoxGuestAdditions.iso >>> mount: /dev/loop0 is write-protected, mounting read-only >>> Installing Virtualbox Guest Additions 5.0.14 - guest version is 5.0.14 >>> Verifying archive integrity... All good. >>> Uncompressing VirtualBox 5.0.14 Guest Additions for Linux............ >>> VirtualBox Guest Additions installer >>> Removing installed version 5.0.14 of VirtualBox Guest Additions... >>> Removing existing VirtualBox non-DKMS kernel modules[ OK ] >>> Copying additional installer modules ... >>> Installing additional modules ... >>> Removing existing VirtualBox non-DKMS kernel modules[ OK ] >>> Building the VirtualBox Guest Additions kernel modules >>> Building the main Guest Additions module[ OK ] >>> Building the shared folder support module[ OK ] >>> Building the OpenGL support module[ OK ] >>> Doing non-kernel setup of the Guest Additions[ OK ] >>> You should restart your guest to make sure the new modules are actually >>> used >>> >>> Installing the Window System drivers >>> Could not find the X.Org or XFree86 Window System, skipping. >>> An error occurred during installation of VirtualBox Guest Additions >>> 5.0.14. Some functionality may not work as intended. >>> In most cases it is OK that the "Window System drivers" installation >>> failed. >>> ==> default: Checking for guest additions in VM... >>> ==> default: Configuring and enabling network interfaces... >>> ==> default: Mounting shared folders... >>> default: /home/vagrant/sync => C:/Users/ameya_000/VirtualBox >>> VMs/test2 >>> ==> default: Machine already provisioned. Run `vagrant provision` or use >>> the `--provision` >>> ==> default: flag to force provisioning. Provisioners marked to run >>> always will still run. >>> >>> Content of setup.sh >>> yum -y upgrade --exclude kernel* >>> yum -y install vim git gedit nmap >>> yum -y install httpd >>> systemctl restart httpd >>> >>> On Thursday, July 21, 2016 at 7:36:44 AM UTC+10, Alvaro Miranda Aguilera >>> wrote: >>>> >>>> Hello the script is not correct. >>>> >>>> ITs ok as a series of command that someone need to type, but as soon as >>>> sudo su - happens the script should wait for ever, or exit and continue, >>>> not sure. But you can skip that line and all the sudo. >>>> >>>> Vagrant will run the commands as root (by sudo), so your script should >>>> be like this, >>>> >>>> setup.sh: >>>> yum -y install vim git gedit nmap >>>> systemctl restart httpd >>>> >>>> Do not run yum upgrade, since that will upgrade the kernel and that >>>> will cause issues with virtualnbox and other modules. >>>> >>>> Options: >>>> a. Create a new base box that is fully updated (fit for use) >>>> b. Update what you require and expclude kernel, ie. yum upgrade -y >>>> --exclude kernel* >>>> >>>> >>>> Thanks >>>> Alvaro >>>> >>>> On Thu, Jul 21, 2016 at 3:30 AM, <[email protected]> wrote: >>>> >>>>> Hi Alvaro, >>>>> >>>>> I have invested days in learning vagrant but somehow not yet in >>>>> comfort zone. What I find interesting is that I did "vagrant destroy" and >>>>> then did "vagrant up" and everything seems to be working fine even thought >>>>> loop back, eth0 and eth1 are all UP. >>>>> >>>>> My Vagrantfile contents was in my original post., anyway posting it >>>>> again: >>>>> Vagrant.configure("2") do |o| >>>>> o.vm.box="centos/7" >>>>> o.vm.network "public_network", ip: "192.168.1.13" >>>>> o.vm.provision "shell", :path=>"setup.sh" >>>>> end >>>>> >>>>> setup.sh contents: >>>>> sudo su - root >>>>> yum -y update >>>>> yum -y install vim git gedit nmap >>>>> yum -y install httpd >>>>> systemctl restart httpd >>>>> >>>>> Not sure why vagrant is not able to install packages?? >>>>> >>>>> vagrant up log output is below, I don't think I anything wrong with my >>>>> Vagrantfile or setup file. >>>>> Output of vagrant up: >>>>> Bringing machine 'default' up with 'virtualbox' provider... >>>>> ==> default: Checking if box 'centos/7' is up to date... >>>>> ==> default: Clearing any previously set forwarded ports... >>>>> ==> default: Clearing any previously set network interfaces... >>>>> ==> default: Preparing network interfaces based on configuration... >>>>> default: Adapter 1: nat >>>>> default: Adapter 2: bridged >>>>> ==> 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: Remote connection disconnect. Retrying... >>>>> ==> default: Machine booted and ready! >>>>> [default] GuestAdditions versions on your host (5.0.26) and guest >>>>> (5.0.14) do not match. >>>>> Loaded plugins: fastestmirror >>>>> Loading mirror speeds from cached hostfile >>>>> * base: mirror.colocity.com >>>>> * extras: centos.mirror.crucial.com.au >>>>> * updates: centos.mirror.crucial.com.au >>>>> Package kernel-devel-3.10.0-327.22.2.el7.x86_64 already installed and >>>>> latest version >>>>> Package gcc-4.8.5-4.el7.x86_64 already installed and latest version >>>>> Package binutils-2.23.52.0.1-55.el7.x86_64 already installed and >>>>> latest version >>>>> Package 1:make-3.82-21.el7.x86_64 already installed and latest version >>>>> Package 4:perl-5.16.3-286.el7.x86_64 already installed and latest >>>>> version >>>>> Package bzip2-1.0.6-13.el7.x86_64 already installed and latest version >>>>> Nothing to do >>>>> Copy iso file C:\Program >>>>> Files\Oracle\VirtualBox\VBoxGuestAdditions.iso into the box >>>>> /tmp/VBoxGuestAdditions.iso >>>>> mount: /dev/loop0 is write-protected, mounting read-only >>>>> Installing Virtualbox Guest Additions 5.0.14 - guest version is 5.0.14 >>>>> Verifying archive integrity... All good. >>>>> Uncompressing VirtualBox 5.0.14 Guest Additions for Linux............ >>>>> VirtualBox Guest Additions installer >>>>> Removing installed version 5.0.14 of VirtualBox Guest Additions... >>>>> Removing existing VirtualBox non-DKMS kernel modules[ OK ] >>>>> Copying additional installer modules ... >>>>> Installing additional modules ... >>>>> Removing existing VirtualBox non-DKMS kernel modules[ OK ] >>>>> Building the VirtualBox Guest Additions kernel modules >>>>> Building the main Guest Additions module[ OK ] >>>>> Building the shared folder support module[ OK ] >>>>> Building the OpenGL support module[ OK ] >>>>> Doing non-kernel setup of the Guest Additions[ OK ] >>>>> You should restart your guest to make sure the new modules are >>>>> actually used >>>>> >>>>> Installing the Window System drivers >>>>> Could not find the X.Org or XFree86 Window System, skipping. >>>>> An error occurred during installation of VirtualBox Guest Additions >>>>> 5.0.14. Some functionality may not work as intended. >>>>> In most cases it is OK that the "Window System drivers" installation >>>>> failed. >>>>> ==> default: Checking for guest additions in VM... >>>>> ==> default: Configuring and enabling network interfaces... >>>>> ==> default: Mounting shared folders... >>>>> default: /home/vagrant/sync => C:/Users/ameya_000/VirtualBox >>>>> VMs/test2 >>>>> ==> default: Machine already provisioned. Run `vagrant provision` or >>>>> use the `--provision` >>>>> ==> default: flag to force provisioning. Provisioners marked to run >>>>> always will still run. >>>>> >>>>> P.S: I realized why I have two interfaces as there is two adapters ! >>>>> My mistake for sure. >>>>> >>>>> Would wait to hear from learned people why package installation is not >>>>> working. >>>>> >>>>> Regards, >>>>> Jim >>>>> >>>>> On Wednesday, July 20, 2016 at 6:07:40 AM UTC+10, Alvaro Miranda >>>>> Aguilera wrote: >>>>>> >>>>>> Hello, >>>>>> >>>>>> Vagrant does one job and does it very nice. Time by time people want >>>>>> to make vagrant what they would like to do, instead of learning a bit of >>>>>> Vagrant, and that create fustration. >>>>>> >>>>>> 1. Vagrant always will use eth0 for local host/vm communication, and >>>>>> over this network you can use the forwarder ports, and the VM will have >>>>>> access to the network using nat. >>>>>> >>>>>> 2. When you add a private network, you can use this IP (fixed or >>>>>> dhcp) to ssh into the VM, VM->Host, or in a multi machine setup to VM->VM >>>>>> >>>>>> 3. When you use public network, you will get an IP from your >>>>>> home/office network, and by default, its documented, Vagrant wont >>>>>> override >>>>>> the default GW. So if you need to do this, there is an example script in >>>>>> the documentation on how to do this. >>>>>> >>>>>> IF you could share what you want to do, how your Vagrantfile looks >>>>>> like, there is a lot of people that can have a look and share ideas with >>>>>> you. >>>>>> >>>>>> Thanks >>>>>> Alvaro. >>>>>> >>>>>> On Wed, Jul 20, 2016 at 3:59 AM, <[email protected]> wrote: >>>>>> >>>>>>> Hi Alvaro, >>>>>>> >>>>>>> It works with public_network but I don't have access to internet as >>>>>>> I see two active interfaces eth0 and eth1. Can we make it working with >>>>>>> only >>>>>>> one interface ? How to do that? >>>>>>> >>>>>>> Cheers >>>>>>> Jim >>>>>>> >>>>>>> P.S: Not at all happy with "Vagrant" product. No >>>>>>> offence.............. >>>>>>> >>>>>>> >>>>>>> On Tuesday, July 19, 2016 at 4:38:17 AM UTC+10, Alvaro Miranda >>>>>>> Aguilera wrote: >>>>>>>> >>>>>>>> Hello, >>>>>>>> >>>>>>>> the message is telling you that ip network can be used for private >>>>>>>> network because there is a network that already exists. >>>>>>>> >>>>>>>> you can use a different network, or try wirth public if what you >>>>>>>> want is the vm to connect to 192.168.1.x >>>>>>>> >>>>>>>> Alvaro >>>>>>>> >>>>>>>> On Tue, Jul 19, 2016 at 12:11 AM, <[email protected]> wrote: >>>>>>>> >>>>>>>>> Hello Folks, >>>>>>>>> >>>>>>>>> I ran into the following error when I execute "vagrant up" command. >>>>>>>>> >>>>>>>>> The specified host network collides with a non-hostonly network! >>>>>>>>> This will cause your specified IP to be inaccessible. Please change >>>>>>>>> the IP or name of your host only network so that it no longer >>>>>>>>> matches that of >>>>>>>>> a bridged or non-hostonly network. >>>>>>>>> >>>>>>>>> Vagrant file: >>>>>>>>> Vagrant.configure("2") do |o| >>>>>>>>> o.vm.box="centos/7" >>>>>>>>> o.vm.network "private_network", ip: "192.168.1.13" >>>>>>>>> o.vm.provision "shell", :path=>"setup.sh" >>>>>>>>> end >>>>>>>>> >>>>>>>>> setup.sh: >>>>>>>>> sudo yum -y update >>>>>>>>> sudo yum -y install vim,git,gedit,nmap >>>>>>>>> sudo systemctl restart httpd >>>>>>>>> >>>>>>>>> Nothing is started but I see a machine in Virtual box and I double >>>>>>>>> click and I start as usual. Could assign static IP but no network to >>>>>>>>> outside world. Not sure where the things are going wrong. >>>>>>>>> >>>>>>>>> Any help would be very much appreciated. >>>>>>>>> >>>>>>>>> Thanks >>>>>>>>> Jim >>>>>>>>> >>>>>>>>> -- >>>>>>>>> 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 [email protected]. >>>>>>>>> To view this discussion on the web visit >>>>>>>>> https://groups.google.com/d/msgid/vagrant-up/4bf32117-cc9d-4386-89db-6ab202d73ce8%40googlegroups.com >>>>>>>>> <https://groups.google.com/d/msgid/vagrant-up/4bf32117-cc9d-4386-89db-6ab202d73ce8%40googlegroups.com?utm_medium=email&utm_source=footer> >>>>>>>>> . >>>>>>>>> For more options, visit https://groups.google.com/d/optout. >>>>>>>>> >>>>>>>> >>>>>>>> -- >>>>>>> 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 [email protected]. >>>>>>> To view this discussion on the web visit >>>>>>> https://groups.google.com/d/msgid/vagrant-up/85aae2b1-e1af-48e7-b11f-f124a1a2bbf1%40googlegroups.com >>>>>>> <https://groups.google.com/d/msgid/vagrant-up/85aae2b1-e1af-48e7-b11f-f124a1a2bbf1%40googlegroups.com?utm_medium=email&utm_source=footer> >>>>>>> . >>>>>>> For more options, visit https://groups.google.com/d/optout. >>>>>>> >>>>>> >>>>>> -- >>>>> 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 [email protected]. >>>>> To view this discussion on the web visit >>>>> https://groups.google.com/d/msgid/vagrant-up/f0182934-0da2-4e30-b203-b3c3380f0821%40googlegroups.com >>>>> <https://groups.google.com/d/msgid/vagrant-up/f0182934-0da2-4e30-b203-b3c3380f0821%40googlegroups.com?utm_medium=email&utm_source=footer> >>>>> . >>>>> For more options, visit https://groups.google.com/d/optout. >>>>> >>>> >>>> -- >>> 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 [email protected]. >>> To view this discussion on the web visit >>> https://groups.google.com/d/msgid/vagrant-up/7b0199fe-8715-4874-9b88-09b6edf27661%40googlegroups.com >>> <https://groups.google.com/d/msgid/vagrant-up/7b0199fe-8715-4874-9b88-09b6edf27661%40googlegroups.com?utm_medium=email&utm_source=footer> >>> . >>> For more options, visit https://groups.google.com/d/optout. >>> >> >> -- > 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 [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/vagrant-up/33b17ca9-7720-460d-8ac3-8fb3e3d1b99a%40googlegroups.com > <https://groups.google.com/d/msgid/vagrant-up/33b17ca9-7720-460d-8ac3-8fb3e3d1b99a%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- 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 [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0eynGgWsmE8Xc_N-2QqxrZEYyzfkCnNUQ%3DF1MZ6swWjjYg%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
