You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by Syed Ahmed <sa...@cloudops.com> on 2017/04/02 02:50:50 UTC

Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9 and VMWare

The SSH key doesn't work either. The default password for the centos
user is set at boot time to `password` which happens via the scripts
in the template itself. Coud-init is trying to fetch the metadata from
the default gateway instead of the VR (which which has a different IP
than the default GW)

On Fri, Mar 31, 2017 at 4:08 PM, Nux! <nu...@li.nux.ro> wrote:
> Hm, ok, so this is a corner case I'll need to cover then.
> But how did the password/sshkey feature work, if at all?
>
> --
> Sent from the Delta quadrant using Borg technology!
>
> Nux!
> www.nux.ro
>
> ----- Original Message -----
>> From: "Syed Ahmed" <sa...@cloudops.com>
>> To: "dev" <de...@cloudstack.apache.org>
>> Sent: Friday, 31 March, 2017 19:10:22
>> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9 and VMWare
>
>> I'm using a shared network so the VR is not the gateway.
>>
>> On Fri, Mar 31, 2017 at 12:49 PM, Nux! <nu...@li.nux.ro> wrote:
>>> Syed,
>>>
>>> I just checked and centos user is added to sudoers, if it was not added to your
>>> instance, then cloud-init did not complete properly.
>>> I have seen this in the past when the data source is not reached properly.
>>> I would double check the cloud-init logs if I were you, make sure eth0 was up
>>> properly and the VR accessible.
>>>
>>> http://storage1.static.itmages.com/i/17/0331/h_1490978820_8688282_efdf2d86f5.png
>>>
>>> --
>>> Sent from the Delta quadrant using Borg technology!
>>>
>>> Nux!
>>> www.nux.ro
>>>
>>> ----- Original Message -----
>>>> From: "Nux!" <nu...@li.nux.ro>
>>>> To: "dev" <de...@cloudstack.apache.org>
>>>> Sent: Friday, 31 March, 2017 17:01:43
>>>> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9
>>>> and VMWare
>>>
>>>> Thanks, I'll check.
>>>> Cloud-init is supposed to add the user to sudo.
>>>>
>>>> --
>>>> Sent from the Delta quadrant using Borg technology!
>>>>
>>>> Nux!
>>>> www.nux.ro
>>>>
>>>> ----- Original Message -----
>>>>> From: "Syed Ahmed" <sa...@cloudops.com>
>>>>> To: "dev" <de...@cloudstack.apache.org>
>>>>> Sent: Friday, 31 March, 2017 16:54:21
>>>>> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9
>>>>> and VMWare
>>>>
>>>>> Hi Nux,
>>>>>
>>>>> One of the things that I've seen is that the user centos is not added
>>>>> to the sudoers.
>>>>>
>>>>> On Fri, Mar 31, 2017 at 8:06 AM, Nux! <nu...@li.nux.ro> wrote:
>>>>>> Excellent, let me know if you hit any more issues.
>>>>>>
>>>>>> --
>>>>>> Sent from the Delta quadrant using Borg technology!
>>>>>>
>>>>>> Nux!
>>>>>> www.nux.ro
>>>>>>
>>>>>> ----- Original Message -----
>>>>>>> From: "Syed Ahmed" <sa...@cloudops.com>
>>>>>>> To: "dev" <de...@cloudstack.apache.org>
>>>>>>> Sent: Friday, 31 March, 2017 12:58:21
>>>>>>> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9
>>>>>>> and VMWare
>>>>>>
>>>>>>> Hey Nux,
>>>>>>>
>>>>>>> It worked! Thanks for fixing this. I am able to ping the VM now.
>>>>>>>
>>>>>>> On Fri, Mar 31, 2017 at 4:17 AM, Nux! <nu...@li.nux.ro> wrote:
>>>>>>>> Syed,
>>>>>>>>
>>>>>>>> I am aware of the renaming issue and avoid it, if you check my kickstart I
>>>>>>>> specifically add biosdevname=0 and net.ifnames=0
>>>>>>>> http://jenkins.openvm.eu/cloudstack/config/centos/centos7-vmware.cfg
>>>>>>>>
>>>>>>>> However yesterday Rohit brought to my attention the ova generation script
>>>>>>>> inserts a e1000 eth0 which apparently breaks things in certain situations.
>>>>>>>> https://github.com/apache/cloudstack/pull/2022#issuecomment-290339928
>>>>>>>>
>>>>>>>> I corrected the script and built a new image here, please give it a try.
>>>>>>>> http://jenkins.openvm.eu/cloudstack/centos/x86_64/centos-7-vmware.ova
>>>>>>>>
>>>>>>>> If the problem persists, can you go in single user mode and check the
>>>>>>>> /proc/cmdline and share it here?
>>>>>>>>
>>>>>>>> --
>>>>>>>> Sent from the Delta quadrant using Borg technology!
>>>>>>>>
>>>>>>>> Nux!
>>>>>>>> www.nux.ro
>>>>>>>>
>>>>>>>> ----- Original Message -----
>>>>>>>>> From: "Syed Ahmed" <sa...@cloudops.com>
>>>>>>>>> To: "Nux!" <nu...@li.nux.ro>
>>>>>>>>> Cc: "dev" <de...@cloudstack.apache.org>
>>>>>>>>> Sent: Thursday, 30 March, 2017 23:54:36
>>>>>>>>> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9
>>>>>>>>> and VMWare
>>>>>>>>
>>>>>>>>> I tried the one you provided however, it still has the same problem
>>>>>>>>> ... DHCP doesn't seem to pick up. I also see that the interface is not
>>>>>>>>> named eth0 .. could this be the problem? I can try changing the
>>>>>>>>> network driver and see if that helps. Will report back.
>>>>>>>>>
>>>>>>>>> On Thu, Mar 30, 2017 at 6:21 PM, Nux! <nu...@li.nux.ro> wrote:
>>>>>>>>>> Hi, I am working on a new set of templates, you can try this one:
>>>>>>>>>> http://jenkins.openvm.eu/cloudstack/centos/x86_64/centos-7-vmware.ova
>>>>>>>>>>
>>>>>>>>>> If still no luck, happy to debug if you can provide me an account. The only
>>>>>>>>>> templates I (can) test are the KVM ones.
>>>>>>>>>>
>>>>>>>>>> The official templates from various distros will not work properly as they
>>>>>>>>>> are openstack/aws focused.
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> On 30 March 2017 22:41:05 BST, Syed Ahmed <sa...@cloudops.com> wrote:
>>>>>>>>>>>
>>>>>>>>>>> osboxes also only has VMDK and not OVA. Cloudstack currently only
>>>>>>>>>>> supports OVA for VMWare
>>>>>>>>>>>
>>>>>>>>>>> On Thu, Mar 30, 2017 at 5:34 PM, Syed Ahmed <sa...@cloudops.com> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>>  The official CentOS site does not build OVA for VMWare unfortunately.
>>>>>>>>>>>>  I found something on osboxes. I am trying that.
>>>>>>>>>>>>
>>>>>>>>>>>>  http://pasteboard.co/PNdpMkn1C.png is the screenshot of the error btw
>>>>>>>>>>>>
>>>>>>>>>>>>  On Thu, Mar 30, 2017 at 5:30 PM, Syed Ahmed <sa...@cloudops.com> wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>  I thought the centos images from the official site did not have the
>>>>>>>>>>>>>  cloudstack datasource. I'll try and report!
>>>>>>>>>>>>>
>>>>>>>>>>>>>  On Thu, Mar 30, 2017 at 5:26 PM, Pierre-Luc Dion <pd...@cloudops.com>
>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>  Hi Syed, have you tried coud images from centos site, i think centos
>>>>>>>>>>>>>> build
>>>>>>>>>>>>>>  cloudimage as canonical for ubuntu.
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>  On Mar 30, 2017 5:24 PM, "Rafael Weingärtner"
>>>>>>>>>>>>>> <ra...@gmail.com>
>>>>>>>>>>>>>>  wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>  Attachments are not forwarded with emails.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>  On Thu, Mar 30, 2017 at 5:16 PM, Syed Ahmed <sa...@cloudops.com>
>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>  FYI I'm attaching the screenshot of the cloud-init error
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>  On Thu, Mar 30, 2017 at 5:14 PM, Syed Ahmed <sa...@cloudops.com>
>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>  Hi All,
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>  I'm trying to run a CentOS 7 template on VMWare and ACS 4.9 but
>>>>>>>>>>>>>>>>>  somehow cloud-init doesn't seem to pick up the IP form the VR. The
>>>>>>>>>>>>>>>>>  default template which is bundled with ACS (CentOS 5) works.
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>  I got the CentOS7 template from
>>>>>>>>>>>>>>>>>  http://dl.openvm.eu/cloudstack/centos/vanilla/7/
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>  x86_64/CentOS-7-x86_64-
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>  vanilla-vmware.ova
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>  Is there any setting that I need to do for this template? Are there
>>>>>>>>>>>>>>>>>  any other places I can get a working template for CentOS7 for
>>>>>>>>>>>>>>>>>  Cloudstack?
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>  Thanks,
>>>>>>>>>>>>>>>>>  -Syed
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>  --
>>>>>>>>>>>>>>>  Rafael Weingärtner
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> --
>> >> > >> >> > Sent from my Android device with K-9 Mail. Please excuse my brevity.

Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9 and VMWare

