Displaying 20 results from an estimated 900 matches similar to: "Ruby Facter.add syntax please help"
2010 Oct 04
2
Issue with match.call
Hi,
I have a function that I'm writing. The arguments in the function are as follows
RFF<-function(qtype, qOpt,...){}
i.e., I have two args that are compulsary and the rest are optional. Now when my user passes the function call, I need to see what optional args are defined and process accordingly...what I have so far is..
RFF<-function(qtype, qOpt,...){
mc <-
2006 Jun 08
2
Page caching for urls with dots
hi everyone,
I have a pesky problem with page caching, sorry if it sounds dummy.
Whenever I''m caching an url like
/controller/argument.with.dots
instead of getting a saved page like
/public/controller/arguments.with.dots.html
I get
/public/controller/arguments.with.dots
which makes the webserver confused as to how to send it (it gets a
Content-Type of text/plain instead of
2000 May 30
1
Unable to use rdist in parrellel mode with 2.1.0p2 ...
Morning all ...
using the following command to sync up the binaries on several
machines:
rdist -P /usr/slocal/bin/ssh -Rf /root/sync-systems
generates the following error message(s):
jasper: updating host jasper
hermes: updating host hermes
attila: updating host attila
hercules: updating host hercules
".rcules: LOCAL ERROR: Unexpected input from server: "Couldn't initialise
2012 Aug 14
4
hiera command line performance
Hi everyone,
The hiera command line program (version 0.3.0) is currently taking around 2
seconds per invocation. This seems quite slow to me, but is probably not
an issue for most users.
We have a number of legacy machines that for one reason or another have not
been puppetised yet, and probably won''t be anytime soon, so I have a
somewhat clever script that, for each of these
2007 Mar 03
0
Facter recipies
Hello! In going over some of the sample cases on the Puppet wiki,
(specifically the Debian tips) I saw a pretty clear need for more
facts. Is there a place to submit new facts?
In this case, the definition of a variable for each node''s Debian
Version seemed like an easy thing to introspect. The following is
what I whipped up... please let me know if I''m doing
2007 Apr 26
2
[PATCH] facter: add interfaces, default_gateway facts on Linux
Quick and dirty:
--- lib/facter.rb (revision 203)
+++ lib/facter.rb (working copy)
@@ -989,6 +989,18 @@
%x{/usr/sbin/scutil --get LocalHostName}
end
end
+ Facter.add(:interfaces) do
+ confine :kernel => :linux
+ setcode do
+ %x{/sbin/ifconfig -a -s}.split($/)[1..-1].collect {|line|
2006 Feb 05
1
SNMP help
Hello
I'm trying to setup SNMP on my Centos 4.2 server.
I want the ability to monitor the disk and some other non default settings
that can be defined in snmpd.conf but when I request the data, it
doesn't give the disired results.
Config below and trap results below.
Thanks in advance for any help.
Kevin
[root at localhost snmp] snmpget -v 2c -c public localhost disk
2012 Jan 30
2
SLES11: facter without arguments produces Error: uninitialized constant Facter::IPAddress
Hi, I run into problems with the ipaddress fact using the latest
Facter gem (1.6.4, 1.6.5) on SLES11. The versions and gems I use work
perfectly fine on SLES10 SP3.
The problem: running "facter" without arguments results in an error,
even though the erroring fact "ipaddress" is ok.
test:~ # cat /etc/SuSE-release
SUSE Linux Enterprise Server 11 (x86_64)
VERSION = 11
PATCHLEVEL
2011 Jan 07
4
facter --puppet does not report "environment"
Is it normal that "facter --puppet" does not show the environment
variable? is there a way to have it include it?
Thanks a lot,
Mohamed.
--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to
2010 Jul 19
1
facter fails to recognize OEL/OVS in operatingsystemrelease.rb
For the benefit of those running OEL (Oracle Enterprise Linux) or OVS,
be aware that under 2.6.0rc4 facter doesn''t properly recognize OEL in
/usr/lib/ruby/site_ruby/1.8/facter/operatingsystemrelease.rb. A diff
for a fix is below; probably not the best fix but if you need it work
now, this''ll do it for you.
I''ve already filed a bug:
2008 Jan 08
1
odd facter error with split
Not sure if this is another issue cropping up with 0.24.1 but I''m getting
the following:
info: Loading fact raid
/etc/puppet/facts/location.rb:5: private method `split'' called for
nil:NilClass (NoMethodError)
from /usr/lib/ruby/site_ruby/1.8/facter.rb:510:in `call''
from /usr/lib/ruby/site_ruby/1.8/facter.rb:510:in `value''
from
2010 Aug 28
1
ANNOUNCE: Facter 1.5.8
For 40 days and 40 nights Facter wandered in the wilderness sustained
only by the occasional patch and bottle of Kool-Aid.
Slightly less tanned and equally happy Facter 1.5.8 has arrived!
1.5.8 is a feature and maintenance release containing a number of fixes,
updates and additional tests.
You can get the release at:
http://reductivelabs.com/downloads/facter/facter-1.5.8.tar.gz
Please log any
2013 Feb 21
6
Using Facter to find the Java version running on the machine
Hello all,
I am currently trying to setup a Custom Fact that will can be used to
determine the version of the Java JRE running on a machine, in order to use
it in my manifests to ensure the proper JARS are distribured based on
environment. I''m trying to use the java -version command and then capture
the JRE release (eg "1.6.0_37"). No matter what I have tried, the output
2011 Apr 07
12
Mutliple custom facts not showing in facter
Hi,
I''ve noticed that defining multiple facts in one file is possible, and
puppet can make use of them correctly, but when trying to call with facter
--puppet they are not shown, do I need something special to make them work
as any other single custom fact?
Master is running 2.6.7
This is a custom fact with two facts in it:
[modules/foobar/lib/facter/foobar.rb ]
require
2008 Nov 19
0
net-snmp puzzle
I have a bunch of centos 5.2 boxes.
I'm trying to run smtp on all of them.
Using indentical net-snmp configuration files.
/etc/snmp/snmpd.conf
com2sec notConfigUser localhost smssnmp
com2sec notConfigUser 10.1.1.0/24 smssnmp
group notConfigGroup v1 notConfigUser
group notConfigGroup v2c notConfigUser
view systemview included
2007 Nov 13
6
Facter and arrays
Hi,
Is it possible to have an array as the output of a custom fact? And
then to pass it into a template in Puppet?
I currently have a fact that looks like this:
Facter.add("exports") do
setcode do
case Facter.hostname
when (/thishost/i):
[ "/local", "/local2" ]
end
end
end
& a template like this:
<%
2011 Jan 18
2
help with read.table.ffdf parameters
Hello fellow R users,
I am trying to read a 6.9 million row text file with 26 columns separated by
spaces into R using ff. When I specify a small number for first.rows,
next.rows and nrows it is read with no issue. However, when I try to specify
larger next.rows values and no nrows parameter to read the entire file, I
keep getting errors. Please see code below.
I am trying to this on a m1.large
2007 Mar 14
2
A java initialization routine
Whe using a particular web page, the default values of the form are set
by a java function, then I can modify the web page and submit it.
But when I use Mechanize, I am having trouble figuring out how to get
those values so I can put them into the form I am going to submit.
Below is the function that has the data...and I have changed pertinent
info. What other choices might I have to
2008 Jul 02
12
Module interaction and dependencies in Puppet (SNMP in particular)
Hello folks,
I''m sitting here converting my static, simple classes/snmp.pp into a
full module, and I''ve run into a bit of a brick wall.
net-snmp is one of those wonderful programs that will only read two
configuration files (it reads a few more, but only 2 are in /etc) -
/etc/snmpd.conf and /etc/snmpd.local.conf. This means that my SNMP
module is somehow going to have to
2013 Apr 22
3
Udefined method `get_uptime` for Facter::Util::Uptime:Module
Hi,
I''m rookie puppet user and I trying to establish simple Server-Client
connection on configuration:
Server: *Fedora F18*, Puppet 3.1.1 (installed by yum), Ruby 1.8.7
Client: *Debian 6.0.6*, Puppet 3.1.1 (installed by guide<http://shapeshed.com/setting-up-puppet-on-ubuntu-10-04/>),
Ruby 1.8.7
Server sign client certificate with success but now I''m struggle with apply