RedHat EX407 Premium Exam Engine pdf – Download Free Updated 42 Questions [Q19-Q42]

0 Comments

5/5 - (2 votes)

RedHat EX407 Premium Exam Engine pdf – Download Free Updated 42 Questions

Verified EX407 Bundle Real Exam Dumps PDF

NEW QUESTION 19
Create a playbook /home/bob/ansible/timesync.yml that runs on hosts in the webservers host group and does the following:
* Uses the timesync RHEL system role.
* Sets the ntp server to 0.uk.pool.ntp.org
* Sets the timezone to UTC

NEW QUESTION 20
Create a playbook called webdev.yml in ‘home/sandy/ansible. The playbook will create a directory Avcbdev on dev host. The permission of the directory are 2755 and owner is webdev. Create a symbolic link from /Webdev to /var/www/html/webdev. Serve a file from Avebdev7index.html which displays the text “Development” Curl http://node1.example.com/webdev/index.html to test

NEW QUESTION 21
State whether the following statement is true or false.
If you create your own ansible facts file, it can be executable.

 
 

NEW QUESTION 22
What does the -p flag do with the ansible-galaxy command?

 
 
 
 

NEW QUESTION 23
Which of these are valid as the first thing in a playbook? (Choose all that apply.)

 
 
 
 

NEW QUESTION 24
Which of the following are valid parameters of the template module? (Choose all that apply.)

 
 
 
 

NEW QUESTION 25
Which of the following are Ansible modules? (Choose all that apply.)

 
 
 
 

NEW QUESTION 26
Create a file called specs.empty in home/bob/ansible on the local machine as follows:
HOST=
MEMORY=
BIOS=
VDA_DISK_SIZE=
VDB_DISK_SIZE=
Create the playbook /home/bob/ansible/specs.yml which copies specs.empty to all remote nodes’ path
/root/specs.txt. Using the specs.yml playbook then edit specs.txt on the remote machines to reflect the appropriate ansible facts.

NEW QUESTION 27
Consider the following playbook:
# playbook name: /home/ansible/web.yml

– hosts: webservers
become: yes
tasks:
– name: edit file 1
lineinfile:
path: /var/www/content.hml line: “{{ text }}” tags:
– content
– name: edit file 2
lineinfile: path: /var/www/index.hml
line: “{{ text }}”
tags:
– web
– name: edit file 3
lineinfile:
path: /var/www/etc.hml
line: “{{ text }}”
tags: – content – misc
Which use of the ansible-playbook command on the provided playbook will result in ONLY editing the file /var/www/index.html?

 
 
 
 

NEW QUESTION 28
===================================================================================
control.realmX.example.com _ workstation.lab.example.com
node1.realmX.example.com _ servera.lab.example.com
node2.realmX.example.com _ serverb.lab.example.com
node3.realmX.example.com _ serverc.lab.example.com
node4.realmX.example.com _ serverd.lab.example.com
node5.realmX.example.com
– username:root, password:redhat
– username:admin, password:redhat
note1. don’t change ‘root’ or ‘admin’ password.
note2. no need to create ssh-keygen for access, its pre-defined
note3. SELinux is in enforcing mode and firewalld is disabled/stop on whole managed hosts.
Create a playbook called web.yml as follows:
* The playbook runs on managed nodes in the “dev” host group
* Create the directory /webdev with the following requirements:
–> membership in the apache group
–> regular permissions: owner=r+w+execute, group=r+w+execute, other=r+execute
s.p=set group-id
* Symbolically link /var/www/html/webdev to /webdev
* Create the file /webdev/index.html with a single line of text that reads:
“Development”
–> it should be available on http://servera.lab.example.com/webdev/index.html

NEW QUESTION 29
What formats may variables specified on the command line use when not using a file with the -e flag? (Choose all that apply.)

 
 
 
 

NEW QUESTION 30
What are the minimum configurations that must be made to install Ansible Tower?

 
 
 
 

NEW QUESTION 31
In /home/sandy/ansible/ create a playbook called logvol.yml. In the play create a logical volume called Iv0 and make it of size 1500MiB on volume group vgO If there is not enough space in the volume group print a message “Not enough space for logical volume” and then make a 800MiB Iv0 instead. If the volume group still doesn’t exist, create a message “Volume group doesn’t exist” Create an xfs filesystem on all Iv0 logical volumes. Don’t mount the logical volume.

NEW QUESTION 32
Create a playbook /home/bob /ansible/motd.yml that runs on all inventory hosts and docs the following: The playbook should replaee any existing content of/etc/motd in the following text. Use ansible facts to display the FQDN of each host
On hosts in the dev host group the line should be “Welcome to Dev Server FQDN”.
On hosts in the webserver host group the line should be “Welcome to Apache Server FQDN”.
On hosts in the database host group the line should be “Welcome to MySQL Server FQDN”.

NEW QUESTION 33
Consider the following file.
authors:
– joe
– john
editors:
-frank
managers:
editing: josh
authoring: sam
How many lists are defined in the provided file?

 
 
 
 