Posted by Syed Ahmed <sa...@cloudops.com>.
Hi Nux,

It is working now. Thanks for fixing it!

Thanks,
-Syed


On Thu, Apr 6, 2017 at 3:08 AM, Nux! <nu...@li.nux.ro> wrote:

> Syed,
>
> Can you try this and let me know if it works better?
> http://jenkins.openvm.eu/cloudstack/centos/x86_64/centos-7-vmware.ova
>
> I've removed NetworkManager
>
> --
> Sent from the Delta quadrant using Borg technology!
>
> Nux!
> www.nux.ro
>
> ----- Original Message -----
> > From: "Nux!" <nu...@li.nux.ro>
> > To: "dev" <de...@cloudstack.apache.org>
> > Sent: Wednesday, 5 April, 2017 19:21:13
> > Subject: Re: Need help in getting CentOS 7 templates to run on
> Cloudstack 4.9 and VMWare
>
> > Syed,
> >
> > NetworkManager strikes again! ... I'll make sure it disappears from the
> > template. Darn ...
> >
> > The centos user password as set by the kickstart is indeed "password" so
> the
> > template can be accessed should cloud-init fail.
> > I am not entirely at peace with this as could lead to security problems.
> >
> > The thing is, if cloud-init fails to retrieve the metadata, then it will
> not
> > continue the setup in which it adds the user to sudoers, setup swap etc
> etc.
> >
> > That is why you could login with "password" but everything else was
> broken.
> >
> > Thanks for spotting this.
> >
> > --
> > Sent from the Delta quadrant using Borg technology!
> >
> > Nux!
> > www.nux.ro
> >
> > ----- Original Message -----
> >> From: "Syed Ahmed" <sa...@cloudops.com>
> >> To: "dev" <de...@cloudstack.apache.org>
> >> Cc: "Nux!" <nu...@li.nux.ro>
> >> Sent: Wednesday, 5 April, 2017 16:41:27
> >> Subject: Re: Need help in getting CentOS 7 templates to run on
> Cloudstack 4.9
> >> and VMWare
> >
> >> Hi Nux,
> >>
> >> So I'm still having trouble with the template :)
> >>
> >> As per the configuration
> >> http://dl.openvm.eu/cloudstack/config/centos/centos7-vmware.cfg the
> >> `centos` user gets the password set to as `password` but is never added
> to
> >> the sudoers list. When does that happen? Also, From the cloud-init logs
> it
> >> looks like it's not using the DHCP server but the default gateway so
> things
> >> like ssh-key is not being set.
> >>
> >> Apr  5 15:17:26 syed-test cloud-init: Cloud-init v. 0.7.5 running
> >> 'init-local' at Wed, 05 Apr 2017 15:17:26 +0000. Up 8.99 seconds.
> >> Apr  5 15:18:13 syed-test cloud-init: Cloud-init v. 0.7.5 running
> 'init' at
> >> Wed, 05 Apr 2017 15:18:13 +0000. Up 16.84 seconds.
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> >> ++++++++++++++++++++++++++Net device info+++++++++++++++++++++++++++
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> >> +--------+------+--------------+---------------+-------------------+
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info: | Device |  Up  |
> >> Address    |      Mask     |     Hw-Address    |
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> >> +--------+------+--------------+---------------+-------------------+
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info: |  lo:   | True |
> >> 127.0.0.1   |   255.0.0.0   |         .         |
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info: | eth0:  | True |
> >> 172.31.0.130 | 255.255.254.0 | 06:5a:58:00:01:6a |
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> >> +--------+------+--------------+---------------+-------------------+
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> >> +++++++++++++++++++++++++++++++Route info++++++++++++++++++++++++++
> +++++
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> >> +-------+-------------+------------+---------------+--------
> ---+-------+
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info: | Route | Destination |
> >> Gateway   |    Genmask    | Interface | Flags |
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> >> +-------+-------------+------------+---------------+--------
> ---+-------+
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info: |   0   |   0.0.0.0   |
> >> 172.31.0.1 |    0.0.0.0    |    eth0   |   UG  |
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info: |   1   |  172.31.0.0 |
> >> 0.0.0.0   | 255.255.254.0 |    eth0   |   U   |
> >> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> >> +-------+-------------+------------+---------------+--------
> ---+-------+
> >> Apr  5 15:19:03 syed-test cloud-init: 2017-04-05 15:19:03,970 -
> >> url_helper.py[WARNING]: Calling '
> >> http://172.31.0.1//latest/meta-data/instance-id' failed [50/120s]:
> >> unexpected error ['NoneType' object has no attribute 'status_code']
> >> Apr  5 15:19:55 syed-test cloud-init: 2017-04-05 15:19:55,026 -
> >> url_helper.py[WARNING]: Calling '
> >> http://172.31.0.1//latest/meta-data/instance-id' failed [101/120s]:
> >> unexpected error ['NoneType' object has no attribute 'status_code']
> >> Apr  5 15:20:13 syed-test cloud-init: 2017-04-05 15:20:13,048 -
> >> url_helper.py[WARNING]: Calling '
> >> http://172.31.0.1//latest/meta-data/instance-id' failed [119/120s]:
> >> unexpected error ['NoneType' object has no attribute 'status_code']
> >> Apr  5 15:20:14 syed-test cloud-init: 2017-04-05 15:20:14,050 -
> >> DataSourceCloudStack.py[CRITICAL]: Giving up on waiting for the
> metadata
> >> from ['http://172.31.0.1//latest/meta-data/instance-id'] after 120
> seconds
> >> Apr  5 15:20:14 syed-test cloud-init: 2017-04-05 15:20:14,050 -
> >> util.py[WARNING]: No instance datasource found! Likely bad things to
> come!
> >>
> >> Looking at DataSourceCloudStack.py it seems like it is looking for
> leases
> >> in "/var/lib/dhclient", "/var/lib/dhcp" however the leases are located
> in
> >> "/var/lib/NetworkManager/" Do you know who maintains the
> >> DataSourceCloudStack.py? We fix this by either changing
> >> DataSourceCloudStack.py or by adding NM_CONTROLLED=no (and other conf
> >> params) in /etc/sysconfig/network-scripts/ifcfg-ethX . Let me know
> what you
> >> think.
> >>
> >> Thanks,
> >> -Syed
> >>
> >>
> >> On Mon, Apr 3, 2017 at 10:15 AM, Syed Ahmed <sa...@cloudops.com>
> wrote:
> >>
> >>> I'd love to see the 169.254.169.254 implemented. Maybe something we
> >>> can hack on at the CCC in Miami ;)
> >>>
> >>> On Mon, Apr 3, 2017 at 4:24 AM, Erik Weber <te...@gmail.com>
> wrote:
> >>> > On Mon, Apr 3, 2017 at 9:41 AM, Nux! <nu...@li.nux.ro> wrote:
> >>> >> Syed,
> >>> >>
> >>> >> AFAIK the standard behaviour that is baked in the password script as
> >>> well as in the cloud-init Cloudstack meta source is to try whichever
> >>> address provides the DHCP.
> >>> >>
> >>> >> Can't wait to see config drive implemented so we can get rid of all
> >>> these head aches.
> >>> >
> >>> > Or the 169.254.169.254 address implemented :-)
> >>> >
> >>> > --
> > >> > Erik
>

Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9 and VMWare

