/srv/irclogs.ubuntu.com/2017/10/19/#juju.txt

fallenourwhat api runs on port 17070?01:29
=== frankban|afk is now known as frankban
sri_I am exploring the possibility of setting k8 cluster using juju/conjure-up on aws. could someone help me find a working solution to set kubernetes cloud-provider as aws?14:12
sri_I tried below commands and reboot the containers but containers does not come online anymore14:13
sri_juju ssh MACHINE-NUMBER "sudo snap set kube-apiserver cloud-provider=aws"; juju ssh MACHINE-NUMBER "sudo snap set kube-controller-manager cloud-provider=aws"; juju ssh MACHINE-NUMBER "sudo snap set kubelet cloud-provider=aws"14:13
tvansteenburghsri_: if you deploy to aws with conjure-up, the cloud provider is set for you14:18
tvansteenburghsri_: in other words, you don't have to set it manually14:19
sri_tvansteenburgh, i tried juju ssh MACHINE-NUMBER "sudo snap get kube-apiserver"; which returns nothing14:43
tvansteenburghsri_: cat /var/snap/kube-apiserver/current/args14:55
sri_tvansteenburgh: https://ghostbin.com/paste/xq63r is the output for juju status15:12
sri_tvansteenburgh: added the output of juju ssh 1 'cat /var/snap/kube-apiserver/current/args' also in the same link15:15
sri_tvansteenburgh: sorry, pastebin is down hence using ghostbin, not sure if it is the best alternate :-)15:16
ryebotsri_: Can you share the output of `kubectl get po --all-namespaces` ?15:25
sri_ryebot: Actually i just pasted very detailed log of yaml files, pod description etc in the same link15:27
ryebotsri_: excellent, taking a look15:28
sri_ryebot: just added the output of kubectl get po --all-namespaces at the end of the doc...please help me here15:29
ryebotsri_: any idea what's going on with "postgres_pv"?15:29
sri_ryebot: i created the volume vol-0445bc1b6acae0622 in aws and referred to it here15:30
sri_ryebot: Is it not correct?15:31
ryebotsri_: I'm not sure. It looks like it's failing to mount, doesn't it?15:31
ryebotnamely, "...vol-0445bc1b6acae0622 does not exist"15:32
sri_ryebot: thats exactly where i could not trace down to root cause15:33
sri_ryebot: when i deploy postgres using ebs via juju, it works fine...it does not work only through kubernetes15:34
ryebotsri_: alright, let me look at this a moment15:34
sri_ryebot: Thanks a lot...A quick google search results points out that juju is not setting cloud-provider as aws w.r.t https://github.com/juju-solutions/bundle-canonical-kubernetes/issues/34615:36
ryebotsri_: I see, that's why you're trying to add the cloud-provider flag15:36
sri_ryebot: but that did not help me :-(15:36
sri_ryebot: After i set this flag manually, reboot of containers fails and they never successfully start15:37
sri_ryebot: Not sure if there is a good way to reboot the cluster using juju15:38
ryebothmm15:38
ryebotwere you actually able to set the flag?15:38
sri_yes15:39
ryebotsri_: where do you see that it has been set?15:39
sri_ryebot: let me paste those results15:40
ryebotsri_: thanks15:40
sri_ryebot: pasted those commands and output at the end of the doc15:44
ryebotsri_: thanks, looking15:44
ryebotsri_: How about kubelet?15:46
sri_as per https://github.com/juju-solutions/bundle-canonical-kubernetes/issues/346, i need to reboot those machines after setting these flags but if i do, i could not start anymore15:46
sri_I did that for kubelet also in machine 015:46
ryebotalright, hmm15:46
sri_ryebot: is there a good way to restart juju machines?15:47
ryebotsri_: This is a bit confusing, because if you deployed with the latest conjure-up (e.g., http://blog.astokes.org/conjure-up-dev-summary-aws-cloud-native-integration-and-vsphere-3/), this should all just work for you.15:47
ryebotsri_: you should be able to juju ssh in and `sudo reboot`, at the very least15:48
sri_ryebot: Let me do that but i am sure it fails to start...but at-least i can show you the error it gives15:49
ryebotsri_: that'd be good to see, thanks.15:50
sri_now, it stuck at `kubernetes-master/0*  waiting   executing  1        13.58.179.90    6443/tcp        (update-status) Waiting to retry addon deployment`15:55
sri_ryebot: now, it stuck at `kubernetes-master/0*  waiting   executing  1        13.58.179.90    6443/tcp        (update-status) Waiting to retry addon deployment`15:55
sri_ryebot: This happens only after i add cloud-provider=aws and reboot the machine15:55
ryebotokay15:56
ryebotone moment15:56
sri_ryebot: I am not sure which addon it is trying to deploy...shall i add new juju status, juju debug-log to the pastebin?15:56
ryebotsri_: juju debug-log would be great15:57
ryebotthank you15:57
sri_ryebot: juju debug-log only shows that it cannot connect to kubernetes-master15:57
sri_ryebot: could be because it is not ready15:58
sri_ryebot: any other juju commands to get detailed logs per machine and per app?15:58
ryebotsri_: you can try ssh'ing into the relevant machine and looking in /var/log/juju15:59
ryebotthat should bypass any erroring agents15:59
sri_ryebot: kindly check https://ghostbin.com/paste/xq63r now16:01
* ryebot clicks16:02
ryebotsri_: one moment16:04
ryebotsri_: Can you check the logs for apiserver?16:05
sri_ryebot: Sure take your time... I see failure logs at `  File "/snap/cdk-addons/169/apply", line 93, in <module>`16:05
sri_sure16:05
ryebotsri_: on the maste node, `journalctl -u snap.kube-apiserver.daemon`16:07
ryebotmaster*16:07
sri_ryebot: Pasted new log at the bottom...i think we have the root cause there...16:09
sri_Oct 19 15:51:27 ip-172-31-25-174 kube-apiserver.daemon[4246]: error setting the external host value: "aws" cloud provider could not be initialized: could not init cloud provider "aws": error fi16:09
ryebotsri_: can you do that with `journalctl -xn --no-pager`16:10
skayI'm not seeing a flag I expect from a charm that provides the rabbitmq interface. from reading the src, anything that provides rabbitmq should be setting myname.connected, but I'm not seeing it16:11
skayhttps://github.com/openstack/charm-interface-rabbitmq/blob/master/requires.py#L3816:12
sri_ryebot: output added at the bottom16:12
ryebotsri_: thanks16:13
ryebotdangit, journalctl, I just want untruncated output.16:14
ryebotokay, let's try journalctl -o cat -xn -u snap.kube-apiserver.daemon16:15
ryebotsri_: or if you know a better way, by all means16:15
sri_okay, let me add it16:16
sri_its actually truncating and giving only last few lines :-(16:17
sri_I redirected output to a tmpfile but its huge...16:19
sri_ryebot: untracked error message seems to be: `Oct 19 16:00:38 ip-172-31-25-174 kube-apiserver.daemon[12360]: error setting the external host value: "aws" cloud provider could not be initialized: could not init cloud provider "aws": error finding instance i-08e7af80c7f9dc876: "error listing AWS instances: \"NoCredentialProviders: no valid providers in chain. Deprecated. \\n\\tFor verbose messaging see aws.Config.CredentialsChainVerboseErrors16:20
ryebotsri_: okay, that's gross16:20
* ryebot thinks16:20
ryebotsri_: Did you deploy with conjure-up, as is done here? http://blog.astokes.org/conjure-up-dev-summary-aws-cloud-native-integration-and-vsphere-3/16:22
sri_ryebot: i-08e7af80c7f9dc876 is actually on us-east-2b and logs shows as us-east-216:22
sri_is that an issue?16:22
ryebotsri_: yeah that's weird16:23
* ryebot thinks16:23
sri_I am on macOS and i got conjure-up via brew16:23
ryebotahhh okay one sec16:23
sri_ryebot: I deployed using just "conjure-up" command but the UI does not look same as the one shown in the link16:24
sri_ryebot: I dont think i see addons support16:24
stokachusri_: https://github.com/conjure-up/conjure-up/issues/1195 is that you?16:24
sri_stokachu: yes16:26
stokachusri_: ok let me look at your files you attached16:26
sri_ryebot: I am on mac and my version is: conjure-up 2.3.116:27
ryebotsri_: ack, thanks16:27
sri_ryebot: not sure it has addons and aws native integration in it or not16:27
ryebotLooks like it errored out looking for juju wait?16:29
sri_ryebot: sorry, i didn't get you16:31
ryebotsri_: nvm, just thinking out loud16:32
stokachusri_: give me a few minutes im working on something then ill look at your issue16:32
=== frankban is now known as frankban|afk
sri_Sure thanks alot for your time ryebot, stokachu16:33
sri_ryebot: You want me to send full journal file in some way?16:50
ryebotsri_ I think that's enough for now17:08
sri_ryebot: Okay, do you know any workaround for me to use PVs?17:09
ryebotsri_: Well, it looks to me like you're on the right track. The problem appears to be the aws credentials got mixed up, and also that you're somehow not getting the native cloud integrations. I suspect stokachu will be able to help with that when he takes a look at your issue.17:17
sri_ryebot: Thanks. BTW, what do you mean by `aws credentials got mixed up`? anyway I can dig further?17:21
ryebotsri_: Yeah, it seems strange to me that your instances are coming up in different regions. It makes me think there's a couple sets of credentials pointing to different regions.18:19
sri_ryebot: But when i do conjure-up, I only give one set of credentials18:22
sri_BTW, conjure-up only let us choose us-east-2 or us-east-118:22
ryebotsri_: Ah dang, I'm sorry, I misread that - -2b and -2 are different AZs, not two regions. I think that should be fine, actually.18:23
sri_but aws, create instances with an alphabet at the end right18:23
sri_all my machines are in us-east-2 but with us-east-2a as one us-east-2b as another18:24
ryebotsri_: Yeah, I think that should be okay.18:25
ryebotStill, the error breaking us looks like some credentials got mucked up somewhere.18:25
sri_is there a way i can cleanup all the conjure-up history?18:26
sri_ryebot: is there a way i can cleanup all the conjure-up history?18:26
sri_Even though i delete .cache folder, it still remember somehow18:27
* ryebot thinks18:27
ryebotsri_: I think you want to `snap remove conjure-up`, `rm -rf ~/snap/conjure-up`, and `rm ~/.local/share/juju` if it's there, at the least18:28
ryebotah sheesh, you're not using snaps, sorry18:28
sri_ryebot: i am on mac so snap wont work right18:28
ryebotI'm not sure what the brew cleanup looks like, tbh. stokachu might know. I'd also look for ~/.local/share/juju and wipe it (if you're not otherwise using it)18:29
sri_okay18:29
sri_ryebot: if i use conjure-up edge, cloud-provider config should be aws right18:30
ryebotI would expect edge to have it, though I don't know why stable wouldn't.18:31
sri_ryebot: I mean, If i follow the version from http://blog.astokes.org/conjure-up-dev-summary-aws-cloud-native-integration-and-vsphere-3/ and setup cluster and run `juju ssh 1 "sudo snap get kube-apiserver cloud-provider"` it should return aws?18:32
ryebotsri_: I think that's correct, though I'd replace `1` with `kubernetes-master/0`18:33
sri_Yes got you...thanks18:34
ryebotDoes juju create new subnets when it's deployed to a vpc?20:10
wpkNo, it uses the ones that are in the VPC21:05
=== thumper is now known as thumper-afk

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