Posted on

Puppet Interview Questions


Puppet is the most popular software configuration tool that forms part of any interview starting from fresher, middle level to experienced IT professionals owing to migration to Devops culture. Here are useful interview questions that will help you with preparation
1) Which operator can convert an array into a comma separated list of arguments?
A.*(splat)
2) While writing a new class named mongodb::master which module path should contain definition class?
The class modules and codes reside in the manifests directory. mongodb/manifests/master.pp
3) For running mcollective commands which user will you make use of?
Make use of user peadmin
4) Who can issue mcollective commands as they control the puppet master?
Make use of user peadmin
5) In which directory of the module structure does the test function written to test functionality of the application reside?
It resides in the directory examples
6) Which is a control expression of an unless statement?
Make use of undef values
7) Mcollective makes use of ports to accept inbound traffic connection requests from puppet agents. Which port is being made use of for this purpose?
Any host used to invoke commands must be able to reach MCollective on this port. The PE Console accepts HTTPS traffic from end-users on this port 61613
8) You have monolithic installations. In which port does puppetdb accept incoming traffic?
In port 8081
9) What are the many different ways in which you can apply puppet manifests to the nodes?
Make use of one of the following methods :
a) Using Hiera
b) Puppet Enterprise Console
c) Include in manifests/site.pp
10) What kind of operands are accepted on either side of chained arrows?
a) Resource declarations
b) Resource references
c) Resource Collectors
11) You have to create complex expressions in resource collectors. Which of the operators can be used for this purpose?
We can make use of anyone of the following operators :
a) and
b) or
c) !=
12) As per puppet language style guide what should a comment explain?
It should explain why of the code
13) What is proper format of comments as per puppet guide?
As per puppet language style guide comments must be hash and not /* */
14) Which command is used to view all certificates waiting to be signed?
Make use of the command puppet cert list -a
15) Which status is invalid in puppet reporting in the Puppet::Transaction::Event?
The status ready is not a valid status
16) Can a resource have multiple namevars?
Yes. There can be
17) [master] environmentpath = $codedir/override_environments:$codedir/environments Is this a valid reference for the code directory?
Yes. This is a valid reference for the code directory
18) How will you make use of mcollective to trigger a puppet run on all your CentOS linux nodes?
Using command mco puppet runonce –wf operatingsystem=CentOS
19) How will you make use of fact option in puppet?
In puppet enterprise the fact option is to be used with with fact option –wf (or) -F
20) What is a fact in puppet enterprise?
It is a standard puppet facts available in puppet manifests
21) Which attributes do you need to make use of to make exec command Idempotent?
We need the following attributes:
a) unless
b) onlyif
c) creates
22) Which are valid statements of the producing and consuming service?
a) produces
b) consumes
c) export
23) Which operators take precedence in puppet?
The operator ! takes precedence
24) Which mcollective subcommand is the general purpose client that can invoke actions from any MCollective agent plugin ?
Make use of command rpc
25) Does variant datatype accept undef type as a parameter that will lead to resulting datatype match the undef?
Yes . It does
26) Give details on some catalog statements :-
a) realize
b) include
c) require
d) contain
27) Which key types are accepted by priority lookup in hiera 3.x?
a) top-level lookup keys
b) qualiqed keys
28) Which abstract datatype will not match undef default?
It is scalar datatype
29) Which abstract datatype will match undef default?
It includes datatypes like the ones below :
a) variant
b) data
c) any
d) vector
30) You have been asked to install puppetlabs-apache module from another module repository. Which command would you make use of for this purpose?
Using command puppet module install –module_repository http://dev-forge.example.com puppetlabs-apache
31) Which categories does appear in the report of Puppet::Util::Metric object?
a) resources
b) events
c) time
d) changes
32) Which component is not a component of the mcollective orchestration internals?
It is the rpc
33) Which component is a component of the mcollective orchestration internals?
a) mco
b) pe-actiemq
c) pe-mcollective
34) In $facts hash which variables are available?
It is the variable $clientversion
35) Which $facts hash variable has current version of puppet agent information and are available as top-score variable as well?
It is the variable $clientversion

Posted on

Scope of devops for DBA


DBA the database administrator is an essentially important personnel in infrastructure team. In larger enterprises like IBM, Oracle, Google DBA is a separate group in itself.
Devops has been the talk of the town this year. Devops is a culture that did start gaining momentum ever since 2014. In this post lets see what is the scope of Devops for a DBA. As such what does a DBA do in Devops team
Organizations create a brand new Devops engineer profile and much of them talk about knowledge of linux, ability to work comfortably in linux systems etc. System administrators find easy transition onto Devops space. That doesn’t stop there. Every member in infrastructure has some role major or minor when become part of Devops. So, what is expected out of a DBA who is to join Devops team in real-time?
1) Cloud infrastructure knowledge – Datacentre has started moving out of your office space onto cloud ever since amazon launched AWS service in 2006. Though it was thought out to be a service to cater internet based companies like google, facebook etc organizations started realizing the pay as you go model value and are migrating their infrastructure onto cloud.

Say, you are a DBA for a brand new project and you have been asked to come up with capacity planning – Once you come up with proposal on disk space, anticipated growth in next 5 years now firms ask you to migrate your database onto cloud services like AWS, Rackspace etc.

DBA’s will have to work with AWS engineers in case you want to go with Amazon service, migrate your database onto AWS using their GUI tools, make sure performance is perfect. If you find some issues, have them add more CPU’s, disk, memory etc resources on the go. Biggest advantage is that you only pay as you use the resources. You don’t have to lock the money in servers costing 1000’s of dollars as you did before

Take away : DBA’s should learn basics of AWS to support databases in cloud. You will be hired as part of Devops team if you know cloud computing infrastructure like AWS, rackspace, openstack etc.

Recently Oracle has come up with Oracle Cloud that offers database as a service DaaS. Once migrated DBA’s should evangelize this to Devops team

2) Database Install/Upgrades/Migration scripts update – When the culture does get transformed from waterfall onto Devops adopting Lean agile methodologies, DBA’s who work in development will need to checkin the code changes, add new scripts that come as part of product install, upgrade, migration scripts onto source code system, will need to check automated email notification from continuous integration and delivery frameworks like jenkins, make changes, support until code in deployed in pre-production environment

3) Knowledge of Devops infrastructure, tools – When you adapt to a particular culture you start learning tools, techniques, processes that does support it. This is no different. DBA’s should know something about the following tools that are integral part of Devops framework

Linux shell scripting – It can be bash,ksh,csh,bash etc

Source control tools – git, svn, clearcase and can be any choice of your organization. This is wherein you checkin code

Build & release engineering tool – ant, apache maven

Continuous integration and continuous delivery – CI&CD tools can be jenkins, hudson etc

Jira, docker, chef, puppet – some understanding on this will come handy