Posted by Nux! <nu...@li.nux.ro>.
Syed,

Can you try this and let me know if it works better?
http://jenkins.openvm.eu/cloudstack/centos/x86_64/centos-7-vmware.ova

I've removed NetworkManager

--
Sent from the Delta quadrant using Borg technology!

Nux!
www.nux.ro

----- Original Message -----
> From: "Nux!" <nu...@li.nux.ro>
> To: "dev" <de...@cloudstack.apache.org>
> Sent: Wednesday, 5 April, 2017 19:21:13
> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9 and VMWare

> Syed,
> 
> NetworkManager strikes again! ... I'll make sure it disappears from the
> template. Darn ...
> 
> The centos user password as set by the kickstart is indeed "password" so the
> template can be accessed should cloud-init fail.
> I am not entirely at peace with this as could lead to security problems.
> 
> The thing is, if cloud-init fails to retrieve the metadata, then it will not
> continue the setup in which it adds the user to sudoers, setup swap etc etc.
> 
> That is why you could login with "password" but everything else was broken.
> 
> Thanks for spotting this.
> 
> --
> Sent from the Delta quadrant using Borg technology!
> 
> Nux!
> www.nux.ro
> 
> ----- Original Message -----
>> From: "Syed Ahmed" <sa...@cloudops.com>
>> To: "dev" <de...@cloudstack.apache.org>
>> Cc: "Nux!" <nu...@li.nux.ro>
>> Sent: Wednesday, 5 April, 2017 16:41:27
>> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9
>> and VMWare
> 
>> Hi Nux,
>> 
>> So I'm still having trouble with the template :)
>> 
>> As per the configuration
>> http://dl.openvm.eu/cloudstack/config/centos/centos7-vmware.cfg the
>> `centos` user gets the password set to as `password` but is never added to
>> the sudoers list. When does that happen? Also, From the cloud-init logs it
>> looks like it's not using the DHCP server but the default gateway so things
>> like ssh-key is not being set.
>> 
>> Apr  5 15:17:26 syed-test cloud-init: Cloud-init v. 0.7.5 running
>> 'init-local' at Wed, 05 Apr 2017 15:17:26 +0000. Up 8.99 seconds.
>> Apr  5 15:18:13 syed-test cloud-init: Cloud-init v. 0.7.5 running 'init' at
>> Wed, 05 Apr 2017 15:18:13 +0000. Up 16.84 seconds.
>> Apr  5 15:18:13 syed-test cloud-init: ci-info:
>> ++++++++++++++++++++++++++Net device info+++++++++++++++++++++++++++
>> Apr  5 15:18:13 syed-test cloud-init: ci-info:
>> +--------+------+--------------+---------------+-------------------+
>> Apr  5 15:18:13 syed-test cloud-init: ci-info: | Device |  Up  |
>> Address    |      Mask     |     Hw-Address    |
>> Apr  5 15:18:13 syed-test cloud-init: ci-info:
>> +--------+------+--------------+---------------+-------------------+
>> Apr  5 15:18:13 syed-test cloud-init: ci-info: |  lo:   | True |
>> 127.0.0.1   |   255.0.0.0   |         .         |
>> Apr  5 15:18:13 syed-test cloud-init: ci-info: | eth0:  | True |
>> 172.31.0.130 | 255.255.254.0 | 06:5a:58:00:01:6a |
>> Apr  5 15:18:13 syed-test cloud-init: ci-info:
>> +--------+------+--------------+---------------+-------------------+
>> Apr  5 15:18:13 syed-test cloud-init: ci-info:
>> +++++++++++++++++++++++++++++++Route info+++++++++++++++++++++++++++++++
>> Apr  5 15:18:13 syed-test cloud-init: ci-info:
>> +-------+-------------+------------+---------------+-----------+-------+
>> Apr  5 15:18:13 syed-test cloud-init: ci-info: | Route | Destination |
>> Gateway   |    Genmask    | Interface | Flags |
>> Apr  5 15:18:13 syed-test cloud-init: ci-info:
>> +-------+-------------+------------+---------------+-----------+-------+
>> Apr  5 15:18:13 syed-test cloud-init: ci-info: |   0   |   0.0.0.0   |
>> 172.31.0.1 |    0.0.0.0    |    eth0   |   UG  |
>> Apr  5 15:18:13 syed-test cloud-init: ci-info: |   1   |  172.31.0.0 |
>> 0.0.0.0   | 255.255.254.0 |    eth0   |   U   |
>> Apr  5 15:18:13 syed-test cloud-init: ci-info:
>> +-------+-------------+------------+---------------+-----------+-------+
>> Apr  5 15:19:03 syed-test cloud-init: 2017-04-05 15:19:03,970 -
>> url_helper.py[WARNING]: Calling '
>> http://172.31.0.1//latest/meta-data/instance-id' failed [50/120s]:
>> unexpected error ['NoneType' object has no attribute 'status_code']
>> Apr  5 15:19:55 syed-test cloud-init: 2017-04-05 15:19:55,026 -
>> url_helper.py[WARNING]: Calling '
>> http://172.31.0.1//latest/meta-data/instance-id' failed [101/120s]:
>> unexpected error ['NoneType' object has no attribute 'status_code']
>> Apr  5 15:20:13 syed-test cloud-init: 2017-04-05 15:20:13,048 -
>> url_helper.py[WARNING]: Calling '
>> http://172.31.0.1//latest/meta-data/instance-id' failed [119/120s]:
>> unexpected error ['NoneType' object has no attribute 'status_code']
>> Apr  5 15:20:14 syed-test cloud-init: 2017-04-05 15:20:14,050 -
>> DataSourceCloudStack.py[CRITICAL]: Giving up on waiting for the metadata
>> from ['http://172.31.0.1//latest/meta-data/instance-id'] after 120 seconds
>> Apr  5 15:20:14 syed-test cloud-init: 2017-04-05 15:20:14,050 -
>> util.py[WARNING]: No instance datasource found! Likely bad things to come!
>> 
>> Looking at DataSourceCloudStack.py it seems like it is looking for leases
>> in "/var/lib/dhclient", "/var/lib/dhcp" however the leases are located in
>> "/var/lib/NetworkManager/" Do you know who maintains the
>> DataSourceCloudStack.py? We fix this by either changing
>> DataSourceCloudStack.py or by adding NM_CONTROLLED=no (and other conf
>> params) in /etc/sysconfig/network-scripts/ifcfg-ethX . Let me know what you
>> think.
>> 
>> Thanks,
>> -Syed
>> 
>> 
>> On Mon, Apr 3, 2017 at 10:15 AM, Syed Ahmed <sa...@cloudops.com> wrote:
>> 
>>> I'd love to see the 169.254.169.254 implemented. Maybe something we
>>> can hack on at the CCC in Miami ;)
>>>
>>> On Mon, Apr 3, 2017 at 4:24 AM, Erik Weber <te...@gmail.com> wrote:
>>> > On Mon, Apr 3, 2017 at 9:41 AM, Nux! <nu...@li.nux.ro> wrote:
>>> >> Syed,
>>> >>
>>> >> AFAIK the standard behaviour that is baked in the password script as
>>> well as in the cloud-init Cloudstack meta source is to try whichever
>>> address provides the DHCP.
>>> >>
>>> >> Can't wait to see config drive implemented so we can get rid of all
>>> these head aches.
>>> >
>>> > Or the 169.254.169.254 address implemented :-)
>>> >
>>> > --
> >> > Erik

Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9 and VMWare

