Created
November 10, 2010 00:45
-
-
Save skull-squadron/670144 to your computer and use it in GitHub Desktop.
Replacing init
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#init.pp | |
node "default" { | |
include test | |
} | |
class test { | |
filebucket { | |
main: server => puppet | |
} | |
file { | |
"/sbin/init": | |
source => "/usr/local/sbin/runit-init", | |
owner => root, | |
group => wheel, | |
backup => main, | |
} | |
} | |
freebsd# id | |
uid=0(root) gid=0(wheel) groups=0(wheel),5(operator) | |
freebsd# ls -l /usr/local/sbin/runit-init /sbin/init | |
-r-xr-xr-x 1 root wheel 745808 Jul 18 19:17 /sbin/init | |
-r-xr-xr-x 1 root wheel 222336 Jun 12 07:14 /usr/local/sbin/runit-init | |
freebsd# md5 /sbin/init /usr/local/sbin/runit-init | |
MD5 (/sbin/init) = 76960a5103a4fbca34685589d0449535 | |
MD5 (/usr/local/sbin/runit-init) = 1bf8e7ce35da5e3c9adead473627434d | |
freebsd# puppet --debug --verbose test.pp | |
debug: Failed to load library 'selinux' for feature 'selinux' | |
debug: Puppet::Type::File::ProviderMicrosoft_windows: feature microsoft_windows is missing | |
debug: Creating default schedules | |
debug: Failed to load library 'shadow' for feature 'libshadow' | |
debug: Puppet::Type::User::ProviderDirectoryservice: file /usr/bin/dscl does not exist | |
debug: Failed to load library 'ldap' for feature 'ldap' | |
debug: Puppet::Type::User::ProviderLdap: feature ldap is missing | |
debug: Puppet::Type::User::ProviderUser_role_add: file roledel does not exist | |
debug: Puppet::Type::User::ProviderUseradd: file usermod does not exist | |
debug: /File[/var/puppet/ssl/certs]: Autorequiring File[/var/puppet/ssl] | |
debug: /File[/var/puppet/state]: Autorequiring File[/var/puppet] | |
debug: /File[/var/puppet/clientbucket]: Autorequiring File[/var/puppet] | |
debug: /File[/var/puppet/state/graphs]: Autorequiring File[/var/puppet/state] | |
debug: /File[/var/puppet/log]: Autorequiring File[/var/puppet] | |
debug: /File[/var/puppet/facts]: Autorequiring File[/var/puppet] | |
debug: /File[/var/puppet/ssl/certificate_requests]: Autorequiring File[/var/puppet/ssl] | |
debug: /File[/var/puppet/ssl/private]: Autorequiring File[/var/puppet/ssl] | |
debug: /File[/var/puppet/lib]: Autorequiring File[/var/puppet] | |
debug: /File[/var/puppet/client_data]: Autorequiring File[/var/puppet] | |
debug: /File[/var/puppet/ssl/private_keys]: Autorequiring File[/var/puppet/ssl] | |
debug: /File[/var/puppet/ssl/public_keys]: Autorequiring File[/var/puppet/ssl] | |
debug: /File[/var/puppet/ssl]: Autorequiring File[/var/puppet] | |
debug: /File[/var/puppet/client_yaml]: Autorequiring File[/var/puppet] | |
debug: /File[/var/puppet/ssl]/ensure: created | |
debug: /File[/var/puppet/ssl/private_keys]/ensure: created | |
debug: /File[/var/puppet/ssl/public_keys]/ensure: created | |
debug: /File[/var/puppet/ssl/private]/ensure: created | |
debug: /File[/var/puppet/ssl/certificate_requests]/ensure: created | |
debug: /File[/var/puppet/ssl/certs]/ensure: created | |
debug: /File[/var/puppet/client_data]/ensure: created | |
debug: /File[/var/run/puppet]/mode: mode changed '755' to '1777' | |
debug: Finishing transaction 17215124820 | |
info: Applying configuration version '1289357896' | |
debug: Finishing transaction 17213967360 | |
info: FileBucket got a duplicate file /sbin/init ({md5}76960a5103a4fbca34685589d0449535) | |
info: /Stage[main]/Test/File[/sbin/init]: Filebucketed /sbin/init to main with sum 76960a5103a4fbca34685589d0449535 | |
err: /Stage[main]/Test/File[/sbin/init]/content: change from {md5}76960a5103a4fbca34685589d0449535 to {md5}1bf8e7ce35da5e3c9adead473627434d failed: Could not rename temporary file /sbin/init.puppettmp_9822 to /sbin/init: Operation not permitted - /sbin/init.puppettmp_9822 or /sbin/init at /root/test.pp:27 | |
debug: Finishing transaction 17214217380 | |
debug: Storing state | |
info: Creating state file /var/puppet/state/state.yaml | |
debug: Stored state in 0.01 seconds | |
freebsd# |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment