Perl 6 - the future is here, just unevenly distributed

IRC log for #salt, 2016-08-05

| Channels | #salt index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:01 hexa- hi, I'm installing bird on deb8 like so: https://paste.linuxlounge.net/#/p6DinTecmN2d6l9v2gf5y80U7AA!EwsnrNxgrM0Jlbq4b3WWeK3BCm99_916n2bw0jTnhfc
00:02 hexa- it says `- enable: True`
00:02 hexa- but it's not being enabled
00:02 hexa- Loaded: loaded (/lib/systemd/system/bird.service; disabled)
00:02 hexa- running salt-minion 2016.3.2+ds-1
00:03 hexa- result of the state says service is already running; doesn't enable it. https://paste.linuxlounge.net/#/KDOjn8o4co-FYrcuqSDmFFjbfT8!mLeNwHx7Fv0G_RJ0dVmSm1HZCEA3n57T2yhuGstd1TA
00:09 vodik joined #salt
00:09 hexa- ugh, it's because of the watches
00:11 vodik joined #salt
00:21 MTecknology iggy: lol, I couldn't get too excited about lxdocker
00:22 PerilousApricot joined #salt
00:33 stanchan joined #salt
00:38 Salander27 joined #salt
00:42 __number5__ https://groups.google.com/d/msg/salt-users/iebkXpWX1DA/z7WrgDq4BgAJ (can't agree more with this)
00:47 zer0def joined #salt
00:52 subsignal joined #salt
00:57 Nahual joined #salt
01:02 Vaelatern iggy: Shame there are so few ways to manage lxc
01:03 flowstate is there any way at all to get a true return code for a python client call?
01:04 flowstate running localclient, executed cmd.run with arg "lsdfskldfjsdlkfjsldkfj", response "command not found" ... success: true.
01:04 flowstate ???
01:08 ajolo joined #salt
01:12 badon joined #salt
01:15 amcorreia joined #salt
01:16 catpiggest joined #salt
01:23 PerilousApricot joined #salt
01:40 ajw0100 joined #salt
01:41 subsigna_ joined #salt
01:47 DEger joined #salt
01:48 cliluw joined #salt
01:50 mdpolaris joined #salt
01:59 pipps joined #salt
01:59 Lionel_Debroux_ joined #salt
02:01 Nahual1 joined #salt
02:04 ZachLanich joined #salt
02:05 ZachLanich_ joined #salt
02:06 ZachLanich iggy & hemebond: First of all, I just watched a video on the Salt YouTube channel of Iggy and was like "OMG I KNOW THAT GUY...kinda" lol, but on to real stuff. Here's what I've decided on for my initial infrastructure and I wanted your input on it. Similar to this paste I posted a couple days ago (https://gist.github.com/zlanich/1d759994751b0d73714caa7434ee6dcb), I'm thinking the following:
02:07 ZachLanich -> https://gist.github.com/zlanich/dd2626f10b9db837b597eae8a40fa91b
02:07 ZachLanich Also, am I losing it, or is states.cloud.map not a thing??? That's annoying as hell.
02:07 ZachLanich I see the states.cloud subheading is "USING STATES INSTEAD OF MAPS TO DEPLOY CLOUDS". I feel like I'm missing something here. I need a way to "list" all of the resources that need created before I run states, etc. Where do I put that infrastructure layout when using an orchstration??
02:09 hemebond There's a video of iggy on YouTube?
02:09 antpa joined #salt
02:10 ZachLanich Unless it's a different iggy haha
02:11 ZachLanich I only assumed that since iggy is a rare name/nickname and he's in the Salt IRC channel and there's a guy on the Salt YT channel who goes by iggy talking about Salt, that's it's him and he's famous or something lol
02:13 stanchan joined #salt
02:24 PerilousApricot joined #salt
02:31 lukehflynn joined #salt
02:31 lukehflynn Hey, I'm having some issues using gitfs with pillar.
02:32 ZachLanich Hemebond & Iggy: Nothing? lol
02:33 lukehflynn top.sls: https://gist.github.com/LukeFlynn/bd8a209e4f537b009d6490ac594a01ff
02:33 lukehflynn git_pillar.conf https://gist.github.com/LukeFlynn/5433b28760c5f5f54cf762ff7ff10d14
02:34 lukehflynn Wrong link for git_pillar.
02:34 lukehflynn https://gist.github.com/LukeFlynn/064ac93edb1dd3b05191a1973e511269
02:37 bastiandg joined #salt
02:46 edrocks joined #salt
02:47 evle joined #salt
02:52 lukehflynn I forgot to mention... the issue I am encountering is: when I attempt to get pillar items it say they are not found in the environment base.,
02:52 lukehflynn When I have clearly defined the env.
02:54 hemebond ZachLanich: I'm at work right now.
02:54 ZachLanich Ah
02:55 hemebond Oh I've watched an Iggy video before.
03:00 flowstate joined #salt
03:11 antpa joined #salt
03:27 fracklen joined #salt
03:37 west575_ joined #salt
03:41 stanchan joined #salt
03:46 vadimck joined #salt
03:55 Salander27 joined #salt
04:00 flowstate joined #salt
04:00 subsignal joined #salt
04:03 fracklen joined #salt
04:03 k_sze[work] joined #salt
04:26 PerilousApricot joined #salt
04:49 edrocks joined #salt
04:50 badon joined #salt
04:53 ZachLanich hemebond or iggy, either of you around and familiar with Orchestrate at all?
04:53 hemebond I'm not familiar with it.
04:56 badon joined #salt
05:00 flowstate joined #salt
05:03 beardedeagle joined #salt
05:03 subsignal joined #salt
05:16 stanchan joined #salt
05:23 ivanjaros joined #salt
05:28 impi joined #salt
05:29 sagerdearia joined #salt
05:41 bocaneri joined #salt
05:53 M-liberdiko joined #salt
05:57 felskrone joined #salt
06:00 flowstate joined #salt
06:07 antpa joined #salt
06:08 cyborg-one joined #salt
06:08 mohae_ joined #salt
06:12 Miouge joined #salt
06:17 antpa joined #salt
06:28 necronian joined #salt
06:28 M-MadsRC joined #salt
06:30 sjorge joined #salt
06:30 Inver joined #salt
06:33 POJO joined #salt
06:36 ivanjaros3916 joined #salt
06:43 CeBe joined #salt
06:52 edrocks joined #salt
06:56 evidence so it appears when you have multiple transports enabled everything works fine, until the master sends jobs over the bus
06:56 evidence then everything grinds to a halt and the masters stop functioning
06:56 evidence 2016.3.2 master
07:00 flowstate joined #salt
07:03 fracklen joined #salt
07:03 fracklen joined #salt
07:04 subsignal joined #salt
07:12 stanchan joined #salt
07:13 ribx joined #salt
07:14 evidence looks like it might be known based on comments in https://github.com/saltstack/salt/issues/33881
07:14 saltstackbot [#33881][OPEN] Minion Transport Fallback | Automatic fallback for transport....
07:24 rdas joined #salt
07:27 Electron^- joined #salt
07:33 Elsmorian joined #salt
07:35 fredvd joined #salt
07:37 iggy different iggy
07:40 cyborg-one joined #salt
07:56 JohnnyRun joined #salt
07:57 impi joined #salt
07:59 flowstate joined #salt
08:04 stanchan joined #salt
08:14 toanju joined #salt
08:14 om joined #salt
08:19 fredvd left #salt
08:30 aalmenar joined #salt
08:40 jhauser joined #salt
08:53 s_kunk joined #salt
08:54 s_kunk_ joined #salt
08:54 POJO joined #salt
08:55 edrocks joined #salt
08:58 s_kunk joined #salt
08:58 flowstate joined #salt
09:04 jcalero joined #salt
09:06 subsignal joined #salt
09:10 lero joined #salt
09:12 blueelvis joined #salt
09:19 jcalero joined #salt
09:24 Sylvain31 joined #salt
09:43 k_sze[work] joined #salt
09:57 sjorge joined #salt
09:59 flowstate joined #salt
10:05 jhauser joined #salt
10:06 subsignal joined #salt
10:07 jcalero I'm trying to understand how salt-ssh and target machines without a salt-minion work. Yesterday I was told grains are only really for minions and that the grains I get when I do 'salt-ssh [target] grains.items' is fetched by salt-ssh's portable minion. But today I tried setting a custom grain, 'environment: test', and I can do 'salt-ssh [target] grains.get environment' and get 'test' back. So clearly the
10:07 jcalero grain must've been stored somewhere, is there a temporary persistent minion set up on the target when you do salt-ssh?
10:16 AndreasLutro how did you set said custom grain?
10:17 jcalero salt-ssh [target] grains.setval environment test
10:18 jcalero another thing I just noticed is that, if I change that value, (I just changed it to 'test2') it didn't change immediately. When I called grains.get environment I was still getting 'test' for a while, maybe 5 minutes or so, before I got 'test2', so I'm guessing there's some caching going on
10:20 AndreasLutro the salt-ssh minion has its own config directory inside /tmp, grains.setval probably writes the value you set to the grains file there
10:20 AndreasLutro and yes, grains are cached
10:22 KingOfFools if there is mislead in documentation where would i report?
10:23 AndreasLutro KingOfFools: just make a pull request to the salt repo, or issue if you don't know what the fix would be
10:24 KingOfFools ok, thx
10:25 jcalero AndreasLutro: That's what I imagined, thanks! Found this: https://docs.saltstack.com/en/latest/topics/ssh/roster.html#thin-dir, which I'm guessing is what you're talking about.
10:28 AndreasLutro yep
10:31 bluenemo joined #salt
10:32 bluenemo hi guys. When I have a syntax error in my pillar they wont render. Is there a switch that does not let a state execute when there is any pillar render error?
10:34 alexhayes joined #salt
10:40 traph joined #salt
10:40 traph joined #salt
10:42 bluenemo pillar_raise_on_missing seems to be  a direction
10:48 antpa joined #salt
10:50 flowstate joined #salt
10:58 edrocks joined #salt
11:00 amcorreia joined #salt
11:01 jhauser joined #salt
11:02 Rumbles joined #salt
11:10 Elsmorian joined #salt
11:14 aasirc joined #salt
11:17 DammitJim joined #salt
11:24 p3rror joined #salt
11:40 rhi joined #salt
11:54 nicksloan joined #salt
12:06 jcalero joined #salt
12:08 subsignal joined #salt
12:22 ssplatt joined #salt
12:26 nicksloan joined #salt
12:29 nicksloan joined #salt
12:33 gh34 joined #salt
12:34 freelock joined #salt
12:39 scoates joined #salt
12:44 nicksloan joined #salt
12:49 nicksloan joined #salt
12:50 mikecmpbll joined #salt
13:00 subsignal joined #salt
13:00 stanchan joined #salt
13:00 edrocks joined #salt
13:03 Elsmorian joined #salt
13:07 flowstate joined #salt
13:09 numkem joined #salt
13:14 _JZ_ joined #salt
13:15 RandyT joined #salt
13:21 fracklen joined #salt
13:24 stanchan joined #salt
13:28 rovar_ joined #salt
13:30 flowstate joined #salt
13:39 stanchan joined #salt
13:40 protoz joined #salt
13:42 perfectsine joined #salt
13:47 Rumbles when I connect a new host to my salt server, sometimes I want to test what the highstate will do, but I get this weird error: https://paste.fedoraproject.org/401696/
13:47 Rumbles if I run it without the test it works fine
13:48 Rumbles if I then run a test after doing the first run it's fine
13:48 Rumbles can anyone suggest what the issue could be ?
13:48 citaret joined #salt
13:53 antpa joined #salt
13:53 ivanjaros joined #salt
13:59 Tanta joined #salt
14:00 Elsmorian joined #salt
14:01 subsignal joined #salt
14:02 PerilousApricot joined #salt
14:06 cmarzullo perhaps the pip.installed state module doesn't support testing and fails poorly?
14:08 stanchan joined #salt
14:10 mindscratch joined #salt
14:11 mindscratch Hello, I have 3 salt masters and 2 minions. The minions are configured to know about all 3 masters, and I have "random_masters" set to True. I was under the impression that any master should be able to talk to any minion
14:11 cmarzullo you'll need to sync the keys
14:11 mindscratch but what I'm seeing is that master-1 can ping minion 1, and master-2 can ping minion-2 ...i suppose when minion-2 came up it randomly connected to master-2 and that's why this is happening.
14:11 mindscratch @cmarzullo -- i am syncing keys
14:11 cmarzullo kk
14:12 mindscratch on startup if minion-1 connects to master-1 does that mean master-2 can't ping it? (meaning: salt 'minion-2' test.ping)
14:12 cmarzullo Sounds like your analysis is right. they are joined to different masters.
14:12 mindscratch ok so i want to disable "random masters" then
14:13 riftman joined #salt
14:14 Rumbles cmarzullo, I just tried installing pip on the server and running the test again and it worked fine...
14:14 Rumbles should I open a bug?
14:15 cmarzullo Not sure it's a bug. the docs do state that pip needs to be installed before the state will work. You'll see that with a number of modules.
14:16 cmarzullo I have a generic python formula I apply that sets up system python and pip.
14:16 cmarzullo I do that before any custom pipping
14:17 Rumbles ah right, okay
14:17 Rumbles we have in our "bootstrap" state awscli to be installed via pip, which is applied to all hosts
14:18 doublemetres joined #salt
14:18 Rumbles a bit annoying that it fails so ungracefully, but I know why now so I can work around it or think of a way to improve it
14:18 Rumbles thanks!
14:18 Sylvain31 hi, I wrote a small state form partitionning and adding an new attached storage to a server: http://paste.debian.net/787061/
14:18 p3rror joined #salt
14:19 Sylvain31 unfortunately it fails, as I try to fetch the blkid of the partition before it exists
14:20 Sylvain31 does it have a way to evalate it lately? or should I do it differently?
14:20 Sylvain31 line 30
14:21 impi joined #salt
14:23 bowhunter joined #salt
14:24 Sylvain31 maybe by using file.append: -source: parameter it would be evaluated when it would be executed?
14:25 Slimmons joined #salt
14:26 cmarzullo instead of file append use the mounts state: https://docs.saltstack.com/en/latest/ref/states/all/salt.states.mount.html
14:27 Sylvain31 cmarzullo: I don't want the partition to be mounted
14:27 Sylvain31 just to be listed in the fstab
14:27 cmarzullo you can define it an not mount it.
14:27 Sylvain31 ah…
14:28 paant joined #salt
14:28 Sylvain31 mount=False, cool
14:28 cmarzullo but maybe that's not the problem? disk.blkid isn't there yet?
14:29 cmarzullo you can set the mount option noauto to not have it mount on reboot.
14:30 stanchan joined #salt
14:31 impi joined #salt
14:32 Sylvain31 cmarzullo: I just want to create it, and record the mount in fstab, not to mount it immediately, it will be mounted at reboot after. I'm extending the fs, with a remote storage. using - source: of file.append delay the evaluation of blkid, so it works. I'm gonna test mount.mounted() now. I was supposed it allways force the mount. ;)
14:32 Sylvain31 ~ I was supposing
14:33 corichar joined #salt
14:33 stanchan joined #salt
14:34 antpa joined #salt
14:34 Sylvain31 but mount.mounted will try to evaluate the blkid so I fallback to my first problem…
14:35 POJO joined #salt
14:36 west575 joined #salt
14:36 Sylvain31 so it should be spilt in two sls file?
14:38 perfectsine joined #salt
14:39 RandyT joined #salt
14:43 riftman joined #salt
14:49 sm1ly joined #salt
14:50 sm1ly re2all, guys, cant understand how to correct configure engine https://docs.saltstack.com/en/develop/ref/engines/all/salt.engines.slack.html#salt.engines.slack.start ? I added it to /etc/salt/master
14:51 DammitJim joined #salt
14:52 cmarzullo Sylvain31: maybe put a jinja guard around the blkid. if not defined or null or whatever don't execute the mount state?
14:53 cmarzullo Like {% myblkid = salt[blalval] %} Then you can do an unless in the mount state or wrap it in a jinja conditiional.
15:01 fyb3r joined #salt
15:02 Sylvain31 yep, it may be the way to go.
15:02 shiriru joined #salt
15:03 edrocks joined #salt
15:09 hoonetorg joined #salt
15:10 ivanjaros joined #salt
15:11 Sylvain31 oh, I found a bug in disk.wipe
15:18 stanchan joined #salt
15:19 lilvim joined #salt
15:19 sm1ly guys, really, help me with engines please. dont understand how to start it
15:20 babilen Why do you think that it hasn't been started?
15:21 babilen And what have you done to start it?
15:23 sm1ly babilen, I configured /etc/salt/master with http://pastebin.com/m3Bh0fvA so it must got test.ping command, but nothing
15:24 babilen But you haven't restarted the master. Where do you see nothing?
15:25 sm1ly babilen, i restarted master ofc
15:25 sm1ly Aug 05 11:09:16 tsvpnqualification hubot[26295]: [Fri Aug 05 2016 11:09:16 GMT-0400 (EDT)] DEBUG Received message: 'test.ping' in channel: jira, from: sm1ly
15:25 sm1ly Aug 05 11:09:16 tsvpnqualification hubot[26295]: [Fri Aug 05 2016 11:09:16 GMT-0400 (EDT)] DEBUG No listeners executed; falling back to catch-all
15:26 sm1ly oh, nvm about hubot, miss window
15:26 babilen So, could you run "salt-run state.event pretty=True" and paste the output to one of http://refheap.com, http://paste.debian.net, https://gist.github.com, http://sprunge.us, … while sending messages via slack?
15:27 babilen Where is that debug message from?
15:28 sm1ly babilen, dont take it to our talk. its hubot debug, just miss window
15:29 stanchan joined #salt
15:29 babilen Well, something seems to have received a message
15:29 sm1ly babilen, http://pastebin.com/esajsti2
15:30 sm1ly babilen, it just looks in #jira and logging all, cause hubot in debug mode too
15:30 babilen Sorry .. could you use a different pastebin in the future? It would really make my life easier and I'd be more willing to help
15:31 babilen Which messages have you send?
15:31 sm1ly babilen, https://www.refheap.com/121929 no prob. i tryied send test.ping and !test.ping
15:31 babilen And that doesn't look like the output of "salt-run state.event pretty=True"
15:31 ajw0100 joined #salt
15:32 babilen How does slack communicate with salt?
15:33 oida joined #salt
15:34 babilen And just to make sure: you did install the slackclient module on the master?
15:34 sm1ly babilen, wow... i guess no
15:34 sm1ly about slackclient
15:34 babilen It's listed as dependency
15:35 babilen And the paste you created looks rather like the master log than the output of that salt-run .. what was it?
15:35 antpa joined #salt
15:36 sm1ly babilen, but salt-run only on master
15:36 sm1ly salt-call    salt-minion  salt-proxy
15:36 babilen I don't follow
15:36 sm1ly only this one can minions
15:37 babilen You run that command on the master, yes
15:37 sm1ly babilen, yes. and when I runed it - I paste it to you. and yes my master in debug mode
15:38 babilen okay
15:38 sm1ly babilen, how I can get slack client? no info on saltstack docs
15:38 babilen So, install the slackclient Python module and restart the master
15:39 babilen Doesn't Slack document that? When I google for that I find https://github.com/slackhq/python-slackclient
15:40 sm1ly babilen, it only writes depends on slackclient. https://docs.saltstack.com/en/latest/ref/engines/all/salt.engines.slack.html when i try to google - it always go to salt )) ok, trying
15:40 babilen Not sure if that is the "slackclient" that is mentioned in the Salt documentation, but I deem it likely
15:40 babilen You google for "slackclient" and you only find https://docs.saltstack.com/en/latest/ref/engines/all/salt.engines.slack.html ?
15:41 paant joined #salt
15:42 stanchan joined #salt
15:43 hasues joined #salt
15:43 hasues left #salt
15:45 Slimmons I'm currently having salt run a powershell script using cmd.run, with - shell: powershell, and that script is storing the PID  locally on the server.  Is there a way to run a powershell script, and get its output back to the master?  for example, if my script echo's $app.id, is there a way to store that to a pillar.  Maybe do something other than cmd.ruN?
15:46 keys joined #salt
15:47 iggy I would probably write a returner that handled that... but then I'm weird, so...
15:49 Sylvain31 Slimmons: for what purpose do you need the pid, can it stay on the minion?
15:50 stanchan joined #salt
15:50 sm1ly babilen, hm.... now it works only when I use your command salt-run state.event pretty=True. and using hubot to answer me)))
15:52 Sylvain31 Slimmons: hint could be: fetch in jinja with set pid = salt['cmd.run']('yourpowershell showpid'), or salt mine, or fetching the file from the minion.
15:54 ZachLanich joined #salt
15:57 Sylvain31 cmarzullo: will the jinja code be evaluated when the state is reached, I don't think so, it will be evaluated as a wall before the yaml is sent to salt… I'm still blocked. maybe run a second sls, that's what happen with file.append(source=fstab_in_jinja)
16:01 protoz joined #salt
16:04 sm1ly babilen, thx a lot, it works with client now! tell me please, is there the way to correct output ? cause it sending it to me like host1: blablabla
16:04 sm1ly host1: blablabla\nblablabla\netc
16:05 stanchan joined #salt
16:10 PredatorVI joined #salt
16:12 sm1ly babilen, is there the way to choose which host i want control/
16:12 cmarzullo Sylvain31: I'm not tracking. I've used that pattern before. Lemme find a snippet.
16:14 cmarzullo will this help you? http://pastebin.com/DydCxBCd
16:15 cmarzullo On first run it will compile the nagios plugins but won't on subsequent runs.
16:16 stanchan joined #salt
16:17 antpa joined #salt
16:17 Sylvain31 cmarzullo: I see… here what I tested, sofar: http://paste.debian.net/787082/
16:18 cmarzullo which stateid is having the issue?
16:19 Sylvain31 currently none. As I deported the blkid execution in the template. and not using it at line 28 and using the device name…
16:20 Sylvain31 the blkid becomes available after state mkfs_vdb1 at line 16.
16:21 Sylvain31 so add_fstab don't have the blkid when the jinja is evaluated.
16:21 jcalero joined #salt
16:22 cmarzullo couldn't you just read it in with jinja? {% set mydisk = salt['disk.blkid']('/dev/vdb1')['/dev/vdb1']['UUID'] %}
16:22 cmarzullo does that not work?
16:23 cmarzullo then use mydisk in your state?
16:23 Sylvain31 I'm trying, more for fun or headhach as being really useful… useful to knowit…
16:27 babilen sm1ly: I have no idea
16:28 sm1ly babilen, salt 'host1' state.sls bench  --state-output=terse
16:31 babilen sm1ly: I have never used the slack engine before. All I did was read documentation and code
16:38 Sylvain31 cmarzullo: {% set blkid = salt['disk.blkid']('/dev/vdb1')['/dev/vdb1']['UUID'] %} will fail with 'Jinja variable 'dict object' has no attribute '/dev/vdb1' in any case
16:39 cmarzullo {% set blkids = salt['disk.blkid'] %} work? what structre is returned. You can check the datastucture for the element you care about perhaps.
16:40 ageorgop joined #salt
16:41 Sylvain31 http://paste.debian.net/787086/
16:41 mikecmpbll joined #salt
16:42 Sylvain31 cmarzullo: it is more a time of execution. salt['disk.blkid']('/dev/vdb1')['/dev/vdb1']['UUID'] works when the partition is created. but not when the jinja is ran
16:45 Sylvain31 did you catch the subtile delayed eval when I use file.append and template source? the jinja is in the source parameter and evaluatede later… so it works
16:47 Sylvain31 there is a state for excuting an other sls file, I may split the code in two file…
16:47 armyriad joined #salt
16:48 cmarzullo sorry I couldn't be more help. /afk
16:50 PredatorVI Folks I have a problem with gitfs on my saltmaster.  It's been working until a few weeks ago but recently I get the AssertionError:  "AssertionError: Require 20 byte binary sha, got '\xe6\x90', len = 2" (See full stack at https://gist.github.com/PredatorVI/23bd40b1c40199232d9696401e5c4bf2 ).  I saw this last week and basically purged all salt packages and reinstalled from scratch, but it started again last evening.  I upgraded to latest 2016.3.2 packag
16:50 Sylvain31 no problemo, it's headhach this kind of depedance, do you rember the state that execute an othe sls?
16:51 PredatorVI The effect is that none of my states get loaded and I get a bunch of errors stating that my minions are not defined in the top file.
16:54 GreatSnoopy joined #salt
16:56 Edgan joined #salt
16:56 pipps joined #salt
16:57 Slimmons Sylvain31: The purpose of returning the pid was that later I wanted to kill the exact process I started by the command.
16:58 Slimmons Sylvain31: and the jinja method looks like it's a good idea.  I could also set it in the minion, but I wanted to skip the step of retrieving it later, just to make it a little more simple
17:00 Sylvain31 cmarzullo: http://paste.debian.net/787090/ two file it works, could be improved may be…
17:01 stanchan joined #salt
17:02 Sylvain31 Slimmons: so keep the pid on the minion and modify your script to allow "powerscript kill" it will look to its known pid file and kill itself no need to retrieve it on the saltmaster
17:02 om joined #salt
17:03 Sylvain31 very common under Linux OS /etc/init.d/service stop … etc.
17:03 Slimmons thx, sounds good
17:04 Sylvain31 cool, retreiving the pid file or something else could be possible but not needed here, look at salt mine if you're currious.
17:05 Salander27 joined #salt
17:06 edrocks joined #salt
17:13 Slimmons I've never messed with salt mine.  I guess now's a good time to start
17:16 PerilousApricot joined #salt
17:16 lovecraftian joined #salt
17:18 blueelvis joined #salt
17:23 woodtablet left #salt
17:31 oida joined #salt
17:31 FroMaster joined #salt
17:31 PredatorVI Anyone have suggestions on what could be causing this:  https://github.com/saltstack/salt/issues/35239
17:31 saltstackbot [#35239][OPEN] [ERROR   ] Exception Require 20 byte binary sha, got '\xe6\x90', len = 2 occurred in file server update | Running on Ubuntu 14.04.5 with latest salt-master version 2016.3.2 packages.  It also happened recently with previous (newish) versions.  ...
17:36 PerilousApricot joined #salt
17:39 pipps joined #salt
17:40 impi joined #salt
17:40 tuxx joined #salt
17:41 * PredatorVI instructs a pet piranha to munch on PredatorVI's shoulder blades
17:43 armyriad joined #salt
17:49 ageorgop joined #salt
17:51 ageorgop joined #salt
17:54 fracklen joined #salt
17:57 PerilousApricot joined #salt
17:57 Fiber^ joined #salt
17:58 flowstate I'm trying to execute a localClient.cmd in python. When I run it in the repl, it's fine
17:59 flowstate when I run it in my code, I get "salt.exceptions.SaltClientError: 'load'"
18:00 squishypebble joined #salt
18:02 PredatorVI any gitfs experts?  I'm dead in the water due to https://github.com/saltstack/salt/issues/35239 and I don't know what it the issue.
18:02 saltstackbot [#35239][OPEN] [ERROR   ] Exception Require 20 byte binary sha, got '\xe6\x90', len = 2 occurred in file server update | Running on Ubuntu 14.04.5 with latest salt-master version 2016.3.2 packages.  It also happened recently with previous (newish) versions.  ...
18:07 pipps joined #salt
18:09 bowhunter joined #salt
18:10 Tanta joined #salt
18:10 stanchan joined #salt
18:11 om joined #salt
18:12 Perilous_ joined #salt
18:14 Perilou__ joined #salt
18:21 west575__ joined #salt
18:24 impi joined #salt
18:24 Eldarth joined #salt
18:25 Eldarth left #salt
18:30 fyb3r1 joined #salt
18:33 iggy downgrade?
18:34 iggy I haven't used gitfs in a while, we ended up going to a webhook+reactor+git.latest setup... and the current job uses packages
18:34 iggy gitfs updating every minute was killing our master
18:35 iggy and you can't change it's timer
18:37 PerilousApricot joined #salt
18:40 POJO joined #salt
18:40 ageorgop joined #salt
18:51 Edgan iggy: doesn't seem like it would be a hard pull request to make 60 seconds a setting instead of hard coded
18:51 iggy lol
18:51 iggy it's tied to the main salt timer, so you'd have to either make that configurable (hint: don't) or completely decouple the gitfs code from that timer
18:52 Perilous_ joined #salt
18:53 stanchan joined #salt
18:53 Edgan PredatorVI: Sounds like a "corrupt" git repo
18:56 perfectsine joined #salt
18:57 Edgan PredatorVI: Otherwise it is a GitPython bug
18:57 mikea joined #salt
18:57 Edgan PredatorVI: I use gitfs, and I use pygit2, which seemed like the best option of the gitfs providers.
18:57 mikea Is there a salt command or preferably python API similar to ansible -m setup where it dumps all of the facts/grains it knows about a host?
18:58 Edgan PredatorVI: To easily support pygit2, I switched to from Trusty(14.04) to Xenial(16.04) for my salt masters.
18:58 sagerdearia joined #salt
18:58 Edgan PredatorVI: But that has been a double edge sword. I keep running into new Xenial only salt bugs.
18:58 Edgan mikea: salt 'hostname' grains.items or salt 'hostname' pillar.items
18:59 mikea Edgan, thanks
18:59 west575 joined #salt
18:59 Edgan PredatorVI: I would still recommend switching to Xenial.
19:00 Edgan PredatorVI: Otherwise, give up on gitfs and go back to filesystem based.
19:01 fyb3r1 Did the layout of the presence events change in 2016.3?
19:01 fyb3r1 Im seeing new events coming in as syndic/SYNDIC_ID/salt/run/20160805135648534713/new, which is nothing like it used to be.
19:01 Edgan PredatorVI: gitfs_provider: pygit2
19:07 dyasny joined #salt
19:09 squishypebble1 joined #salt
19:09 edrocks joined #salt
19:09 perfectsine joined #salt
19:10 antpa joined #salt
19:16 PerilousApricot joined #salt
19:17 fracklen joined #salt
19:17 keys what version of libgit2 and pygit2?
19:18 keys I'm using 0.24.1 of libgit2/pygit2 with 2016.3.2 and seems to work well enough
19:20 Edgan keys: he isn't using pygit2, he is using the default, gitpython
19:21 keys oh I read above he said he is using pygit2, eww gitpython
19:21 Edgan keys: Looking at his config in the bug, and his error message he isn't using pygit2
19:21 keys wiz oh lol, that was u
19:21 PredatorVI @EveryoneWhoResponded:  sorry for the delay...was at lunch.  Trying pygit2 now...
19:21 keys my bad
19:22 Edgan PredatorVI: :)
19:22 keys pygit2 can be a little bit of a pain to setup dependencies on ubuntu but better control
19:23 Edgan keys: Easy on xenial
19:23 Edgan keys: They made it a package
19:23 keys ah that is great, haven't tried that. Went through a bit of dependency hell first time setup
19:24 Edgan keys: yeah, I looked at it on trusty, and was like Nope.
19:24 PredatorVI How do you enable Xenial?  gitfs_provider: xenial?
19:24 Edgan PredatorVI: Xenial is Ubuntu 16.04
19:25 keys yes it was a pain to setup, although for others doing that, there is also a salt-formula out there which can help, though I found it to be out of date a bit
19:25 PredatorVI D'oH!
19:25 Edgan PredatorVI: Is your salt master a VM? EC2 instance? physical machine?
19:26 PredatorVI VM
19:26 PredatorVI ESXi 6
19:26 Edgan PredatorVI: Do you make VM images per distro version, or install by hand?
19:26 PredatorVI usually by distro, but haven't done 16 yet
19:27 Edgan PredatorVI: I would recommend starting down that road.
19:27 Edgan PredatorVI: Xenial has had official packages for weeks
19:27 keys pygit2 on ubuntu 14 is painful experience
19:27 fredvd joined #salt
19:28 PredatorVI kk
19:28 PredatorVI creating snapshot and going to do dist upgrade
19:28 Edgan PredatorVI: https://github.com/saltstack/salt/issues/created_by/edgan  You can follow the salt Xenial only bugs I find.
19:31 PredatorVI OH!  Xenial is codename for 16.04...I need to get out more
19:31 Sketch this is why codenames are annoying
19:33 Tanta Ubuntu is general is annoying
19:33 Sketch well, that too
19:34 keys It's not what I would choose but it's widely in use and supported
19:35 PredatorVI I tend to like debian-based distros, but maybe my use cases are more trivial
19:35 Tanta I understand the desktop appeal, but for a server? pff
19:36 keys just that people who don't know a ton about linux, can find answers easier, so that might be appeal from server angle
19:36 keys not sayiung I'm some guru but just my thoughts
19:36 Tanta I don't like Ubuntu because they've done so much to the base system that it doesn't feel like Debian, or Linux to me, so when you go to fix it it's just that much more complicated
19:39 Perilous_ joined #salt
19:48 hokie1999 joined #salt
19:49 PredatorVI Xenial dist upgrade crapped out...gotta start fresh.
19:49 Edgan Tanta: I am not fond of Ubuntu, but among devs it is the standard distro. If you also want to touch Docker, it is both the standard and much easier solution.
19:50 hokie1999 joined #salt
19:50 hokie1999 How would I test a jinja script named "test.jinja" -- could not find answer searching around?
19:51 Edgan hokie1999: define test
19:51 hokie1999 {%- for host in hostnames -%}
19:51 hokie1999 {%- endfor %}
19:51 hokie1999 that's all
19:52 Edgan hokie1999: You want to see the output, or you actually want to test the salt code?
19:52 whytewolf hokie1999: that jinja would output nothing...
19:53 hokie1999 maybe, but there'd be a way to execute it, that's what I'm looking for
19:53 cmarzullo hokie1999: you can use the test state. in your for loop do a 'loopitem {{host}}': test.succeed_without_changes
19:53 hokie1999 let me give another example.....
19:54 cmarzullo that'll just put a little message out for every element.
19:54 cmarzullo or 'echo {{ host }}': cmd.run
19:54 Edgan whytewolf: point him at your debug renderer
19:54 whytewolf was just pulling up the link
19:54 whytewolf hokie1999: https://github.com/whytewolf/salt-debug
19:54 hokie1999 {% for r in salt['pillar.items'](NAME_OF_LIST) %}
19:55 hokie1999 {{r}}
19:55 hokie1999 {% endfor %}
19:55 hokie1999 render.....
19:55 cmarzullo Is that in a state file or a template?
19:55 Edgan whytewolf: please add saltutil.sync_modules to the readme.md
19:55 pipps joined #salt
19:56 hokie1999 salt.renderers.jinja.render(template_file, saltenv='base', sls='', argline='', context=None, tmplpath=None, **kws)
19:56 whytewolf :P I put the word crappy in for a reason
19:56 hokie1999 yes, tried that...
19:56 hokie1999 that is in a template, cmarzullo
19:56 whytewolf hokie1999: um no. this is a module that renders
19:57 whytewolf you can't call the renders directly from salt cli
19:57 hokie1999 sudo salt salt.renderers.jinja.render test.jinja
19:57 hokie1999 no luck with above command
19:58 fracklen joined #salt
19:58 whytewolf hokie1999: i just said you can't call the salt renders directly
19:59 berserk joined #salt
19:59 hokie1999 I'll ask someone else
20:00 cmarzullo another happy customer
20:00 whytewolf english must not have been their first lang. :/
20:01 cmarzullo I guess if he really just want to test the template you could go into the python interactive session and do it there. I'd done that way back when.
20:02 cmarzullo not really a salt thing
20:02 * cmarzullo shrugs
20:02 PerilousApricot joined #salt
20:02 whytewolf yeah that is WAY outside of salt. and i think it might be kind of iffy on if it renders right since you are not sure if you have the right pillars/grains
20:02 Edgan cmarzullo: He just wasn't listening. whytewolf's solution is the best I have seen. Technically you can create a file with {{ foo }} in it and force salt to write out the variable
20:03 Edgan cmarzullo: Lack of something like whytewolf's solution built-in is my single biggest pain point with salt
20:03 cmarzullo clicking the linky now.
20:04 Edgan cmarzullo: Doesn't work with salt-ssh.
20:04 cmarzullo no issues here.
20:04 Edgan cmarzullo: Figuring out how to make it work is on my todo list.
20:05 Edgan cmarzullo: Also nothing runs saltutil.sync_modules for you. So you have to either salt '*' it, or do it per host.
20:05 jrklein joined #salt
20:05 whytewolf well sync_modules is needed with any external modules
20:05 Edgan cmarzullo: I use salt-ssh for development of salt code. I find it much easier than a salt master in vagrant, or going through git push/pull
20:05 cmarzullo I haven't done too much with custom modules at the moment. More focused on just state management. And I do all that in test-kitchen so I see all my stuf there.
20:06 Edgan whytewolf: yes, but it isn't in your readme, and that tripped me up for a while. I would expect salt to sync like grains
20:11 whytewolf Edgan: that better?
20:11 whytewolf [i hate markdown i really should transfer this to rst]
20:12 lero joined #salt
20:12 dijit first person I've seen who hates MD.
20:12 dijit may I ask why?
20:14 Edgan whytewolf: I am not sure about state.sync_modules, I used saltutil.sync_modules.
20:14 whytewolf damn it, did i put state?
20:15 Edgan whytewolf: yes
20:15 whytewolf dijit: okay, fixed
20:15 whytewolf err Edgan fixed
20:15 Edgan whytewolf: +1
20:21 POJO joined #salt
20:21 XenophonF joined #salt
20:23 whytewolf dijit: odd escape issues. some issues with getting the text to look like i want. and i don't do a lot that uses markup which is what MD was made for
20:23 dijit fair enough.
20:25 Perilous_ joined #salt
20:26 mapu joined #salt
20:37 ssplatt i’m trying to think of a good way to make sure that a state is only run if a minion is connected to and accepted on a master; vs. running masterless.  something like “unless: - salt-call test.ping”.  anyone done something like that before
20:37 ssplatt ?
20:40 whytewolf {% if salt.config.get('file_client') == remote %} do thing with master {% endif%}
20:40 whytewolf or something like that
20:42 whytewolf oops, remote should be in quotes
20:48 jcalero joined #salt
20:49 PerilousApricot joined #salt
20:54 DammitJim how does one replace a repository key?
20:54 armyriad joined #salt
20:55 babilen Yo don't
20:56 babilen There's a set of trusted keys ..
20:56 DammitJim babilen, the people that support from rabbitmq changed it
20:56 DammitJim 2 months ago
20:56 babilen I guess they have a new one?
20:57 DammitJim so, they went from https://www.rabbitmq.com/rabbitmq-signing-key-public.asc to https://www.rabbitmq.com/rabbitmq-release-signing-key.asc
20:57 DammitJim right
20:57 babilen So, use it
20:57 DammitJim so, I changed that information on the state
20:57 DammitJim but it's not updating my minion
20:57 babilen Remove the old one if you like
20:57 DammitJim it doesn't think that there is anything to be done
20:57 babilen Ah, so salt is messing up?
20:57 DammitJim that's an interesting thought... right now, I download the key from the internet to the minion
20:58 DammitJim I don't download it and push it from the master
20:58 babilen You shouldn't have to
20:58 DammitJim here is my state
20:58 babilen But it's to late for me to delve into pkgrepo.py :)
20:58 DammitJim http://pastie.org/10931380
20:59 DammitJim the key_url was updated
20:59 DammitJim so, pkgrepo.managed isn't doing anything
21:01 babilen Sounds as if there is not check of the key .. that would require downloading it every single time
21:01 lero joined #salt
21:01 DammitJim hhmmm
21:01 DammitJim ok, but what you are suggesting now is to just go ahead and delete it manually?
21:02 babilen I don't think that would change salt's behaviour, but try it .. sounds like the whole "repo key handling" is suboptimal
21:03 babilen (if not handled with proper keyring packages)
21:03 DammitJim oh
21:03 DammitJim well, thanks for looking into this
21:03 babilen I haven't, this is just gut feeling
21:03 DammitJim oh
21:03 DammitJim yeah, the thing didn't do anything
21:03 babilen As I said: Too late to delve into pkgrepo.py this evening :)
21:03 DammitJim that's ok
21:04 DammitJim should I delete the repo?
21:04 babilen That should work
21:04 babilen (because salt can and does actually test for it)
21:05 DammitJim got it
21:10 armyriad joined #salt
21:12 edrocks joined #salt
21:12 bowhunter joined #salt
21:12 Perilous_ joined #salt
21:20 nZac joined #salt
21:20 fyb3r1 left #salt
21:24 stanchan joined #salt
21:35 PerilousApricot joined #salt
21:38 cyborg-one joined #salt
21:39 ronp_usa joined #salt
21:41 subsignal joined #salt
21:45 flowstate joined #salt
21:46 felskrone joined #salt
21:49 Electron^- joined #salt
21:52 subsignal joined #salt
21:53 ishiz joined #salt
21:57 flowstate joined #salt
21:58 bash1235123 joined #salt
21:58 bash1235123 largest known saltstack deployment ? :)
21:59 evidence linkedin has ~30k i think, split into different zones and on isolated masters..
21:59 pranav joined #salt
22:00 evidence we have about 10k split across 2 masters, 50k lines of states/maps/modules
22:01 iggy 20k
22:01 bash1235123 5k per master ?
22:01 bash1235123 what are the hardware specs of the master ?
22:01 evidence bash1235123: yeah.. but we have quite a bit going on there.. average of ~200 states per server.  10k on one master is doable with more modest states
22:01 bash1235123 do you also have syndics ?
22:01 evidence no syndics.. they are basically balls for complexity/stability :x
22:02 evidence 2.8Ghz x 16 core, cpu is what you'll be bound by.  mostly pillar and runner stuff
22:02 evidence pillar_cache really helps
22:03 bash1235123 how do you manage deployments of new code ? you have testing cluster etc ?
22:04 evidence yes, we created a system we call fmasters for pre prod envs.. they are basically lxcs that get spun up when you create a new branch in GH, and their masters point to that
22:04 evidence but you could just use conditionals or isolated states to test just as easily depending on your size
22:05 bash1235123 do you do the initial minion installation & configuration through ssh or manually ?
22:05 iggy we have vagrant testing for dev, for PRs travis tests, staging area, and canarying into prod
22:06 evidence yeah sounds similar to us.. we use jenkins for linting and state testing on PRs before they are allowed to be merged
22:06 evidence similar to how salt upstream does the code tests
22:06 evidence and vagrant is amaze for state dev
22:07 bash1235123 pretty cool
22:07 evidence bash1235123: we have bootstrap scripts that run on all boxes at 'firstboot', it's all automated
22:07 bash1235123 never thought master could handle those kind of numbers
22:07 evidence if you are virtualized that's trivial to do
22:07 bash1235123 are minions on different dcs or same ?
22:07 evidence when we first started a single master handled 12k fine with a bunch of tweaking
22:08 evidence we have servers in 50 different locations around the world.. apac/eu/us/africa
22:08 ishiz We have a master on a dedicated machine with 20 minions and applying a single state with state.sls still takes several minutes
22:08 evidence ishiz we have 200 states getting applied in under a minute on masters with 5k minions.. the operations in the state must be slow for some reason
22:09 evidence or the master just has bad connectivity maybe
22:09 bash1235123 probably ishiz is referring to the initial run
22:09 bash1235123 downloading packages etc
22:09 evidence so yeah that'd be operations in the states then, not salt itself
22:09 ishiz bash1235123: No, even the second run still takes 1m+ on a single state with one pkg.installed use
22:11 bash1235123 well, I haven't done much performance improvements since it wasn't really necessary but I'm sure I could tweak some states to run faster
22:11 iggy we have a nih bare metal provisioning system that does the salting for us
22:11 stanchan joined #salt
22:11 ishiz bash1235123: How long does a simple command like test.ping take on a single minion?
22:12 bash1235123 on lan ?
22:12 om joined #salt
22:12 ishiz Yes
22:14 Nahual joined #salt
22:15 bash1235123 ishiz : real    0m1.693s
22:15 ishiz bash1235123: It takes around 10s for us on lan
22:18 bash1235123 ishiz : can you post a test.ping with -l debug ?
22:18 bash1235123 maybe you can notice where does it get stuck
22:19 ishiz It's considerably faster now, I think maybe my master sporadically gets under high load from another service, I thought it was normal but now I know it's not
22:20 bash1235123 memory on server has been a problem for me sometimes
22:20 bash1235123 if you are on aws try to enable swap
22:22 bash1235123 evidence: do you have scheduled highstates ?
22:23 bash1235123 or iggy
22:25 Edgan bash1235123: I use a cron job to run it with batch mode every 30 minutes. I would use a schedule, but it doesn't work with foreman that I am using as a dashboard.
22:29 bash1235123 Edgan: thanks for answering. Do you also have a large setup ? if yes how many minions ?
22:31 Edgan bash1235123: I have two regions. One is about 100 minions, and the other is about 50. So not really that large, but I am engineering for hundreds.
22:31 evidence bash1235123: yeah highstate every 90m in the schedule
22:32 stanchan joined #salt
22:42 bash1235123 How do you handle master upgrades ?
22:42 bash1235123 backup, upgrade - normal or anything special ?
22:48 ishiz I have a file managed with file.manage, but I'd also like to append to it from another state. The append isn't running. Is this a bug or am I doing this wrong?
22:50 ishiz I'm appending it by using extend: /etc/salt/minion: file: -append etc
22:58 flowstate joined #salt
23:00 bash1235123 joined #salt
23:07 evidence bash1235123: daily backups.. nothing special.. it's just a package so rolling forward/back is easy
23:08 Rumbles joined #salt
23:08 stanchan joined #salt
23:09 evidence ishiz: try file.accumulated
23:11 synapse joined #salt
23:14 edrocks joined #salt
23:15 ssplatt joined #salt
23:20 Edgan bash1235123: I just do it with salt. There is a bug where on 2016.3.x it doesn't go well on upgrade, but that is a one time pain.
23:20 Edgan bash1235123: I setup new salt masters in a new region with salt-ssh.
23:21 Edgan bash1235123: I can reuse the same code between ssh mode and master mode
23:41 hasues joined #salt
23:41 stanchan joined #salt
23:41 hasues left #salt
23:53 alexhayes joined #salt
23:55 nZac joined #salt
23:58 flowstate joined #salt

| Channels | #salt index | Today | | Search | Google Search | Plain-Text | summary