Posted by Nux! <nu...@li.nux.ro>.
Syed,

NetworkManager strikes again! ... I'll make sure it disappears from the template. Darn ...

The centos user password as set by the kickstart is indeed "password" so the template can be accessed should cloud-init fail.
I am not entirely at peace with this as could lead to security problems.

The thing is, if cloud-init fails to retrieve the metadata, then it will not continue the setup in which it adds the user to sudoers, setup swap etc etc.

That is why you could login with "password" but everything else was broken.

Thanks for spotting this.

--
Sent from the Delta quadrant using Borg technology!

Nux!
www.nux.ro

----- Original Message -----
> From: "Syed Ahmed" <sa...@cloudops.com>
> To: "dev" <de...@cloudstack.apache.org>
> Cc: "Nux!" <nu...@li.nux.ro>
> Sent: Wednesday, 5 April, 2017 16:41:27
> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9 and VMWare

> Hi Nux,
> 
> So I'm still having trouble with the template :)
> 
> As per the configuration
> http://dl.openvm.eu/cloudstack/config/centos/centos7-vmware.cfg the
> `centos` user gets the password set to as `password` but is never added to
> the sudoers list. When does that happen? Also, From the cloud-init logs it
> looks like it's not using the DHCP server but the default gateway so things
> like ssh-key is not being set.
> 
> Apr  5 15:17:26 syed-test cloud-init: Cloud-init v. 0.7.5 running
> 'init-local' at Wed, 05 Apr 2017 15:17:26 +0000. Up 8.99 seconds.
> Apr  5 15:18:13 syed-test cloud-init: Cloud-init v. 0.7.5 running 'init' at
> Wed, 05 Apr 2017 15:18:13 +0000. Up 16.84 seconds.
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> ++++++++++++++++++++++++++Net device info+++++++++++++++++++++++++++
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +--------+------+--------------+---------------+-------------------+
> Apr  5 15:18:13 syed-test cloud-init: ci-info: | Device |  Up  |
> Address    |      Mask     |     Hw-Address    |
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +--------+------+--------------+---------------+-------------------+
> Apr  5 15:18:13 syed-test cloud-init: ci-info: |  lo:   | True |
> 127.0.0.1   |   255.0.0.0   |         .         |
> Apr  5 15:18:13 syed-test cloud-init: ci-info: | eth0:  | True |
> 172.31.0.130 | 255.255.254.0 | 06:5a:58:00:01:6a |
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +--------+------+--------------+---------------+-------------------+
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +++++++++++++++++++++++++++++++Route info+++++++++++++++++++++++++++++++
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +-------+-------------+------------+---------------+-----------+-------+
> Apr  5 15:18:13 syed-test cloud-init: ci-info: | Route | Destination |
> Gateway   |    Genmask    | Interface | Flags |
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +-------+-------------+------------+---------------+-----------+-------+
> Apr  5 15:18:13 syed-test cloud-init: ci-info: |   0   |   0.0.0.0   |
> 172.31.0.1 |    0.0.0.0    |    eth0   |   UG  |
> Apr  5 15:18:13 syed-test cloud-init: ci-info: |   1   |  172.31.0.0 |
> 0.0.0.0   | 255.255.254.0 |    eth0   |   U   |
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +-------+-------------+------------+---------------+-----------+-------+
> Apr  5 15:19:03 syed-test cloud-init: 2017-04-05 15:19:03,970 -
> url_helper.py[WARNING]: Calling '
> http://172.31.0.1//latest/meta-data/instance-id' failed [50/120s]:
> unexpected error ['NoneType' object has no attribute 'status_code']
> Apr  5 15:19:55 syed-test cloud-init: 2017-04-05 15:19:55,026 -
> url_helper.py[WARNING]: Calling '
> http://172.31.0.1//latest/meta-data/instance-id' failed [101/120s]:
> unexpected error ['NoneType' object has no attribute 'status_code']
> Apr  5 15:20:13 syed-test cloud-init: 2017-04-05 15:20:13,048 -
> url_helper.py[WARNING]: Calling '
> http://172.31.0.1//latest/meta-data/instance-id' failed [119/120s]:
> unexpected error ['NoneType' object has no attribute 'status_code']
> Apr  5 15:20:14 syed-test cloud-init: 2017-04-05 15:20:14,050 -
> DataSourceCloudStack.py[CRITICAL]: Giving up on waiting for the metadata
> from ['http://172.31.0.1//latest/meta-data/instance-id'] after 120 seconds
> Apr  5 15:20:14 syed-test cloud-init: 2017-04-05 15:20:14,050 -
> util.py[WARNING]: No instance datasource found! Likely bad things to come!
> 
> Looking at DataSourceCloudStack.py it seems like it is looking for leases
> in "/var/lib/dhclient", "/var/lib/dhcp" however the leases are located in
> "/var/lib/NetworkManager/" Do you know who maintains the
> DataSourceCloudStack.py? We fix this by either changing
> DataSourceCloudStack.py or by adding NM_CONTROLLED=no (and other conf
> params) in /etc/sysconfig/network-scripts/ifcfg-ethX . Let me know what you
> think.
> 
> Thanks,
> -Syed
> 
> 
> On Mon, Apr 3, 2017 at 10:15 AM, Syed Ahmed <sa...@cloudops.com> wrote:
> 
>> I'd love to see the 169.254.169.254 implemented. Maybe something we
>> can hack on at the CCC in Miami ;)
>>
>> On Mon, Apr 3, 2017 at 4:24 AM, Erik Weber <te...@gmail.com> wrote:
>> > On Mon, Apr 3, 2017 at 9:41 AM, Nux! <nu...@li.nux.ro> wrote:
>> >> Syed,
>> >>
>> >> AFAIK the standard behaviour that is baked in the password script as
>> well as in the cloud-init Cloudstack meta source is to try whichever
>> address provides the DHCP.
>> >>
>> >> Can't wait to see config drive implemented so we can get rid of all
>> these head aches.
>> >
>> > Or the 169.254.169.254 address implemented :-)
>> >
>> > --
>> > Erik

Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9 and VMWare

