/srv/irclogs.ubuntu.com/2014/07/31/#cloud-init.txt

=== harlowja is now known as harlowja_away
=== praneshp_ is now known as praneshp
=== evilissimo|afk is now known as evilissimo
nvucinichi guys, anyone here? :)  have some questions about cloud-init 09:28
harmwso, I've specified the EXTERNAL_DHCPC=y thingy in buildroot.config, but it still doesn't execute /sbin/ifupdown10:34
harmwand calling /sbin/ifupdown directly complains about unknown mappings10:34
harmwso prhaps I should take the easy route afterall, and just change udhcpc to /sbin/bla :p10:34
nvucinichelo, i have instaled cloud-init on my centos machine, and i am stuck now. 10:41
nvucinicit's some strange configuration with centos on hyperv 10:42
harmwin which way are you stuck :)10:42
nvucinicis there any chance i could add cloud-init config file over mounted disk  or url ?10:42
nvucinicwell i dont really know what to do now :)10:42
nvucinici want to specify configuration to run at machine boot 10:42
nvucinicone time 10:42
nvucinici know what i want in cloud-config and how to define it 10:43
harmwyou have an amazone-like api machine setup?10:43
harmwlike openstack, cloudstack 10:43
nvucinici have default installation from yum packet manager on centos10:43
nvucinicso, that would be - no10:43
harmwah10:43
harmwcloud-init is used to configure cloud images10:43
harmwand basically, that requirs a metadata service in your network10:43
harmw- the web url you mentioned10:44
harmwto download the config from10:44
harmwusualy lives at http://169.254.169.254/10:44
nvucinicah 10:44
nvucinicok, is there any way to conigure metadata service only ? 10:44
nvucinici deploy instances in "cloud" manner 10:45
nvucinichmm... maybe i could get some layer in front of hyperv ?10:45
harmwjust make sure there is a metadata api accessible at that ip, and make sure your vm is able to reach it :)10:45
nvucinicok, but how to install // configure metadata api ?10:46
nvucinicit's part of openstack right ?10:46
harmwbtw, cloud-init can also use configdrive - eg. put the json config on a usb stick (well, image) and add that to the vm10:46
harmwyea10:46
harmwor any other cloud platform10:46
harmwdepending on your environment, you could also script something yourself10:47
harmwafaik, using configdrive would be sufficient for environments that lack a metadata service - like yours10:47
nvucinicgreat10:48
harmwhm, just don't know since whn cloud-init supports it...10:49
nvucinicthis was very helpful 10:49
pareshhey my cloud-init process is not able to get user-data file on my aws setup10:49
harmwwhy not :)10:49
paresh2014-02-12 16:16:13,268 - util.py[DEBUG]: Writing to /var/lib/cloud/instances/i-xxxxxxx/user-data.txt - wb: [384] 0 bytes10:49
pareshit says 0 bytes downloaded10:49
harmwindeed it does10:49
nvucinicdo i need to setup something extra for configdrive?10:49
harmwreadthdocs.org :)10:50
harmwabout it format10:50
harmwdocs.openstack.org/user-guide/content/config-drive.html10:51
nvucinicyeah, find it 10:51
harmwgreat :)10:51
nvucinichttp://developer.openstack.org/api-ref.htmlext_config_drive.html not working  :|10:52
harmwparesh: you could try curl on the user-data url from within the instance10:52
harmwhttp://docs.openstack.org/user-guide/content/enable_config_drive.html10:53
harmwnvucinic: I think you should be able to use that10:53
smosernvucinic, you can use the 'nocloud' datasource, and 'seed_from' to probably accomplish what you want.14:05
smoseror you could configure on the disk the url to the ec2 mtadata service and then stand something like that up.14:05
smosernvucinic, http://bazaar.launchpad.net/~cloud-init-dev/cloud-init/trunk/view/head:/doc/examples/cloud-config-datasources.txt14:06
smoserthat shows how to configure 'NoCloud' to give it a 'seedfrom'14:06
smoserthen just stand something up there with user-data nd meta-data as described in 14:07
smoserhttp://bazaar.launchpad.net/~cloud-init-dev/cloud-init/trunk/files/head:/doc/examples/seed/14:07
smoseryou can also pass the seedfrom informatoin on the kernel cmdline if you had easier access to that.14:07
nvucinicsmoser: great, thank you14:09
=== evilissimo is now known as evilissimo|afk
smoserharmw, what complains about unknown mappings ?15:08
smoseryour patch surely seemed sane to me.15:08
=== evilissimo|afk is now known as evilissimo
=== evilissimo is now known as evilissimo|afk
=== evilissimo|afk is now known as evilissimo
harmwnah, forget it :)16:05
harmwits almost done, Ill push the last bits tonight16:05
=== evilissimo is now known as evilissimo|afk
=== evilissimo|afk is now known as evilissimo
=== evilissimo is now known as evilissimo|afk
=== harlowja_away is now known as harlowja
harmwsmoser: https://code.launchpad.net/~harmw/cirros/udhcpc-wrapper19:37
harmwive had to build this patchd into my updated buildroot env, since thats the one that builds on CentOS19:38
harmwthough it should compile without issues on ubuntu19:39
harmwso: https://code.launchpad.net/~harmw/cirros/udhcpc-wrapper/+merge/22911419:44
smoserharmw, seems odd you'd have to set that.19:48
smoserCONFIG_FEATURE_IFUPDOWN_EXTERNAL_DHCP19:48
smosersince i thought previously we were running ghrough that code19:48
smoserin order to get udchpc invoked with the options19:48
harmwthere is a big if EXTERNAL_BLABLA around the part that decides which dhcp client to run19:51
harmwit's N by default19:51
smoserso how does udchpc run in 0.3.2 ?20:00
smoserthat seems "external" :)20:00
harmwplease check out static int FAST_FUNC dhcp_up(struct interface_defn_t *ifd, execfn *exec) in ifupdown.c20:02
harmwit ends with:20:02
harmwreturn execute("udhcpc " UDHCPC_CMD_OPTIONS " -p /var/run/udhcpc.%iface%.pid "20:02
harmwand before that function is the stuff that concerns CONFIGURE_FEATURE_IFUPblablabla20:03
harmwthis all revolvs around L575 :)20:04
smoserah. ok.20:12
smoseri believe you20:12
smoser:)20:12
smoserharmw, that looks really nice.20:16
smoseractually..20:17
smoserit looks to me like its busted for non-eth020:17
smoseras when busybox calls us, it will set that in the environment i presume20:17
smoserbut then you override it by reaading /etc/default/udchppc20:17
smoserand also i don tlike the global 'DISABLED'20:17
harmwyou dont?21:12
harmwand that interface... hm, I suppose I shouldve paid a little more attention to that21:12
harmwill just remove that from the config file :)21:12
harmwand disabled as well, if you dont like it21:13
harmwah, so22:28
harmwcommnting between watching netflix isn't very wise either :p22:29
harmwsmoser: udhcpc uses eth0 by default22:29
harmwso using a config file to make it changable for whatever reason shouldn't be a problem22:29
harmwso, we can configure on which interface we want it to acquire an address22:31
harmwand udhdpc will in turn set $interface with the interface it got an adress from/on22:31
harmwhttp://git.busybox.net/busybox/tree/networking/udhcp/README.udhcpc?h=1_1_stable&id=179f41778880d0a233435f5c9ed04e17316f479a#n73 22:32
harmwwhats wrong with DISABLED, or is there some other easier way of saying 'no, please move on and leave me without an address!'?22:34
smoserharmw, hm..23:47
smoseri was thinking when someone types:23:47
smoser ifup eth023:47
smoserand /etc/networking/interfaces says to bring eth0 up as dhcp23:47
smoserthen 'ifup' invokes cirros-dhcpc23:48
smoseras:23:48
smoser  cirros-dhcpc up23:48
smoseri assumed it somehow conveyed which interface should be brought up23:48
smoserharmw, yeah, so our command there (line 33 of https://code.launchpad.net/~harmw/cirros/udhcpc-wrapper/+merge/229114)23:50
smoserneeds to :23:50
smoser cirros-dhcpc up %iface%23:51
smoserat least. and can't see why not put in some othe other things avialalbe (like leasetime).23:51
smoserthen, when cirros-dhcpc calls udhcpc it will pass on the provided %iface.23:52
smoseri suspect then that udhcpc then stuffs that interface into the environment23:52
smoserand we'll be able to expect it in environment on renew|bound23:52

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!