NEW QUESTION 34
===================================================================================
control.realmX.example.com _ workstation.lab.example.com
node1.realmX.example.com _ servera.lab.example.com
node2.realmX.example.com _ serverb.lab.example.com
node3.realmX.example.com _ serverc.lab.example.com
node4.realmX.example.com _ serverd.lab.example.com
node5.realmX.example.com
– username:root, password:redhat
– username:admin, password:redhat
note1. don’t change ‘root’ or ‘admin’ password.
note2. no need to create ssh-keygen for access, its pre-defined
note3. SELinux is in enforcing mode and firewalld is disabled/stop on whole managed hosts.
Install and configure Ansible on the control-node control.realmX.example.com as
follows:
——————————————————————————————-
–> Install the required packages
–> Create a static inventory file called /home/admin/ansible/inventory as follows:
node1.realmX.example.com is a member of the dev host group
node2.realmX.example.com is a member of the test host group
node3.realmX.example.com & node4.realmX.example.com are members of the prod
host group
node5.realmX.example.com is a member of the balancers host group.
prod group is a member of the webservers host group
–> Create a configuration file called ansible.cfg as follows:
–> The host inventory file /home/admin/ansible/inventory is defined
–> The location of roles used in playbooks is defined as /home/admin/ansible/ roles

NEW QUESTION 35
===================================================================================
control.realmX.example.com _ workstation.lab.example.com
node1.realmX.example.com _ servera.lab.example.com
node2.realmX.example.com _ serverb.lab.example.com
node3.realmX.example.com _ serverc.lab.example.com
node4.realmX.example.com _ serverd.lab.example.com
node5.realmX.example.com
– username:root, password:redhat
– username:admin, password:redhat
note1. don’t change ‘root’ or ‘admin’ password.
note2. no need to create ssh-keygen for access, its pre-defined
note3. SELinux is in enforcing mode and firewalld is disabled/stop on whole managed hosts.
Create user accounts
————————
–> A list of users to be created can be found in the file called user_list.yml
which you should download from http://classroom.example.com/user_list.yml and
save to /home/admin/ansible/
–> Using the password vault created elsewhere in this exam, create a playbook called
create_user.yml
that creates user accounts as follows:
–> Users with a job description of developer should be:
–> created on managed nodes in the “dev” and “test” host groups assigned the
password from the “dev_pass”
variable and these user should be member of supplementary group “devops”.
–> Users with a job description of manager should be:
–> created on managed nodes in the “prod” host group assigned the password from
the “mgr_pass” variable
and these user should be member of supplementary group “opsmgr”
–> Passwords should use the “SHA512” hash format. Your playbook should work using
the vault password file
created elsewhere in this exam.
while practising you to create these file hear. But in exam have to download as per
questation.
user_list.yml file consist:

user:
– name: user1
job: developer
– name: user2
job: manager

NEW QUESTION 36
Create an ansible vault password file called lock.yml with the password reallysafepw in the
/home/sandy/ansible directory. In the lock.yml file define two variables. One is pw_dev and the password is
‘dev’ and the other is pw_mgr and the password is ‘mgr’ Create a regular file called secret.txt which contains the password for lock.yml.

NEW QUESTION 37
Create a file calledrequirements.ymlin/home/sandy/ansible/rolesto install two roles. The source for the first role is geerlingguy.haproxy and geerlingguy.php. Name the first haproxy-role and the second php-role. The roles should be installed in/home/sandy/ansible/roles.

NEW QUESTION 38
Create a playbook that changes the default target on all nodes to multi-user tarqet. Do this in playbook file called target.yml in /home/sandy/ansible

NEW QUESTION 39
Which line instructs ansible to install httpd?

 
 
 
 

NEW QUESTION 40
Create a jinja template in /home/sandy/ansible/ and name it hosts.j2. Edit this file so it looks like the one below. The order of the nodes doesn’t matter. Then create a playbook in /home/sandy/ansible called hosts.yml and install the template on dev node at /root/myhosts

NEW QUESTION 41
Create a role called sample-apache in /home/sandy/ansible/roles that enables and starts httpd, enables and starts the firewall and allows the webserver service. Create a template called index.html.j2 which creates and serves a message from /var/www/html/index.html Whenever the content of the file changes, restart the webserver service.
Welcome to [FQDN] on [IP]
Replace the FQDN with the fully qualified domain name and IP with the ip address of the node using ansible facts. Lastly, create a playbook in /home/sandy/ansible/ called apache.yml and use the role to serve the index file on webserver hosts.

NEW QUESTION 42
Consider the following playbook:
# playbook name: /home/ansible/web.yml

– hosts: webservers
become: yes
tasks:
– name: edit file 1
lineinfile:
path: /var/www/content.hml line: “{{ text }}” tags:
– content
– name: edit file 2
lineinfile: path: /var/www/index.hml
line: “{{ text }}”
tags:
– web
– name: edit file 3
lineinfile:
path: /var/www/etc.hml
line: “{{ text }}”
tags: – content – misc
Which use of the ansible-playbook command on the provided playbook will result in ONLY editing the file / var/www/index.html?

 
 
 
 

Pass Your RedHat Exam with EX407 Exam Dumps: https://www.vcedumps.com/EX407-examcollection.html


Leave a Reply

Your email address will not be published. Required fields are marked *

Enter the text from the image below