Wednesday, 2017-07-05

jamielennoxhey all, is there a dib element for setting hostname and/or /etc/hosts00:17
jamielennox?00:17
jamielennoxsuddenly getting a different failure with sudo because the hostname (ubuntu) is not resolvable - but it takes ~60 seconds to determine this00:18
*** openstackgerrit has joined #openstack-dib00:33
openstackgerritJamie Lennox proposed openstack/diskimage-builder master: Don't use du -x to calculate image size  https://review.openstack.org/47673200:33
jamielennoxianw: ping re hostname setting?00:42
jamielennoxsorry, probably shouldn't single you out for questions, but you're generally the only one here in my tx00:43
jamielennoxtz00:43
ianwjamielennox: hi, sorry, distracted .01:17
ianwumm, .... glean?01:17
jamielennoxianw: yea, sorry, should have just waited till you saw it01:18
ianwcloud-init i guess?  are you sure that it's the hostname issue causing the hang?  i see that all the time, it might be a red herring01:18
jamielennoxhmm, so glean is something i've not poked at much, afaik we're not using it, but it might have been put in by others01:19
jamielennoxi also see the message all the time, however for whatever reason on my most recent image build it takes a minute to actually check it can't resolve it01:19
jamielennoxwhich blows up ansible01:19
ianwhmm, are you using infra elements?01:20
jamielennoxno01:20
jamielennoxhowever in grepping i don't see glean anywhere in those images01:20
jamielennoxs/images/elements01:20
ianwyeah, probably using cloud-init?  you maybe don't want glean, it depends i guess01:20
jamielennoxianw: not using either as i understand it01:21
ianwhmm, ok, just dhcp to get an address?  it doesn't set things?01:21
jamielennoxyea, afaik we just bake users, keys etc into the image and it just gets an ip on boot01:22
jamielennoxwhich i'm going to guess is just dhclient01:22
jamielennoxbut i'm not sure that's actually sufficient01:22
jamielennoxoh, maybe:01:23
jamielennox  system-glean.slice                                                loaded active active    system-glean.slice01:23
ianwso that would, iirc, grab a hostname from the config-drive01:25
jamielennoxhmm, ok i think i have a bigger problem just that sudo was the first thing to catch it01:32
jamielennoxall outbound networking is failing01:33
ianw:)01:33
jamielennoxsorry for the interruption01:34
*** chhavi has joined #openstack-dib04:04
*** chhavi has quit IRC04:38
*** chhavi has joined #openstack-dib04:41
*** andreas-f has joined #openstack-dib04:42
*** chhavi has quit IRC04:44
*** mtreinish has quit IRC04:44
jamielennoxany idea what would cause: lsattr: Operation not supported While reading flags on /tmp/dib_build.IUDu73Ng/mnt/etc/resolv.conf04:50
jamielennoxin a finalize i'm doing ln -sf /run/resolvconf/resolv.conf /etc/resolv.conf04:51
jamielennoxwhich I'm not sure exists at the time04:51
*** mtreinish has joined #openstack-dib04:51
jamielennoxexcellent, resolv.conf is handled differently, and -infra has an rc.local hack05:20
*** andreas-f has quit IRC05:44
*** andreas-f has joined #openstack-dib06:10
jamielennoxis there a way to make nodepool builder and dib build in a directory other than /tmp06:31
*** yolanda_ has joined #openstack-dib07:01
*** andreas-f has quit IRC07:23
*** hashar has joined #openstack-dib08:13
*** aparnav has joined #openstack-dib09:26
*** appu103 has joined #openstack-dib09:47
*** aparnav has quit IRC09:50
*** hashar has quit IRC11:42
*** hashar has joined #openstack-dib11:51
*** appu103 has quit IRC11:59
*** appu103 has joined #openstack-dib12:02
*** appu103 has quit IRC12:06
*** farosas_ has joined #openstack-dib12:13
clarkbjamielennox: yes dib honors TMPDIR iirc. Look at infras builder config we set it to be /opt/dib_tmp15:06
openstackgerritBen Kero proposed openstack/diskimage-builder feature/v2: Revert "Fix #1627402: fix grub2 element for ubuntu xenial"  https://review.openstack.org/48067116:45
*** hashar has quit IRC17:02
*** farosas_ has quit IRC21:05
openstackgerritBen Kero proposed openstack/diskimage-builder feature/v2: Revert "Fix #1627402: fix grub2 element for ubuntu xenial"  https://review.openstack.org/48067121:50
bkero(rebase)21:50
jamielennoxianw: so im' wondering if there is a good way to handle resolv.conf23:27
jamielennoxthere's a few things i've noticed23:28
ianwjamielennox: it definitely seems like something the dhcp client should handle?23:28
jamielennoxianw: so dhclient is getting the right addresses, and passing it to resolvconf (ubuntu)23:29
jamielennoxhowever /etc/resolv.conf in my image is a real file that was copied off the builder23:29
jamielennoxif i symlink /etc/resolv.conf to /run/resolvconf/resolv.conf i get dns back23:30
jamielennoxbut i can't see a way to do that correctly in an element23:30
jamielennoxfirst problem is: https://github.com/openstack/diskimage-builder/blob/master/diskimage_builder/lib/img-functions#L10823:30
jamielennoxlsattr is not supported on symlinks so that fails, also i *think* that it's not supported on aufs so it occassionally fails there as well23:31
ianwhmmm ... lots of layers there :)23:32
jamielennoxyea23:33
ianwi have no idea why we do this swizzle in create_base() ... will dig a bit23:35
jamielennoxit looks like -infra hacks it up: https://github.com/openstack-infra/project-config/blob/master/nodepool/elements/nodepool-base/finalise.d/89-unbound#L9223:36
jamielennoxianw: it makes a certain amount of sense23:36
ianwit's been there since the original imports by lifeless23:36
jamielennoxwhen you're in the chroot and stuff you have to be able to apt install23:36
ianwyes, ok, so we copy in the host system then uncopy it later23:37
jamielennoxyep, but the lsattr immutable thing is a weird choice23:37
jamielennoxthe commit for that seems to be related to unbound23:38
ianwthat came later ... https://review.openstack.org/#/c/90504/23:38
jamielennoxyep - oh, i see what you're saying23:39
jamielennoxso yea, create base makes a backup of resolv.conf23:39
jamielennoxthen we install a new resolv.conf in the image23:39
jamielennoxs/image/elements23:39
jamielennoxthen at finalize it restores the old one23:39
jamielennoxand clobbers what we installed23:40
ianwhmm, so the "don't clobber" is failing because it's a symlink, or it's on aufs ... or both?23:43
jamielennoxi don't know, i'm not exactly sure how to break in there23:45
jamielennoxif lsattr returns 1 then i'm not sure how that statement falls out23:45
ianwthat would fall into the else23:46
jamielennoxbut what i want there is a symlink23:46
ianwshould be traced with "-x"?23:46
jamielennox4897 2017-07-05 07:26:05,675 INFO nodepool.image.build.ubuntu-xenial: b'lsattr: Operation not supported While reading flags on /tmp/dib_build.cA5n6i4q/mnt/etc/resolv.conf'23:49
jamielennox   1 2017-07-05 07:26:05,885 INFO nodepool.image.build.ubuntu-xenial: b'Unmount /tmp/dib_build.cA5n6i4q/mnt/sys'23:49
jamielennox   2 2017-07-05 07:26:05,905 INFO nodepool.image.build.ubuntu-xenial: b'Unmount /tmp/dib_build.cA5n6i4q/mnt/proc'23:49
jamielennox   3 2017-07-05 07:26:05,921 INFO nodepool.image.build.ubuntu-xenial: b'Unmount /tmp/dib_build.cA5n6i4q/mnt/dev/pts'23:49
jamielennox   4 2017-07-05 07:26:05,937 INFO nodepool.image.build.ubuntu-xenial: b'Unmount /tmp/dib_build.cA5n6i4q/mnt/dev'23:49
ianwoh, it hits the errexit23:49
ianwif [ -L $TMP_MOUNT_PATH/etc/resolv.conf.ORIG ]23:50
ianwi think we handle this.  i guess the main problem is that lsattr failure23:51
ianw$ sudo lsattr /etc/resolv.conf23:51
ianwlsattr: Operation not supported While reading flags on /etc/resolv.conf23:51
ianwthough it is not a aufs issue, that's local23:51
ianwthe plot thickens23:51
*** owalsh has quit IRC23:53

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