| [2008/05/31 00:10:52] <DavidS> lak, i'm having troubles with collecting by tags, can you throw an eye at (14:12:24) pastie: http://pastie.org/205925 by DavidS. ? | ||
| [2008/05/31 00:20:46] <duritong> :qwq/win 41 | ||
| [2008/05/31 00:20:48] <chadh> heh. had me going for a minute | ||
| [2008/05/31 00:20:51] <duritong> blub | ||
| [2008/05/31 00:20:53] <chadh> (crap) | ||
| [2008/05/31 00:21:49] <DavidS> synchronous mistyping :) | ||
| [2008/05/31 00:22:00] <duritong> hehe | ||
| [2008/05/31 00:22:43] <chadh> yeah. screen/irssi is really cool, but it does lead to frequent failed context switches :) | ||
| [2008/05/31 00:23:34] * duritong nods | ||
| [2008/05/31 00:30:41] <ashp> urgh i think i need more coffee | ||
| [2008/05/31 00:31:03] <ashp> i'm inheriting classes that include stuff and it doesn't work and i just can't bring myself to fix it without more coffee :) | ||
| [2008/05/31 00:31:58] <muerr> thats often my excuse. | ||
| [2008/05/31 00:38:20] <ashp> I'm surprised this fails, I have class mysql | ||
| [2008/05/31 00:38:28] <ashp> that includes mysql::install and ::service | ||
| [2008/05/31 00:38:36] <ashp> and then I had class mysql::dbserver inherits mysql | ||
| [2008/05/31 00:38:48] <ashp> and that tried to do a Service['mysql'] override, which fails | ||
| [2008/05/31 00:39:09] <ashp> as only 'subclasses can override parameters', I guess you can't chain them, it has to be a direct decendent | ||
| [2008/05/31 00:39:12] <DavidS> ashp: you have to include the inheriting class too | ||
| [2008/05/31 00:39:24] <DavidS> includes are not inheritance | ||
| [2008/05/31 00:39:45] <ashp> I figured that would break things, maybe I should just do class mysql::dbserver, and not inherit the main class, and just slap the includes in again | ||
| [2008/05/31 00:40:27] <ashp> I'd only be inheriting one line. :) | ||
| [2008/05/31 00:40:53] * DavidS believes that inheritance should only ever be used to create (very) specific modified versions of a common baseclass | ||
| [2008/05/31 00:40:58] <ashp> Oh hmm, this is still failing. I wonder what on earth I'm doing wrong. | ||
| [2008/05/31 00:41:04] <DavidS> i.e. mostly for one-off things | ||
| [2008/05/31 00:41:25] <ashp> I now have class mysql::dbserver, that has incldue mysql::service then beneath that a Service["mysql"] | ||
| [2008/05/31 00:41:33] <ashp> Why would that fail, as I'm including the ::service above? | ||
| [2008/05/31 00:42:37] @ Quit: shake-n-bake: | ||
| [2008/05/31 00:42:47] <DavidS> to override, you need to inherit, not include | ||
| [2008/05/31 00:43:04] <ashp> Oh, of course | ||
| [2008/05/31 00:43:24] <ashp> urgh, this just looks ugly to me now. | ||
| [2008/05/31 00:43:26] <muerr> Which class has your mysql service? | ||
| [2008/05/31 00:43:34] <muerr> mysql, mysql::install or mysql::service? | ||
| [2008/05/31 00:44:09] <ashp> ::service | ||
| [2008/05/31 00:44:20] <muerr> if i read the above correctly, you need class mysql::service inherits mysql, class mysql::dbserver inherits mysql::service | ||
| [2008/05/31 00:44:57] <ashp> This may be awful but what I did was | ||
| [2008/05/31 00:45:10] <muerr> if the only thing you want to override is the Service['mysql'], you just need class mysql::dbserver inherits mysql::service. ::service doesn't *need* to inherit mysql if there's nothing from that class its going to override. | ||
| [2008/05/31 00:45:18] <ashp> mysql includes mysql::install/service. I made mysql::service::dbserver inherit mysql::service, and added the changes there | ||
| [2008/05/31 00:45:32] <ashp> and then I made a mysql::dbserver inherit mysql, and then include the mysql::service::dbserver file | ||
| [2008/05/31 00:46:02] <ashp> That was a really ugly way to make a generic mysql module that can also allow custom changes for the main db servers, but it does however (seem) to work ok. | ||
| [2008/05/31 00:46:55] * muerr peeks at your github | ||
| [2008/05/31 00:47:21] <ashp> I didn't upload this monster to github yet, I don't want to blind people (but I will, right now!) | ||
| [2008/05/31 00:48:10] <muerr> heh. i've got plenty of pretty bad manifests i've written that i will subject the community to (if they choose to look :)) at some point in the next month. | ||
| [2008/05/31 00:48:27] <muerr> of course getting our mail servers up and running with RHCS is a higher priority . | ||
| [2008/05/31 00:49:18] <ashp> http://github.com/apenney/puppet/tree/master/mysql/manifests there, terribleness | ||
| [2008/05/31 00:51:41] <muerr> where is mysql::dbserver included? | ||
| [2008/05/31 00:51:43] <muerr> at the node? | ||
| [2008/05/31 00:52:04] <lak> DavidS: what's your actual collection look like? i don't thing the tag-based queries are quite as consistent as they should be | ||
| [2008/05/31 00:52:25] <ashp> muerr: yeah, in ldap | ||
| [2008/05/31 00:52:34] <muerr> k | ||
| [2008/05/31 00:52:38] <ashp> muerr: It looks hideous, but I just do baseclass: mysql::dbserver | ||
| [2008/05/31 00:52:47] <ashp> I can't think of a cleaner way to do customised bits of generic modules | ||
| [2008/05/31 00:52:52] <muerr> and that also includes mysql? | ||
| [2008/05/31 00:53:17] <ashp> yeah, mysql::dbserver inherits mysql | ||
| [2008/05/31 00:53:17] <muerr> customized bits of generic modules: with a define of course :-) | ||
| [2008/05/31 00:53:27] <ashp> I haven't really messed with defines, and maybe that's making a mistake | ||
| [2008/05/31 00:53:40] <muerr> i feel i've had this conversation before. | ||
| [2008/05/31 00:53:48] <muerr> defines are awesome. | ||
| [2008/05/31 00:53:51] <ashp> but the issue comes of how to integrate it into a external node database, so I tend to just make custom classes and include those | ||
| [2008/05/31 00:54:28] <muerr> I'm sure DavidS has noticed this, since he makes heavy use of defines: as your config code base gets larger and more complex, and you want to make it more flexible, you start using more defines than classes. | ||
| [2008/05/31 00:54:38] <muerr> Because I've certainly noticed that. | ||
| [2008/05/31 00:55:12] <ashp> I think I'm going to spend an hour or so reading through some of DavidS's modules | ||
| [2008/05/31 00:55:21] <ashp> Before all my work was really stuff that globally applied | ||
| [2008/05/31 00:55:40] <muerr> Yeah. Ours too | ||
| [2008/05/31 00:55:49] <ashp> but now I'm starting to have more cases where I have a generic module and then suddenly I need that, but a little more | ||
| [2008/05/31 00:55:51] <muerr> Now we've got more one-off type configs, and defines really work well for that. | ||
| [2008/05/31 00:56:01] <ashp> in this case I have mysql but I just need to throw on a different my.cnf for our main databases | ||
| [2008/05/31 00:56:21] <ashp> another case that made a mess of my modules was apache, that and iclassify is probably built terribly | ||
| [2008/05/31 00:56:45] <muerr> ashp: well, you could solve the my.cnf part with a define for my.cnf. | ||
| [2008/05/31 00:57:13] <muerr> we have a define, mysql::config, that merely builds the my.cnf. | ||
| [2008/05/31 00:57:22] <ashp> http://github.com/apenney/puppet/tree/master/apache/manifests/install.pp | ||
| [2008/05/31 00:57:31] <ashp> If you see in there, you can see what I ended up doing for apache/iclassify | ||
| [2008/05/31 00:57:32] <muerr> we call that on a node basis with the parameters required. we have two separate database pairs that have different my.cnf's | ||
| [2008/05/31 00:57:35] <ashp> it's kind of messy but it works | ||
| [2008/05/31 00:57:57] <ashp> I wonder how I call defines from the node via ldap | ||
| [2008/05/31 00:57:59] <muerr> like i said yesterday. i've used (and written, heh.) heaping piles of horrid looking code because they worked. | ||
| [2008/05/31 00:58:06] <ashp> I should look at that, then start looking at moving some stuff to defines | ||
| [2008/05/31 00:58:16] <ashp> I definitely need to think about moving in that direction as it's getting more and more fragile | ||
| [2008/05/31 00:58:23] <muerr> definename { "${hostname}-something-sensible": } | ||
| [2008/05/31 00:58:29] <ashp> getting the dependencies for iclassify right took about a while | ||
| [2008/05/31 00:58:35] <ashp> er, about a week | ||
| [2008/05/31 00:58:35] @ a-priori joined channel #puppet | ||
| [2008/05/31 00:58:39] <ashp> and that's obviously not going to scale so well | ||
| [2008/05/31 00:58:57] <ashp> I don't want things to become this giant interconnected ball of dependencies that can collapse at any time | ||
| [2008/05/31 00:59:22] <muerr> :) | ||
| [2008/05/31 00:59:33] <ashp> I'm getting more and more in that direction and it's making me nervous | ||
| [2008/05/31 00:59:40] <ashp> with all these overrides and 'clever' things that are cropping up | ||
| [2008/05/31 00:59:44] <muerr> i have 47 defines. | ||
| [2008/05/31 00:59:54] <muerr> actually, 50. | ||
| [2008/05/31 01:00:02] <ashp> Well, I'll spend an hour looking at davids modules, are yours public at all? | ||
| [2008/05/31 01:00:06] <ashp> I have one define, for my network | ||
| [2008/05/31 01:00:08] <muerr> Not yet. | ||
| [2008/05/31 01:00:18] <ashp> and I put that into site.pp as every box needs it configuring! | ||
| [2008/05/31 01:00:27] <muerr> :) | ||
| [2008/05/31 01:00:42] <muerr> i have 7 defines in my network omdule | ||
| [2008/05/31 01:00:44] <muerr> module, too. | ||
| [2008/05/31 01:00:47] <ashp> I almost wish I could write my own puppet book | ||
| [2008/05/31 01:00:53] <ashp> 'Things I learnt as I started writing manifests' | ||
| [2008/05/31 01:00:57] <muerr> I probably could :D | ||
| [2008/05/31 01:01:01] <ashp> Because the path you go through seems to be similar | ||
| [2008/05/31 01:01:11] <ashp> You start basic, then move to modules, then start inheriting stuff, then move to defines.. | ||
| [2008/05/31 01:01:14] <muerr> Given the amount of trees I've killed printing manifests, templates and writing notes, I could. | ||
| [2008/05/31 01:01:17] <lak> nothing's stopping you from writing a book :) | ||
| [2008/05/31 01:01:29] <ashp> just my wife :) | ||
| [2008/05/31 01:01:46] <muerr> lak: only thing keeping me from writing a book is the same thing keeping me from publishing the modules management said could be made public | ||
| [2008/05/31 01:02:02] <ashp> I'm tempted to take a weekend and at least write a mini-document on 'lessons from writing manifests' | ||
| [2008/05/31 01:02:05] <muerr> too much chatting in irc so no time ;-) | ||
| [2008/05/31 01:02:08] <ashp> as I'm fairly sure a lot of the mistakes I made can be avoided | ||
| [2008/05/31 01:02:22] <ashp> shame I'm still making dozens :) | ||
| [2008/05/31 01:02:27] <lak> ashp: that's a great document to make | ||
| [2008/05/31 01:02:41] <lak> i think there are short versions already available, but they need help | ||
| [2008/05/31 01:03:03] <ashp> I'll have to poke around on the wiki and see if there's anything existing that's extendable, a hints and tips guide would be nice | ||
| [2008/05/31 01:03:11] <ashp> there's a lot of things I don't even realise that I know now that I wish I had known when I started | ||
| [2008/05/31 01:03:32] <ashp> even down to little tips like make sure all files belong to modules, not just one fat directory of files you serve out | ||
| [2008/05/31 01:06:32] <ashp> I could always modify the best practices document | ||
| [2008/05/31 01:06:41] <ashp> that's really the right place to put pitfalls you want to avoid | ||
| [2008/05/31 01:08:33] @ Quit: Innocenti: Client Quit | ||
| [2008/05/31 01:08:56] <lak> yeah, and most people read it early on | ||
| [2008/05/31 01:09:03] <muerr> There's really two types of best practices, depending on how scalable you need your configuration to be. | ||
| [2008/05/31 01:09:42] <muerr> There's the omg super scalable, external nodes, storeconfigs, defines everywhere type configs for large and fast growth environments. | ||
| [2008/05/31 01:10:06] <muerr> then there's smaller configs that serve environments of a couple dozen servers at most. | ||
| [2008/05/31 01:10:19] <muerr> I imagine most people are somewhere in between :) | ||
| [2008/05/31 01:10:20] <ashp> The trouble I discovered the hard way | ||
| [2008/05/31 01:10:25] <ashp> is anything I think is a small environment | ||
| [2008/05/31 01:10:36] <ashp> somehow scales in unexpected ways a year later and I have to scrabble to catch up | ||
| [2008/05/31 01:10:46] <muerr> Heh heh. | ||
| [2008/05/31 01:10:58] <muerr> Well, we've got fewer servers now than we planned to have at thsi time a year ago | ||
| [2008/05/31 01:11:29] <ashp> I suppose the other benefit is the more scalable you design the module, the more flexible it normally is by design | ||
| [2008/05/31 01:11:53] <muerr> But we've still got a quite complex environment. we have server pairs for redundancy on things like firewall, vpn, web, dns, smtp, database, etc. so we have a pile of different services on top of the base OS that need to be configured. | ||
| [2008/05/31 01:12:03] <muerr> ashp: and extensible. | ||
| [2008/05/31 01:12:17] <ashp> That's very true, I've only had a few spots where it's been hard to extend my existing modules | ||
| [2008/05/31 01:12:20] <muerr> i was able to add interface handling for bsd to our network module easily. | ||
| [2008/05/31 01:12:26] <ashp> and hopefully, as suggested, defines will help me remove those limitations. | ||
| [2008/05/31 01:12:36] <muerr> it required new defines, but it was much the same :) | ||
| [2008/05/31 01:12:43] <ashp> My interface handling is shamefully basic, but I don't think we have any machines with more than two network interfaces | ||
| [2008/05/31 01:13:04] <muerr> primarily the difference was adding a new template because bsd uses different files and formats than red hat. | ||
| [2008/05/31 01:14:07] <muerr> our network module is someting i'll be posting when i make a public repo. | ||
| [2008/05/31 01:14:18] <muerr> Anyway, I should make this new box build and get cluster on it. | ||
| [2008/05/31 01:17:09] @ shenson is now known as shenson_not_here | ||
| [2008/05/31 01:17:33] <ashp> DavidS: You around? | ||
| [2008/05/31 01:20:26] <DavidS> ashp: pong | ||
| [2008/05/31 01:20:47] <ashp> DavidS: I was just looking at your mysql module | ||
| [2008/05/31 01:20:57] <DavidS> I'd hoped so :) | ||
| [2008/05/31 01:21:02] <DavidS> ... and feared | ||
| [2008/05/31 01:21:06] <ashp> I noticed you collect all the users/databases etc at the end | ||
| [2008/05/31 01:21:13] <ashp> I'm just wondering what the reason for that is/what does it let you do? | ||
| [2008/05/31 01:21:32] <ashp> I didn't even know you could add custom plugins into modules, I haven't gone that far, so it was a surprise to see | ||
| [2008/05/31 01:23:08] <DavidS> ashp: becaus i want to configure a user in the context of one of my hosting vservers, but of course the user has to be configured on the mysql server, which is running in another vserver | ||
| [2008/05/31 01:23:15] <muerr> i recall a post on the mailing list regarding that module | ||
| [2008/05/31 01:23:28] <ashp> DavidS: Ahhh, so it lets you use that stuff in the main hosting module? | ||
| [2008/05/31 01:23:45] <ashp> I'm just trying to work out where in your modules you reference and use that information | ||
| [2008/05/31 01:23:55] <ashp> I'm in hosting/init.pp so I figured it might be the stuff in hosting::database | ||
| [2008/05/31 01:24:07] <DavidS> <<-- confused | ||
| [2008/05/31 01:24:18] <ashp> me too :/ | ||
| [2008/05/31 01:24:48] <ashp> I've not used the storedconfig stuff at all, so my understanding is | ||
| [2008/05/31 01:24:54] <ashp> Mysql_database<<||>> grabs all that info | ||
| [2008/05/31 01:24:58] <ashp> and then you use it elsewhere | ||
| [2008/05/31 01:25:08] <DavidS> other way rount | ||
| [2008/05/31 01:25:10] <DavidS> d* | ||
| [2008/05/31 01:25:19] <DavidS> everyone says @@mysql_database { .... } | ||
| [2008/05/31 01:25:37] <ashp> I wonder if there's a place I can get my brain removed and polished and tuned up. :) | ||
| [2008/05/31 01:25:44] <DavidS> and when i really want to create all databases i say Mysql_database<<||>> | ||
| [2008/05/31 01:25:59] <ashp> Ahhhh, ok | ||
| [2008/05/31 01:26:06] <ashp> I hadn't really dug into the plugin stuff to figure out what was going on | ||
| [2008/05/31 01:26:07] <DavidS> ashp: read wiki:ExportedResources | ||
| [2008/05/31 01:26:09] <gepetto> DavidS: ashp: wiki:ExportedResources is http://reductivelabs.com/trac/puppet/wiki/ExportedResources | ||
| [2008/05/31 01:26:33] <ashp> I just had it flipped in my head and thought the <<||>> was the gathering bit :) | ||
| [2008/05/31 01:26:53] <ashp> I've been avoiding this part of puppet along with defines hoping to get away with not dabbling for as long as possible | ||
| [2008/05/31 01:27:50] <DavidS> ashp: if you are avoiding defines, you're missing out on the greatest part of puppet | ||
| [2008/05/31 01:28:04] <ashp> I've banged into the limitations of what I can do without defines, and it's clear I've had the wrong approach | ||
| [2008/05/31 01:28:07] <DavidS> ashp: and <<||>> is the _gathering_ bit | ||
| [2008/05/31 01:28:20] <ashp> DavidS: I was saying to meurr earlier that my stuff is getting ever more brittle from not being done with defines | ||
| [2008/05/31 01:28:35] <ashp> so I'm just pouring over your modules trying to get to grips with how I'm going to start changing things | ||
| [2008/05/31 01:28:44] <DavidS> defines are _the_ way to go from syntax to semantics | ||
| [2008/05/31 01:29:03] <ashp> previously all my stuff was generic so I didn't really need to meddle in that | ||
| [2008/05/31 01:29:10] <ashp> but now it's all getting more complicated :) | ||
| [2008/05/31 01:29:18] <ashp> Do you call your defines from the node defs? | ||
| [2008/05/31 01:29:49] <ashp> I've seen a lot of backend defines, but not how people are tying them to hosts | ||
| [2008/05/31 01:31:35] @ muer1 joined channel #puppet | ||
| [2008/05/31 01:36:54] <DavidS> ashp: you want to start at my manifests repo then, It's just offline at the moment because i botched a move of the repo :-7 | ||
| [2008/05/31 01:37:08] <ashp> haha :) | ||
| [2008/05/31 01:37:49] <DavidS> not funny | ||
| [2008/05/31 01:38:03] <DavidS> http://git.black.co.at/?p=manifests;a=summary | ||
| [2008/05/31 01:38:06] <DavidS> ^^ there it is | ||
| [2008/05/31 01:38:53] <ashp> I like to hear of other people botching stuff, as sometimes I feel like forest gump in a doctorate class, in here. | ||
| [2008/05/31 01:39:10] <DavidS> on line #113 of the manifest/site.pp there is my mysql server e.g. | ||
| [2008/05/31 01:39:13] <gepetto> DavidS: #113 is http://reductivelabs.com/trac/puppet/ticket/113 "Mounts should remount after changing options" | ||
| [2008/05/31 01:39:34] <ashp> Ahhh, I see it | ||
| [2008/05/31 01:39:43] <ashp> that helps put them into context, thanks! | ||
| [2008/05/31 01:40:00] @ Quit: dysinger: | ||
| [2008/05/31 01:40:05] <DavidS> I just include mysql::server to get all the hosted (i.e. exported stuff) and define a few manually | ||
| [2008/05/31 01:40:10] <DavidS> not very clean, but that's how it is ... | ||
| [2008/05/31 01:40:33] <ashp> Later today I think I'll move stuff out of ldap to iclassify as my external node database, as it seems a pain defining any kind of variables or anything in it | ||
| [2008/05/31 01:40:50] <ashp> be easier to use defines from iclassify, I suspect | ||
| [2008/05/31 01:41:48] <DavidS> *shrug* i haven't used either | ||
| [2008/05/31 01:42:21] <ashp> Sometimes I suspect it would be easier to go back to manually putting them all in | ||
| [2008/05/31 01:42:39] <ashp> But I do think that, once I work out the best way to use them, external nodes are the way to go | ||
| [2008/05/31 01:43:35] @ Quit: DerekW: "Leaving" | ||
| [2008/05/31 01:44:09] @ kambiz joined channel #puppet | ||
| [2008/05/31 01:44:24] * benp- makes coffee | ||
| [2008/05/31 01:44:47] <ashp> Make me an irish one? :) | ||
| [2008/05/31 01:45:33] @ Quit: muerr: Read error: 110 (Connection timed out) | ||
| [2008/05/31 01:46:11] @ Quit: f--z: "KVIrc 3.2.5 Anomalies http://www.kvirc.net/" | ||
| [2008/05/31 01:46:26] @ muer1 is now known as muerr | ||
| [2008/05/31 01:48:58] <benp-> whats in that? bailey's? | ||
| [2008/05/31 01:49:18] <benp-> that does seem appropriate | ||
| [2008/05/31 01:49:23] <ashp> just whiskey I think, you can make anything better with whiskey | ||
| [2008/05/31 01:49:36] <benp-> ahh much better even | ||
| [2008/05/31 01:49:38] <ashp> Irish coffee (Irish: Caife Gaelach) is a cocktail consisting of hot coffee, Irish whiskey, and sugar, stirred, then with thick cream floated on top. | ||
| [2008/05/31 01:49:49] <ashp> I used to go to this little whiskey bar in amsterdam and order those, it was fantastic | ||
| [2008/05/31 01:49:55] <holoway> ashp: iClassify won't really make a difference in using definitions | ||
| [2008/05/31 01:50:16] <holoway> think of definitions as a way to build custom types that are composed of other resources | ||
| [2008/05/31 01:50:18] <benp-> can you use definitons directly from iclassify? | ||
| [2008/05/31 01:50:28] <benp-> or do you have to set variables and wrap them into classes? | ||
| [2008/05/31 01:50:29] <ashp> holoway: I just mean from the node listing in ldap | ||
| [2008/05/31 01:50:36] <ashp> holoway: Right now if I want to set variables in ldap it's a huge hassle | ||
| [2008/05/31 01:50:39] @ AimanA joined channel #puppet | ||
| [2008/05/31 01:50:44] <holoway> ah | ||
| [2008/05/31 01:50:48] <holoway> oh yeah, iclassify makes that a ton easier | ||
| [2008/05/31 01:50:49] <ashp> I either extend the schema or mess around in other ways, and it's a huge pain in the ass | ||
| [2008/05/31 01:50:56] <benp-> (i havent looked at doing external nodes at all before) | ||
| [2008/05/31 01:50:56] <holoway> right | ||
| [2008/05/31 01:51:00] <ashp> That's where I struggle with calling defines and setting variables, it's horrible under ldap | ||
| [2008/05/31 01:51:04] <ashp> ldap is simply the wrong tool for it :) | ||
| [2008/05/31 01:51:05] <holoway> ahhh | ||
| [2008/05/31 01:51:17] <holoway> yeah, iclassify makes it much easier to set variables on nodes | ||
| [2008/05/31 01:51:30] <holoway> since you can use the web ui, or the icagent scripts | ||
| [2008/05/31 01:51:38] <ashp> I made the mistake of trying to make the modules generic and make it so I didn't use defines and variables as part of the node definition, just included different classes based on function | ||
| [2008/05/31 01:51:54] <ashp> because it was too hard to modify ldap, but really I need to focus on moving off ldap rather than avoiding useful functionality just because ldap is a pain | ||
| [2008/05/31 01:52:14] @ Maliuta joined channel #puppet | ||
| [2008/05/31 01:52:28] <holoway> when you say "defines" | ||
| [2008/05/31 01:53:09] <holoway> do you mean "define foo ($bar="baz") {" ? | ||
| [2008/05/31 01:53:25] <holoway> or do you just mean variable definition? | ||
| [2008/05/31 01:53:32] <ashp> I mean define foo {} | ||
| [2008/05/31 01:54:09] <holoway> ok, then I don't understand why LDAP or iClassify would make any diference | ||
| [2008/05/31 01:54:18] <holoway> external node tools can assign attributes or classes to apply to the node | ||
| [2008/05/31 01:54:30] <holoway> and those classes might use a defined type | ||
| [2008/05/31 01:54:32] <holoway> right? | ||
| [2008/05/31 01:54:53] <ashp> I wish I could explain things easier, but I guess what I'm driving at is my current way of say, setting up my main mysql servers | ||
| [2008/05/31 01:54:55] <holoway> is the issue that the options to your defined type would come from variables? | ||
| [2008/05/31 01:55:08] <ashp> holoway: yes, generally I'd be using variables I set to provide the options | ||
| [2008/05/31 01:55:09] <holoway> and setting those variables differently per node is a huge pain in the ass? :) | ||
| [2008/05/31 01:55:13] <ashp> yes :) | ||
| [2008/05/31 01:55:15] <holoway> gotcha | ||
| [2008/05/31 01:55:24] <ashp> There's no easy way to set variables per node without hoop jumping and it's annoying | ||
| [2008/05/31 01:55:34] <ashp> my example for today was setting up mysql | ||
| [2008/05/31 01:55:52] <ashp> I have a mysql module that is 'generic', and then I have iclassify and my main mysql servers that need to extend that base installation | ||
| [2008/05/31 01:55:59] <holoway> right | ||
| [2008/05/31 01:56:06] <holoway> instead of a mysql definition that gets called | ||
| [2008/05/31 01:56:11] <ashp> so I end up with class mysql::dbserver that inherits mysql, and then adds all kinds of modifications | ||
| [2008/05/31 01:56:23] <ashp> and then in ldap I can just include mysql::dbserver, avoiding variables or calling definitions or anything | ||
| [2008/05/31 01:56:33] <ashp> It made sense at the time I was doing it, but it seems fragile as hell the more I add them | ||
| [2008/05/31 01:56:48] <ashp> I should be using a mysql definition and just doing the right stuff in that rather than adding class after class | ||
| [2008/05/31 01:57:29] <ashp> (I assume I can say, list all my requirements as part of the call to the definition from the node, thereby avoiding all my crazy work to override the default require => lines to make sure all required things are in replace | ||
| [2008/05/31 01:57:37] <ashp> Just that alone will make my dependency handling vastly cleaner | ||
| [2008/05/31 01:57:55] <ashp> that's my major concern right now, as I'm growing a web of dependencies where everything depends on everything else and I have to manually define it all | ||
| [2008/05/31 02:02:29] <muerr> fyi, I love puppet. | ||
| [2008/05/31 02:03:50] * ska-fan hasn't gotten around to trying it, yet | ||
| [2008/05/31 02:08:42] <muerr> I do not however love pxe, primarily because the kernel panic that occurred on this pxe boot. | ||
| [2008/05/31 02:15:43] <Volcane> ashp: for solving hard to fix dependencies/relationship enable the graph option and draw the thing | ||
| [2008/05/31 02:15:50] <Volcane> ashp: it makes spotting them and fixing them soooo much easier | ||
| [2008/05/31 02:17:29] <Volcane> ashp: i just thought about it the other night and remembered you having troubles with getting it right | ||
| [2008/05/31 02:18:30] <ashp> A graph option? | ||
| [2008/05/31 02:18:35] <ashp> I could do with a drawing, that's for sure! | ||
| [2008/05/31 02:19:12] <Volcane> it makes dot files, so for graphviz or omnigraffle or something | ||
| [2008/05/31 02:20:03] <Volcane> just loads of blobs with lines between them showing the relationships | ||
| [2008/05/31 02:20:22] <Volcane> handy but they get huge, i have a png export of a simpleish node thats 8meg big | ||
| [2008/05/31 02:24:03] <DavidS> Volcane: how many resources do you have on your "simpleish" node? | ||
| [2008/05/31 02:24:07] <lak> Volcane: wow, that's gigantic | ||
| [2008/05/31 02:24:32] <muerr> thats the reports option right? | ||
| [2008/05/31 02:24:39] @ dysinger joined channel #puppet | ||
| [2008/05/31 02:24:41] <muerr> i've been meaning to enable that. | ||
| [2008/05/31 02:25:15] <DavidS> damn, it takes ages to reconfigure my systems ... | ||
| [2008/05/31 02:25:21] <Volcane> graph option | ||
| [2008/05/31 02:25:50] <DavidS> lak, i'm having troubles with collecting by tags, can you throw an eye at (14:12:24) pastie: http://pastie.org/205925 by DavidS. ? | ||
| [2008/05/31 02:26:10] <lak> DavidS: yeah, i saw earlier; what's your collection look like, and what's the actual problem? | ||
| [2008/05/31 02:26:16] <Volcane> ok, maybe not as simple as I thought | ||
| [2008/05/31 02:26:17] <Volcane> :) | ||
| [2008/05/31 02:26:29] <Volcane> 573 resources | ||
| [2008/05/31 02:26:38] <muerr> rrdgraph? | ||
| [2008/05/31 02:26:42] <Volcane> oh | ||
| [2008/05/31 02:26:42] <Volcane> no | ||
| [2008/05/31 02:26:44] <Volcane> i lie | ||
| [2008/05/31 02:26:49] <Volcane> its hard to figure out how many | ||
| [2008/05/31 02:26:49] <DavidS> Concatenated_file<<|tag=='bind::master'|>> | ||
| [2008/05/31 02:27:08] <DavidS> Volcane: my biggest node has 1200+ | ||
| [2008/05/31 02:27:17] <Volcane> how do you easily find out how many resources? | ||
| [2008/05/31 02:27:34] <DavidS> lak: problem: the Concatenated_file is not collected | ||
| [2008/05/31 02:27:54] <DavidS> Volcane: I'm using storeconfigs and select the database | ||
| [2008/05/31 02:27:54] <Volcane> if you enable graph, it will put files in /var/lib/puppet/state/graphs/*.dot | ||
| [2008/05/31 02:27:57] <Volcane> no rrd or anything | ||
| [2008/05/31 02:28:06] <Volcane> DavidS: ah, not enabled on this specific site unfort | ||
| [2008/05/31 02:28:22] <DavidS> but you can probably interpret the yaml cache too ... | ||
| [2008/05/31 02:28:32] <DavidS> it's just not as convenient | ||
| [2008/05/31 02:29:09] <Volcane> seems grepping for type: in the localconfig.yaml is a good indication | ||
| [2008/05/31 02:29:12] <Volcane> < 300 of those | ||
| [2008/05/31 02:29:18] <Volcane> so not a big node | ||
| [2008/05/31 02:30:33] @ Quit: dysinger: Read error: 104 (Connection reset by peer) | ||
| [2008/05/31 02:31:07] @ Quit: tim|mb: Read error: 110 (Connection timed out) | ||
| [2008/05/31 02:31:10] @ dysinger joined channel #puppet | ||
| [2008/05/31 02:33:26] @ Quit: lutter: "Leaving." | ||
| [2008/05/31 02:33:44] @ Quit: dysinger: Client Quit | ||
| [2008/05/31 02:34:04] @ dysinger joined channel #puppet | ||
| [2008/05/31 02:34:48] @ plathrop joined channel #puppet | ||
| [2008/05/31 02:36:48] <DavidS> err: Could not retrieve catalog: bind::zone is already defined at /srv/puppet/modules-development/bind/manifests/zone.pp:48; cannot redefine at /srv/puppet/modules-development/bind/manifests/zone.pp:48 on node fw-schmidg.edv-bus.at | ||
| [2008/05/31 02:36:52] <DavidS> O'RLY? | ||
| [2008/05/31 02:37:25] <Volcane> not including something twice anywhere perhaps? | ||
| [2008/05/31 02:39:18] <DavidS> Volcane: it's the same file ffs! | ||
| [2008/05/31 02:39:41] @ Quit: kolla: Remote closed the connection | ||
| [2008/05/31 02:40:00] <Volcane> yes, but you could somewhere else have done 'include bind::zone' or whatever it is twice | ||
| [2008/05/31 02:40:02] <DavidS> and it was fixed by restarting the puppetmaster ... hmm :-/ | ||
| [2008/05/31 02:40:09] <DavidS> it's a define | ||
| [2008/05/31 02:40:10] <Volcane> oh that sux | ||
| [2008/05/31 02:42:10] <muerr> our backup server has 823 "type:" entries in localconfig.yaml. I think thats the largest. | ||
| [2008/05/31 02:42:29] <Volcane> muerr: kewl, that'll be one big graph then :) | ||
| [2008/05/31 02:42:31] <muerr> but it has a define statement for every system in our environment for each filesystem we back up. | ||
| [2008/05/31 02:42:50] <muerr> to configure the backup software. | ||
| [2008/05/31 02:42:59] <lak> DavidS: if it's a define, you've got some resource in there that is unique, and thus can't be in a define | ||
| [2008/05/31 02:43:00] <Volcane> i dont find them useful in general, just makes it easy to spot stuff that dont have dependencies | ||
| [2008/05/31 02:43:05] <lak> pull it into a class, and just include the class from there | ||
| [2008/05/31 02:43:55] <DavidS> hmmm ... | ||
| [2008/05/31 02:45:28] <DavidS> it works when i do Concatenated_file<<||>> | ||
| [2008/05/31 02:45:35] <muerr> Volcane: whats that, the graphs? | ||
| [2008/05/31 02:45:39] <Volcane> yip | ||
| [2008/05/31 02:45:42] <DavidS> i.e. the resources are collected correctly | ||
| [2008/05/31 02:45:54] <muerr> yeah, im probably more likely to enable reports in general, rather than just graphs. | ||
| [2008/05/31 02:46:46] * Volcane 's only done the rrd graphs with reports | ||
| [2008/05/31 02:47:45] <Volcane> would be nice to have some tool to browse through all the nodes and see when/what changes they made, not sure if thats what reports for just thinking loud | ||
| [2008/05/31 02:47:58] @ Quit: dysinger: Read error: 104 (Connection reset by peer) | ||
| [2008/05/31 02:48:33] @ dysinger joined channel #puppet | ||
| [2008/05/31 02:49:30] @ dinococcus joined channel #puppet | ||
| [2008/05/31 02:50:11] @ Quit: tim|imac: "Leaving" | ||
| [2008/05/31 02:53:11] <hacim> why cant I do module::define { ${user}-{$name}: user => $user, host => $host, dir => $directory } ? | ||
| [2008/05/31 02:53:21] <hacim> it chokes on the ${user}-{$name}: with the error: | ||
| [2008/05/31 02:53:31] <hacim> Could not parse for environment development: Could not match '${user}-${name}:' | ||
| [2008/05/31 02:54:05] @ tim|imac joined channel #puppet | ||
| [2008/05/31 02:54:21] <lak> hacim: you have to quote it | ||
| [2008/05/31 02:54:28] <muerr> yeah. | ||
| [2008/05/31 02:54:31] <hacim> arrr | ||
| [2008/05/31 02:54:40] <hacim> double quoted? | ||
| [2008/05/31 02:54:44] <muerr> { "${user}-${name}": } | ||
| [2008/05/31 02:54:49] <muerr> double. | ||
| [2008/05/31 02:54:58] <muerr> if you use single, the variables won't get parsed. | ||
| [2008/05/31 02:55:12] <hacim> thanks, that straightens things out in my head | ||
| [2008/05/31 02:55:15] <muerr> generally speaking, its good practice to doublequote resource names. | ||
| [2008/05/31 02:55:58] <DavidS> i try to quote everything that is not a obvious keyword like "true" | ||
| [2008/05/31 02:56:20] <muerr> yup | ||
| [2008/05/31 02:56:21] <muerr> ditto. | ||
| [2008/05/31 02:56:34] <muerr> I even put curly braces around variables for clarity and "just in case" when i use them. | ||
| [2008/05/31 02:57:26] <plathrop> muerr: +1 | ||
| [2008/05/31 02:57:31] <muerr> ensure => "${ensure}" (which usually == installed). | ||
| [2008/05/31 02:58:43] <lak> heh | ||
| [2008/05/31 02:58:51] * lak *so* doesn't follow best practice :) | ||
| [2008/05/31 02:59:07] <DavidS> do i need something else to enable graphs other than putting --graphs on the puppetmaster's cl? | ||
| [2008/05/31 02:59:18] <Volcane> puppetd | ||
| [2008/05/31 02:59:27] <Volcane> graphs are client side | ||
| [2008/05/31 03:00:30] <DavidS> oh | ||
| [2008/05/31 03:02:45] @ Quit: dysinger: | ||
| [2008/05/31 03:02:49] <muerr> lak: you're exempt, you wrote the tool :) | ||
| [2008/05/31 03:03:09] <muerr> so could i get a sample of graphs by doing say, puppetd --test --graphs on a client? | ||
| [2008/05/31 03:03:32] <muerr> hmm... guess not. /usr/sbin/puppetd: unrecognized option `--graphs' | ||
| [2008/05/31 03:03:50] <Volcane> try --graph | ||
| [2008/05/31 03:03:58] <muerr> :) | ||
| [2008/05/31 03:04:12] <muerr> trying $ sudo puppetd --test --reports=rrdgraph :) | ||
| [2008/05/31 03:04:18] <muerr> seeing if that turns up anything interesting. | ||
| [2008/05/31 03:04:46] <DavidS> nirg .. double quotes in titles breakdot | ||
| [2008/05/31 03:05:41] <DavidS> (and I have plenty of those) | ||
| [2008/05/31 03:06:52] <Volcane> ah, the rrd graphs has a graph of resource count :) | ||
| [2008/05/31 03:06:59] <Volcane> thats another way to find out how many resources per host | ||
| [2008/05/31 03:07:08] <muerr> Mmm. | ||
| [2008/05/31 03:07:21] <muerr> ha. I forgot about this one: "Git::Clone[/srv/build/git/davids]" | ||
| [2008/05/31 03:08:04] <muerr> okay i have these .dot files in /var/lib/puppet/state/graphs... what do i do with them? O.o | ||
| [2008/05/31 03:08:24] <Volcane> muerr: http://www.graphviz.org/ | ||
| [2008/05/31 03:09:16] <benp-> if you have a mac, omnigraffle will load them | ||
| [2008/05/31 03:09:22] <Volcane> yeah was about to say :) | ||
| [2008/05/31 03:09:29] <DavidS> dot from imagemagik from unstable just dies on them ;) | ||
| [2008/05/31 03:09:34] * DavidS has just tested | ||
| [2008/05/31 03:09:40] <benp-> nice | ||
| [2008/05/31 03:09:42] <Volcane> but graphviz works well on a mac now too | ||
| [2008/05/31 03:10:11] <benp-> the mac graphviz won some awards or something | ||
| [2008/05/31 03:10:18] <benp-> -s | ||
| [2008/05/31 03:10:24] <Volcane> yeah its pretty nifty, though I'll stick to omni | ||
| [2008/05/31 03:11:04] <DavidS> err. "dot" is actually from graphviz | ||
| [2008/05/31 03:11:30] <Volcane> heh | ||
| [2008/05/31 03:11:44] <DavidS> still, it does crash on me ... | ||
| [2008/05/31 03:11:57] * Volcane has no linux machine with graphcs heads on them, so cant test if it works | ||
| [2008/05/31 03:12:35] <muerr> wow thats a mess. | ||
| [2008/05/31 03:13:12] <Volcane> hehe yeah getting them to nicely arrange into something sensible isnt easy | ||
| [2008/05/31 03:13:21] <muerr> installed graphviz on windows, copied the .dot files over and loaded them, then ran the converter thing. | ||
| [2008/05/31 03:13:28] <DavidS> Volcane: just use dot -Tpng < $somedotfile | ||
| [2008/05/31 03:13:46] <muerr> 4693x2301 pixel gif file. | ||
| [2008/05/31 03:14:44] <Volcane> DavidS: still, would need to install all the X libraries and such to get graphviz on the machine | ||
| [2008/05/31 03:15:24] <muerr> Im kind of scared to run this on our backup server with the 800+ resources :) | ||
| [2008/05/31 03:15:25] @ shenson_not_here is now known as shenson | ||
| [2008/05/31 03:15:34] <Volcane> hehe | ||
| [2008/05/31 03:15:36] <muerr> and this is just relationships.dot | ||
| [2008/05/31 03:15:42] <muerr> not even extended_relationships.dot | ||
| [2008/05/31 03:15:45] <Volcane> muerr: its amazing trhou | ||
| [2008/05/31 03:15:57] <ashp> Oh god, that is the best burger joint in cambridge | ||
| [2008/05/31 03:16:04] <ashp> I missed all the graph stuff, sorry, I got dragged to lunch | ||
| [2008/05/31 03:16:07] <Volcane> muerr: i look at machines i used to manage by hand, 5 "identical" ones, and then i look at this graph for them and realise how impossible that is | ||
| [2008/05/31 03:17:22] <muerr> Yeah, its pretty slick. But man is this unreadable. | ||
| [2008/05/31 03:17:41] <Volcane> yeah | ||
| [2008/05/31 03:17:55] <muerr> especialy our user stuff. | ||
| [2008/05/31 03:17:59] <muerr> thats a freakin nightmare. | ||
| [2008/05/31 03:18:07] <muerr> of course, that was a freaking nightmare to write the manifest for :-\ | ||
| [2008/05/31 03:18:14] <ashp> I dread to see the iclassify graph :) | ||
| [2008/05/31 03:18:14] <Volcane> would be nice to have a graph like that say just for a given module | ||
| [2008/05/31 03:18:17] <Volcane> so you can visualise them | ||
| [2008/05/31 03:18:26] <muerr> oh hmm. | ||
| [2008/05/31 03:18:29] <muerr> I wonder. | ||
| [2008/05/31 03:18:32] <ashp> scrolling back to find out what i'm supposed to be doing :) | ||
| [2008/05/31 03:19:11] <ashp> oh, I can load these in omnigraffle? time to fire up the laptop. | ||
| [2008/05/31 03:19:25] <Volcane> yes, its scary though :) | ||
| [2008/05/31 03:19:48] <Volcane> but when i look at mine, i immediately spot stuff that have no dependencies etc, | ||
| [2008/05/31 03:20:19] <muerr> yeah - even run with --tags=sometag it still graphs the whole thing. | ||
| [2008/05/31 03:20:37] <muerr> that'd be neat if you could graph only a certain tag or set of tags. | ||
| [2008/05/31 03:20:42] <muerr> oh man | ||
| [2008/05/31 03:20:48] <muerr> no dependencies is most of mine. | ||
| [2008/05/31 03:21:14] <muerr> our security module though, has a heaping pile of file{} resources that merely strip permissions (like setuid etc) | ||
| [2008/05/31 03:21:15] <Volcane> yeah, i want to get it to 1 run per box | ||
| [2008/05/31 03:21:25] <Volcane> but unfort i get bitten by the custom fact first run bug | ||
| [2008/05/31 03:21:36] <ashp> 1 run per box is so hard :/ | ||
| [2008/05/31 03:21:49] <ashp> I managed to get that working with our current configuration | ||
| [2008/05/31 03:21:54] <ashp> but changing anything will bring the house of cards down | ||
| [2008/05/31 03:22:10] <ashp> tonight i have to move what I have into 'production', whereby we don't introduce changes that aren't agreed/signed off | ||
| [2008/05/31 03:22:11] <muerr> we need to do two runs. | ||
| [2008/05/31 03:22:17] <plathrop> ashp: It's really hard. | ||
| [2008/05/31 03:22:18] <ashp> and then I'm going to redo everything in a cleaner way (hopefully) | ||
| [2008/05/31 03:22:25] <muerr> at a minimum, two runs. | ||
| [2008/05/31 03:22:34] <ashp> My last fix was to get ruby-shadow in the build system, now it does one run on almost all boxes that I've tested on | ||
| [2008/05/31 03:22:53] <muerr> Primarily because our systems start out life being kickstarted on the build vlan, and the first run configures the network interfaces, which breaks connection to the puppet server midstream. | ||
| [2008/05/31 03:22:54] <ashp> One run was what took the week really, I fixed so many little dependency bugs. | ||
| [2008/05/31 03:23:13] <ashp> The dependency ordering is the hardest part of my configuration and the bit I desperately wish puppet helped with more. | ||
| [2008/05/31 03:23:29] <muerr> plus, when they're built we don't have bonded interfaces, and thus no etherchannel group on the switch, so we have to manually set the switch ports before the second run. | ||
| [2008/05/31 03:23:41] <ashp> I have one main wish that has caused much problems, and that's the ability to change puppet from 'scheduling refreshes', but instead to follow dependency chains executing each action at once. | ||
| [2008/05/31 03:23:58] <ashp> muerr: For the build I have my build server and puppet server in one | ||
| [2008/05/31 03:24:12] <ashp> so as long as the network they change to is open to the puppet server | ||
| [2008/05/31 03:24:13] <muerr> ashp: our puppet server is the build server. | ||
| [2008/05/31 03:24:20] <ashp> it picks back up and carries on fine | ||
| [2008/05/31 03:24:21] <muerr> other than the firewalls its the only server on multiple vlans. | ||
| [2008/05/31 03:24:24] <ashp> and I restart the network half way through | ||
| [2008/05/31 03:25:11] <muerr> ashp: well, in order to bond interfaces, we have to put the switch ports in an etherchannel group. until that happens, no communication. | ||
| [2008/05/31 03:25:20] <muerr> thats a limitation of the switches. | ||
| [2008/05/31 03:25:23] <ashp> Ahhh | ||
| [2008/05/31 03:25:31] <ashp> We don't do any bonding or anything | ||
| [2008/05/31 03:25:34] <muerr> :) | ||
| [2008/05/31 03:25:47] <muerr> the only server we don't have bonded interfaces is the build server. | ||
| [2008/05/31 03:25:49] * Volcane 's rack is full, cant fit a 2nd switch | ||
| [2008/05/31 03:25:55] * Volcane 's ISP is full, cant fit a 2nd rack | ||
| [2008/05/31 03:26:00] <muerr> hehe | ||
| [2008/05/31 03:26:01] * Volcane 's up the creek so to speak | ||
| [2008/05/31 03:26:19] <muerr> we've got plenty of space for probably 8 more racks :) | ||
| [2008/05/31 03:26:34] <Volcane> rack space is such a huge problem in london now | ||
| [2008/05/31 03:26:37] <muerr> but, thats the point of this datacenter im at. our main one was out of space. | ||
| [2008/05/31 03:26:40] <benp-> my data center can't supply us enough power :( | ||
| [2008/05/31 03:27:00] <Volcane> benp-: yeah, u end up with 1/2 full racks, same story here | ||
| [2008/05/31 03:27:24] <muerr> we're lucky. ours can supply use with easily 8 208/30 circuits per rack, and still have capacity. we're just a tiny customer. | ||
| [2008/05/31 03:27:25] * Volcane goes home | ||
| [2008/05/31 03:27:26] <ashp> so what's the difference with extended/relationships, how does it choose the difference | ||
| [2008/05/31 03:27:33] <ashp> oh god this graph is unreadable even in graffle | ||
| [2008/05/31 03:27:48] <muerr> the room our cage is in is half the size of the room one of their largest customers has, and its like 3000 sqft. | ||
| [2008/05/31 03:28:42] <muerr> our current planned growth for the infrastructure in the next 3 years doesn't even put us close to capacity for our little cage. | ||
| [2008/05/31 03:29:11] <ashp> Ahaha, these graphs, I tried to print it | ||
| [2008/05/31 03:29:13] <ashp> it's 51 pages | ||
| [2008/05/31 03:29:15] <muerr> lol | ||
| [2008/05/31 03:29:18] <ashp> this is going to be a mess | ||
| [2008/05/31 03:29:23] <muerr> yeah i wouldn't even bother. | ||
| [2008/05/31 03:29:23] <plathrop> The graph is really useful, though! | ||
| [2008/05/31 03:29:33] <plathrop> I'm amazed at how useful this is! | ||
| [2008/05/31 03:29:34] <muerr> potentially, but not 51 pages useful. :) | ||
| [2008/05/31 03:30:06] <muerr> but ashp's employer isn't afraid to kill trees, after all they teach Law. ;) | ||
| [2008/05/31 03:30:25] <plathrop> muerr: true, not 51 pages... Of course, there's some cleaning up you can do. | ||
| [2008/05/31 03:30:40] * muerr lunches. | ||
| [2008/05/31 03:35:34] <plathrop> I've already located 3 areas where I should have defined a dependency... | ||
| [2008/05/31 03:39:05] <ashp> oh god, importing that graph was a mess | ||
| [2008/05/31 03:39:13] <ashp> I imported it as a circle | ||
| [2008/05/31 03:39:19] <ashp> and removed all the non-dependant nodes | ||
| [2008/05/31 03:39:22] <ashp> which reduced it right now | ||
| [2008/05/31 03:40:09] <holoway> plathrop: yeah, those graphs are super handy | ||
| [2008/05/31 03:41:01] <holoway> I had a nice puppet moment last night, where I got a dkimproxy recipe working for postfix in a couple hours, and it worked the first time | ||
| [2008/05/31 03:41:04] <holoway> that's never happened for me before | ||
| [2008/05/31 03:41:11] <ashp> i think i'll have to look on the screen | ||
| [2008/05/31 03:41:17] <ashp> as omnigraffle makes terrible output | ||
| [2008/05/31 03:41:53] <plathrop> Oddly, my "expanded relationships" has less than the other one. | ||
| [2008/05/31 03:42:01] <plathrop> holoway: congrats! | ||
| [2008/05/31 03:42:42] <ashp> What are you guys using to look at the graphs? | ||
| [2008/05/31 03:42:44] * plathrop adds checking the graph to the list of things he'll do by default going forward. | ||
| [2008/05/31 03:42:52] <plathrop> ashp: I'm using Omnigraffle. | ||
| [2008/05/31 03:42:56] <plathrop> So no help | ||
| [2008/05/31 03:43:01] <ashp> That's what I put it into, but it was a terrible mess of lines | ||
| [2008/05/31 03:43:04] <ashp> like, unreadable really | ||
| [2008/05/31 03:43:15] <ashp> the radial one was ALMOST readable | ||
| [2008/05/31 03:43:17] <plathrop> ashp: I did a heirarchical graph | ||
| [2008/05/31 03:43:21] <ashp> if it wasn't busy putting everything on top of everything | ||
| [2008/05/31 03:43:30] <ashp> my hierarchical one was about 50 pages big | ||
| [2008/05/31 03:43:43] <ashp> I have a terrible network apparently, let me show you the dot file | ||
| [2008/05/31 03:44:02] <plathrop> ashp: Your manifests are probably way more complex than the ones I'm playing with at the moment. | ||
| [2008/05/31 03:44:38] <ashp> www.untaken.net/relationships.dot | ||
| [2008/05/31 03:44:42] <ashp> check that out for a mess! | ||
| [2008/05/31 03:45:26] <plathrop> ashp: holy monkey! | ||
| [2008/05/31 03:46:00] <ashp> That's why I can barely see what's going on, I think I need to find ways to reduce this | ||
| [2008/05/31 03:46:05] <ashp> maybe this is normal for a big deployment | ||
| [2008/05/31 03:46:11] <ashp> I'm going to deploy iclassify on this server and regraph it | ||
| [2008/05/31 03:48:14] <plathrop> ashp: Your manifests are clearly more complete than mine. For example, I don't put root in our manifests. | ||
| [2008/05/31 03:48:27] @ Quit: oxtail: Read error: 110 (Connection timed out) | ||
| [2008/05/31 03:49:17] <ashp> Well, I only have root in there because it changes the password so they are all unified | ||
| [2008/05/31 03:49:24] <ashp> then anything with owner => root suddenly links against that | ||
| [2008/05/31 03:50:00] <ashp> I am thinking of persuading my coworker that we need to remove all passwords and only allow ssh keys. :) | ||
| [2008/05/31 03:50:33] <plathrop> ashp: I've gone that route on several occasions. | ||
| [2008/05/31 03:50:52] <holoway> plathrop: our graphs are outrageously large | ||
| [2008/05/31 03:50:59] <holoway> still handy | ||
| [2008/05/31 03:51:00] <plathrop> holoway: I'm sure :-P | ||
| [2008/05/31 03:51:03] <holoway> but not simple | ||
| [2008/05/31 03:51:11] <ashp> I want to see a monster graph from holoway :) | ||
| [2008/05/31 03:52:15] <holoway> well, for reference | ||
| [2008/05/31 03:52:20] <holoway> yours is 20k ash | ||
| [2008/05/31 03:52:34] <holoway> one of our ops masters is 113k | ||
| [2008/05/31 03:52:42] <ashp> How on earth do you manage those | ||
| [2008/05/31 03:52:50] <ashp> I am having more and more dependency ordering problems | ||
| [2008/05/31 03:52:53] <ashp> where am I going so wrong :) | ||
| [2008/05/31 03:53:14] <holoway> ashp: did you see my arguing about dependency stuff in the philosophical differences thread? :) | ||
| [2008/05/31 03:53:27] <ashp> Oh, you rely on iclassify for some of this | ||
| [2008/05/31 03:53:27] <holoway> most of the systems are 1 run complete | ||
| [2008/05/31 03:53:37] <holoway> the ops master isn't | ||
| [2008/05/31 03:53:37] <ashp> I haven't seen any modules that use iclassify in any way to see what would be different | ||
| [2008/05/31 03:53:57] <ashp> I wish I could give certain statements priority for when to complete, because I could unwind this horrendous dependency mess | ||
| [2008/05/31 03:54:06] <ashp> I'm hoping that as I move to definitions some of that will unwind | ||
| [2008/05/31 03:54:13] <ashp> But if I could force more to run up front it would be easier | ||
| [2008/05/31 03:54:52] @ skorgu joined channel #puppet | ||
| [2008/05/31 03:55:03] <holoway> the dependency stuff works great when you aren't dealing with a huge amount of stuff | ||
| [2008/05/31 03:55:07] * Volcane should use the +> syntax more for deps | ||
| [2008/05/31 03:55:10] <holoway> it still works when it's huge | ||
| [2008/05/31 03:55:18] <holoway> it's just a whole lot harder to manage | ||
| [2008/05/31 03:55:20] <Volcane> so i can say Package[...] setting dependency on yumrepos | ||
| [2008/05/31 03:55:26] <Volcane> then just append to that everywhere else | ||
| [2008/05/31 03:55:26] <ashp> hey, what's the +> syntax? | ||
| [2008/05/31 03:55:38] <Volcane> saw it in collected resources stuff | ||
| [2008/05/31 03:55:45] <Volcane> you can append dependencies to a class | ||
| [2008/05/31 03:55:55] <Volcane> now if i could apend to the default, that would roq | ||
| [2008/05/31 03:56:04] <Volcane> not class, resources | ||
| [2008/05/31 03:56:06] <Volcane> been a long day. | ||
| [2008/05/31 03:56:08] <ashp> I need to find more about this, hmm | ||
| [2008/05/31 03:56:21] <ashp> I can't search on +> as it's too short so I have to look around by hand | ||
| [2008/05/31 03:56:46] <Volcane> i didnt try, but it would be kewl to say have a base node where everything inherits from, set Package[] depedencies, User[] etc, then in actual manifests just +> deps | ||
| [2008/05/31 03:56:57] <Volcane> ashp: hmm, the user example maybe, its defo in the book | ||
| [2008/05/31 03:57:00] <ashp> what I have right now is, in site.pp: | ||
| [2008/05/31 03:57:02] <Volcane> ashp: by the users stuff | ||
| [2008/05/31 03:57:11] <ashp> Package { | ||
| [2008/05/31 03:57:13] <ashp> require => [ Yumrepo['epel'], Yumrepo['hls'], Exec['rhnreg_ks'], Exec['rhn-profile-sync'], Service['network'] ], | ||
| [2008/05/31 03:57:26] @ dysinger joined channel #puppet | ||
| [2008/05/31 03:57:37] <ashp> I did have Network::ip["eth0"] Which is a define I call earlier in site.pp, but it didn't like that at all. | ||
| [2008/05/31 03:57:40] <Volcane> and then no requires in your packages? | ||
| [2008/05/31 03:57:49] <ashp> I guess I can probably just do ip["eth0"] | ||
| [2008/05/31 03:57:59] <ashp> Volcane: I only have the additional requires that would be above and beyond those | ||
| [2008/05/31 03:58:10] <ashp> and it SEEMS to append the ones defined elsewhere to the list of those requirements | ||
| [2008/05/31 03:58:13] <Volcane> ashp: and does thos eaditional requires append to those ? | ||
| [2008/05/31 03:58:15] <Volcane> oooh | ||
| [2008/05/31 03:58:18] <ashp> In that it now waits until my network exists to add packages | ||
| [2008/05/31 03:58:18] <Volcane> that would be good | ||
| [2008/05/31 03:58:27] <ashp> You might want to do some testing but it seemed to fix a lot of problems I was having | ||
| [2008/05/31 03:58:28] <Volcane> i should chek that out, I'd be very impressed | ||
| [2008/05/31 03:58:46] <Volcane> would solve loads of my hassles too | ||
| [2008/05/31 03:58:55] <ashp> It could have just been coincidental as I was changing lots of other stuff, but it seems to work better | ||
| [2008/05/31 03:59:07] <ashp> I do wish I could have a single 'bootstrap.pp' file | ||
| [2008/05/31 03:59:18] <ashp> and it would always run those resources before anything else on the system | ||
| [2008/05/31 03:59:22] <ashp> I was hoping site.pp was it | ||
| [2008/05/31 03:59:28] <ashp> but it didn't seem to work out | ||
| [2008/05/31 03:59:47] <Volcane> ashp: hmm, you can make a default node, like a fallback node for when a node hostname isnt found | ||
| [2008/05/31 04:00:03] <ashp> True, but does it execute things in the default node before it applies other stuff? | ||
| [2008/05/31 04:00:15] <Volcane> ashp: only define actual machine nodes once the fallback has completed somehow? | ||
| [2008/05/31 04:00:17] <plathrop> ashp: nope. I though it did. | ||
| [2008/05/31 04:00:18] <ashp> I want it to go to ldap (or iclassify), pull out some variables and then do three or four steps up front | ||
| [2008/05/31 04:00:27] <ashp> plathrop: nope to which bit? | ||
| [2008/05/31 04:00:44] <plathrop> ashp: It doesn't execute default node resources first | ||
| [2008/05/31 04:00:50] <ashp> Ahhh, ok. | ||
| [2008/05/31 04:01:03] <ashp> It's a shame because it's quite common to need a few setup resources to execute first, we all have that requirement | ||
| [2008/05/31 04:01:08] <ashp> (aka, network, repos, packages available) | ||
| [2008/05/31 04:01:31] <ashp> Ohhhh, +> could be very useful | ||
| [2008/05/31 04:01:38] <Volcane> ashp: indeed | ||
| [2008/05/31 04:01:57] <ashp> I was trying to do exactly that example in http://reductivelabs.com/trac/puppet/wiki/LanguageTutorial | ||
| [2008/05/31 04:02:04] <ashp> Which is to inherit a class and override a few requirements | ||
| [2008/05/31 04:10:53] <ashp> hmm, iclassify has broken my subversion stuff, whoops | ||
| [2008/05/31 04:15:26] <e^ipi> does puppet have multiple inheritance? | ||
| [2008/05/31 04:17:17] <ashp> No. | ||
| [2008/05/31 04:17:31] <ashp> It definitely doesn't :) | ||
| [2008/05/31 04:17:52] @ lutter joined channel #puppet | ||
| [2008/05/31 04:18:03] <ashp> http://www.untaken.net/relationships.dot | ||
| [2008/05/31 04:18:07] <ashp> that's with iclassify in, for added horror | ||
| [2008/05/31 04:18:18] <holoway> ;) | ||
| [2008/05/31 04:18:42] <ashp> I think later I'll look at this +> syntax, that might make things easier to handle all of these | ||
| [2008/05/31 04:18:46] @ Demosthenes joined channel #puppet | ||
| [2008/05/31 04:20:26] <e^ipi> drats. | ||
| [2008/05/31 04:23:54] @ Quit: pastie: Remote closed the connection | ||
| [2008/05/31 04:24:19] @ Quit: kenvandine: Read error: 110 (Connection timed out) | ||
| [2008/05/31 04:24:36] @ pastie joined channel #puppet | ||
| [2008/05/31 04:34:57] @ Quit: dysinger: | ||
| [2008/05/31 04:41:51] @ Quit: kambiz: "Leaving" | ||
| [2008/05/31 04:48:38] @ Quit: lak: | ||
| [2008/05/31 04:49:55] @ dysinger joined channel #puppet | ||
| [2008/05/31 04:54:56] @ Ol_ joined channel #puppet | ||
| [2008/05/31 04:58:47] @ zirpu2 joined channel #puppet | ||
| [2008/05/31 04:58:55] @ zirpu2 is now known as zirpu | ||
| [2008/05/31 05:07:05] @ pleemans joined channel #puppet | ||
| [2008/05/31 05:07:44] <muerr> ashp: re your relationships.dot - mine was worse :) | ||
| [2008/05/31 05:08:11] <muerr> re: root password, we set that in kickstart. | ||
| [2008/05/31 05:08:31] <muerr> and we use ssh key authentication for users, no passwords are set | ||
| [2008/05/31 05:08:51] @ lak joined channel #puppet | ||
| [2008/05/31 05:09:00] <muerr> holoway: 113k size - the .dot file or the .gif file? | ||
| [2008/05/31 05:09:01] <ashp> Well, I figure we might want to change the root password sometimes! | ||
| [2008/05/31 05:09:07] <ashp> But yes, I'd like to change to using keys and no passwords. | ||
| [2008/05/31 05:09:42] <ashp> I just added a new environment and puppet will simply NOT notice it's there, how strange. | ||
| [2008/05/31 05:09:52] <ashp> [dev] | ||
| [2008/05/31 05:09:52] <ashp> modulepath = /etc/puppet/modules/dev | ||
| [2008/05/31 05:09:59] <ashp> 'Invalid enviornment dev' | ||
| [2008/05/31 05:11:27] <muerr> the only place root is allowed to login on our servers is /dev/tty[0-6] | ||
| [2008/05/31 05:11:39] <muerr> and the serial console. | ||
| [2008/05/31 05:11:49] <muerr> s/0/1/ | ||
| [2008/05/31 05:12:01] <ashp> You know, that brings up a good point.. | ||
| [2008/05/31 05:12:12] <ashp> Why AM I setting a root password, when everyone uses sudo? | ||
| [2008/05/31 05:12:32] <muerr> ashp: Which is why we set it at kickstart and just leave it :D. | ||
| [2008/05/31 05:12:37] <ashp> I should just lock it down to the console, and set it at kickstart, aye | ||
| [2008/05/31 05:12:45] <muerr> KISS | ||
| [2008/05/31 05:13:14] <ashp> I'm not crazy, there's NOTHING more to adding an environment than slapping it into the puppet.conf and restarting puppetmaster, right? | ||
| [2008/05/31 05:13:55] @ shake-n-bake_ joined channel #puppet | ||
| [2008/05/31 05:17:19] <ashp> hmm, I thought as i called it dev it might be that | ||
| [2008/05/31 05:17:21] <muerr> *adding* an environment? Yes, just put it in the puppet.conf, don't even need to restart the puppet master. | ||
| [2008/05/31 05:17:22] <ashp> but I changed it to [developers] | ||
| [2008/05/31 05:17:25] <ashp> and it STILL can't see it | ||
| [2008/05/31 05:17:33] @ greenmoss left channel #puppet () | ||
| [2008/05/31 05:17:36] <muerr> using an environment is a different matter :) | ||
| [2008/05/31 05:18:03] @ Quit: dysinger: | ||
| [2008/05/31 05:18:04] <ashp> Well, I set it in ldap | ||
| [2008/05/31 05:18:07] <ashp> environment: developers | ||
| [2008/05/31 05:18:44] <ashp> it's pretty simple and all my others work fine | ||
| [2008/05/31 05:18:59] <ashp> http://reductivelabs.com/trac/puppet/wiki/UsingMultipleEnvironments <-- all you do is add two lines in puppet.conf | ||
| [2008/05/31 05:19:35] <muerr> hey if the initrd.img and vmlinuz files actually completely copied, they work better when not. | ||
| [2008/05/31 05:23:36] @ dysinger joined channel #puppet | ||
| [2008/05/31 05:24:10] <ashp> ARGHHHHHH, what is WRONG with this tonight | ||
| [2008/05/31 05:24:38] @ Quit: DavidS: Read error: 110 (Connection timed out) | ||
| [2008/05/31 05:25:13] @ DavidS joined channel #puppet | ||
| [2008/05/31 05:26:01] <ashp> err: Could not call: Invalid environment 207 | ||
| [2008/05/31 05:26:09] <ashp> -sh-3.2# grep 207 /etc/puppet/puppet.conf | ||
| [2008/05/31 05:26:10] <ashp> [207] | ||
| [2008/05/31 05:26:13] <ashp> I don't get what the hell. | ||
| [2008/05/31 05:27:17] <holoway> muerr: the .dot file | ||
| [2008/05/31 05:31:03] <muerr> holoway: the one from my puppetmaster/build server is 66k :) | ||
| [2008/05/31 05:31:15] <ashp> someone take a shotgun to my puppetmaster. | ||
| [2008/05/31 05:32:17] <muerr> we're not actually using environments yet. | ||
| [2008/05/31 05:32:40] <ashp> I have about 5 environments | ||
| [2008/05/31 05:32:44] <muerr> since all our critical services run on redundant hosts, we apply changes to one in the node context, if they work add to the nodetype and apply on both. | ||
| [2008/05/31 05:32:44] <ashp> 4 work just fine, one suddenly doesn't? | ||
| [2008/05/31 05:33:22] <ashp> I just have it split out so I can add custom bits for our dev network that's all filtered down | ||
| [2008/05/31 05:33:36] <ashp> I can set my environment to development and it works, set it to dev or another name, and it refuses to work | ||
| [2008/05/31 05:36:22] <bartc> ashp: did you add the env name to the 'environments' option in puppet.conf? | ||
| [2008/05/31 05:36:57] <ashp> On the server? | ||
| [2008/05/31 05:37:01] <bartc> yep | ||
| [2008/05/31 05:37:09] <ashp> I don't have that | ||
| [2008/05/31 05:37:13] <ashp> I just have [environmentname] | ||
| [2008/05/31 05:37:18] <ashp> and then a modulepath | ||
| [2008/05/31 05:37:32] <bartc> its default value is 'production,development', so [development] would work without changing the environments option | ||
| [2008/05/31 05:38:17] <ashp> Haha, maybe I never tested the ones that weren't production or development | ||
| [2008/05/31 05:38:27] <ashp> So I got lucky | ||
| [2008/05/31 05:38:47] @ diggyk joined channel #puppet | ||
| [2008/05/31 05:39:06] <ashp> Ahhhh, I had others defined but they weren't in use | ||
| [2008/05/31 05:39:10] <ashp> and production and development were | ||
| [2008/05/31 05:39:42] <bartc> that would explain it | ||
| [2008/05/31 05:39:57] <diggyk> Is the "parent class must have dissimilar names" thing going to be fixed sometime? I find it a limitation though one that is easy to work around. I just need to know if I need to come up with a subclass naming policy since we were hoping the namespace would be enough | ||
| [2008/05/31 05:40:01] <ashp> i'm surprised it didn't give any kind of warning or error | ||
| [2008/05/31 05:40:10] <ashp> that I had defined environments that couldn't be used | ||
| [2008/05/31 05:40:17] <diggyk> lak: that was mostly a question for you | ||
| [2008/05/31 05:40:32] * lak raises his head | ||
| [2008/05/31 05:40:36] <diggyk> pastie: hitme | ||
| [2008/05/31 05:40:46] <pastie> http://pastie.org/206149 by diggyk. | ||
| [2008/05/31 05:41:05] <lak> hmm | ||
| [2008/05/31 05:41:23] <lak> i'm mostly been viewing it as a feature rather than a bug | ||
| [2008/05/31 05:41:28] <lak> probably because i'm lazy | ||
| [2008/05/31 05:41:36] <diggyk> Hehehe | ||
| [2008/05/31 05:41:37] <lak> so i hadn't been planning on "fixing" it | ||
| [2008/05/31 05:42:16] <diggyk> Well, for instance, when we have a module called ssh and our kerberos service needs a special ssh setup, we override with kerberos::ssh, which is nicer than kerberos::ssh_kerberos | ||
| [2008/05/31 05:42:31] <lak> makes sense | ||
| [2008/05/31 05:42:35] <ashp> I'm surprised I didn't stumble over that with all my crazy inheriting classes | ||
| [2008/05/31 05:43:29] @ Quit: dysinger: Read error: 104 (Connection reset by peer) | ||
| [2008/05/31 05:43:43] <diggyk> Well, it is weird b/c this works fine: class test {} | ||
| [2008/05/31 05:43:43] <diggyk> class exam {} | ||
| [2008/05/31 05:43:43] <diggyk> class namespace::test inherits exam {} | ||
| [2008/05/31 05:43:44] <diggyk> include namespace::test, test | ||
| [2008/05/31 05:43:46] <lak> diggyk: well, it's probably not a lot of work to make that happen, but it's got some potential gotchas, i guess | ||
| [2008/05/31 05:43:47] @ dysinger joined channel #puppet | ||
| [2008/05/31 05:44:16] <lak> yeah, because the 'include' is looking up both classes relative to its namespace | ||
| [2008/05/31 05:44:20] <diggyk> So I can reuse a classname as long as it inherits from something unrelated. | ||
| [2008/05/31 05:44:27] <lak> right | ||
| [2008/05/31 05:44:44] <lak> it's basically a bit of an ordering problem combined with how puppet looks up classes | ||
| [2008/05/31 05:45:14] <lak> given class namespace::test, looking up 'test' in namespace *or* 'namespace::test' will find the right class | ||
| [2008/05/31 05:45:26] <lak> as opposed to, say, in ruby, where 'test' wouldn't resolve in 'namespace::test' | ||
| [2008/05/31 05:46:28] <lak> i think puppet's behaviour is better, but it means that when the 'namespace::test' class goes to look up its parent, which it would normally do recursively by asking its namespace, it would need a special check to ignore itself or something | ||
| [2008/05/31 05:46:55] <lak> i.e., it's not just a simple "remove that exception" | ||
| [2008/05/31 05:47:53] <diggyk> Right, I hear ya | ||
| [2008/05/31 05:50:57] @ oxtail joined channel #puppet | ||
| [2008/05/31 05:55:45] @ diggyk left channel #puppet () | ||
| [2008/05/31 06:02:08] @ Quit: dysinger: Read error: 110 (Connection timed out) | ||
| [2008/05/31 06:06:02] @ shadoi joined channel #puppet | ||
| [2008/05/31 06:10:39] <stick> can you do a pipe in an exec? | ||
| [2008/05/31 06:10:56] <stick> exec { foo: command => "echo foo | grep foo" } | ||
| [2008/05/31 06:12:02] <ashp> yeah, should be able to | ||
| [2008/05/31 06:12:07] <ashp> I do && and || and stuff in some of mine | ||
| [2008/05/31 06:13:44] <stick> cool, wasn't sure if exec was spawning a ruby exec or an actual shell | ||
| [2008/05/31 06:14:50] @ Quit: lak: | ||
| [2008/05/31 06:15:24] <holoway> stick: I believe it spwans a shell | ||
| [2008/05/31 06:15:30] <holoway> er spawns | ||
| [2008/05/31 06:18:06] @ lak joined channel #puppet | ||
| [2008/05/31 06:18:29] @ Quit: lak: Client Quit | ||
| [2008/05/31 06:18:43] <shadoi> you need '/bin/sh -c <command>' | ||
| [2008/05/31 06:19:00] <shadoi> or whatever shell | ||
| [2008/05/31 06:23:00] <ashp> Hmm. | ||
| [2008/05/31 06:23:05] <ashp> Is there a way to put requirements on a class? | ||
| [2008/05/31 06:23:26] <ashp> I mean, in my iclassify::httpd class | ||
| [2008/05/31 06:23:34] <ashp> it would be nice to say 'before doing anything, require this:' | ||
| [2008/05/31 06:24:00] <ashp> so I can slap a require => Package['httpd'] as part of the class, and then remove it from the individual stanzas below | ||
| [2008/05/31 06:26:02] @ Quit: DavidS: "Leaving." | ||
| [2008/05/31 06:29:24] @ Quit: dinococcus: "leaving" | ||
| [2008/05/31 06:30:13] <shadoi> ashp: pick the first resource in your dependency chain and make it require it | ||
| [2008/05/31 06:30:50] <ashp> shadoi: Well, an example is in iclassify::install I have about 20 package{} statements | ||
| [2008/05/31 06:31:03] <ashp> and about 12 of those require => Package['rubygems'] | ||
| [2008/05/31 06:31:13] <shadoi> Package { require => Package["httpd"] } | ||
| [2008/05/31 06:31:14] <ashp> There's no easy thing to hitch that require on other than each individual package | ||
| [2008/05/31 06:31:27] <ashp> True, I can always set one of those at the top, I forget I can do that now | ||
| [2008/05/31 06:31:28] <shadoi> you don't need multiple requires for the same package if you get the order right | ||
| [2008/05/31 06:31:34] <ashp> I think if I use +> I'll get the right thing | ||
| [2008/05/31 06:31:43] <shadoi> yeah | ||
| [2008/05/31 06:31:59] <ashp> this is new to me, the +> syntax, so I'm trying to get to grips with it to simplify things | ||
| [2008/05/31 06:32:10] <shadoi> definitely removes a lot of redundant code | ||
| [2008/05/31 06:33:19] <ashp> Because I have a Package {} set in site.pp | ||
| [2008/05/31 06:33:33] <shadoi> yeah it just applies to the scope | ||
| [2008/05/31 06:33:35] <ashp> I basically have to always use +> because then I can keep my require's from site.pp is my understanding | ||
| [2008/05/31 06:33:42] <shadoi> yup | ||
| [2008/05/31 06:33:53] <ashp> So I do need +> for anything below site.pp to get it to work? | ||
| [2008/05/31 06:34:01] <ashp> If I use => it will just ignore the stuff in site.pp? | ||
| [2008/05/31 06:34:08] <shadoi> right, it overrides it | ||
| [2008/05/31 06:34:11] <shadoi> +> adds to it | ||
| [2008/05/31 06:34:15] <ashp> OK, good, that's where I came unstuck | ||
| [2008/05/31 06:34:19] <ashp> I have a lot of =>'s to modify | ||
| [2008/05/31 06:35:14] @ Quit: pleemans: "Ex-Chat" | ||
| [2008/05/31 06:36:48] <ashp> hmm | ||
| [2008/05/31 06:36:56] <ashp> class iclassify::install { | ||
| [2008/05/31 06:36:58] <ashp> Package { require +> Package['rubygems'] } | ||
| [2008/05/31 06:37:14] <ashp> That immediately errors. I thought by doing that it would pass down the Package { require => }'s I have in site.pp? | ||
| [2008/05/31 06:38:09] <ashp> Maybe I don't get how this trickles down :) | ||
| [2008/05/31 06:38:36] @ Quit: Kindred: Read error: 104 (Connection reset by peer) | ||
| [2008/05/31 06:40:10] <shadoi> hmm, I think it should work | ||
| [2008/05/31 06:40:22] <shadoi> syntax issue somewhere else? | ||
| [2008/05/31 06:40:54] <ashp> I don't think so | ||
| [2008/05/31 06:40:59] <shadoi> oh crap, I'm mixing up defaults and overrides | ||
| [2008/05/31 06:41:09] <shadoi> you can only do +> in an override | ||
| [2008/05/31 06:41:12] <ashp> I think perhaps I can onl.. yeah | ||
| [2008/05/31 06:41:12] <muerr> yeah | ||
| [2008/05/31 06:41:15] <ashp> damn, that's a pain | ||
| [2008/05/31 06:41:28] <ashp> So does => append or override what's in place ordinarily, I can't get a definite answer on this | ||
| [2008/05/31 06:41:44] <shadoi> override | ||
| [2008/05/31 06:41:45] <ashp> because I want to be able to define Package { require => Package['rubygems'] } | ||
| [2008/05/31 06:41:55] <ashp> and then in each package statement have that take place, but also allow myself to add a few more | ||
| [2008/05/31 06:41:56] <shadoi> that will replace your site.pp default | ||
| [2008/05/31 06:42:03] <ashp> urgh, goddamn | ||
| [2008/05/31 06:42:06] <ashp> sometimes I hate this job | ||
| [2008/05/31 06:42:08] <muerr> looks like +> only adds values to the require parameter. | ||
| [2008/05/31 06:42:25] <ashp> I just want to be able to post require at a higher level, and constantly append to the list | ||
| [2008/05/31 06:42:42] <ashp> I don't want every package {} statement to have 7 or more require's | ||
| [2008/05/31 06:42:51] <shadoi> ashp: I recommend you make a definition and use it for all the packages, then you can add all the defaults you want for your current context to it. | ||
| [2008/05/31 06:43:07] @ Kindred joined channel #puppet | ||
| [2008/05/31 06:43:13] <ashp> I guess I'm going to have to | ||
| [2008/05/31 06:44:16] <shadoi> I do it for almost everything | ||
| [2008/05/31 06:44:20] <shadoi> it's actually realy convenient | ||
| [2008/05/31 06:44:30] <shadoi> because then you can set defaults and overrides on the define | ||
| [2008/05/31 06:44:31] <ashp> shame I can't just do package { "a b c d e f g h i j k l m": require => blah, } | ||
| [2008/05/31 06:44:39] <shadoi> you can | ||
| [2008/05/31 06:44:44] <shadoi> make an array | ||
| [2008/05/31 06:44:48] <ashp> Oh, I could do that to at least reduce a lot of the mess at least | ||
| [2008/05/31 06:44:49] <shadoi> but it gets unwieldy | ||
| [2008/05/31 06:44:58] <ashp> I guess a package define is the way to go | ||
| [2008/05/31 06:45:10] <ashp> It just seems that if we had a way to properly trickle down dependencies | ||
| [2008/05/31 06:45:28] <ashp> I want a better syntax and method to apply global requirements, and then extend those in the module. | ||
| [2008/05/31 06:46:25] <shadoi> You could apply defaults in a "defaults" class and then override it down the line | ||
| [2008/05/31 06:46:45] <shadoi> make all your classes/modules inherit from it | ||
| [2008/05/31 06:46:48] <ashp> hmm | ||
| [2008/05/31 06:46:52] <ashp> that's not a terrible idea if that works | ||
| [2008/05/31 06:47:11] <shadoi> not particularly modular though | ||
| [2008/05/31 06:47:15] <ashp> I do my classes oddly, so I don't know how well it would work, maybe if I had | ||
| [2008/05/31 06:47:26] <ashp> class iclassify inherits default {} | ||
| [2008/05/31 06:47:33] <ashp> and then did my normal include iclassify::install | ||
| [2008/05/31 06:47:41] <ashp> It would trickle those down still | ||
| [2008/05/31 06:47:52] <shadoi> yeah | ||
| [2008/05/31 06:48:01] <ashp> I don't think I can do class iclassify::install inherits default as well | ||
| [2008/05/31 06:48:16] <ashp> I do sometimes do things where it's iclassify::blah inherits iclassify::install | ||
| [2008/05/31 06:48:17] <shadoi> you'd do iclassify::install inherits iclassify | ||
| [2008/05/31 06:48:21] <ashp> so I'd want to just do it on the top level | ||
| [2008/05/31 06:48:23] <ashp> oh that's true | ||
| [2008/05/31 06:48:31] <ashp> I can do that just fine, and pass them down | ||
| [2008/05/31 06:48:43] <shadoi> yup | ||
| [2008/05/31 06:48:45] <ashp> I want to hear what lak's opinion is on how global dependencies and requirements are meant to be handled in a puppet way | ||
| [2008/05/31 06:49:02] <shadoi> the language reflects his opinion. :) | ||
| [2008/05/31 06:49:10] <shadoi> defaults and overrides are the mechanisms | ||
| [2008/05/31 06:49:29] <ashp> But surely he has come across a situation where you always have to have a few bits in place before adding every package | ||
| [2008/05/31 06:49:39] <ashp> he can't add those require's to every package{} used in a customer environment | ||
| [2008/05/31 06:49:44] <ashp> or maybe he can, but i'd like to know :) | ||
| [2008/05/31 06:49:49] <shadoi> ? | ||
| [2008/05/31 06:50:04] <shadoi> you use defines, and overrides, like we've been talking about | ||
| [2008/05/31 06:50:21] <ashp> Is that actually what is done, some sort of inheritance on every class to make sure it trickles down? | ||
| [2008/05/31 06:50:27] <shadoi> I do it all the time | ||
| [2008/05/31 06:50:31] <shadoi> at various clients | ||
| [2008/05/31 06:50:40] <ashp> Maybe defines is just what everyone else does and I'm the weird stick in the mud who seems that as a mistake | ||
| [2008/05/31 06:50:52] <shadoi> defines are what make puppet powerful | ||
| [2008/05/31 06:51:09] <ashp> I just don't think I should have to make any custom definitions to get global dependencies on resources | ||
| [2008/05/31 06:51:09] <plathrop> ashp: I dunno, I only use defines when they seem called for, ie when there isn't a native type. | ||
| [2008/05/31 06:51:24] <ashp> plathrop: the idea of writing a define that's just a wrapper for a native type is what I really hate | ||
| [2008/05/31 06:51:27] <shadoi> defines are meant to aggregate native types together. | ||
| [2008/05/31 06:51:33] <shadoi> in fact | ||
| [2008/05/31 06:51:41] <shadoi> your iclassify::install is a great candidate for a define | ||
| [2008/05/31 06:51:53] <shadoi> because it's a "thing" | ||
| [2008/05/31 06:52:34] <shadoi> if you think about your apps as resources it starts to make a lot of sense. | ||
| [2008/05/31 06:52:56] <ashp> I think what I'm going to do | ||
| [2008/05/31 06:52:59] <ashp> is trick someone at some point | ||
| [2008/05/31 06:53:12] <ashp> into writing install.pp out of my github in a real lazy half-baked way as a define to see what THEY'D do | ||
| [2008/05/31 06:54:20] <shadoi> ashp: look at luke's puppet modules repository on github | ||
| [2008/05/31 06:54:24] <shadoi> I'm sure they'll inspire you. | ||
| [2008/05/31 06:55:37] <mistik1> shadoi: I'll be trying out puppet when I get a change here, I hope I can count on you for some help ;-) | ||
| [2008/05/31 06:55:50] <mistik1> s/change/chance | ||
| [2008/05/31 06:56:32] <shadoi> mistik1: I'll probably be around. :) | ||
| [2008/05/31 06:57:48] <mistik1> IRC is certainly a funny place, I always try my best to personable to folks where ever I meet them and not act like they are a retard or something because they dont know an area you may know | ||
| [2008/05/31 06:57:59] <mistik1> I meet so much of that kind of crap | ||
| [2008/05/31 06:58:40] <shadoi> yeah it's pretty brutal sometimes. | ||
| [2008/05/31 06:59:20] <mistik1> lots of eleetist mentalities out there | ||
| [2008/05/31 06:59:50] <mistik1> shadoi: How's your app working out btw? | ||
| [2008/05/31 07:00:20] <shadoi> you were the one in extjs that helped with that window thing? | ||
| [2008/05/31 07:00:28] <mistik1> yup | ||
| [2008/05/31 07:00:31] <shadoi> ah.. heh | ||
| [2008/05/31 07:00:55] <shadoi> it's working but in firefox the window is randomly placed and sized every time | ||
| [2008/05/31 07:00:56] <mistik1> When I saw you in here I started laughing at the irony | ||
| [2008/05/31 07:00:59] <shadoi> works fine in safari | ||
| [2008/05/31 07:01:12] <shadoi> pretty weird | ||
| [2008/05/31 07:01:32] <shadoi> yeah I'm pretty much a noob at javascript | ||
| [2008/05/31 07:01:35] <mistik1> are you using any type of state management? | ||
| [2008/05/31 07:01:56] <shadoi> no, I think that's probably the issue | ||
| [2008/05/31 07:02:04] <shadoi> I'm sort of injecting this grid into an existing rails app | ||
| [2008/05/31 07:02:09] <shadoi> I think it's time to refactor | ||
| [2008/05/31 07:02:32] <mistik1> I found that sometimes when I use Cookie management FF uses the placement of where the element was the last time you used it | ||
| [2008/05/31 07:02:48] <shadoi> oh wait, yeah I am using cookie management | ||
| [2008/05/31 07:03:18] <mistik1> turn it off for a sec and see if that makes the problem go away | ||
| [2008/05/31 07:03:51] <mistik1> If it does then you could prolly delete the state for that id from the cookie when your app loads in FF | ||
| [2008/05/31 07:04:09] <mistik1> You can check for FF with Ext.isGecko | ||
| [2008/05/31 07:05:40] <shadoi> trying it now | ||
| [2008/05/31 07:08:08] <shadoi> EC2 is sloooowww | ||
| [2008/05/31 07:08:13] <plathrop> Argh... | ||
| [2008/05/31 07:08:20] <plathrop> Modules + namespaces == confusing | ||
| [2008/05/31 07:08:30] <shadoi> plathrop: how so? | ||
| [2008/05/31 07:08:45] <plathrop> I'm trying to make use of lak's subversion module | ||
| [2008/05/31 07:08:48] <shadoi> that's ironic, since namespacing is meant to clarify... hehe | ||
| [2008/05/31 07:09:05] <plathrop> Located at: http://github.com/lak/puppet-subversion/tree/master | ||
| [2008/05/31 07:09:24] <plathrop> So, I put this in my {puppetdir}/modules | ||
| [2008/05/31 07:10:07] <plathrop> Then I try using the svnrepo define... no luck. "Could not retrieve catalog: Could not find resource type svnrepo" right? | ||
| [2008/05/31 07:10:12] <shadoi> you need an init.pp | ||
| [2008/05/31 07:10:20] <shadoi> that code was written before modules existed | ||
| [2008/05/31 07:10:21] <plathrop> shadoi: Yeah I added one | ||
| [2008/05/31 07:10:40] <shadoi> ah you're probably hitting the bug I reported | ||
| [2008/05/31 07:10:47] @ Quit: cote: | ||
| [2008/05/31 07:10:53] <plathrop> I wanted a class that installed subversion, so I made that class in init.pp | ||
| [2008/05/31 07:10:57] <plathrop> shadoi: Which bug? | ||
| [2008/05/31 07:11:13] <shadoi> http://reductivelabs.com/trac/puppet/changeset/2925ad1 | ||
| [2008/05/31 07:11:39] <plathrop> Changesets are completely unreadable for me on our trac | ||
| [2008/05/31 07:11:56] @ lak joined channel #puppet | ||
| [2008/05/31 07:12:56] <plathrop> shadoi: Got a ticket # instead? | ||
| [2008/05/31 07:12:58] <shadoi> http://reductivelabs.com/trac/puppet/ticket/1184 | ||
| [2008/05/31 07:13:08] <plathrop> thanks | ||
| [2008/05/31 07:14:46] @ dysinger joined channel #puppet | ||
| [2008/05/31 07:14:47] @ Quit: dysinger: Client Quit | ||
| [2008/05/31 07:14:48] @ dinococcus joined channel #puppet | ||
| [2008/05/31 07:15:02] <plathrop> shadoi: Thanks. Manually importing the file worked as a workaround for me. | ||
| [2008/05/31 07:15:14] <shadoi> cool | ||
| [2008/05/31 07:15:19] @ dysinger joined channel #puppet | ||
| [2008/05/31 07:18:16] <dinococcus> what am i doing wrong? here is my class: http://pastie.org/206193 , and here is output from puppetd: http://pastie.org/206196 | ||
| [2008/05/31 07:18:47] <shadoi> mistik1: well, it make it more consistent, but now the window is like 30px high by 50000px wide | ||
| [2008/05/31 07:18:54] <shadoi> s/make/made/ | ||
| [2008/05/31 07:19:39] @ shenson is now known as shenson_not_here | ||
| [2008/05/31 07:19:44] <shadoi> dinococcus: what's the error? | ||
| [2008/05/31 07:20:56] <mistik1> shadoi: make sure you're not using autoWidth: true | ||
| [2008/05/31 07:21:06] <mistik1> set a fixed width | ||
| [2008/05/31 07:21:55] <shadoi> ok, I had moved the position/size into the CSS for it the div I'm rendering to, is that a bad idea? | ||
| [2008/05/31 07:22:40] <mistik1> I had MAJOR problems with grids when I used a center tag in the containing div | ||
| [2008/05/31 07:22:57] <mistik1> Things like the Column headers not showing up | ||
| [2008/05/31 07:23:11] <mistik1> It was rather a pain until I tracked it down | ||
| [2008/05/31 07:23:36] <shadoi> yuck | ||
| [2008/05/31 07:23:37] <shadoi> ok | ||
| [2008/05/31 07:23:38] <shadoi> thanks | ||
| [2008/05/31 07:25:23] <shadoi> mistik1: yay it works. :) | ||
| [2008/05/31 07:25:29] <mistik1> ;) | ||
| [2008/05/31 07:25:46] <plathrop> grrr... variables in Puppet... | ||
| [2008/05/31 07:26:59] <plathrop> gepetto: seen emerose | ||
| [2008/05/31 07:27:01] <gepetto> plathrop: emerose was last seen 23 hours, 29 minutes and 8 seconds ago, quitting IRC (Read error: 110 (Connection timed out)) | ||
| [2008/05/31 07:27:24] <plathrop> damn. | ||
| [2008/05/31 07:27:55] <plathrop> I'm borrowing emerose's apache2 module and running into variable scoping issues. | ||
| [2008/05/31 07:28:36] <plathrop> anyone else have this? The module is apache2. In apache2/manifests/init.pp he defines a class 'apache2'. That class sets variables. | ||
| [2008/05/31 07:28:55] <plathrop> Also in the init.pp is several defines, which reference those variables. | ||
| [2008/05/31 07:29:01] @ Quit: skorgu: "Leaving." | ||
| [2008/05/31 07:29:02] @ jvanzyl joined channel #puppet | ||
| [2008/05/31 07:29:16] <plathrop> But if you 'include apache2' none of those variables are defined when you try to use the defines... | ||
| [2008/05/31 07:29:22] <plathrop> Known variable scoping thing? | ||
| [2008/05/31 07:29:22] @ Quit: dysinger: | ||
| [2008/05/31 07:29:52] <plathrop> Any ideas how to make it work? | ||
| [2008/05/31 07:30:05] <shadoi> plathrop: does the apache2 class _use_ the defines? | ||
| [2008/05/31 07:31:12] <shadoi> the usage is probably mean to be: include apache2 then later usedefine1 {"": ..} etc. | ||
| [2008/05/31 07:31:44] <plathrop> shadoi: That's the use pattern I want. But it doesn't work unless you *inherit* apache2. | ||
| [2008/05/31 07:32:11] <plathrop> shadoi: The apache2 class sets variables. The defines do stuff with those variables. | ||
| [2008/05/31 07:32:20] <shadoi> hmm... yeah it's because you can't guarantee the load order for the include vs. the defines | ||
| [2008/05/31 07:32:34] <shadoi> so why not inherit from it? | ||
| [2008/05/31 07:32:48] <plathrop> shadoi: No, because I can do that with "require => Class["apache2"]" - which is what I do. | ||
| [2008/05/31 07:32:59] <plathrop> Because I'm already inheriting from something else. | ||
| [2008/05/31 07:33:46] <shadoi> class myclass::mysubapache2 inherits apache2 { ... } | ||
| [2008/05/31 07:33:59] <shadoi> just make a class inside your class that inherits from it | ||
| [2008/05/31 07:34:18] <plathrop> hmmm... that might work. | ||
| [2008/05/31 07:34:27] <shadoi> but I think you're right, the require Class should work | ||
| [2008/05/31 07:34:31] <plathrop> Sounds dirty, I think it *should* work the other way, but... | ||
| [2008/05/31 07:34:31] <shadoi> not sure why it doesn't. | ||
| [2008/05/31 07:34:59] <shadoi> I know stanford does a LOT of tiny sub classes for inheritence because of it though. | ||
| [2008/05/31 07:35:17] <shadoi> gotta run catch a flight... to VEGAS baby! later all. | ||
| [2008/05/31 07:35:22] @ Quit: shadoi: "leaving" | ||
| [2008/05/31 07:35:32] <dinococcus> shadoi: the error i get is http://pastie.org/206196 , it fails to finish syncing /packages between puppetmaster and puppet | ||
| [2008/05/31 07:36:55] <plathrop> dinococcus: Puppet is very bad at shipping large files around right now | ||
| [2008/05/31 07:37:16] <plathrop> This is because it currently uses XML/RPC for that, so it has to escape the file, which can lead to an exponential increase in size. | ||
| [2008/05/31 07:37:46] <plathrop> The way most people get around this is they make a "define" that has an "exec" resource in it to fetch the file using another method. | ||
| [2008/05/31 07:38:47] <muerr> we're still grabbing probably more than we should with file source=>puppet://.... | ||
| [2008/05/31 07:39:06] <muerr> but none of the files we're doing that with are really over about 2M | ||
| [2008/05/31 07:39:13] <muerr> anything larger is wget'd | ||
| [2008/05/31 07:45:38] @ Quit: mellen: Read error: 110 (Connection timed out) | ||
| [2008/05/31 07:47:07] <plathrop> gepetto: seen lak | ||
| [2008/05/31 07:47:08] <gepetto> plathrop: lak was last seen 35 minutes and 11 seconds ago, joining #puppet | ||
| [2008/05/31 07:47:15] <plathrop> lak: You actually here? | ||
| [2008/05/31 07:47:19] <lak> plathrop: what's up? | ||
| [2008/05/31 07:47:23] @ dysinger joined channel #puppet | ||
| [2008/05/31 07:47:26] <lak> if i'm logged in, i'm *usually* around | ||
| [2008/05/31 07:47:45] <plathrop> I'm having a strange problem with dependencies that I can't seem to get to the bottom of. | ||
| [2008/05/31 07:47:52] <plathrop> Let me pastie. | ||
| [2008/05/31 07:48:00] <plathrop> pastie: link love | ||
| [2008/05/31 07:48:19] <lak> ok | ||
| [2008/05/31 07:48:21] @ Quit: oxtail: Read error: 113 (No route to host) | ||
| [2008/05/31 07:48:38] <pastie> http://pastie.org/206212 by plathrop. | ||
| [2008/05/31 07:48:59] <plathrop> So, I get that depedency cycle error. | ||
| [2008/05/31 07:49:06] <plathrop> But I loko at the graphs, and I don't see a cycle! | ||
| [2008/05/31 07:49:12] <plathrop> Everything looks great there. | ||
| [2008/05/31 07:49:56] <plathrop> You probably need to see the module, too... | ||
| [2008/05/31 07:50:21] @ Quit: muerr: "Leaving." | ||
| [2008/05/31 07:50:33] <plathrop> http://github.com/wesabe/puppet-apache2/tree/master/manifests/init.pp is the relevant module piece. | ||
| [2008/05/31 07:50:50] <plathrop> I'm just not sure how to untangle this. | ||
| [2008/05/31 07:51:24] <lak> i think the graph won't get written if it's broken | ||
| [2008/05/31 07:51:33] <lak> so your non-cyclic graph is probably from a valid config | ||
| [2008/05/31 07:51:36] <Volcane> yeah it'll draw cached configs | ||
| [2008/05/31 07:51:38] <plathrop> oh... | ||
| [2008/05/31 07:52:06] <plathrop> No, that can't be... This is the first puppet run since I added one of these resources, and it's in the graph. | ||
| [2008/05/31 07:52:44] <lak> ah | ||
| [2008/05/31 07:52:50] <lak> which graph are you looking at? | ||
| [2008/05/31 07:52:51] <plathrop> But that's mostly irrelevant, really. I just need advice on where to look for this cycle, because I've been tracing things for an hour and can't seem to find the cycle. | ||
| [2008/05/31 07:52:56] <lak> the expanded relationships or whatever? | ||
| [2008/05/31 07:52:59] <plathrop> relationships | ||
| [2008/05/31 07:53:04] <plathrop> not expanded | ||
| [2008/05/31 07:53:05] <lak> yeah, that's not complete | ||
| [2008/05/31 07:53:09] <lak> it's the expanded one you want | ||
| [2008/05/31 07:53:14] <lak> that's where the chek is | ||
| [2008/05/31 07:53:17] <lak> check, even | ||
| [2008/05/31 07:53:19] <plathrop> ah ha | ||
| [2008/05/31 07:53:22] * plathrop looks | ||
| [2008/05/31 07:53:38] @ mellen joined channel #puppet | ||
| [2008/05/31 07:53:58] <plathrop> There is a cycle in that graph! You were right... Now to figure out *why* | ||
| [2008/05/31 07:54:26] * Volcane does like the graph, wish we can make it more readable :) | ||
| [2008/05/31 07:54:38] <lak> heh | ||
| [2008/05/31 07:54:50] <lak> looks like th |