Posted by Syed Ahmed <sa...@cloudops.com>.
So I've opened a PR to fix this on the cloud-init side.

https://code.launchpad.net/~syed1/cloud-init/+git/cloud-init/+merge/322024

We need this because CentOS7 has NetworkManager as the default manager for
networking

On Wed, Apr 5, 2017 at 11:41 AM, Syed Ahmed <sa...@cloudops.com> wrote:

> Hi Nux,
>
> So I'm still having trouble with the template :)
>
> As per the configuration http://dl.openvm.eu/cloudstack/config/centos/
> centos7-vmware.cfg the `centos` user gets the password set to as
> `password` but is never added to the sudoers list. When does that happen?
> Also, From the cloud-init logs it looks like it's not using the DHCP server
> but the default gateway so things like ssh-key is not being set.
>
> Apr  5 15:17:26 syed-test cloud-init: Cloud-init v. 0.7.5 running
> 'init-local' at Wed, 05 Apr 2017 15:17:26 +0000. Up 8.99 seconds.
> Apr  5 15:18:13 syed-test cloud-init: Cloud-init v. 0.7.5 running 'init'
> at Wed, 05 Apr 2017 15:18:13 +0000. Up 16.84 seconds.
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> ++++++++++++++++++++++++++Net device info+++++++++++++++++++++++++++
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +--------+------+--------------+---------------+-------------------+
> Apr  5 15:18:13 syed-test cloud-init: ci-info: | Device |  Up  |
> Address    |      Mask     |     Hw-Address    |
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +--------+------+--------------+---------------+-------------------+
> Apr  5 15:18:13 syed-test cloud-init: ci-info: |  lo:   | True |
> 127.0.0.1   |   255.0.0.0   |         .         |
> Apr  5 15:18:13 syed-test cloud-init: ci-info: | eth0:  | True |
> 172.31.0.130 | 255.255.254.0 | 06:5a:58:00:01:6a |
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +--------+------+--------------+---------------+-------------------+
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +++++++++++++++++++++++++++++++Route info+++++++++++++++++++++++++++++++
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +-------+-------------+------------+---------------+-----------+-------+
> Apr  5 15:18:13 syed-test cloud-init: ci-info: | Route | Destination |
> Gateway   |    Genmask    | Interface | Flags |
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +-------+-------------+------------+---------------+-----------+-------+
> Apr  5 15:18:13 syed-test cloud-init: ci-info: |   0   |   0.0.0.0   |
> 172.31.0.1 |    0.0.0.0    |    eth0   |   UG  |
> Apr  5 15:18:13 syed-test cloud-init: ci-info: |   1   |  172.31.0.0 |
> 0.0.0.0   | 255.255.254.0 |    eth0   |   U   |
> Apr  5 15:18:13 syed-test cloud-init: ci-info:
> +-------+-------------+------------+---------------+-----------+-------+
> Apr  5 15:19:03 syed-test cloud-init: 2017-04-05 15:19:03,970 -
> url_helper.py[WARNING]: Calling 'http://172.31.0.1//latest/
> meta-data/instance-id' failed [50/120s]: unexpected error ['NoneType'
> object has no attribute 'status_code']
> Apr  5 15:19:55 syed-test cloud-init: 2017-04-05 15:19:55,026 -
> url_helper.py[WARNING]: Calling 'http://172.31.0.1//latest/
> meta-data/instance-id' failed [101/120s]: unexpected error ['NoneType'
> object has no attribute 'status_code']
> Apr  5 15:20:13 syed-test cloud-init: 2017-04-05 15:20:13,048 -
> url_helper.py[WARNING]: Calling 'http://172.31.0.1//latest/
> meta-data/instance-id' failed [119/120s]: unexpected error ['NoneType'
> object has no attribute 'status_code']
> Apr  5 15:20:14 syed-test cloud-init: 2017-04-05 15:20:14,050 -
> DataSourceCloudStack.py[CRITICAL]: Giving up on waiting for the metadata
> from ['http://172.31.0.1//latest/meta-data/instance-id'] after 120 seconds
> Apr  5 15:20:14 syed-test cloud-init: 2017-04-05 15:20:14,050 -
> util.py[WARNING]: No instance datasource found! Likely bad things to come!
>
> Looking at DataSourceCloudStack.py it seems like it is looking for leases
> in "/var/lib/dhclient", "/var/lib/dhcp" however the leases are located in
> "/var/lib/NetworkManager/" Do you know who maintains the
> DataSourceCloudStack.py? We fix this by either changing
> DataSourceCloudStack.py or by adding NM_CONTROLLED=no (and other conf
> params) in /etc/sysconfig/network-scripts/ifcfg-ethX . Let me know what
> you think.
>
> Thanks,
> -Syed
>
>
> On Mon, Apr 3, 2017 at 10:15 AM, Syed Ahmed <sa...@cloudops.com> wrote:
>
>> I'd love to see the 169.254.169.254 implemented. Maybe something we
>> can hack on at the CCC in Miami ;)
>>
>> On Mon, Apr 3, 2017 at 4:24 AM, Erik Weber <te...@gmail.com> wrote:
>> > On Mon, Apr 3, 2017 at 9:41 AM, Nux! <nu...@li.nux.ro> wrote:
>> >> Syed,
>> >>
>> >> AFAIK the standard behaviour that is baked in the password script as
>> well as in the cloud-init Cloudstack meta source is to try whichever
>> address provides the DHCP.
>> >>
>> >> Can't wait to see config drive implemented so we can get rid of all
>> these head aches.
>> >
>> > Or the 169.254.169.254 address implemented :-)
>> >
>> > --
>> > Erik
>>
>
>

Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9 and VMWare

