Try adding --factsync to the puppetd line.
Does your puppet.conf include factsync = true? that would explain it
working a second time and not a first (sort of)
-Jason
On Jan 12, 9:03 am, Arnau Bria <arnaub...@pic.es>
wrote:> Hi all,
>
> I have a custom fact which determines what interface is primary in
> future bonding:
> It works fine when I run puppet for second time:
>
> # /usr/bin/ruby /usr/sbin/puppetd --server=gridinstall.pic.es
--logdest=/var/log/puppet/puppet.log --test
> info: Retrieving plugins
> notice: /File[/var/lib/puppet/lib/facter]/ensure: created
> notice: /File[/var/lib/puppet/lib/facter/primaryint.rb]/ensure: created
> info: Loading fact primaryint
>
> And then, I add some line in /etc/modprobe.conf:
> notice:
/:main/Node[td234.pic.es]/worker_node/bond/Line[options]/Exec[/bin/echo
''options bonding mode=1 primary=eth0 miimon=100'' >>
''/etc/modprobe.conf'']/returns: executed successfully
> info:
/:main/Node[td234.pic.es]/worker_node/bond/Line[options]/Exec[/bin/echo
''options bonding mode=1 primary=eth0 miimon=100'' >>
''/etc/modprobe.conf'']: Scheduling refresh of Service[network]
>
> As you can see, all works fine for the second time, but when running
> that line from kickstart postinstall I see no refernce to primaryint
> and the line is filled up with empty value:
>
> This is the line I have in my postintakll:
> /usr/bin/ruby /usr/sbin/puppetd --server=gridinstall.pic.es
--logdest=/var/log/puppet/puppet.log --test --fqdn $1 >
/root/postinstall_puppet.log
>
> and grepping log file:
> [root@td065 ~]# grep primaryint.rb postinstall_puppet.log
> [root@td065 ~]#
>
> then, the line is filled with nothing:
>
> #cat /etc/modprobe.conf
> [...]
> options bonding mode=1 primary= miimon=100
>
> and after second run, is filled again with correct value:
>
> #cat /etc/modprobe.conf
> [...]
> options bonding mode=1 primary= miimon=100
> options bonding mode=1 primary=eth1 miimon=100
>
> Is there any limitation when running custom facts?
>
> Cheers,
> Arnau
--~--~---------~--~----~------------~-------~--~----~
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
puppet-users+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/puppet-users?hl=en
-~----------~----~----~----~------~----~------~--~---