Perl 6 - the future is here, just unevenly distributed

IRC log for #salt, 2014-03-19

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

All times shown according to UTC.

Time Nick Message
00:01 che-arne joined #salt
00:03 sat_user_1 hello
00:04 sat_user_1 having issue running salt_minion on armel https://github.com/saltstack/salt/issues/11273
00:04 sat_user_1 can anyone help?
00:06 mpanetta joined #salt
00:14 krow joined #salt
00:24 UtahDave techdragon: fixed!
00:24 taion809 joined #salt
00:28 allanparsons i'm placing a bash script on the server... how would you store the result for a cmd.run into a local variable in salt?
00:29 GoKage joined #salt
00:32 strgcloud joined #salt
00:33 manfred allanparsons: you could have it write its output in yaml/json format to /etc/salt/grains.d/bash-script.conf ?
00:33 manfred that is how I would do it
00:34 allanparsons and then i would read it via grains?
00:34 allanparsons i have to run a script to first get the git_revision
00:35 allanparsons so that i can write to a ../<revision_id> folder
00:35 allanparsons chicken-and-egg problem
00:38 Ryan_Lane joined #salt
00:42 quickdry21 joined #salt
00:42 krow joined #salt
00:43 ivan joined #salt
00:47 meteorfox joined #salt
00:48 strgcloud joined #salt
00:49 bhosmer joined #salt
01:04 ajw0100 joined #salt
01:08 davet joined #salt
01:11 n8n_ joined #salt
01:15 nedrocks joined #salt
01:21 bhosmer joined #salt
01:21 krow joined #salt
01:22 fllr joined #salt
01:24 bhosmer_ joined #salt
01:28 xmltok_ left #salt
01:35 bhosmer joined #salt
01:36 meteorfox joined #salt
01:39 Ryan_Lane joined #salt
01:40 dimeshake is there any way to concatenate data easily?
01:40 dimeshake in a template, loop over files and construct an authorized_keys for example
01:41 Heartsbane so we are doing a maintenance event here and one of coworkers wiped out the DNS servers
01:42 Heartsbane which leads me to salt question
01:42 Heartsbane I can not look up
01:42 dimeshake sounds like quite an event!
01:42 Heartsbane lol
01:42 Heartsbane dimeshake: he rebooted both internal DNS servers
01:42 Heartsbane lol
01:43 dimeshake do they not save states? lol
01:43 Heartsbane so what is the salt command that would get me the kernel version accross all my hosts
01:43 Heartsbane s/version/versions/
01:44 Heartsbane just the kernel versions
01:44 Heartsbane nevermind
01:44 Heartsbane grains.item
01:44 n8n joined #salt
01:45 Heartsbane trial and error
01:45 dimeshake grains.item kernelrelease
01:45 dimeshake ought to do it
01:45 Heartsbane I was typing grains.items
01:45 dave_den dimeshake: where is your data coming from?
01:45 Heartsbane I was typing grains.items
01:45 sat_user_1 did anyone manage to install the latest salt-minion on armel box?
01:46 dimeshake dave_den: right now, from a pillar. for a particular host i have a pillar like, devs: ['user1', 'user2']
01:46 mgw joined #salt
01:46 dimeshake and then a salt state file under ./salt/users/{user1,user2}
01:47 dimeshake i'd like to take the values in user1 and user2 and concat them into one within the salt state
01:47 Heartsbane dimeshake: you give a sysadmin his first maintenance and he decides to patch all the DNS servers and reboot (ALL OF THEM)
01:47 Heartsbane dimeshake: thanks for your help though
01:47 dimeshake basically, assigning multiple keys to a single user's ssh auth
01:47 dimeshake Heartsbane: growing pains ;)
01:47 dimeshake he won't do it again
01:47 dimeshake if he does, wellt hen you know what kinda admin he is
01:47 dimeshake lol
01:48 dave_den so in your authorized_keys.jinja template, just do {% for user in pillar['users'] %}\n {{ user.ssh_pub }}
01:48 dave_den or pass a context to the jinja template
01:49 dimeshake hmmmmm
01:49 dimeshake i was originally tring to do this with source:
01:49 dimeshake so that i could have each dev's key in a single place and refer to them that way
01:49 fllr joined #salt
01:50 Heartsbane dimeshake: well technically his first maintenance event with salt
01:50 * Heartsbane blames UtahDave, for showing us how to do that.
01:50 Heartsbane LOLz
01:51 dimeshake dave_den: http://ix.io/b9Q
01:51 manfred dimeshake: have you tried jinjas join() ? jinja.pocoo.org/2/documentation/switching#filter-arguments
01:51 dimeshake there's an example state
01:51 dimeshake i have a list of siteusers, loop over them - create user, create home, then deal with ssh_auth
01:52 dimeshake i haven't looked at join()
01:52 dimeshake that might do the trick
01:52 manfred dimeshake: http://stackoverflow.com/questions/2061439/string-concatenation-in-jinja
01:53 manfred looks like their site is down, but you should be able to join strings with newlines
01:53 manfred http://isup.me/jinja.pocoo.org
01:54 manfred :(
01:54 manfred guess I will stop refreshing and just making the whole thing worse :)
01:54 dimeshake so i noticed
01:54 dimeshake i'm not sure how to use that, manfred
01:55 dimeshake i don't want the loop to execute if there are no items in the 'devs' list
01:55 dimeshake using stuff assumes that there are, i think
01:55 manfred dimeshake: {{ list_of_keys|join('\n') }}
01:55 dimeshake using join
02:04 Anders__ joined #salt
02:07 puppet joined #salt
02:07 xl1 joined #salt
02:11 troyready joined #salt
02:11 snarfy^ joined #salt
02:13 Furao joined #salt
02:14 manfred will pillars resolve and merge information together, so if I have a users: in two different files, does it merge the dictionaries if both pillars are assigned?
02:14 krow joined #salt
02:16 jcockhren manfred: yes
02:16 manfred jcockhren: awesome
02:18 Ryan_Lane joined #salt
02:19 TyrfingMjolnir joined #salt
02:22 googolhash joined #salt
02:23 rostam joined #salt
02:24 UtahDave Heartsbane: oops!   :)
02:28 mgw joined #salt
02:28 dave_den manfred: it will only merge dicts.
02:28 dave_den pillar keys of lists will be overwritten
02:28 manfred ok
02:31 Networkn3rd joined #salt
02:31 thayne joined #salt
02:33 xl1 joined #salt
02:33 Heartsbane UtahDave: no worries
02:35 Heartsbane UtahDave: remind me to email cro tonight
02:35 fllr joined #salt
02:35 Heartsbane I think I may have fixed the i386 Centos issues
02:35 Heartsbane I will respond to the thread
02:47 GradysGhost joined #salt
02:53 Luke joined #salt
02:55 krow joined #salt
03:06 GradysGhost joined #salt
03:06 manicouman joined #salt
03:07 rgbkrk joined #salt
03:09 pugs left #salt
03:13 bhosmer joined #salt
03:13 pugs joined #salt
03:14 gzcwnk joined #salt
03:14 pugs Hi - Anyone used the docker built in execution module yet?
03:14 gzcwnk anyone in pls?
03:14 gzcwnk how can i trace failures to execute commands?
03:16 gzcwnk so when I do a salt 'target' cmd.run "reboot" and nothing happens, where can I look? mnothing in logs I can see
03:17 Gareth gzcwnk: you need to increase the log level on your minion in the minon conf file or by starting it up using -l debug
03:18 pugs gzcwnk: what user is salt running as?
03:18 gzcwnk when I run a salt '*' test.ping it seems to hang after a few returns, suggesting a master or network issue?
03:18 gzcwnk user is root
03:18 gzcwnk Im trying to set at jobs
03:19 Ryan_Lane joined #salt
03:19 pugs hanging in my experience is a minion that's not responding
03:19 druonysus joined #salt
03:19 druonysus joined #salt
03:20 pugs pretty annoying - you'l have to run that test ping and there's a supplemental argument to see which minions haven't returned
03:20 pugs i'd purge those and it should be fast again
03:20 gzcwnk well i ran iptraf and I can see a connection to the client....
03:20 gzcwnk how do i purge?
03:21 pugs salt-key -L
03:21 pugs salt-key -d <key>
03:22 gzcwnk oh i did taht already
03:22 pugs i'd first just ping everything and append --show-timeout
03:22 pugs to see which minions are timing out
03:23 gzcwnk how do I get the minion to re-request its accepted?
03:24 googolhash_y joined #salt
03:24 pugs I've had an issue like that where they didn't match.  You shoudl just be able to restart the minion.. It's a bit fuzzy but I think you ahve to nuke something cached before that works
03:24 gzcwnk i resrated it.
03:25 tyler-baker left #salt
03:25 schimmy joined #salt
03:25 pugs OH! I think i remember now
03:26 pugs so when you restart you should be able to go on the master and do a salt-key -L to see unaccepted keys
03:26 pugs and the -A to accept
03:26 pugs but if it's bombing out, check the minion logs
03:26 pugs i think if the masters change, i've seen it quiety puke in there before
03:26 gzcwnk yeah its not re-asking
03:27 pugs cat /var/log/salt/minion
03:27 gzcwnk now it has, just a bit slow
03:29 gzcwnk ok that seems to have allowed me to reboot it
03:29 pugs oh, well that's good
03:29 gzcwnk thanks
03:29 pugs no problem
03:29 jeremyfelt joined #salt
03:29 gzcwnk I will run a few more tests
03:30 gzcwnk im trying to get it to patch and reboot
03:30 gzcwnk very simple stuff
03:30 pugs yeah
03:30 pugs I'm trying to use this docker stuff which i'm about to just go rip command line and parse it
03:31 pugs Anyone around here used the docker module yet?
03:32 gzcwnk hehe I dont even know what a docker module is!..
03:32 pugs Supposed to let you manage lifecycle of docker.io linux containers
03:32 pugs Heroku type stuff
03:33 pugs Platform-as-a-Service.  Admittedly, execution module is just a wrapper for stuff I can do today on it
03:33 gzcwnk im none the wiser....
03:33 pugs Just was hoping it would work
03:33 pugs haha
03:33 mgw joined #salt
03:34 gzcwnk im just looking to see if i can auto patch 100 machines at once
03:34 pugs sounds like a good time
03:34 gzcwnk looks like not.
03:34 gzcwnk wierd
03:35 gzcwnk well i want to avoid getting up at 4am
03:37 gzcwnk i can no longer ping the client
03:37 gzcwnk i can no longer test.ping the client
03:37 gzcwnk i think its died again
03:38 gzcwnk yep its no longer working
03:44 krow joined #salt
03:47 pugs is the minion running?
03:48 pugs check the minion log
03:48 pugs tail it even
03:48 forrest joined #salt
03:50 yomilk joined #salt
03:53 joehh joined #salt
03:56 pugs left #salt
03:59 gparent joined #salt
03:59 schimmy joined #salt
03:59 krow joined #salt
04:00 jforest joined #salt
04:02 schimmy1 joined #salt
04:02 smcquay joined #salt
04:04 MTecknology joined #salt
04:12 googolhash joined #salt
04:17 thayne joined #salt
04:18 googolhash joined #salt
04:19 Ryan_Lane joined #salt
04:20 n8n joined #salt
04:26 suckaplease joined #salt
04:26 kuL4 joined #salt
04:28 suckaplease Could anyone please help me figure out why I'm getting a pip.installed found in … is unavailable here: http://pastebin.com/ekJhCpeg
04:29 forrest suckaplease, because you're referencing it incorrectly in your require
04:30 manfred forrest: is he?
04:30 manfred my guess is he needs to refresh_modules
04:30 suckaplease tried it…, but maybe improperly
04:30 forrest suckaplease, you reference via ID, so you'd want something like this https://gist.github.com/gravyboat/9635433
04:30 manfred ahh
04:31 forrest because Salt doesn't understand that uwsgi-packages = python-dev, and python-pip, it just sees it as one ID
04:31 manfred it doesn't correspond the names: into the multiple name: functions
04:31 forrest exactly
04:31 manfred makes sense
04:32 manfred that might fix something that I was having to work around the otherday
04:32 suckaplease forrest: the same thing is happening
04:33 suckaplease http://pastebin.com/bYYxA7qB
04:34 forrest try this: https://gist.github.com/gravyboat/9635433
04:34 forrest I fixed it
04:34 forrest pip.installed doesn't support - pkgs.
04:35 forrest except don't put the name value on the second line like an idiot did (aka me)_
04:35 manfred can you double check, i do think that the older format will work as well with that...
04:35 forrest for - pkgs?
04:35 manfred nah
04:35 manfred with the require: pkg: python-pip
04:35 manfred i wanna know if it works if he can try it
04:35 forrest gotcha
04:36 suckaplease i tried both variations, hmmm
04:36 forrest what was the error that time?
04:37 jalbretsen joined #salt
04:37 suckaplease exact same message
04:38 suckaplease http://pastebin.com/0GPikxmp
04:38 forrest hang on let me spin up a drpolet.
04:38 forrest *droplet
04:38 suckaplease thanks, sorry for the trouble
04:38 manfred http://ix.io/b9X
04:38 manfred this works for me
04:39 forrest manfred, oh cool, I must be mistaken then, I thought you could only reference via ID.
04:39 manfred forrest: so , i think what actually happens is the opposite of what I stated before
04:39 manfred forrest: names: is a built in
04:39 forrest ahh gotcha
04:39 manfred it expands to 1 block per entry in names:
04:40 manfred https://github.com/saltstack/salt/blob/develop/salt/states/pkg.py#L331
04:40 manfred yeah
04:40 manfred names isn't an actual variable
04:40 manfred the purpose of pkgs seems to be so that you can install all of the packages in one shot
04:41 forrest names is now actually documented
04:41 forrest I updated the docs after saltconf
04:41 manfred so if you used pkgs instead of names: then you would need to reference it with the id, becuause then the id would be the name
04:42 suckaplease manfred, i tried what you shared and it's still failing. Is there any way I can figure out why it's still screwed up? could it be a version thing?
04:42 manfred what version are you on for salt?
04:43 suckaplease salt-call 2014.1.0
04:43 suckaplease running a masterless minion on vagrant ubuntu 12.04
04:43 manfred http://ix.io/b9Y
04:43 goodwill no it won't ... I just saw it out with another sysadmin, it won't be calling you back
04:44 manfred that is on rhel box, so it has python-devel instead of -dev
04:44 manfred but it is working
04:44 manfred it should work find in 2014.1.0 can you do -l debug and check for if it is throwing an error?
04:45 manfred forrest: http://ix.io/b9Z
04:46 forrest manfred, cool
04:46 manfred results goes to init.sls
04:46 manfred yar
04:46 forrest good to know I'm not suddenly crazy
04:46 manfred hehe :)
04:47 suckaplease I had to change python-devel => python-dev b/c i'm not loading python-devel anywhere (is that even valid)?
04:48 __number5__ ubuntu/debian called it python-dev
04:48 __number5__ redhat/fedora called it python-devel
04:48 suckaplease ahh, ht
04:49 baniir joined #salt
04:49 forrest the joys of vagrant, anyways I've gotta head out guys, best of luck
04:49 suckaplease k, thanks
04:49 krow joined #salt
04:49 forrest np
04:51 fllr joined #salt
05:01 dren joined #salt
05:01 bhosmer joined #salt
05:01 luminous what's this about cmd.run breaking in 2014.1, with what used to work in 17.x: sal-call cmd.run 'echo hi'
05:01 googolhash joined #salt
05:01 * luminous sadface
05:02 luminous is there a legit reason for this madness?
05:17 suckaplease joined #salt
05:18 yomilk joined #salt
05:20 Ryan_Lane joined #salt
05:21 middleman_ joined #salt
05:22 jesusaur joined #salt
05:27 xl1 joined #salt
05:31 krow joined #salt
05:32 manfred local:
05:32 manfred hi
05:33 manfred what happened?
05:33 manfred bah
05:33 manfred [root@salt ~]# salt-call cmd.run 'echo hi'
05:33 manfred local:
05:33 manfred hi
05:34 luminous manfred: are you on 2014.1?
05:34 manfred i am on develop
05:34 manfred so if it was broke, probably fixed in 2014.1.1 that was just tagged?
05:34 luminous I do not know
05:34 nedrocks joined #salt
05:35 luminous I haven't been able to test with develop yet
05:35 luminous still testing a number of other things first
05:35 krow joined #salt
05:39 krow1 joined #salt
05:41 TheRealBill_here joined #salt
05:41 meteorfo_ joined #salt
05:48 pdayton joined #salt
06:00 Ryan_Lane joined #salt
06:08 schimmy joined #salt
06:10 viod joined #salt
06:14 n8n joined #salt
06:19 schimmy1 joined #salt
06:23 schimmy joined #salt
06:26 terminalmage joined #salt
06:28 meteorfox joined #salt
06:35 fllr joined #salt
06:37 _fllr_ joined #salt
06:39 Shish joined #salt
06:40 Katafalkas joined #salt
06:46 Shish joined #salt
06:48 JordanRinke joined #salt
06:49 bhosmer joined #salt
06:51 dccc joined #salt
06:53 viod joined #salt
06:58 justlooks joined #salt
07:00 justlooks hi,i set a git server and use gitolite do auth and manager ,i can do this " git clone gitolite:salttest.git" successfully ,how can i set salt use this gitfs?
07:15 harobed_ joined #salt
07:20 justlooks i installed GitPython why salt master still complain     Git fileserver backend is enabled in configuration but could not be loaded, is GitPython installed  ?
07:23 justlooks https://gist.github.com/justlooks/9636959
07:28 Iwirada joined #salt
07:30 johtso joined #salt
07:41 krow joined #salt
07:43 justlooks how to handle this https://gist.github.com/justlooks/9637137  The function "state.sls" is running as PID xxx
07:48 yomilk joined #salt
07:49 slav0nic joined #salt
07:56 justlooks if i just use gitfs ,should i need comment file_roots ?
08:06 krow joined #salt
08:08 hhenkel justlooks: As far as I know it's possible to have a mixed environment - therefore gitfs and roots: http://docs.saltstack.com/topics/tutorials/gitfs.html#multiple-backends
08:10 Kenzor joined #salt
08:13 balboah joined #salt
08:16 justlooks hhenkel: here is  details https://gist.github.com/justlooks/9637137
08:16 gammalget joined #salt
08:19 Ashleyb joined #salt
08:22 hhenkel justlooks: I guess your gitfs_remotes is wrong - have a look at: http://docs.saltstack.com/topics/tutorials/gitfs.html#multiple-remotes
08:24 giantlock joined #salt
08:25 justlooks hhenkel: i use gitolite to manager git server , if i can clone using this url ,i think it will fine as master do
08:28 hhenkel justlooks: IMHO you're not using a valid syntax. From the man page it looks like a git repo starts with git:// or with file:///
08:35 actum1933 joined #salt
08:36 Ashleyb can I ask a newbie question please?
08:36 techdragon ask away
08:36 Ashleyb Is it possible to abort a batched cmd run after a certain number of machines fail the command in some way? eg. I have 1000 minions and I want to run /usr/bin/command_that_might_fail in batches of 5, but stop early if 10 or more machines error
08:36 fllr joined #salt
08:37 yomilk_ joined #salt
08:38 Ashleyb can a module track minion state?
08:38 JonBal joined #salt
08:40 krow joined #salt
08:43 Shenril joined #salt
08:48 yomilk joined #salt
08:51 techdragon hrm...
08:51 techdragon theoretically id say yes... but id also say its a bad idea.
08:51 Ashleyb why?
08:53 ThomasJ|d joined #salt
08:53 techdragon It would be better coordinating that via minion targeting in whatever tool your using to run the commands.
08:53 techdragon like jenkins or equivalent.
08:54 zz_cro joined #salt
08:55 Ashleyb well no, I want the command to run on all the minions, but there is a chance some might fail for various reasons (eg out of disk space etc), so I want to abort the run before too many fail
08:55 techdragon so you target the minions in sets of 5, execute the command, and set a failure threshold in your CI to abort the build pipeline after 5 failures
08:55 techdragon ahhh
08:55 techdragon i see what you mean.
08:55 mike25ro joined #salt
08:56 topochan joined #salt
08:57 Ashleyb The use case I am thinking of is deploying new software to various machines. I can afford to take say 20 out of service before customers notice a service derogation
08:57 Ashleyb so if there is something wrong the the update steps, I dont want all 1000 machine dead.
08:58 Ashleyb (and I don't really want to watch it roll out) :-)
08:58 mike25ro hey guys.... i have updated my minion and master to version 2014.1.0. I have a simple state that wants to install 2 packages sssd and nss-pam-ldapd. I have this error> The following package(s) were not found, and no possible matches were found in the package db: nss-pam-ldapd, sssd   ... If i log in to the minion... i can install the packages manually with yum install sssd and nss-pam-ldapd
09:00 scalability-junk joined #salt
09:00 ThomasJ|d joined #salt
09:01 techdragon Hrm... Id say you need to reconsider the deploy and try to make it more indempotent. so then the failures don't break the users software
09:01 Ashleyb well it a service
09:01 techdragon But failing that... tackle it in the orchestration layer.
09:01 Ashleyb can you explain?
09:01 mike25ro techdragon: is just a simple pkg.installed ! nothing else
09:02 mike25ro or techdragon to whom were you responding ? :)
09:02 zz_cro joined #salt
09:07 mike25ro damn... i hate updates ...
09:08 techdragon mike25ro, it was to Ashleyb
09:08 mike25ro techdragon: sorry
09:10 Ixan joined #salt
09:11 mike25ro anyone around that can help?
09:13 techdragon Ashleyb if the tool that launches your salt cmds is sufficiently 'clever' then you could, launch the cmds as background jobs or scheduled jobs (http://docs.saltstack.com/topics/jobs/index.html#scheduling-jobs), then poll the state of the jobs in the background using the commands in the job runner tools http://docs.saltstack.com/topics/jobs/index.html#the-jobs-runner and then if a certain number of jobs fail (which you know based on
09:13 techdragon the results coming back from the polling) you abort all the remaining ones.
09:22 * mike25ro crying - head about to explode
09:22 techdragon mike25ro, one sec, let me read yours while my pull request runs through jenkins
09:22 techdragon Ashleyb does that make sense?
09:22 mike25ro techdragon:  thanks buddy
09:23 elfixit joined #salt
09:23 techdragon mike25ro what is the operating system?
09:23 mike25ro centos 6.4
09:24 mike25ro sorry 6.5
09:24 mike25ro yesterday i have updated the master and minion .. bot centos 6.5 and salt 2014.1.0
09:25 techdragon ok, and what do you see in the output of salt-call -l debug state.sls <name of the simple state>
09:25 Ashleyb yes techdragon, thanks for the references. I'll go and have a read. It seems a little clunky though. It would be nice if a single module could do it all for me.
09:25 yomilk joined #salt
09:26 mike25ro techdragon: one sec.. to paste it somewhere
09:26 techdragon Ashleyb it is a little awkward, but it works with little overhead when done right :)
09:26 rofl____ will there be any published videos from Salt Conf?
09:28 Ashleyb Thanks for the help.
09:29 mike25ro techdragon: http://pastebin.com/RKk3VCE6
09:30 mike25ro techdragon: is really weird... i also run the salt-minion -l debug ... nothing that i could see...
09:30 techdragon what does the OS respond with when you manually do the commands salt is trying, repoquery --queryformat="%{NAME}_|-%{VERSION}_|-%{RELEASE}_|-%{ARCH}_|-%{REPOID}"  --all --quiet --whatprovides \'nss-pam-ldapd\' and repoquery --queryformat="%{NAME}_|-%{VERSION}_|-%{RELEASE}_|-%{ARCH}_|-%{REPOID}"  --all --quiet --whatprovides \'sssd\'
09:31 mike25ro techdragon:  nothing ... i run that command... no response
09:31 techdragon no error?
09:32 Shenril joined #salt
09:32 Shenril joined #salt
09:33 techdragon mike25ro i think i may have found your problem - https://github.com/saltstack/salt/issues/11050
09:34 mike25ro techdragon: this is why i hate updating... some fixed, new features added + new bugs
09:35 machmalabala joined #salt
09:35 techdragon Yeah. But at least its been promptly addressed.
09:35 TyrfingMjolnir joined #salt
09:36 mike25ro techdragon: true - no comment about that... but the skip_suggestions is not working ... i have the same error
09:36 fllr joined #salt
09:36 mike25ro ah techdragon.. is only for the next realease
09:36 mike25ro big shit
09:39 mike25ro techdragon:  do you have any idea... how i might fix this?
09:39 techdragon First thought, ... do you mind running from git ?
09:39 techdragon lol
09:39 mike25ro running from git? the salt-master?
09:39 techdragon yeah,
09:39 mike25ro i have to see how to do this ...
09:40 techdragon probably need the minions too,
09:40 techdragon which may be an issue
09:40 mike25ro pf.. then is not possible
09:40 techdragon well its possible, just no good for your circumstances.
09:40 mike25ro techdragon:  true again :)
09:41 techdragon You could get the new code for only that module out of git, create a new module (name it '<oldname> -fixed' or something) and then adjust your state to use that instead of the generic pkg. installed, and then salt should distribute it to the minions automatically.
09:42 mike25ro i have 120+ states
09:42 mike25ro any idea when the new update will be released?
09:46 krow joined #salt
09:48 harobed_ joined #salt
09:50 MrTango joined #salt
09:51 mike25ro techdragon: my solution is to revert to my stable 0.17.1
09:51 techdragon mike25ro that also works.
09:52 mike25ro and ... set up a new test environment .. a new salt-master ... with the latest version ... and check the compatibility ... with my states. Thank for the help techdragon
09:53 zooz joined #salt
09:55 pdayton joined #salt
10:05 lynxman joined #salt
10:06 johtso joined #salt
10:14 NV joined #salt
10:17 ninkotech joined #salt
10:18 rtucker joined #salt
10:27 bhosmer joined #salt
10:33 diegows joined #salt
10:36 fllr joined #salt
10:38 pdayton joined #salt
10:55 Katafalkas joined #salt
10:55 elfixit joined #salt
10:59 goncalo joined #salt
11:00 babilen I seem to have somehow messed up my top.sls and am now getting YAML parsing errors. Details in http://paste.debian.net/88516/ -- Do you see what might be the reason for this or let me know how to deal with it?
11:03 pdayton1 joined #salt
11:06 bhosmer joined #salt
11:07 babilen Not sure why it triggers the "expected <block end>, but found '<block mapping start>" error as I can target just fine with: salt 'foo-web[2-20].example.com' test.ping
11:07 jslatts joined #salt
11:08 yomilk joined #salt
11:10 babilen Err, no I can't. (tested [2-3] actually ...)
11:13 bhosmer_ joined #salt
11:23 bhosmer joined #salt
11:35 bhosmer joined #salt
11:36 fllr joined #salt
11:40 ggoZ joined #salt
11:42 thayne joined #salt
11:47 bhosmer joined #salt
11:51 babilen Under what circumstances with "salt '*' state.highstate" just return without printing any information? It just did for me (targetting a bunch of minions, and the job is still being listed as active in "salt-run jobs.active"
12:06 alfborge joined #salt
12:07 alfborge Is it normal to run a salt-minion on the salt-master, or is there a better way?
12:07 babilen alfborge: Better way to achieve what?
12:08 bitmand babilen: there is a default timeout when executing salt, see the -t option
12:09 babilen bitmand: Ah! That must be it. Thanks :)
12:09 bitmand babilen: np - bit me too in the beginning :)
12:10 suckaplease joined #salt
12:10 babilen And I take it that there is no "just bloody well wait for it to finish" switch? ;)
12:10 alfborge babilen: managing the salt master configuration file and other dependencies...
12:10 alfborge babilen: automating the configuration of the salt master
12:10 babilen alfborge: It's perfectly fine for the master to be its own minion
12:11 alfborge babilen: Thanks, I'll fire it up then
12:17 bhosmer joined #salt
12:23 rojem joined #salt
12:24 fllr joined #salt
12:24 tomasfejfar joined #salt
12:24 oz_akan_ joined #salt
12:25 _fllr_ joined #salt
12:29 tomasfejfar Hi everyone :) I have a question: Is it possible to use jinja and grains in pillar sls files? There is lot of tutorials about using jinja in SLS state templates, but nothing about pillars. What I am trying to archieve is to set config variables based on memory and number of processors of the system dynamically. I could set those directly in the state, but I plan to reuse it on systems with different params. I planned to have "dy
12:29 tomasfejfar namic pillar" with prefilled values that allow to change them and those would then be injected into generic config-generating state that would output them to config file.
12:29 oz_akan_ joined #salt
12:32 yomilk joined #salt
12:33 babilen Is there any way to remove packages with their dependencies on Debian? (i.e. the equivalent of "aptitude purge $PKG") pkg.remove seems to only remove explicitly listed packages.
12:34 babilen Ah, pkg.purge in http://docs.saltstack.com/ref/modules/all/salt.modules.apt.html
12:35 sporkd2 joined #salt
12:36 manicouman joined #salt
12:36 fllr joined #salt
12:40 TyrfingMjolnir joined #salt
12:40 art_ joined #salt
12:41 art_ Hi everybody!
12:44 mapu joined #salt
12:44 Shish joined #salt
12:45 harobed_ joined #salt
12:46 svetlyak40wt Are there a salt state to run some security check on machines, like checking if somebody put private ssh key in a home dir and that permissions on critial files are all right?
12:46 sporkd2 svetlyak40wt:
12:46 sporkd2 http://docs.saltstack.com/ref/states/all/salt.states.file.html
12:46 jaimed joined #salt
12:47 krow joined #salt
12:48 Shish joined #salt
12:48 manicouman joined #salt
12:52 svetlyak40wt sporkd2: it is not the same. I want some thing which could be used like that: http://pastebin.com/xZ0G72rE
12:52 wkf_ joined #salt
12:53 baniir joined #salt
12:53 millz0r joined #salt
12:53 Shish joined #salt
12:54 timoguin joined #salt
12:57 Shish joined #salt
13:02 pdayton joined #salt
13:07 manicouman joined #salt
13:10 suckaplease joined #salt
13:12 racooper joined #salt
13:13 mpanetta joined #salt
13:14 martoss joined #salt
13:15 martoss Hey folks, what's wrong if salt-call -l debug state.highstate gives me a
13:15 gnugnu9 joined #salt
13:15 martoss [DEBUG   ] Results of YAML rendering:
13:15 martoss OrderedDict([('include', ['uwsgi-backend', 'uwsgi-emperor'])])
13:15 martoss Passed invalid arguments: unhashable type: 'dict'
13:15 borgstrom joined #salt
13:17 juicer2 joined #salt
13:22 martoss1 joined #salt
13:24 Gifflen joined #salt
13:29 ggoZ1 joined #salt
13:34 jay-atl joined #salt
13:34 jay-atl Hello everyone!
13:34 sroegner joined #salt
13:34 jay-atl I'm finally resorting to asking for help... I barely have any hair left, as I've been pulling it out over salt the past few days...
13:35 timoguin Sorry to hear that, jay-atl
13:35 DaveQB joined #salt
13:35 jay-atl I've doing a basic hello world type salt script...
13:36 kermit joined #salt
13:36 jay-atl It's vim: pkg: -installed (all on separate lines, like you're supposed too..)
13:36 fllr joined #salt
13:36 jay-atl it works if I just do salt "*" state.sls vim
13:37 Kenzor -installed or - installed ?
13:38 jay-atl But, if I create a top.sls file, such as base: '*': -vim and run salt "*" state.highstate, it doesn't work... I get a 'bool' object is not iterable error on my minion... ugh!
13:38 bhosmer joined #salt
13:38 jay-atl Hmm, is the difference a space after installed?
13:39 timoguin jay-atl, can you pastebin your top.sls and your vim state?
13:39 timoguin and what version of salt are you on?
13:40 R_Shackleford joined #salt
13:40 jay-atl Sure... salt version 2014.1.0 on Ubuntu 13.10, and salt-cloud version 2014.1.0
13:40 elfixit1 joined #salt
13:43 faldridge joined #salt
13:43 jeddi joined #salt
13:43 GradysGhost joined #salt
13:43 jay-atl http://pastebin.com/Bs130Wwq
13:45 jay-atl I have one Minion, it's an ubuntu 13.10 minion.. like I said it installs fine if I do state.sls vim, but fails when I do state.highstate
13:45 jay-atl It's driving me crazy... :'(
13:46 timoguin I think that should work. Looks like that could be a bug.
13:48 krow joined #salt
13:49 jay-atl This is pretty basic stuff... I'd think there would be a lot of people complaining if something this simple didn't work...
13:49 timoguin jay-atl, I'm not sure why it's not parsing your top.sls properly. Are you consistent with all your spacing in the YAML??
13:49 tomasfejfar Is there a way how to do mysql_grant.present with " WITH MAX_QUERIES_PER_HOUR 20"? There is "with grant option" option for the state (which does something different), but nowhere to set the "WITH" contents. Have anyone tried to implement it?
13:50 funzo joined #salt
13:50 jay-atl I think so.. The top.sls file has 0 spaces, 2 spaces, 4 spaces (respectively.) The vim.sls file must be ok, as it works by itself..
13:51 ajprog_laptop1 joined #salt
13:51 jeddi tomasfejfar: the mysql grant stuff is pretty basic - check out the actual source (salt) to confirm it's capabilities.  i raised a request a year or so ago to implement 'with ssl' - but i don't think it's in there yet.
13:51 jeddi jay-atl:  you can do a vim state specifically?
13:51 boakley joined #salt
13:51 timoguin yea he can
13:52 jeddi ack.   i'd just re-type a new file given it's three lines long, just to rule out weirdness in spaces / tabs / eol's.
13:52 quickdry21 joined #salt
13:52 timoguin jay-atl, did you upgrade recently by any chance?
13:52 timoguin I know there was a packaging issue with Ubuntu where an upgrade would leave around .pyc files
13:53 jay-atl I just built this master yesterday... it's about the 5th server I've built as I thought I must have done something wrong...
13:54 timoguin https://github.com/saltstack/salt/issues/10967
13:54 babilen Sorry, not sure about it, but would I run file.missing with "salt 'someglob' state.sls file.missing /path/to/file" ?
13:55 timoguin maybe something to do with that, jay-atl? i don't have a 13.10 machine around to test
13:55 alfborge joined #salt
13:55 jay-atl Hmm, ok, let me try that and see if it works...
13:55 Networkn3rd joined #salt
13:55 HeadAIX joined #salt
13:55 jay-atl Thanks for your help.
13:56 scuwolf joined #salt
13:56 vejdmn joined #salt
13:58 suckaplease joined #salt
13:59 tomasfejfar jeddi: I have no knowledge of python whatsoever :( And it seems that even the module does not allow WITH ... http://salt.readthedocs.org/en/latest/ref/modules/all/salt.modules.mysql.html
13:59 bhosmer joined #salt
13:59 napper2 joined #salt
14:00 nulldude_ joined #salt
14:01 seapasulli joined #salt
14:02 jay-atl I tried deleting the .pyc files and restarting the services but it still doesn't work...
14:02 diegows joined #salt
14:03 jay-atl I'll try it on another linux type and see if that works, if it does then it must be an ubuntu bug...
14:04 TyrfingMjolnir joined #salt
14:06 pnl joined #salt
14:07 bhosmer joined #salt
14:07 babilen How could I run file.missing or file.absent "interactively" ?
14:07 bhosmer joined #salt
14:08 babilen salt 'someglob' state.sls file.missing /path/to/file doesn't return anything (not False)
14:08 mpanetta_ joined #salt
14:11 Gifflen joined #salt
14:13 BogdanR Hello
14:13 BogdanR I have this error when i run jobs.active http://hastebin.com/raw/remapuqeku
14:13 BogdanR Anyone know's what's up with it?
14:14 BogdanR Other then that salt seems to work fine
14:15 mpanetta joined #salt
14:15 suckaplease joined #salt
14:15 jeremyBass joined #salt
14:16 babilen BogdanR: Which version is that?
14:18 BogdanR 2014.1.0
14:19 babilen Okay, works fine here. Can you reproduce it consistently?
14:20 BogdanR It happens every time for me
14:21 ajprog_laptop1 joined #salt
14:21 BogdanR I also have another 2014.1.0 where it doesn't happen
14:21 babilen Ever since you've done something or right from the start? Would it be possible for you to restart the salt-master ?
14:21 babilen https://github.com/saltstack/salt/issues/11151
14:22 rojem joined #salt
14:22 babilen https://github.com/saltstack/salt/pull/11212/files is the commit that fixed that particular bug
14:22 tr_h joined #salt
14:24 BogdanR Cool thanks
14:24 rostam joined #salt
14:24 BogdanR Do you have a suggestion how I can overcome this untill I upgrade?
14:25 babilen You could patch it locally
14:26 timoguin You could also try using saltutil.running, which is what the jobs.active runner actually calls.
14:26 naiyte joined #salt
14:27 BogdanR timoguin: How do I do that?
14:27 timoguin salt '*' saltutil.running
14:28 timoguin I think it will return the running jobs for each minion you match.
14:28 babilen I'm still not sure how to actually execute file.absent manually. I tried "salt '*' state.sls file.missing /path/to/file" but that doesn't return anything. (the file is not missing)
14:28 pdayton joined #salt
14:29 babilen Not sure if that is expected behaviour or if I am doing something wrong ... How would I be expected to run file.missing (or any other state for that matter)
14:30 bhosmer joined #salt
14:33 meteorfox joined #salt
14:33 che-arne joined #salt
14:34 babilen All I want is to delete a couple of files ... any way to do that or will I have to resort to cmd.run ?
14:34 TyrfingMjolnir joined #salt
14:35 krak3n`` joined #salt
14:35 BogdanR babilen: I patched the file localy and still have the same error
14:36 krak3n`` left #salt
14:36 babilen BogdanR: Oh noes! Sorry, it was the only applicable bug report that I could find in the few seconds that I searched for it
14:36 krak3n` joined #salt
14:38 krak3n` joined #salt
14:40 yomilk joined #salt
14:45 Jahkeup joined #salt
14:46 Jahkeup hey what happened to the awesome dash docsets? :C
14:46 Jahkeup I used to be able to search file.touch and get the docs for that module
14:46 Jahkeup but no longer, its quite saddening.
14:48 krow joined #salt
14:49 alunduil joined #salt
14:50 Ahlee babilen: those are not execution states.  Define your desired state file and run it with state.sls
14:51 timoguin or he could use state.single
14:51 fllr joined #salt
14:51 Ahlee right
14:51 Ahlee whatever
14:51 Ahlee and actually
14:52 Ahlee http://docs.saltstack.com/ref/states/all/salt.states.file.html#salt.states.file.missing
14:52 Ahlee missing doesn't remove
14:52 timoguin yea, file.absent does the actually removing
14:53 timoguin actually!
14:56 xerxas joined #salt
14:56 mfournier joined #salt
14:57 babilen Ahlee: I know, that I used to only test. As you see in my earlier comments I was aware of file.absent -- so "salt '*' state.single file.absent .." should work?
14:58 timoguin yea it should. state.single is the correct way to call a single state module
14:59 babilen Wonderful - I used cmd.run for now, but will keep this in mind. Where would that be documented? (I tried to figure it out myself, but ...)
15:00 timoguin here's the main doc that defines the layers of the state system: http://docs.saltstack.com/ref/states/layers.html
15:00 chrisjones joined #salt
15:00 manicouman joined #salt
15:02 babilen timoguin: Ah, splendid. I'll read that now .. I have the feeling as if I should just read everything in there back-to-back before continuing doing anything, but then .. I actually have to do things :)
15:02 mgw joined #salt
15:04 tyler-baker joined #salt
15:06 obimod joined #salt
15:06 meteorfox joined #salt
15:06 jalbretsen joined #salt
15:07 Thiggy joined #salt
15:07 gcbirzan How can I tell which 'virtual' package I'm using, for example, for service?
15:07 obimod goood morning gladiators for good
15:08 gcbirzan Or, aditionally, how can I force using a particular one?
15:09 jeremyfelt joined #salt
15:10 GradysGhost joined #salt
15:11 Ahlee 2014-03-19 10:10:30,214 [salt.master      ][ERROR   ] An extra return was detected from minion minion, please verify the minion, this could be a replay attack
15:11 ckao joined #salt
15:12 obimod sounds like abnormal behavior - http://en.wikipedia.org/wiki/Replay_attack
15:13 Linz joined #salt
15:13 conan_the_destro joined #salt
15:14 Linz joined #salt
15:16 obimod 02:43 niks          the logs say "an extra return was detected from minion, this could be a replay attack" 02:44 raz           hrhr 02:44 niks          so dramatic 02:44 raz           when a system mumbles something explicit about a "replay attack" then it's pretty much always a bug 02:44 raz           i saw this in the docs: salt-run jobs.active 02:44 raz           perhaps something is hung? 02:45 raz           but anyway, i'm really
15:17 obimod https://www.google.com/search?q=site%3Airclog.perlgeek.de+inurl%3Asalt#q=site:irclog.perlgeek.de+inurl:salt+replay
15:17 rallytime joined #salt
15:17 Ahlee thanks
15:18 obimod yw
15:18 Ahlee I'm sure my environment is just freaking out
15:18 Ahlee as per usual
15:18 obimod reminds me of a song
15:22 dave_den gcbirzan: you can override using the 'providers' setting
15:23 dave_den gcbirzan: http://docs.saltstack.com/ref/configuration/minion.html#providers
15:24 timoguin dodm
15:24 timoguin whoops. i didn't know about providers. that's cool.
15:26 quadmasta joined #salt
15:26 ipmb joined #salt
15:27 quadmasta I need some help with halite; I'm trying to understand the select box labeled "target format"
15:27 meteorfox joined #salt
15:27 quadmasta can someone explain what that does?
15:27 GradysGhost joined #salt
15:27 quadmasta does it merely control the visual display of the returned data from the command?
15:28 dave_den i don't use halite, but it sounds like it's the method of targeting, e.g.  minion ID blob, grains, PCRE, IPCIDR, etc
15:29 dave_den http://docs.saltstack.com/topics/targeting/index.html
15:33 mgw joined #salt
15:33 mapu joined #salt
15:34 allanmullan joined #salt
15:35 frasergraham joined #salt
15:35 ze- hey. anyone knows what format will the webinar be published as ? (aka, what should be available/running on your comp before you can attempt...)
15:39 utz joined #salt
15:40 tomasfejfar How do I force the minions to download states from master? I recreated servers from tempalte and now they don't "see" states. with "Data failed to compile:No matching sls found for 'hostsfile' in env 'base'"
15:40 tomasfejfar They are all the same...
15:40 tomasfejfar same hostname, same IP
15:40 tomasfejfar I'm not really sure how to debug this :(
15:41 dave_den tomasfejfar: what version is your master?
15:41 obimod ze-: looks like join.me
15:41 bhosmer_ joined #salt
15:41 timoguin what webinar?
15:41 dave_den tomasfejfar: newer minions have problems talking to older master, so if your minions are 2014.1.0 and your master is < 2014.1.0 you will have problems
15:42 tomasfejfar dave_den: that seems like the problem....
15:42 timoguin oh sweet, found it: http://www.saltstack.com/saltstack-events/saltstack-demo-32014
15:42 tomasfejfar Minion newer than master:
15:42 tomasfejfar - db1.cluster1.levneucebnice.cz
15:42 tomasfejfar - db2.cluster1.levneucebnice.cz
15:42 tomasfejfar - loadbalancer.levneucebnice.cz
15:42 tomasfejfar - web1.levneucebnice.cz
15:42 tomasfejfar Up to date:
15:42 tomasfejfar - master.levneucebnice.cz
15:42 dave_den tomasfejfar: please don't paste in here. use a pastebin service :)
15:43 tomasfejfar sry ...
15:43 dave_den no worries
15:43 baniir joined #salt
15:44 obimod tomasfejfar: target aquired ; P (jk)
15:44 tomasfejfar I know :(
15:44 tomasfejfar dave_den: is it safe to update master from 0.17?
15:45 tomasfejfar dave_den : or would downgrading minions make more sense...
15:45 dave_den if you're not using multimaster, probably. i stick with 0.17, personally.
15:46 tomasfejfar dave_den: ok, that's what I thought... thx
15:46 druonysus joined #salt
15:48 krow joined #salt
15:49 pentabular joined #salt
15:49 druonysus joined #salt
15:49 druonysus joined #salt
15:50 forrest joined #salt
15:51 Ztyx joined #salt
15:51 tomasfejfar dave_den: I added 'version: 0.17' to my minion pkg state, but it does not seem to work. Any ideas? (The following packages failed to install/update: salt-minion=0.17.) Can I somehow
15:52 dave_den tomasfejfar: what distro?
15:52 tomasfejfar debian 7
15:52 schimmy joined #salt
15:52 favadi joined #salt
15:53 tomasfejfar dave_den: I've added the "http://debian.saltstack.com/debian wheezy-saltstack main" repo...
15:53 dave_den use wheezy-saltstack-017
15:53 dave_den http://debian.saltstack.com/
15:55 tomasfejfar dave_den : I see... thx
15:55 schimmy1 joined #salt
15:56 suckaplease joined #salt
15:58 KyleG joined #salt
15:58 KyleG joined #salt
15:59 kzx joined #salt
16:01 sandbender1512 joined #salt
16:02 martoss joined #salt
16:04 mike25ro left #salt
16:05 suckaplease joined #salt
16:06 analogbyte joined #salt
16:09 meteorfox joined #salt
16:12 Ryan_Lane joined #salt
16:15 pdayton joined #salt
16:15 pentabular left #salt
16:16 thayne joined #salt
16:17 ipalreadytaken joined #salt
16:20 seapasulli joined #salt
16:22 Gordonz joined #salt
16:24 Gordonz joined #salt
16:26 mgw joined #salt
16:27 gtmtech joined #salt
16:27 gtmtech morning all
16:28 gtmtech slash afternoon slash evening
16:28 gtmtech I have a Q
16:28 gtmtech When I do "salt-call state.highstate" on a minion it gives me lots of nice information as to what its doing as its happening
16:28 gtmtech When I do "salt <node> state.highstate" on a master, it gives me no information until the job is complete and then gives me a report
16:29 gtmtech adding --log-level=debug doesn't really help
16:29 gtmtech is there a way to get all the nice juicy details as its happening on the master ?
16:29 forrest gtmtech, correct, this is because salt-call is being performed on the minion, so you're seeing all the work done, when you're on the master, it has simply said 'ok minion, you have this job ID, let me know how things go and return data when you are done with the job'
16:29 gtmtech are you saying its not possible forrest ?
16:29 forrest I don't believe there is a way to get the salt-call data on the master as it would then be returning a TON of data back.
16:30 gtmtech OK no prob, I thought I'd ask :)
16:30 forrest gtmtech, yea, I mean maybe someone worked something in, but not that I've seen.
16:30 forrest I don't think you can get that granular with the way jobs work
16:30 joehillen joined #salt
16:33 gtmtech Thanks for your help, I have one other Q - sorry I come from a puppet background. So in puppet I can do a --noop which is useful for showing me what *would* happen if I ran a puppet run on a box. I know salt has something similar by appending test=True to the end, although the irritating thing seems to be that salt stops reporting on the first error reached under this mode, when in fact removing the test=True, doesn't cause salt to fall
16:34 gtmtech Is there a way to show everything under a test=True ?
16:34 gtmtech I'd like to know what is going to happen to my box in its entirety before I apply it sometimes, to make sure I don't wreak too much havoc
16:34 UtahDave joined #salt
16:35 forrest gtmtech, right now there's just test=true
16:35 gtmtech hmm ok :-/
16:36 gtmtech how do you guys have any faith that a production box isn't going to get totally ruined by running a state.highstate ?
16:37 quadmasta testing :)
16:37 gtmtech example - suppose a dev filled in pillar information for a UAT or test environment, but forgot the production values - you'd only realize the error when you ran the state.highstate on prod right?
16:39 quadmasta or if you ran the test on it
16:41 schimmy joined #salt
16:42 utz left #salt
16:42 mateoconfeugo joined #salt
16:45 utz joined #salt
16:46 manicouman joined #salt
16:46 themadcanudist joined #salt
16:46 napper2 joined #salt
16:47 voozl joined #salt
16:47 themadcanudist hey guys, is there a way to test for the existence of a sls module before include: 'ing it?
16:48 smcquay joined #salt
16:48 krow joined #salt
16:49 druonysuse joined #salt
16:49 druonysuse joined #salt
16:49 Networkn3rd joined #salt
16:50 CaptTofu joined #salt
16:50 CaptTofu hi all!
16:51 smcquay joined #salt
16:51 martoss1 joined #salt
16:55 schimmy1 joined #salt
16:55 mgw joined #salt
16:56 davet joined #salt
16:57 schristensen joined #salt
17:04 topochan joined #salt
17:04 jesusaurus hey CaptTofu
17:07 igio joined #salt
17:07 CaptTofu jesusaurus: I love that nickname!
17:08 yano joined #salt
17:10 Heartsbane cro: did you get my email?
17:10 cro I did, had to interview someone this morning, I'm getting to it now.
17:10 cro thank you
17:11 KyleG cro: Do they know python or QA automation? Do they live in/near LA?
17:11 KyleG :P we happen to be looking. hehe
17:11 cro KyleG: python yes, LA no.
17:11 KyleG damnit
17:12 KyleG well, if anyone knows anybody, there's a 4 figure referral reward involved.
17:12 sporkd2 joined #salt
17:12 Heartsbane cro: I have tested that works and that a salt-run manage.down
17:12 Heartsbane shows nothing
17:12 Heartsbane sorry I am still half asleep
17:12 gcbirzan dave_den: Thanks! (belatedly)
17:13 themadcanudist anyone? Is there a way to test for the existence of a salt module before doing an include: on it?
17:13 Iwirada left #salt
17:16 vbabiy joined #salt
17:20 utz joined #salt
17:20 seapasulli joined #salt
17:22 krak3n` joined #salt
17:22 thayne joined #salt
17:24 druonysuse joined #salt
17:26 utz joined #salt
17:29 harobed_ joined #salt
17:29 bhosmer joined #salt
17:30 harobed_ joined #salt
17:30 bhosmer_ joined #salt
17:31 nedrocks joined #salt
17:32 krow joined #salt
17:34 dlloyd joined #salt
17:35 dlloyd does salt not detect ip addresses assigned via ip addr add, when no label is assigned?
17:36 baniir joined #salt
17:36 themadcanudist aight, i believe I figured out how to enumerate all the available states.
17:38 smcquay_ joined #salt
17:40 sporkd2 joined #salt
17:40 fllr joined #salt
17:42 jY dlloyd: it does
17:42 jY ip_interfaces: {'lo': ['127.0.0.1'], 'eth1': ['10.128.2.71', '10.128.2.72']}
17:44 ajw0100 joined #salt
17:45 utz joined #salt
17:45 themadcanudist aight… so, why is it that within a mako template the "env" variable is showing up as not defined?
17:45 dlloyd jY: i have two interfaces on eth0, and am only getting one in grains.items on that host
17:46 dlloyd s/interfaces/addresses
17:46 themadcanudist I'm getting a NameError: 'env' is not defined within a mako template
17:46 themadcanudist it should be available according to: http://docs.saltstack.com/ref/states/vars.html#env
17:46 dlloyd also only one shows in ipv4
17:49 themadcanudist dave_den: you around?
17:49 dlloyd jY: ah, looks like its fixed in a newer version that what i am running
17:49 zain__ joined #salt
17:51 n8n joined #salt
17:52 johtso How can I debug an issue with a specific salt minion not being able to connect to the master? Up until now it has been working fine, but now I can no longer reach it and I see that the minion is "Waiting for minion key to be accepted by the master."
17:52 johtso salt-key show's the minion key having been accepted
17:53 GradysGhost joined #salt
17:53 johtso what else can I look at?
17:53 druonysuse joined #salt
17:53 druonysuse joined #salt
17:54 Kenzor joined #salt
17:54 arthabaska joined #salt
17:56 smcquay joined #salt
17:59 forrest As a heads up, it looks like some of the SaltConf videos have started to go up: http://www.youtube.com/user/SaltStack/videos
18:00 jacksontj forrest: any idea who ca update descriptions? i want to put a link to my slide deck from the video :)
18:04 dave_den themadcanudist: did you try saltenv?
18:04 UtahDave jacksontj: Rhett would be the person to talk to
18:04 themadcanudist dave_den: that worked, figured it out using locals()
18:05 themadcanudist sorry, that's what I did
18:05 dave_den cool
18:05 themadcanudist thx
18:05 dave_den env is not deprecated yet, so that should have still worked in theory, but the tranisition is to saltenv
18:05 Mr_Magic joined #salt
18:05 themadcanudist ahhh
18:05 themadcanudist makes sense
18:07 allanparsons joined #salt
18:08 jacksontj UtahDave: email i assume?
18:08 UtahDave jacksontj: yeah.  rhett@saltstack.com
18:10 johtso i've restarted both the master and minion and still no luck
18:10 johtso still getting "SaltReqTimeoutError: Waited 60 seconds" when the minion tries to authenticate with the master
18:10 johtso I can ping the master as defined in /etc/salt/minion fine
18:11 ajw0100 joined #salt
18:11 johtso I'm not sure what to try next
18:11 johtso I have another two minions that are talking to the master without any problems
18:14 smcquay joined #salt
18:14 suckaplease joined #salt
18:17 ender joined #salt
18:20 allanparsons johtso - i've had similar issues.  ended up having to actually reboot the server, not the service.
18:20 johtso hmm, interesting
18:21 johtso I've just tried deleting the cache on the minion and that doesn't seem to have helped
18:23 dimeshake is there an easy way to construct a managed file via several other files?
18:23 dimeshake i don't necessarily care about order, so file.append might make sense
18:25 Ahlee johtso: remind me, you're on 2014.1.x?
18:25 johtso trying deletion of /etc/salt/pki/minion/minion_master.pub  now
18:25 johtso Ahlee, yep
18:25 Ahlee how many minions to home many worker threads on hte master?
18:26 Ahlee I run 50 worker threads (8 cores) to 300 minions
18:27 johtso Ahlee, just 3 minions, 1 of them being troublesome
18:28 KyleG1 joined #salt
18:28 johtso Ahlee, http://hastebin.com/farilanegu.hs
18:29 themadcanudist previously someone mentioned something about the salt-user list containing many conversations regarding protecting/hiding/encrypting the /var/cache/salt dir on the minion. I'm curious about these conversations, btu I can't seem to find them in the archived google groups.
18:29 gcbirzan they're encrypted!
18:29 themadcanudist gcbirzan: no, it's clear text
18:29 Ahlee that'd be a good disussion to read
18:30 themadcanudist aside from the fact that you don't put sensitive data in your sls files, I'm curious what's been debated/said about this
18:30 Ahlee but, given just how often salt goes into that directory i certianly wouldn't want to pay the overhread
18:31 dave_den allanparsons: re: your question yesterday about how to get the output of a bash script into a salt variable in your state file. You might do: {% set myvar = salt['cmd.script']('salt://your/script.sh').get('stdout', '') %}
18:31 themadcanudist Ahlee: aye.
18:31 gcbirzan encryption is in no way an overhead. but, well, if someone gets access to your minion, they have access to the data too
18:31 gcbirzan if the minion can decrypt it, so can the attacker
18:31 Teknix joined #salt
18:31 johtso Ahlee, I've removed the relevant minion from salt-key, restarted the master and the minion, but no new authentication request in salt-key
18:32 Ahlee johtso: so wait.  Is the issue you can't communicate, or that when it does communicate it times ut?
18:32 johtso Ahlee, I can't communicate at all
18:33 johtso the minion isn't talking to the master, so keeps saying it's trying to authenticate, and when trying to run a command on that minion, clearly it times out
18:33 themadcanudist gcbirzan: yes, precisely. If you own the machine, you own the machine.
18:33 ahammond When is the next planned release due out?
18:34 Ahlee johtso: ok, and your minion's /etc/salt/minion file, it defines master: <hostname of master> and/or your master has a CNAME as salt?
18:34 Ahlee are you _sure_ it can resolve salt and/or the hostname specified?
18:34 Ahlee do you have tcpdump avaiable?  Can you see traffic leaving on 4505/4506? (I can't remember which is which)
18:35 johtso "Attempting to authenticate with the Salt Master at *ip address*"
18:36 johtso pinging that works fine
18:36 johtso from the minion server
18:36 Ahlee ok, so ICMP can get through, can you telnet to port 4505 and 4506 from minion to master?
18:36 Ahlee although, the key was there once
18:36 Ahlee so it worked at one point in the past
18:36 Ahlee but is it working currently
18:37 johtso exactly
18:37 Ahlee no odd routing between the minion and master, right?
18:37 allanparsons aw sweet dave_den
18:37 allanparsons im gonna try it now.
18:37 johtso although I have no removed the key in order to try to get things working again
18:37 johtso *now
18:37 Ahlee dave_den: that's amazing
18:37 Ahlee right
18:38 johtso Ahlee, I can't telnet on those ports, should I be able to?
18:38 allanparsons i presume you can pass args into the script
18:38 Ahlee johtso: what OS and hows it installed
18:38 allanparsons salt://your/script.sh <arg1>
18:38 johtso Ahlee, Ubuntu 12.04.4 LTS
18:39 Ahlee johtso: yes, you need to be able to communicate with the master on those ports
18:39 Ahlee that's the zeromq pub/sub communication channels
18:39 dave_den allanparsons: yes, here are the docs: http://docs.saltstack.com/ref/modules/all/salt.modules.cmdmod.html#salt.modules.cmdmod.script
18:39 Ahlee iptables getting in the way?
18:39 johtso Ahlee, telnet: could not resolve *ipaddress*:4505/telnet: Name or service not known
18:40 Ahlee um. that doesn't look right.  you did telnet <master> 4505 ?
18:40 johtso ah oops, trying that now
18:40 johtso ah interesting, that just hangs on "trying..."
18:41 Ahlee yeah, sounds like while the ports were open at one time, they aren't any longer
18:41 Ahlee check iptables and any ACLs on any swithing infrastructure
18:43 sporkd2 joined #salt
18:43 themadcanudist so, i assume there is not much information/conversation in regards to protecting the cache dir on minions?
18:44 themadcanudist aside from the obvious points?
18:44 dccc joined #salt
18:46 zach_ I was contacted to be an author in a salt book
18:46 zach_ heh
18:47 johtso Ahlee, thanks a lot for the help and being so patient
18:47 rojem joined #salt
18:48 johtso now to work out why my boxes can't talk on those ports :)
18:48 zach strace my friend
18:48 zach It is beautiful
18:48 zach http://linux.die.net/man/1/strace
18:48 * themadcanudist agrees, zach.
18:49 zach I use it for all the things
18:49 zach java, python, perl, c, c#, c++, ruby
18:49 zach It is quite possibly the most helpful tool in linux
18:49 johtso yeah, saw an article on it recently, need to try throwing it at a problem http://chadfowler.com/blog/2014/01/26/the-magic-of-strace/
18:49 zach Strace is more than magic, it is like turning godmode on in a video game
18:50 themadcanudist it can be overwhelming though if debugging something like python… in that case, pdb is your friend.
18:51 krow joined #salt
18:51 zach I deal almost exclusively with java these days :( makes my brain very sad
18:52 arthabaska johtso: the main things you'll want to know are: strage -ftetrace=network -p $pid, strace -fteopen -p $pid, and also how to profile ( -cpe flags?) and the -s string size display flag. that's 95% of my usage, at least
18:52 johtso ah nice, thanks for the tips
18:52 johtso I could use -f salt-minion instead of using the pid in this case too right?
18:53 arthabaska np enjoy. also 2>&1|grep at the end for clarity when needed helps
18:54 zain joined #salt
18:54 arthabaska johtso yes to start a process while watching it (and children)
18:56 KyleG joined #salt
18:56 KyleG joined #salt
18:56 dsgfdfbdfb joined #salt
18:56 dave_den not sure strace will give you anything very helpful, since it seems like you have network issues outside of salt…
18:58 sandbender1512 I have an .sls which depends on stuff in another .sls... when I run state.sls <first state>, I get errors related to the absence of the dependency... is there a way around this, or can cross-sls dependencies only be applied during a highstate run?
18:58 johtso yeah, not going to get me any further, but a nice general method to reach for. Would have given me "[pid 12841] connect(10, {sa_family=AF_INET, sin_port=htons(4506), sin_addr=inet_addr("*ipaddress*")}, 16) = -1 EINPROGRESS (Operation now in progress)"
18:58 johtso although the log output of the minion said as much as well!
18:59 dave_den johtso: a simple 'tcpdump host your.minion.ip' on the master will tell you if the packets are even reaching hte master
18:59 ipalreadytaken joined #salt
18:59 * johtso puts that in the tool belt aswell
19:00 dave_den i would do that, then ping the master from the minion (to make sure you really are pinging the master form the minion), then start salt-minion and see what happens with the tcp connection
19:00 AdamSewell joined #salt
19:00 AdamSewell joined #salt
19:00 Ryan_Lane joined #salt
19:01 dave_den because you cannot telnet to the master port 4505 or 4506, you know the tcp connection is not being fully established
19:01 johtso aha
19:01 dave_den so, focus on which direction is the problem.
19:01 dave_den then go from there
19:02 dave_den this is only going to get harder when it's all over udp in the future, unfortunately.
19:02 KyleG left #salt
19:05 themadcanudist sandbender1512: That's a good question. Anyone have an idea about cross-module deps on state.sls runs?
19:05 dave_den you just need to make sure the other sls is 'include:'d in the first sls
19:07 sandbender1512 hrm... perhaps I'm specifying the include: wrong, because I tried that...
19:07 * sandbender1512 goes to double check before pasting error
19:08 sandbender1512 confirmed: I'm a dumbass :)
19:08 themadcanudist LOL
19:08 sandbender1512 I had multiple include: id's in the sls
19:08 sandbender1512 dave_den: thx ;)
19:10 dave_den np
19:15 suckaplease joined #salt
19:15 zach suckaplease: nice to see another person in here from Austin ;-)
19:18 googolhash joined #salt
19:19 bhosmer_ joined #salt
19:20 allanparsons dave_den .. how do you pass vars into modules?
19:20 allanparsons Rendering SLS "base:deploy" failed: Jinja syntax error: expected token ':', got '}'; line 15
19:20 allanparsons tried both:  {% set commit_id = salt['cmd.script']('salt://deploy/files/git_revision.sh' + ' '.join({{ repository_url }},'').get('stdout', '') %}   AND  {% set commit_id = salt['cmd.script']('salt://deploy/files/git_revision.sh'  + {{ repository_url }}).get('stdout', '') %}
19:21 alekibango joined #salt
19:22 allanparsons ah, i think --template
19:22 allanparsons 1 sec
19:24 jaimed joined #salt
19:26 allanparsons 1 sec
19:29 dave_den is the repository url an argument to the script?
19:30 dave_den salt['cmd.script']('salt://deploy/files/git_revision.sh', '{{ repository_url}}').get('stdout', '')
19:32 dudesalt joined #salt
19:33 krow joined #salt
19:33 dudesalt hi salt gurus so do we have a problem with Salt on OSX ... I see this
19:33 dudesalt sh-3.2# salt '*' state.sls vim macc02g243xdf91.na.bestbuy.com: ----------     State: - pkg     Name:      vim     Function:  installed         Result:    False         Comment:   State pkg.installed found in sls vim is unavailable          Changes:  Summary ------------ Succeeded: 0 Failed:    1 ------------ Total:     1
19:33 seblu manfred: ping?
19:33 schristensen joined #salt
19:33 dave_den dudesalt: please use a pastebin service
19:34 dave_den dudesalt: also, is your minion version newer than your master version?
19:35 krow1 joined #salt
19:35 dudesalt http://pastebin.com/Zet6yTCi here it is .... salt 0.17.4
19:37 dudesalt this is the vim.sls file ... http://pastebin.com/CNZ1BzVG ... cant get to run this
19:37 dave_den dudesalt: i've not used salt in osx, but i believe it only supports pkg provider for homebrew
19:37 dave_den dudesalt: add this to your osx minion config:   providers:\n  pkg: brew
19:37 dudesalt ohh ok
19:37 dave_den if there is a vim formula in brew it should work
19:38 dudesalt gotcha let me see
19:38 dave_den don't forget to restart your salt-minion process
19:40 suckaplease joined #salt
19:44 dudesalt I tried it but doesnt work ... i see this on minion console : [ERROR   ] State pkg.installed found in sls vim is unavailable
19:47 dave_den dudesalt: what does this return:   salt 'http://macc02g243xdf91.na.bestbuy.com/'  cmd.run 'which brew'
19:47 dudesalt No minions matched the target. No command was sent, no jid was assigned.
19:48 dave_den take out the http:// part. stupid adium
19:48 dave_den and the last slash
19:48 krow joined #salt
19:48 dudesalt gotcha here it is
19:48 dave_den dudesalt: the error you are getting means the brew module is not being loaded into salt as the 'pkg' module provider. The brew module does some checks before loading itself. if the checks fail, it will not load.
19:48 dudesalt macc02g243xdf91:     /usr/local/bin/brew
19:48 dave_den https://github.com/saltstack/salt/blob/develop/salt/modules/brew.py#L25
19:49 seblu manfred: why no Type=notify with salt-minion and salt-syndic?
19:49 suckaplease joined #salt
19:49 Katafalkas joined #salt
19:49 dudesalt ahh i see  ... let me try pulling that file
19:49 dave_den dudesalt: here is the providers ref: http://docs.saltstack.com/ref/states/providers.html
19:51 montyboy joined #salt
19:52 schimmy joined #salt
19:52 allanparsons dave_den - yeah, {{ repository_url }} gets set on the line above
19:52 timoguin_ joined #salt
19:53 schimmy1 joined #salt
19:53 dudesalt dave_dev: thanks
19:54 Kenzor joined #salt
19:54 dave_den good luck. how many minions does bestbuy have?
19:56 x5257 joined #salt
19:58 alekibango_ joined #salt
19:58 x5257 Hi, does anybody now if it is possible to use (env) variables in the master config file?
19:59 dave_den the master config file is not templatable and is only loaded as direct yaml load
19:59 analogby1e joined #salt
20:00 x5257 thanks
20:00 allanparsons ah,dave_den... i remember why i didnt go this route before... my ssh config for github is setup under a non-root user
20:00 druonysus joined #salt
20:00 druonysus joined #salt
20:01 allanparsons salt-call cmd.script salt://deploy/files/git_revision.sh salt://deploy/files/git_revision.sh, "git+ssh://git@myproj.github.com/myco/myproj.git", runas=ubuntu
20:01 allanparsons and even when run manually via salt-call i get: OSError: [Errno 2] No such file or directory: 'git+ssh://git@ myproj.github.com/myco/myproj.git,/tmpviE2sz.sh'
20:01 suckaplease joined #salt
20:01 goncalo_ joined #salt
20:02 dave_den well, you have a comma there
20:03 budrose joined #salt
20:04 dave_den and it's trying to execute your git url as the script file
20:05 gkze joined #salt
20:05 rgbkrk joined #salt
20:05 dlloyd left #salt
20:06 gkze hey guys, I'm running into an issue with pulling Pillar data from a Git repo. My config is: ext_pillar: - git: master http://gitlab02.iad/infr/salt.git root=pillar
20:06 gkze and the error I'm getting is
20:06 gkze [salt.pillar      ][ERROR   ] Failed to load ext_pillar git: too many values to unpack
20:07 gkze This is confusing since the states GitFS is working perfectly fine
20:07 jslatts joined #salt
20:07 gkze and I also want to mention that even though I get the error, I am able to get pillar data, which is even more confusing
20:07 dave_den gkze: gitfs and git_pillar are very different code
20:07 gkze gotcha, shouldn't comepare the two
20:07 gkze *compare
20:08 dave_den gkze: are you running 0.17 master?
20:08 allanparsons even if i take the comma out, i get an error
20:08 gkze 2014.1.0 master and minions
20:08 allanparsons salt-call cmd.script salt://deploy/files/git_revision.sh salt://deploy/files/git_revision.sh "git+ssh://git@myproj.github.com/myco/myproj.git", runas=ubuntu
20:09 tdilly joined #salt
20:09 gkze dave_den: does it make a difference?
20:09 forrest joined #salt
20:09 jforest joined #salt
20:09 dave_den gkze: the 'root=' options is added in Helium, which is not yet released
20:10 tdilly I've noticed that after I restart my master server I can't communicate with any of the minons until I manually restart each minion's daemon (SSH in and restart the salt-minion service), Does anyone know why this would happen?
20:10 dave_den gkze: http://docs.saltstack.com/ref/pillar/all/salt.pillar.git_pillar.html#module-salt.pillar.git_pillar
20:10 gkze ah that makes plenty of sense
20:11 yomilk joined #salt
20:11 gkze so should I just slice out the pillar directory into a separate repo for now?
20:11 UtahDave tdilly: you have to wait until the minions reconnect
20:11 UtahDave wait a minute or two
20:11 tdilly UtahDave: Yep I was just too impatient they are trickling in now :)
20:11 [diecast] joined #salt
20:11 dave_den allanparsons: if you want to pastebin your state i can look. or the salt-call commands you are trying
20:11 tdilly I was worried I had something set up incorrectly
20:11 dave_den keep calm and salt on.
20:12 tdilly dave_den: lol
20:12 gkze dave_den: this follows - when is Helium set to be released?
20:12 MTecknology joined #salt
20:12 dave_den not sure
20:13 allanparsons dave_den:  http://pastebin.com/ZnB2WnZM
20:13 dave_den Hydrogen was just released, and that was 4 months after 0.17… maybe UtahDave knows the timeline?
20:13 allanparsons i tried w/o that grep too (i'll utimately need to grep the results)
20:14 Linz joined #salt
20:14 mgw1 joined #salt
20:15 dave_den allanparsons: you won't be able to do the grep
20:16 allanparsons ok, i can probably just write the result to a tmp file and return just the one val in the script
20:16 gkze Thanks a lot dave_den, totally missed the fine print about root= being in helium
20:16 allanparsons i need to run it as {{ user }} as well
20:16 dave_den np gkze
20:16 naiyte joined #salt
20:17 dave_den allanparsons: i would recommend making your script accept options, like '—commit'
20:17 dudesalt no luck Dave :(  thinking of giving up runnign on macosx
20:17 dudesalt http://pastebin.com/bpGj2DjG
20:18 allanparsons ok.
20:18 allanparsons but i still need to pass a git repo into it that's defined via pillar
20:18 dave_den dudesalt: https://github.com/saltstack/salt/issues/8959
20:19 gkze dave_den: if I may, another interesting error: [salt.pillar      ][ERROR   ] Failed to load ext_pillar git: unhashable type: 'OrderedDict'
20:19 gkze now that pillar is in a separate repo
20:19 dave_den allanparsons: you cn do that no problem.
20:19 allanparsons does that commit_id look fine?
20:20 dave_den gkze: that means your info for git_pillar is being loaded as a dict in yaml instead of a scalar
20:21 martoss joined #salt
20:22 gzcwnk joined #salt
20:22 gkze dave_den: I have a top.sls with base:\n - '*':\n - pkgs
20:22 gzcwnk anyone here?
20:22 gkze and a pkgs.sls with a list of packages I want to install
20:22 gkze sorry I don't follow
20:22 gzcwnk once you send a command to a minion, is it expected behavior that you cant send any others until the first has completed?
20:22 martoss1 joined #salt
20:23 krow joined #salt
20:24 dave_den gzcwnk: with the exception of state runs that cannot be run concurrently, you should be able have your minions run multiple commands
20:24 dudesalt dave_den : I still get error in minion log : [ERROR   ] State pkg.installed found in sls vim is unavailable . This is the minion config : master: localhost provider:         pkg: brew
20:24 gzcwnk Ok, well I seem to be getting lockup....ie once a comamnd is sent, no others work unless I reboot the server
20:24 dave_den gkze: your top file is not related to the ordereddict error. the ordereddict error is due to formatting in your master config.
20:25 redondos joined #salt
20:25 redondos joined #salt
20:25 dave_den gzcwnk: run your minion with debug logging on and look at the output. sounds like you're hitting a memory limit possibly.
20:25 alekibango_ joined #salt
20:25 budrose joined #salt
20:26 dave_den dudesalt: you had it almost working with your compare_dicts error. that told use the brew module was being loaded as the package provider, but there was a bug with the module that is fixed in 2014.1.0
20:26 dave_den use/us
20:27 gzcwnk more like some sort of comms failure I think, all Im running a is a simple yum -y update
20:28 gkze dave_den: this is all I have: ext_pillar:\n  - git: master http://gitlab02.iad/infr/pillar.git
20:28 ggoZ joined #salt
20:29 dave_den gzcwnk: older versions of zmq had issues (< zmq 3), but i don't think that caused immediate minion communication problems
20:29 UtahDave jacksontj: you around?
20:30 allanparsons does that commit_id look fine?
20:30 allanparsons oops .. sorry... up-arrowed the wrong window
20:30 jacksontj UtahDave: yea, whats up?
20:30 stewpot_ is there some way that we can get grains style data through reactor?
20:31 dave_den gkze: hrm, not sure then. looks correct.
20:31 stewpot_ I need to get host, ip, and domain from grains at new minion
20:32 UtahDave jacksontj: Hey, what version of Salt are you running right now
20:32 UtahDave ?
20:32 jacksontj 2014.01
20:32 jacksontj we've been running it since the RC ;)
20:32 gkze dave_den: yeah it's a bit confusing. It errors out but still pulls the values because when I run a test highstate I can still see the packages I want to install
20:32 jacksontj with the fixes i commited for reactor performance that is
20:33 UtahDave jacksontj: cool.  Are you seeing any issues with not all minion returns showing up on the master's cli?  But they are showing up in the job cache?
20:33 jacksontj get that all the time its not really a bug since the CLI return is a sync interface to the async event system
20:33 UtahDave I'm helping someone with a little over 3000 minions.  Once we start targeting over 1200 or so minions, the master cli stops being reliable
20:33 jacksontj all depends on how busy your minions are and how busy your master is
20:34 UtahDave ah, ok
20:34 jacksontj you can up the timeout
20:34 jacksontj on the cli that is
20:34 jacksontj we have the default set higher... let me get the #
20:34 UtahDave ok, thanks
20:34 jacksontj we have it at 10
20:34 cewood joined #salt
20:34 jacksontj and it works for most-- but at some point you just have to check the job cache ;)
20:34 UtahDave jacksontj: -t 10    ?
20:35 gzcwnk I have the latest rpms off epel
20:35 jacksontj in the master config we have timeout: 10 as the defaul
20:35 jacksontj *defauly
20:35 jacksontj **default
20:35 jacksontj man i can't type ;)
20:35 UtahDave ok, that's nice to know.
20:35 allanparsons dave_den - here's a better pastebin:  http://pastebin.com/hsSZa98v
20:35 UtahDave thanks, man!  I appreciate it!
20:35 ipalreadytaken joined #salt
20:36 jacksontj also, might want to check how many worker processes they have
20:36 dave_den allanparsons: the script path and the arguments are separate arguments to cmd.script
20:36 jacksontj we have 20 (on 24 core boxes)
20:36 jacksontj if your out of worker processes you won't be able to consume the events either
20:36 UtahDave gotcha
20:36 jacksontj so they'll queue up and take longer (probably common for cloud stuff in EC2 where the master is micro or something)
20:37 Katafalkas joined #salt
20:38 allanparsons dave_den... same error with:  {% set commit_id = salt['cmd.script']('salt://deploy/files/git_revision.sh', {{ repository_url }}, runas={{ user }}).get('stdout', '') %}    <======================
20:43 basepi jacksontj: continuing the UtahDave line of questioning, I would expect that if you passed in a -t 60 or something you would get all of the returns on the CLI.  Do you find that to be true?
20:43 greg joined #salt
20:44 greg Hi, Is there a way to list the packages available on the master for the win_repo?
20:45 dave_den allanparsons: you can't nest jinja
20:45 allanparsons womp womp
20:45 dave_den allanparsons: http://pastebin.com/HvkSreFt
20:46 nedrocks joined #salt
20:46 montyboy joined #salt
20:47 rojem joined #salt
20:47 allanparsons woohoo dave_den... that worked!!!!
20:47 allanparsons thank you thank you.
20:48 dave_den that'll be $500   :)
20:48 timoguin and he only accepts CoinYe
20:48 dave_den lol, of course
20:50 basepi DogeCoin
20:50 scurry joined #salt
20:50 basepi greg: pretty sure it's `pkg.list_pkgs`
20:50 basepi but could be wrong.
20:50 dave_den much jinja, very templates.
20:50 allanparsons i have like $3.00 in doge coins
20:51 allanparsons shoulda sold when it was high:  doge4.us
20:51 allanparsons http://doge4.us
20:51 johtso joined #salt
20:56 bhosmer joined #salt
20:56 greg basepi: I'm not getting a full list of available packages. I'm getting what's installed on that minion. winrepo.genrepo returns some dictionaries with the package names in them, but I was curious if there's a simple command to know what's available for installation from a master.
20:57 basepi greg: hrm, i'm not sure off the top of my head, i've never actually used winrepo.  =P
20:57 basepi i was just glancing at the documentation
20:57 bhosmer_ joined #salt
20:58 greg i suppose on linux you'd normally just query the native repository...
20:59 greg ok, thx anyways. i was just curious if i was missing something.
20:59 googolhash joined #salt
21:01 rallyone joined #salt
21:02 bhosmer joined #salt
21:03 bhosmer__ joined #salt
21:03 basepi greg: I would file an issue, so we don't forget about it.  If it doesn't exist, it's something we should add.  But ya, I'm only useful as far as reading the docs and spewing what they say, so basically Not Useful (tm)
21:03 basepi ;)
21:04 rallyone WHy am I getting this error message
21:04 rallyone and then crash?
21:04 rallyone http://i.imgur.com/kcQPbVA.jpg
21:04 Gareth do not click that link.
21:04 whiteinge ^^ NSFW
21:04 greg This works: salt '*' pkg.get_repo_data. Returns everything though but does the trick.
21:05 rallyone was kicked by basepi: rallyone
21:05 whiteinge jackass
21:06 rojem joined #salt
21:08 dimeshake ping basepi UtahDave
21:09 londo_ joined #salt
21:09 Ahlee grumble grumble saltenv vs env backporting fixes grumble grumble
21:09 RandalSchwartz joined #salt
21:09 RandalSchwartz I'm trying to learn salt and freebsd pkgng management in the same day
21:10 RandalSchwartz trying to go through the tutorial to understand the state files
21:10 xmj ol.
21:10 RandalSchwartz is mod_python: \n pkg \n installed the same as mod_python: \n pkg.installed
21:11 RandalSchwartz because so far, I've now seen it both ways
21:11 Ahlee Yes
21:11 RandalSchwartz and how do you guys talk about YAML in IRC... it's like talking about python
21:11 Ahlee RandalSchwartz: liberal use of pastebin/gists/etc
21:11 RandalSchwartz Ahlee - why isn't that spelled out pretty early in the tutorial then?  all it says is "you can do it this way or that" without explaining how they are equivalent.
21:11 bharper joined #salt
21:12 johtso joined #salt
21:12 basepi Ahlee: sorry about that, i think that caught a lot of people by surprise despite deprecation warnings
21:12 johtso joined #salt
21:12 RandalSchwartz so could I just say extend.apache.service: \n -watch: \n -pkg.mod_python?
21:12 basepi dimeshake: pong
21:13 RandalSchwartz rather than all those levels?
21:13 RandalSchwartz as in, when can a level be turned into a dot, or vice versa?
21:13 Ahlee basepi: how _dare_ you make improvements
21:14 RandalSchwartz or if you can just point me to some good online docs, I can keep reading.
21:14 Ahlee that's beyond my understanding
21:14 whiteinge RandalSchwartz: not for extend, no. the short version is more readable but it has a yaml-specific caveat. i generally recommend against using the short form
21:15 whiteinge most (all?) of the formulas on the saltstack-formulas org use the long-form. i've been wanting to comb through the docs and change everythng to long-form too
21:15 RandalSchwartz why not "for extend"?
21:15 RandalSchwartz what makes it different?
21:15 RandalSchwartz it seems like there's three or four categories of things in the YAML, with no discernable markup to explain why they act differently
21:16 RandalSchwartz that's why I prefer perl over python actually... I know $foo acts differently than @bar. :)
21:16 RandalSchwartz and part of my uphill climb with salt will be learning *just* enough python to not make my jinja blow up
21:16 whiteinge it was added as a special case for the "state declaration" part of a salt state. so salt's state compiler actually looks for both formats. this one is salt-specific and not yaml specific
21:16 whiteinge details on why we don't recommend it now: http://docs.saltstack.com/topics/troubleshooting/yaml_idiosyncrasies.html#yaml-does-not-like-double-short-decs
21:17 * RandalSchwartz reads
21:23 whiteinge RandalSchwartz: this is a little tough to reconcile until get you fairly comfy with yaml syntax. if you view your states using state.show_highstate or state.show_sls and output as json, the data structure starts to be more clear
21:23 whiteinge (at least for me)
21:23 whiteinge RandalSchwartz: for example: http://paste.fedoraproject.org/86889/95264079
21:23 RandalSchwartz I know YAML syntax
21:23 RandalSchwartz (mostly)
21:23 RandalSchwartz I just don't know why something dotted at one level is like a nested hash
21:24 whiteinge ah, in this case it's because salt's state compiler manually extracts the short-form out into the long-form like in my pastebin
21:24 conan_the_destro joined #salt
21:27 jacksontj basepi: generally speaking yes, longer the timeout the more data you get
21:27 jacksontj question is do you care enough about getting all of it now to wait
21:27 basepi jacksontj: agreed. this appears to not be a processing issue, however, but rather some sort of "dropping events" issue.
21:28 basepi jacksontj: thanks for the info, though
21:28 jacksontj in my experience its not dropping events... it just can't process them quick enough
21:28 jacksontj since all the return data is in the job cache
21:29 RandalSchwartz why does the "next" button on the turorial not go to the next page of the tutorial?
21:29 jdenning joined #salt
21:29 bhosmer joined #salt
21:29 RandalSchwartz oh. maybe it does
21:30 whiteinge we re-orged a bunch of the docs a couple weeks ago. it's possible (probably) we missed a thing or two
21:30 RandalSchwartz is contents.html still the master list?
21:31 whiteinge yes
21:31 RandalSchwartz ok... I'll just keep going back to that and drilling down then
21:31 Ahlee basepi: in my experience, uppint past 10 doesn't do much.  If a minion hasn't responded in 10 seconds, it ain't gonna respond in 30
21:32 zain joined #salt
21:32 Ahlee taht said, we leave the default, but most of our scripts/API hits pass -t 60
21:32 dave_den RandalSchwartz: if you want to be able to search *everything* in one big doc, use https://media.readthedocs.org/pdf/salt/latest/salt.pdf
21:32 Chrono joined #salt
21:33 bhosmer joined #salt
21:33 Ahlee 50 worker threads against 8 CPUs, need to re-play with that number to see if recent improvements allow for same-or-better perf with less thrashing
21:33 bharper I am running into an issue with salt-cloud on CentOS.  I can get it to work using EPEL salt-master packages and apache-libcloud from pip.  It does not work with salt-master from EPEL and apache-libcloud from pip in a virtualenv.  I get an error about needing >= libcloud 0.11.4.  Is this a known issue?
21:33 basepi Ahlee: agreed. we're seeing very odd behavior where the return events are seen by eventlisten.py but not by the get_cli_event_returns() method that outputs to the CLI.  it's super strange
21:33 Ahlee oh awesome
21:34 basepi Ahlee: additionally, if we do a -t 300, and *while that's running* we look up the job cache, we can see that all minions successfully returned, but the CLI doesn't see the events for some reason
21:34 basepi It's a weird one, I've never seen anyone else with an issue quite like it.
21:34 Ahlee ext_job_cache or filesystem?
21:34 RandalSchwartz thanks
21:35 faldridge joined #salt
21:36 calvinhp_mac joined #salt
21:36 RandalSchwartz hmm.  salt '*' test.ping just hanges
21:36 RandalSchwartz hangs
21:36 RandalSchwartz I wonder if my minions are still configured. :(
21:37 calvinhp_mac If I want to try the Helium version, is that the "develop" branch in git?
21:37 vejdmn joined #salt
21:37 Katafalk_ joined #salt
21:37 TyrfingMjolnir joined #salt
21:37 whiteinge calvinhp_mac: yes. expect random breakages!
21:38 calvinhp_mac is there a better way to try out the gitfs_mountpoint feature?
21:38 whiteinge terminalmage: ^^ around?
21:38 * Ahlee perks up
21:38 Linuturk THE RandalSchwartz ?
21:39 RandalSchwartz weird... I have no accepted keys
21:39 RandalSchwartz even though this was all working some time ago
21:39 RandalSchwartz I have only *unaccepted* keys from 4 of the 5 hosts.
21:39 RandalSchwartz Yeah - tis me
21:40 RandalSchwartz with a client who wants freebsd to use pkgng and salt to configure it
21:40 Linuturk +1 to FLOSS Weekly
21:40 RandalSchwartz so I'm having to learn both at once
21:40 Linuturk thx
21:40 Ahlee well that certianly explains the love of perl above, now doesn't it
21:40 whiteinge RandalSchwartz: did the minion id change? the master would see that as a new minion if so
21:40 * calvinhp_mac uses FreeBSD, salt and pkgng :-)
21:40 RandalSchwartz what would make the minion id change?
21:40 Linuturk upgrading the minion maybe?
21:40 * Linuturk isn't sure
21:41 Ahlee RandalSchwartz: minion_id is stored /etc/salt/minion_id
21:41 Ahlee alternately can be defined in /etc/salt/minion, or is generated via gethostname called via one of hte python methods
21:41 RandalSchwartz looks the same as before
21:41 RandalSchwartz how do I force a new handshake
21:42 RandalSchwartz as in, what do I type on the minion to reset it
21:42 Ahlee stop the minion, salt-key -y -d <id> on master;  remove /etc/salt/pki on minion, start minion
21:42 scurry joined #salt
21:43 krow joined #salt
21:43 RandalSchwartz ahh... can't start minion
21:44 RandalSchwartz something about "distribution not found"
21:44 RandalSchwartz some python traceback
21:44 RandalSchwartz File "/usr/local/bin/salt-minion", line 5, in <module>
21:44 RandalSchwartz from pkg_resources import load_entry_point
21:44 RandalSchwartz etc
21:44 RandalSchwartz is this known?
21:44 RandalSchwartz looks like python 2.7
21:44 whiteinge what version are you running and how did you install?
21:44 RandalSchwartz ahh, looking for "markupsafe"
21:45 Ahlee maybe while it's building the grains?
21:45 RandalSchwartz well - we've outsourced package builds on these machines
21:45 calvinhp_mac RandalSchwartz: sounds like a setuptools/distribute issue
21:45 Ahlee or i suppose it does a bunch of checks for how it's going to load in the virtuals?
21:45 Ahlee anyway
21:45 schristensen joined #salt
21:46 RandalSchwartz lemme try on one of the other hosts where the minion might be running :)
21:47 RandalSchwartz ahh - salt minion failing everywhere
21:48 whiteinge what did you do, ray?
21:49 martoss joined #salt
21:49 RandalSchwartz the minion on the same machine as the master seems to launch
21:50 RandalSchwartz and responds to 'test.ping'.  This is a good sign
21:50 RandalSchwartz now I just have to rebuild the rest of the machines properly. :)
21:51 CaptTofu joined #salt
21:53 whiteinge RandalSchwartz: we do have freebsd packages -- if there's not another biz req for the custom packages that is
21:53 johtso joined #salt
21:53 RandalSchwartz Hmm.  it has both py27-salt-0.17.4 and 'salt-0.11.1' installed
21:53 RandalSchwartz is that a problem? :)
21:53 RandalSchwartz maybe there was a note in "upgrading" that wasn't followed
21:53 whiteinge o_O
21:53 RandalSchwartz ahh - the port was renamed from salt to py-salt
21:54 RandalSchwartz now I have to figure out how to use the package mangler to do the right thing
21:54 RandalSchwartz (the old package manager)
21:54 Linuturk mangler lol
21:55 RandalSchwartz oooh... that was simple
21:55 RandalSchwartz just pkg_delete salt-0.11.1, and salt minion starts!
21:56 [diecast] joined #salt
21:56 * xmj slaps RandalSchwartz with pkgng
21:57 RandalSchwartz test.ping now ok to all machines!
21:57 * RandalSchwartz does happy dance
21:57 RandalSchwartz now I can go back to reading
21:57 xmj RandalSchwartz: now go install ports-mgmt/pkg and use the new stuff.
21:57 RandalSchwartz already doing that, but one machine at a time. :)
21:58 RandalSchwartz stretch is already on pkgng, and I'm rebuilding all the ports
21:58 RandalSchwartz while that's going on, I'm reading the salt docs and trying things out
21:58 xmj haha sheesh
21:58 tr_h joined #salt
21:59 bhosmer joined #salt
21:59 seapasulli joined #salt
22:00 alunduil joined #salt
22:05 g4rlic joined #salt
22:07 yomilk joined #salt
22:09 timoguin joined #salt
22:10 rojem joined #salt
22:10 schristensen joined #salt
22:11 RandalSchwartz grains.ls lists the grain types, but not their value
22:12 RandalSchwartz is there a way to get the value.  or even to get more docs online? :)
22:12 themadcanudist joined #salt
22:12 delkins grains.get
22:12 RandalSchwartz ahh
22:12 * delkins waves to merlyn
22:13 RandalSchwartz grains.get takes one arg... but the error message doesn't really tell me what that arg should be
22:13 RandalSchwartz I had similar problems with salt-key
22:13 themadcanudist left #salt
22:13 RandalSchwartz error message saying "you must put an option here" is silly
22:13 RandalSchwartz tell me WTF option
22:13 RandalSchwartz is all of salt like that?
22:14 RandalSchwartz "you screwed up... but too bad, no hints for you"
22:14 delkins the arg is the grainname
22:14 RandalSchwartz ok... but I put '*' because I wanted them all
22:14 RandalSchwartz and nothing came back
22:14 RandalSchwartz how do you get all the grains *and* their values
22:15 RandalSchwartz I know... read the doc. :)
22:15 RandalSchwartz but WHICH doc
22:15 RandalSchwartz where do I look for this stuff?
22:15 RandalSchwartz "man grains.get" certainly doesn't help :)
22:15 delkins you want grains.items
22:15 RandalSchwartz is there a "salt help" command that describes what these things do?
22:15 delkins http://docs.saltstack.com/ref/modules/all/salt.modules.grains.html#salt.modules.grains.items
22:16 delkins generally google "saltstack state command" or "saltstack modules command"
22:17 RandalSchwartz well - that's a bit silly
22:17 RandalSchwartz what if I'm on a ship or a plane?
22:17 Heartsbane RandalSchwartz: you could try salt <target> sys.doc and it will show you all command available on that target
22:17 RandalSchwartz yes - i saw that.  but where do I get the online details for all those?
22:17 RandalSchwartz err - local details
22:17 RandalSchwartz is there no local docs?
22:17 delkins can get a PDF etc here http://salt.readthedocs.org/en/latest/
22:18 delkins I never got used to using sys.doc but should have
22:18 Heartsbane I also believe you the docs out of the git repo
22:18 RandalSchwartz Yes.  Again.  Why can't I type something on the command line
22:18 RandalSchwartz most tools have their docs nearby
22:18 RandalSchwartz even simple versions in --help
22:18 RandalSchwartz longer ones in "man foo" or .info files
22:19 sandbender1512 are you honestly looking for help here or are you just trolling?
22:19 delkins salt --doc
22:19 johtso joined #salt
22:19 delkins I agree
22:19 RandalSchwartz just expressing frustration
22:20 RandalSchwartz speaking on behalf of everyone new to salt :)
22:20 Heartsbane you could go the minion and do
22:20 Heartsbane salt-call --help
22:20 Heartsbane that will display options that you may be looking for
22:20 sandbender1512 I'm also brand new to salt, and the docs are already driving me a bit nuts in various ways, but I don't feel the need to hop on here and spew ~ 20 lines of non-constructive criticism
22:21 * Heartsbane thinks this is where he should just go back to lurking.
22:21 sandbender1512 everyone here is pretty helpful, if you need help just ask, or if you think there's a deficiency you're welcome to make suggestions/contribute to fixing it.
22:21 RandalSchwartz ahh.  salt-call -d grains is great
22:21 Heartsbane RandalSchwartz: :-)
22:22 dfinn joined #salt
22:22 dfinn is there an easy way to point an existing salt minion at a "test" salt master?
22:22 RandalSchwartz I guess I was dismayed by delkins answer as if it was the only answer.
22:22 dfinn just putting an entry for the test master in /etc/hosts doesn't seem to be working
22:22 mgw joined #salt
22:22 RandalSchwartz since he spoke with great authority :)
22:23 dfinn oh, maybe I spoke too soon
22:23 delkins I learned it from you :)
22:23 g4rlic dfinn: you can specify the master in /etc/salt/minion
22:23 dfinn is an IP OK there?
22:23 bharper an IP will work
22:23 g4rlic dfinn: should be.  Any place a hostname is acceptable, an IP should be as well.
22:23 Heartsbane dfinn: you could change it in the /etc/salt/minion file and then point it to the new master later
22:24 fridiculous joined #salt
22:24 whiteinge RandalSchwartz: behold (or fear): man 7 salt
22:24 fridiculous is there a way to get a list of what was installed on a given minion without looking at the top file?
22:24 Heartsbane Just a thought
22:24 Heartsbane whiteinge: show off!
22:25 fridiculous e.g. i have a minion looking to know what salt states were installed on that minion, or another minion
22:25 Heartsbane whiteinge: you had that coming
22:25 delkins nice
22:25 fridiculous (assuming I have a way to connect to the second minion)
22:25 fridiculous essentially like grains, but for actually salt states
22:26 * Heartsbane did a maintainance upgrade last night with salt and loves the fact that he can use it to check his work.
22:26 suckaplease joined #salt
22:26 Heartsbane No thanks to robawt and fxhp
22:27 xmj best tool for the job, i did an ansible deployment 5m ago :)
22:28 fridiculous what do you guys think? is there a grains['salt-state'].exists param?
22:28 g4rlic fridiculous: state.highstate will tell you which ones failed.
22:28 fridiculous that's on the master
22:28 robawt Heartsbane: you caaaaaalled ;)
22:28 gzcwnk is there a way to get salt to send an alarm to say a pager if a service on a minion isnt running?
22:29 g4rlic gzcwnk: salt reactor might do what you need.  Learning about it this week myself.
22:29 gzcwnk yeah i wondered.
22:29 fridiculous i'm asking... say, i have 3 machines, a master, minion A and minion B, and minion A needs to know what states are on minion B
22:29 fridiculous salt reactor is pretty nifty
22:29 g4rlic fridiculous: why is that the case?
22:29 gzcwnk minions can do peer to peer i think
22:31 utz1 joined #salt
22:31 fxhp Heartsbane - I upgraded all your salt-minions
22:31 fxhp : )
22:33 utz2 joined #salt
22:35 RandalSchwartz are all files in the state tree ending in .sls special?
22:35 RandalSchwartz or just at the top level?
22:35 fridiculous gzcwnk: the reason i need this case is because one of the minions needs to be monitoring X number of other minions
22:37 delkins RS: they are all state files accessible under that path/name
22:37 fridiculous where the other minions have particular salt states attached to them
22:37 gzcwnk fridiculous:  i can undertsand that.
22:37 RandalSchwartz I'm not sure I follow.
22:37 kermit joined #salt
22:38 fridiculous let's say i'm installing redis on 10 servers
22:38 RandalSchwartz if I have /foo/bar/xyz.sls somewhere in my tree
22:38 MedicalJaneParis joined #salt
22:38 fridiculous redis is my salt state
22:38 delkins frid: multi-master with syndic?
22:38 RandalSchwartz would salt treat that specially?
22:38 fridiculous hmm i'll have to look into multi-master
22:38 delkins "specially"?
22:38 RandalSchwartz would it try to parse it for states
22:38 delkins besides as a state name, like "salt '*' state.sls foo.bar.xyz
22:38 RandalSchwartz or can I just use it as a data file?
22:38 bharper left #salt
22:39 delkins the state might only make data, but have you read on "pillars"
22:39 delkins that's more just-data
22:39 fridiculous but i need to make sure that of my 100 servers, the 10 with redis are doing x
22:39 fridiculous the thing is, at any given time
22:39 delkins and per-minion
22:39 fridiculous i can have 8 servers with redis
22:39 RandalSchwartz I guess I'm thinking more of
22:39 fridiculous or 15 servers with redis
22:40 RandalSchwartz installing a tree of files, and one of them happens to be something.sls
22:40 delkins frid: sounds more like you want one(etc) minions to have like zabbix monitoring on some/all others
22:40 RandalSchwartz I recall seeing some "manage recursive files" option
22:40 RandalSchwartz I'm just trying to figure out how special an .sls extension is
22:40 delkins you can send files/directories out to minions from the master
22:40 ChronoOne I think top.sls is the only one that gets automatically searched for states, other sls files only get used if you reference them. But I'm pretty new so correct me if I'm wrong :)
22:40 delkins but sls only helps on interpeting the file
22:40 delkins you have to call the state via top.sls or something top calls
22:40 wkf_ joined #salt
22:41 delkins you can just have files that you call manually too via "salt '*' state.sls statefilename"
22:41 RandalSchwartz ahh, so if I accidentally name one of those deeper .sls files, it's my fault'
22:41 delkins and then call salt on that statename
22:41 delkins the file itself does nothing
22:41 fridiculous zabbix isn't exactly what i'm looking for
22:41 delkins and top.sls only matters when calling "state.highstate"
22:42 fridiculous at least not at the moment
22:42 dfinn well, i got the minion pointing to the test master.  I got the master upgraded to 2014.1.0-1.  And now it looks like the master can't talk to the minion and vice versa.  Nothing really helpful in the logs.  Here's the output from a debug cmd.run from the master
22:42 dfinn http://pastebin.com/PTjj3RGb
22:42 dfinn anything in particular I should look at?
22:42 dfinn the minion is still running 0.17.5
22:42 dfinn make that .4
22:42 delkins did you salt-key?
22:42 dfinn it was working before the upgrade
22:43 dfinn do I need to re-do the key
22:44 gzcwnk interesting dfinn i have a simialr issue
22:44 ender running salt '*' test.ping shows the same minion more than once, is there a fix for this? thx!
22:44 dfinn my guess tried to upgrade the master while I was gone and this is what they ran into as well
22:44 dfinn s/guess/guys
22:44 gzcwnk ender salt-key -L shows the minion more than once?
22:45 ender nah, when i run test.ping on all of the minions ie. salt '*' test.ping
22:45 gzcwnk ender you didnt answer my Q
22:46 ChronoOne Can the grain matcher match against more than one grain at a time, or do you need to use the compound matcher in that case?
22:46 ender apologies, no. salt-key -L only shows 1 instance of each
22:46 schimmy joined #salt
22:46 scurry joined #salt
22:46 gzcwnk k
22:47 gzcwnk try test.ping on that host, do you get 2 replies still?
22:47 meteorfo_ joined #salt
22:48 ender negative, single True responses when running test.ping on the minion
22:48 gzcwnk ok so look at the job for the '*' and see if there is a double reply there
22:48 mgw joined #salt
22:48 dfinn this is interesting.  my minion can successfully do a salt-call state.highstate through the upgraded test.master.  it seems the problem is only when trying to run commands from the master
22:49 gzcwnk dfinn do the commands always fail or sometimes work?
22:50 dfinn never work
22:50 dfinn always time out
22:50 gzcwnk k, my symptom is intermittant
22:50 dfinn this always shows up in the masters log: 2014-03-19 16:40:35,461 [salt.client      ][INFO    ] jid 20140319164032433800 minions set(['productmongodbpqa01.bcinfra.net']) did not return in time
22:51 ender there is double replies when i run. salt '*' saltutil.running
22:51 sroegner joined #salt
22:51 arthabaska quick question, anyone--after a state tree deploy where everything in the file_roots is suddenly replaced, does the salt master require a restart, or any other signal?
22:52 manicouman joined #salt
22:58 RandalSchwartz do the states in the sls map into modules somehow?
22:58 manfred RandalSchwartz: what do you mean?
22:59 RandalSchwartz I mean... apache: \n pkg \n installed
22:59 manfred RandalSchwartz: usually when you want to create a state, you create a module first that does what you are wanting to do, then the state just uses that module to perform the actions, is this what you were asking?
22:59 RandalSchwartz is that really calling 'pkg.installed' apache ?
22:59 RandalSchwartz or something like that
23:00 RandalSchwartz and 'service.running'
23:00 RandalSchwartz and 'service.require.pkg' apache
23:00 manfred there is a pkg.installed state, it checks if it is installed and does all that stuff, then if it isnt installed, it runs __salt__['pkg.install']('apache')
23:00 RandalSchwartz I might be getting the syntax wrong, since I don't understand if there's a mapping
23:00 manfred which calls the module
23:00 RandalSchwartz so there's an indirection somewhere
23:01 manfred __salt__ is a builtin that is injected into every state and module and some other things for calling the salt client.
23:01 RandalSchwartz I can't just look at an SLS file and tell what modules might be run?
23:01 manfred no, you have to look at the salt code
23:01 manfred RandalSchwartz: https://github.com/saltstack/salt/blob/develop/salt/states/pkg.py#L331
23:02 manfred https://github.com/saltstack/salt/blob/develop/salt/states/pkg.py#L620
23:02 RandalSchwartz so states and modules have overlapping namespaces even though they have somewhat distinct semantics
23:02 RandalSchwartz or rather, distinct namespaces that just happen to somewhat correspond.
23:03 RandalSchwartz pkg in a state may or may not have anything to do with pkg in a mdoule
23:03 RandalSchwartz ditto "running"
23:03 RandalSchwartz or "require"
23:03 manfred it doesn't have to, but it usually does
23:03 manfred so
23:03 manfred salt/state/pkg.py has def installed
23:03 manfred that function goes and does a bunch of checking to see if the package is installed already
23:04 jeddi joined #salt
23:04 manfred if not, it calls the pkg module to install it
23:04 manfred usually the names correspond, but you do have overlap
23:04 manfred like, one state may need to call cmd.run for something that the module doesn't take care of
23:04 RandalSchwartz so I'd never use pkg, I'd be using pkgng everywhere
23:05 manfred you don't need to, pkg figures out the os and calls the correct os for you
23:05 manfred so even if you use smartos, you could still use pkg.install
23:05 martoss joined #salt
23:05 manfred or freebsd
23:05 manfred w/e it is
23:05 RandalSchwartz ok
23:06 manfred RandalSchwartz: https://github.com/saltstack/salt/blob/develop/salt/modules/pkg_resource.py
23:06 clemenko joined #salt
23:06 manfred that is the module you are calling when you do salt '*bsd*' pkg.install something
23:06 RandalSchwartz how do I tell { pkg: { fromrepo: 'my.repo' }} globally?
23:06 schimmy joined #salt
23:07 RandalSchwartz or do I have to use it with every single pkg directive?
23:07 manfred wiatsorry
23:07 manfred https://github.com/saltstack/salt/blob/develop/salt/modules/pkgin.py
23:07 manfred that one
23:07 manfred https://github.com/saltstack/salt/blob/develop/salt/modules/pkgin.py#L243
23:07 g4rlic don't forget to use pkg.latest, if you want older machines to get the newest build of a package..
23:08 manfred RandalSchwartz: then that uses pkg_resource.py to parse the stuff you send pkg.install
23:08 manfred and pkg_resource.py sends back the command to run, and that is then run with cmd.run
23:09 manfred https://github.com/saltstack/salt/blob/develop/salt/modules/pkgin.py#L293
23:09 manfred https://github.com/saltstack/salt/blob/develop/salt/modules/pkg_resource.py#L216
23:09 manfred RandalSchwartz: including checks of your grains https://github.com/saltstack/salt/blob/develop/salt/modules/pkg_resource.py#L256
23:09 manfred to figure out which os_family you are in
23:09 manfred to see which package manager to use
23:10 RandalSchwartz and the arguments for the repo?
23:10 manfred it should be able to figure those out in the parse_targets
23:10 RandalSchwartz so where would I spell that out?
23:10 manfred you can use yum, or pkgng  or dpkg directly by specifying the provider
23:10 RandalSchwartz in the grains file?
23:10 manfred RandalSchwartz: you don't need to
23:10 RandalSchwartz Yes. I. Do.
23:11 manfred RandalSchwartz: those grains should be populated by salt/grains/core.py
23:11 RandalSchwartz I do *NOT* want pkgng to go to freebsd.org
23:11 RandalSchwartz it should come to *my* server for install
23:11 manfred oh
23:11 RandalSchwartz where do I spell that out?
23:11 manfred that part
23:11 g4rlic you can't define in freebsd where your repositories connect to?
23:11 manfred RandalSchwartz: https://github.com/saltstack/salt/blob/develop/salt/states/pkg.py#L335
23:11 g4rlic ala: yum.conf, or sources.list?
23:11 manfred RandalSchwartz: fromrepo?
23:12 manfred in your pkg.installed function
23:12 RandalSchwartz right... fromrepo... where do I spell that out
23:12 manfred in the state file
23:12 RandalSchwartz and please don't tell me EVERY SINGLE USE OF pkg
23:12 RandalSchwartz I want a global setting
23:12 manfred i am not aware of a way to set that
23:12 RandalSchwartz Head. Bang. On. Desk.
23:12 RandalSchwartz isn't this being used in corp environs where they have internal repos?
23:13 RandalSchwartz surely they don't list those every time they list "pkg"
23:13 manfred RandalSchwartz: does freebsd not have a file where it is configured where to pull from?
23:13 manfred becaue that is what I would do on rhel or deb or pretty much any distribution I would use
23:13 RandalSchwartz I think it's an environment variable
23:14 RandalSchwartz is there a way to set specific envars when executing pkg
23:14 RandalSchwartz (by that I mean pkgng on freebsd)
23:14 drogoh there's /usr/local/etc/pkg.conf but it doesn't exist by default
23:14 RandalSchwartz ahh... so I could "manage" that file and have it point correctly.
23:14 manfred yes
23:14 RandalSchwartz sorry - new to pkgng
23:14 RandalSchwartz pkg_install (old way) was only environs
23:15 manfred RandalSchwartz: looks like you can also use /usr/local/pkg/repos/something.conf https://wiki.freebsd.org/pkgng
23:15 RandalSchwartz unfortunately, there's still probably no way to say "before you install ANYTHING, make sure this file is up to date"
23:15 arthabaska joined #salt
23:15 fridiculous joined #salt
23:15 manfred you could just set order: 1
23:15 manfred on that file.managed state
23:15 RandalSchwartz Oh?
23:16 RandalSchwartz haven't seen that in the docs yet. :)
23:16 manfred RandalSchwartz: http://docs.saltstack.com/ref/states/ordering.html
23:16 RandalSchwartz thanks
23:16 RandalSchwartz sorry... I'm probably sounding like a real jerk
23:16 manfred RandalSchwartz: http://docs.saltstack.com/ref/states/ordering.html#the-order-option
23:16 RandalSchwartz now I know why I get irritated with people on #perl sometimes :)
23:16 alienresidents joined #salt
23:16 manfred :)
23:17 manfred RandalSchwartz: I spent two years helping people in #archlinux, before giving up on them... nothing could possibly be as bad as that :)
23:17 ajw0100 joined #salt
23:17 RandalSchwartz is there a PDF for the modules and states docs?
23:17 RandalSchwartz so I can offline them and search easier?
23:18 Corey RandalSchwartz: Howdy!
23:18 Corey RandalSchwartz: No there isn't, and there really should be.
23:18 ChronoOne How about https://media.readthedocs.org/pdf/salt/latest/salt.pdf ?
23:18 manfred Corey: doesn't readthedocs.org let you generate it?
23:18 manfred yeah that one
23:18 fridiculous anyone know of any salt modules to get a list of active states on a minion at any given time
23:18 Corey OOh.
23:18 Corey ChronoOne: I owe you a beer.
23:19 manfred Corey: RandalSchwartz http://salt.readthedocs.org/en/latest/
23:19 manfred bottom right
23:19 manfred click the buttom, has a pdf option
23:19 manfred ooohhh also has an epub option
23:19 manfred sorry, bottom left
23:19 manfred the v:latest arrow
23:20 RandalSchwartz manfred - I have that one.  But it dopesn't have *alt* the states, does it?
23:20 RandalSchwartz *all* either :)
23:20 RandalSchwartz Oh, maybe it does
23:20 che-arne joined #salt
23:20 manfred RandalSchwartz: kind of
23:20 manfred RandalSchwartz: https://github.com/saltstack/salt/issues/11355
23:21 manfred not sure if it finished building yet
23:21 manfred but whiteinge had disabled the building
23:21 manfred RandalSchwartz: ♥
23:23 delkins merlyn: see I knew what you wanted
23:24 RandalSchwartz heh
23:26 ajw0100 joined #salt
23:26 rogst joined #salt
23:28 ender i was unaware it's possible to run 2 minion daemons at once...
23:29 ender all of my commands were getting executed twice
23:29 delkins salt closely hews to the zombo ethic
23:36 Katafalkas joined #salt
23:42 g4rlic manfred: truthfully, using Salt states as a monitoring system is probably the wrong path.
23:42 manfred what?
23:42 g4rlic sorry, wrong user.
23:43 manfred :)
23:43 manfred ok
23:43 borgstrom joined #salt
23:44 g4rlic RandalSchwartz: it's worht reading up on Salt's ordering documentation.  The long and short of it, is that it runs the state files in the order they're written, and it executes state files in the order they're matched in top.sls.
23:44 g4rlic So in top.sls, you should generally have a '*': match
23:44 g4rlic and inside that, a file.managed for your custom repositoriy.
23:45 bhosmer joined #salt
23:45 g4rlic that would go a fair way to ensuring that your system is correctly configured without having to specify the repository each time you call pkg.installed or pkg.latest.
23:45 g4rlic Also, it should prevent you from having to sprinke "order: " and "requires:" brackets everywhere.
23:45 borgstrom joined #salt
23:45 g4rlic s/brackets/statements/g
23:48 manicouman joined #salt
23:48 RandalSchwartz ok, thanks
23:49 RandalSchwartz heh... I'm trying to do upgrades... and had to do a force pkg remove
23:49 RandalSchwartz unfortunately, salt depends on that, and now my salt is broken :)
23:49 RandalSchwartz this is why I wanna start building these once, and then installing with pkgng
23:50 Eugene Well there's a name I didn't expect to see in here.
23:50 jalbretsen joined #salt
23:50 RandalSchwartz who... pkgng? :)
23:51 Eugene Yeah, who uses FreeBSD, seriously? :-p
23:52 g4rlic http://docs.saltstack.com/ref/states/ordering.html  <-- ordering reference
23:52 RandalSchwartz yeah saw that
23:53 g4rlic another worthy tip I picked up: in your state files, since ordering counts, the following order of states makes the most sense: packages, files, services, commands
23:53 RandalSchwartz although - in my case, I need a single file installed before *any* package can get installed
23:53 RandalSchwartz but now that I know about that... useful
23:53 * Eugene is a lunatic who believes and idempotence and "run until it works"
23:54 Eugene s/and/in/ wow, brain turn on plz
23:54 g4rlic RandalSchwartz: which is why it should be the first item in the first sls file included in the '*' block of top.sls.
23:54 RandalSchwartz well - for all systems except my master build system :)
23:54 RandalSchwartz oh wait, even there
23:55 RandalSchwartz that way it would just try to connect to itself :)
23:55 xcbt joined #salt

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