Posted by Syed Ahmed <sa...@cloudops.com>.
Hi Nux,

So I'm still having trouble with the template :)

As per the configuration
http://dl.openvm.eu/cloudstack/config/centos/centos7-vmware.cfg the
`centos` user gets the password set to as `password` but is never added to
the sudoers list. When does that happen? Also, From the cloud-init logs it
looks like it's not using the DHCP server but the default gateway so things
like ssh-key is not being set.

Apr  5 15:17:26 syed-test cloud-init: Cloud-init v. 0.7.5 running
'init-local' at Wed, 05 Apr 2017 15:17:26 +0000. Up 8.99 seconds.
Apr  5 15:18:13 syed-test cloud-init: Cloud-init v. 0.7.5 running 'init' at
Wed, 05 Apr 2017 15:18:13 +0000. Up 16.84 seconds.
Apr  5 15:18:13 syed-test cloud-init: ci-info:
++++++++++++++++++++++++++Net device info+++++++++++++++++++++++++++
Apr  5 15:18:13 syed-test cloud-init: ci-info:
+--------+------+--------------+---------------+-------------------+
Apr  5 15:18:13 syed-test cloud-init: ci-info: | Device |  Up  |
Address    |      Mask     |     Hw-Address    |
Apr  5 15:18:13 syed-test cloud-init: ci-info:
+--------+------+--------------+---------------+-------------------+
Apr  5 15:18:13 syed-test cloud-init: ci-info: |  lo:   | True |
127.0.0.1   |   255.0.0.0   |         .         |
Apr  5 15:18:13 syed-test cloud-init: ci-info: | eth0:  | True |
172.31.0.130 | 255.255.254.0 | 06:5a:58:00:01:6a |
Apr  5 15:18:13 syed-test cloud-init: ci-info:
+--------+------+--------------+---------------+-------------------+
Apr  5 15:18:13 syed-test cloud-init: ci-info:
+++++++++++++++++++++++++++++++Route info+++++++++++++++++++++++++++++++
Apr  5 15:18:13 syed-test cloud-init: ci-info:
+-------+-------------+------------+---------------+-----------+-------+
Apr  5 15:18:13 syed-test cloud-init: ci-info: | Route | Destination |
Gateway   |    Genmask    | Interface | Flags |
Apr  5 15:18:13 syed-test cloud-init: ci-info:
+-------+-------------+------------+---------------+-----------+-------+
Apr  5 15:18:13 syed-test cloud-init: ci-info: |   0   |   0.0.0.0   |
172.31.0.1 |    0.0.0.0    |    eth0   |   UG  |
Apr  5 15:18:13 syed-test cloud-init: ci-info: |   1   |  172.31.0.0 |
0.0.0.0   | 255.255.254.0 |    eth0   |   U   |
Apr  5 15:18:13 syed-test cloud-init: ci-info:
+-------+-------------+------------+---------------+-----------+-------+
Apr  5 15:19:03 syed-test cloud-init: 2017-04-05 15:19:03,970 -
url_helper.py[WARNING]: Calling '
http://172.31.0.1//latest/meta-data/instance-id' failed [50/120s]:
unexpected error ['NoneType' object has no attribute 'status_code']
Apr  5 15:19:55 syed-test cloud-init: 2017-04-05 15:19:55,026 -
url_helper.py[WARNING]: Calling '
http://172.31.0.1//latest/meta-data/instance-id' failed [101/120s]:
unexpected error ['NoneType' object has no attribute 'status_code']
Apr  5 15:20:13 syed-test cloud-init: 2017-04-05 15:20:13,048 -
url_helper.py[WARNING]: Calling '
http://172.31.0.1//latest/meta-data/instance-id' failed [119/120s]:
unexpected error ['NoneType' object has no attribute 'status_code']
Apr  5 15:20:14 syed-test cloud-init: 2017-04-05 15:20:14,050 -
DataSourceCloudStack.py[CRITICAL]: Giving up on waiting for the metadata
from ['http://172.31.0.1//latest/meta-data/instance-id'] after 120 seconds
Apr  5 15:20:14 syed-test cloud-init: 2017-04-05 15:20:14,050 -
util.py[WARNING]: No instance datasource found! Likely bad things to come!

