6. A Puppet agent inspects /etc/conf.d, determines the OS to be Gentoo Linux, then activates the Portage package manager. What is the provider in this scenario?
- /etc/conf.d
- Portage
- Gentoo Linux
- The Puppet agent
7. Which of the following examples show proper Puppet syntax?
class AutoConfig { package { 'Executable': ensure => latest, } file { 'executable.cfg': source => 'puppet:///modules/executable/Autoconfig/executable.cfg' replace => true, } service { 'executable.exe': enable => true, ensure => running, }}
class AutoConfig : package ''Executable': ensure => latest, file 'executable.cfg': source => 'puppet:///modules/executable/Autoconfig/executable.cfg' replace => true, service 'executable.exe': enable => true, ensure => running,
class AutoConfig { package { 'Executable': ensure == latest, } file { 'executable.cfg': source == 'puppet:///modules/executable/Autoconfig/executable.cfg' replace == yes, } service { 'executable.exe': enable == yes, ensure == true, }}
class AutoConfig { package { 'Executable': assure=> latest, } file { 'executable.cfg': origin=> 'puppet:///modules/executable/Autoconfig/executable.cfg' substitute=> true, } program{ 'executable.exe': activate => true, assure => running, }}
class AutoConfig {
package { 'Executable':
ensure => latest,
}
file { 'executable.cfg':
source => 'puppet:///modules/executable/Autoconfig/executable.cfg'
replace => true,
}
service { 'executable.exe':
enable => true,
ensure => running,
}
class AutoConfig :
package ''Executable':
ensure => latest,
file 'executable.cfg':
source => 'puppet:///modules/executable/Autoconfig/executable.cfg'
replace => true,
service 'executable.exe':
enable => true,
class AutoConfig {
package { 'Executable':
ensure == latest,
}
file { 'executable.cfg':
source == 'puppet:///modules/executable/Autoconfig/executable.cfg'
replace == yes,
}
service { 'executable.exe':
enable == yes,
ensure == true,
}
class AutoConfig {
package { 'Executable':
assure=> latest,
}
file { 'executable.cfg':
origin=> 'puppet:///modules/executable/Autoconfig/executable.cfg'
substitute=> true,
}
program{ 'executable.exe':
activate => true,
assure => running,
}
- class AutoConfig {package { ‘Executable’:ensure => latest,}file { ‘executable.cfg’:source => ‘puppet:///modules/executable/Autoconfig/executable.cfg’replace => true,}service { ‘executable.exe’:enable => true,ensure => running,}}
8. What is the benefit of grouping resources into classes when using Puppet?
- Providers can be specified
- Configuration management is simplified
- The title is changeable
- Packages are not required
9. What defines which provider will be used for a particular resource?
- Puppet assigns providers based on the resource type and data collected from the system.
- A menu allows you to choose providers on a case-by-case basis.
- The user is required to define providers in a config file.
- Puppet uses an internet database to decide which provider to use.
10. In Puppet’s file resource type, which attribute overwrites content that already exists?
- Purge
- Overwrite
- Replace
- Save