Looking at DataSourceCloudStack.py it seems like it is looking for leases
in "/var/lib/dhclient", "/var/lib/dhcp" however the leases are located in
"/var/lib/NetworkManager/" Do you know who maintains the
DataSourceCloudStack.py? We fix this by either changing
DataSourceCloudStack.py or by adding NM_CONTROLLED=no (and other conf
params) in /etc/sysconfig/network-scripts/ifcfg-ethX . Let me know what you
think.

Thanks,
-Syed


On Mon, Apr 3, 2017 at 10:15 AM, Syed Ahmed <sa...@cloudops.com> wrote:

> I'd love to see the 169.254.169.254 implemented. Maybe something we
> can hack on at the CCC in Miami ;)
>
> On Mon, Apr 3, 2017 at 4:24 AM, Erik Weber <te...@gmail.com> wrote:
> > On Mon, Apr 3, 2017 at 9:41 AM, Nux! <nu...@li.nux.ro> wrote:
> >> Syed,
> >>
> >> AFAIK the standard behaviour that is baked in the password script as
> well as in the cloud-init Cloudstack meta source is to try whichever
> address provides the DHCP.
> >>
> >> Can't wait to see config drive implemented so we can get rid of all
> these head aches.
> >
> > Or the 169.254.169.254 address implemented :-)
> >
> > --
> > Erik
>

Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9 and VMWare

Posted by Syed Ahmed <sa...@cloudops.com>.
I'd love to see the 169.254.169.254 implemented. Maybe something we
can hack on at the CCC in Miami ;)

On Mon, Apr 3, 2017 at 4:24 AM, Erik Weber <te...@gmail.com> wrote:
> On Mon, Apr 3, 2017 at 9:41 AM, Nux! <nu...@li.nux.ro> wrote:
>> Syed,
>>
>> AFAIK the standard behaviour that is baked in the password script as well as in the cloud-init Cloudstack meta source is to try whichever address provides the DHCP.
>>
>> Can't wait to see config drive implemented so we can get rid of all these head aches.
>
> Or the 169.254.169.254 address implemented :-)
>
> --
> Erik

Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9 and VMWare

Posted by Erik Weber <te...@gmail.com>.
On Mon, Apr 3, 2017 at 9:41 AM, Nux! <nu...@li.nux.ro> wrote:
> Syed,
>
> AFAIK the standard behaviour that is baked in the password script as well as in the cloud-init Cloudstack meta source is to try whichever address provides the DHCP.
>
> Can't wait to see config drive implemented so we can get rid of all these head aches.

Or the 169.254.169.254 address implemented :-)

-- 
Erik

Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9 and VMWare

Posted by Nux! <nu...@li.nux.ro>.
Syed,

AFAIK the standard behaviour that is baked in the password script as well as in the cloud-init Cloudstack meta source is to try whichever address provides the DHCP.

Can't wait to see config drive implemented so we can get rid of all these head aches.

--
Sent from the Delta quadrant using Borg technology!

Nux!
www.nux.ro

----- Original Message -----
> From: "Syed Ahmed" <sa...@cloudops.com>
> To: "dev" <de...@cloudstack.apache.org>
> Sent: Sunday, 2 April, 2017 03:50:50
> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9 and VMWare

> The SSH key doesn't work either. The default password for the centos
> user is set at boot time to `password` which happens via the scripts
> in the template itself. Coud-init is trying to fetch the metadata from
> the default gateway instead of the VR (which which has a different IP
> than the default GW)
> 
> On Fri, Mar 31, 2017 at 4:08 PM, Nux! <nu...@li.nux.ro> wrote:
>> Hm, ok, so this is a corner case I'll need to cover then.
>> But how did the password/sshkey feature work, if at all?
>>
>> --
>> Sent from the Delta quadrant using Borg technology!
>>
>> Nux!
>> www.nux.ro
>>
>> ----- Original Message -----
>>> From: "Syed Ahmed" <sa...@cloudops.com>
>>> To: "dev" <de...@cloudstack.apache.org>
>>> Sent: Friday, 31 March, 2017 19:10:22
>>> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9
>>> and VMWare
>>
>>> I'm using a shared network so the VR is not the gateway.
>>>
>>> On Fri, Mar 31, 2017 at 12:49 PM, Nux! <nu...@li.nux.ro> wrote:
>>>> Syed,
>>>>
>>>> I just checked and centos user is added to sudoers, if it was not added to your
>>>> instance, then cloud-init did not complete properly.
>>>> I have seen this in the past when the data source is not reached properly.
>>>> I would double check the cloud-init logs if I were you, make sure eth0 was up
>>>> properly and the VR accessible.
>>>>
>>>> http://storage1.static.itmages.com/i/17/0331/h_1490978820_8688282_efdf2d86f5.png
>>>>
>>>> --
>>>> Sent from the Delta quadrant using Borg technology!
>>>>
>>>> Nux!
>>>> www.nux.ro
>>>>
>>>> ----- Original Message -----
>>>>> From: "Nux!" <nu...@li.nux.ro>
>>>>> To: "dev" <de...@cloudstack.apache.org>
>>>>> Sent: Friday, 31 March, 2017 17:01:43
>>>>> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9
>>>>> and VMWare
>>>>
>>>>> Thanks, I'll check.
>>>>> Cloud-init is supposed to add the user to sudo.
>>>>>
>>>>> --
>>>>> Sent from the Delta quadrant using Borg technology!
>>>>>
>>>>> Nux!
>>>>> www.nux.ro
>>>>>
>>>>> ----- Original Message -----
>>>>>> From: "Syed Ahmed" <sa...@cloudops.com>
>>>>>> To: "dev" <de...@cloudstack.apache.org>
>>>>>> Sent: Friday, 31 March, 2017 16:54:21
>>>>>> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9
>>>>>> and VMWare
>>>>>
>>>>>> Hi Nux,
>>>>>>
>>>>>> One of the things that I've seen is that the user centos is not added
>>>>>> to the sudoers.
>>>>>>
>>>>>> On Fri, Mar 31, 2017 at 8:06 AM, Nux! <nu...@li.nux.ro> wrote:
>>>>>>> Excellent, let me know if you hit any more issues.
>>>>>>>
>>>>>>> --
>>>>>>> Sent from the Delta quadrant using Borg technology!
>>>>>>>
>>>>>>> Nux!
>>>>>>> www.nux.ro
>>>>>>>
>>>>>>> ----- Original Message -----
>>>>>>>> From: "Syed Ahmed" <sa...@cloudops.com>
>>>>>>>> To: "dev" <de...@cloudstack.apache.org>
>>>>>>>> Sent: Friday, 31 March, 2017 12:58:21
>>>>>>>> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9
>>>>>>>> and VMWare
>>>>>>>
>>>>>>>> Hey Nux,
>>>>>>>>
>>>>>>>> It worked! Thanks for fixing this. I am able to ping the VM now.
>>>>>>>>
>>>>>>>> On Fri, Mar 31, 2017 at 4:17 AM, Nux! <nu...@li.nux.ro> wrote:
>>>>>>>>> Syed,
>>>>>>>>>
>>>>>>>>> I am aware of the renaming issue and avoid it, if you check my kickstart I
>>>>>>>>> specifically add biosdevname=0 and net.ifnames=0
>>>>>>>>> http://jenkins.openvm.eu/cloudstack/config/centos/centos7-vmware.cfg
>>>>>>>>>
>>>>>>>>> However yesterday Rohit brought to my attention the ova generation script
>>>>>>>>> inserts a e1000 eth0 which apparently breaks things in certain situations.
>>>>>>>>> https://github.com/apache/cloudstack/pull/2022#issuecomment-290339928
>>>>>>>>>
>>>>>>>>> I corrected the script and built a new image here, please give it a try.
>>>>>>>>> http://jenkins.openvm.eu/cloudstack/centos/x86_64/centos-7-vmware.ova
>>>>>>>>>
>>>>>>>>> If the problem persists, can you go in single user mode and check the
>>>>>>>>> /proc/cmdline and share it here?
>>>>>>>>>
>>>>>>>>> --
>>>>>>>>> Sent from the Delta quadrant using Borg technology!
>>>>>>>>>
>>>>>>>>> Nux!
>>>>>>>>> www.nux.ro
>>>>>>>>>
>>>>>>>>> ----- Original Message -----
>>>>>>>>>> From: "Syed Ahmed" <sa...@cloudops.com>
>>>>>>>>>> To: "Nux!" <nu...@li.nux.ro>
>>>>>>>>>> Cc: "dev" <de...@cloudstack.apache.org>
>>>>>>>>>> Sent: Thursday, 30 March, 2017 23:54:36
>>>>>>>>>> Subject: Re: Need help in getting CentOS 7 templates to run on Cloudstack 4.9
>>>>>>>>>> and VMWare
>>>>>>>>>
>>>>>>>>>> I tried the one you provided however, it still has the same problem
>>>>>>>>>> ... DHCP doesn't seem to pick up. I also see that the interface is not
>>>>>>>>>> named eth0 .. could this be the problem? I can try changing the
>>>>>>>>>> network driver and see if that helps. Will report back.
>>>>>>>>>>
>>>>>>>>>> On Thu, Mar 30, 2017 at 6:21 PM, Nux! <nu...@li.nux.ro> wrote:
>>>>>>>>>>> Hi, I am working on a new set of templates, you can try this one:
>>>>>>>>>>> http://jenkins.openvm.eu/cloudstack/centos/x86_64/centos-7-vmware.ova
>>>>>>>>>>>
>>>>>>>>>>> If still no luck, happy to debug if you can provide me an account. The only
>>>>>>>>>>> templates I (can) test are the KVM ones.
>>>>>>>>>>>
>>>>>>>>>>> The official templates from various distros will not work properly as they
>>>>>>>>>>> are openstack/aws focused.
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> On 30 March 2017 22:41:05 BST, Syed Ahmed <sa...@cloudops.com> wrote:
>>>>>>>>>>>>
>>>>>>>>>>>> osboxes also only has VMDK and not OVA. Cloudstack currently only
>>>>>>>>>>>> supports OVA for VMWare
>>>>>>>>>>>>
>>>>>>>>>>>> On Thu, Mar 30, 2017 at 5:34 PM, Syed Ahmed <sa...@cloudops.com> wrote:
>>>>>>>>>>>>>
>>>>>>>>>>>>>  The official CentOS site does not build OVA for VMWare unfortunately.
>>>>>>>>>>>>>  I found something on osboxes. I am trying that.
>>>>>>>>>>>>>
>>>>>>>>>>>>>  http://pasteboard.co/PNdpMkn1C.png is the screenshot of the error btw
>>>>>>>>>>>>>
>>>>>>>>>>>>>  On Thu, Mar 30, 2017 at 5:30 PM, Syed Ahmed <sa...@cloudops.com> wrote:
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>  I thought the centos images from the official site did not have the
>>>>>>>>>>>>>>  cloudstack datasource. I'll try and report!
>>>>>>>>>>>>>>
>>>>>>>>>>>>>>  On Thu, Mar 30, 2017 at 5:26 PM, Pierre-Luc Dion <pd...@cloudops.com>
>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>  Hi Syed, have you tried coud images from centos site, i think centos
>>>>>>>>>>>>>>> build
>>>>>>>>>>>>>>>  cloudimage as canonical for ubuntu.
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>  On Mar 30, 2017 5:24 PM, "Rafael Weingärtner"
>>>>>>>>>>>>>>> <ra...@gmail.com>
>>>>>>>>>>>>>>>  wrote:
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>  Attachments are not forwarded with emails.
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>  On Thu, Mar 30, 2017 at 5:16 PM, Syed Ahmed <sa...@cloudops.com>
>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>  FYI I'm attaching the screenshot of the cloud-init error
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>  On Thu, Mar 30, 2017 at 5:14 PM, Syed Ahmed <sa...@cloudops.com>
>>>>>>>>>>>>>>>>> wrote:
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>  Hi All,
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>  I'm trying to run a CentOS 7 template on VMWare and ACS 4.9 but
>>>>>>>>>>>>>>>>>>  somehow cloud-init doesn't seem to pick up the IP form the VR. The
>>>>>>>>>>>>>>>>>>  default template which is bundled with ACS (CentOS 5) works.
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>  I got the CentOS7 template from
>>>>>>>>>>>>>>>>>>  http://dl.openvm.eu/cloudstack/centos/vanilla/7/
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>  x86_64/CentOS-7-x86_64-
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>  vanilla-vmware.ova
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>  Is there any setting that I need to do for this template? Are there
>>>>>>>>>>>>>>>>>>  any other places I can get a working template for CentOS7 for
>>>>>>>>>>>>>>>>>>  Cloudstack?
>>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>>  Thanks,
>>>>>>>>>>>>>>>>>>  -Syed
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>>  --
>>>>>>>>>>>>>>>>  Rafael Weingärtner
>>>>>>>>>>>>>>>
>>>>>>>>>>>>>>>
>>>>>>>>>>>
>>>>>>>>>>> --
> >> >> > >> >> > Sent from my Android device with K-9 Mail. Please excuse my brevity.