300-635 · Question #63
An engineer is implementing a Cisco Nexus switch. Which command executes an Ansible playbook called n9k.yml?
The correct answer is A. ansible-playbook n9k.yml. ansible-playbook n9k.yml is the correct syntax for executing an Ansible playbook - the command takes the playbook filename directly as a positional argument, with no additional flags required. Why the distractors are wrong: B uses -f, which in Ansible controls the number of paral
Question
Options
- Aansible-playbook n9k.yml
- Bansible-playbook -f n9k.yml -run now
- Cansible-playbook -f n9k.yml
- Dansible-playbook -f N9K.yml
How the community answered
(53 responses)- A89% (47)
- B4% (2)
- C6% (3)
- D2% (1)
Explanation
ansible-playbook n9k.yml is the correct syntax for executing an Ansible playbook - the command takes the playbook filename directly as a positional argument, with no additional flags required.
Why the distractors are wrong:
- B uses
-f, which in Ansible controls the number of parallel forks (e.g.,-f 10), not file selection - and-run nowis not a valid flag at all. - C combines the real
-fflag with a filename, but-fexpects an integer (fork count), not a filename, so this would throw an error. - D has the same structural problem as C, plus uses uppercase
N9K.yml- Linux filesystems are case-sensitive, so this would fail to find the file even if the syntax were valid.
Memory tip: Think of ansible-playbook like running a Python script - you just pass the filename directly: python script.py → ansible-playbook playbook.yml. No flags needed to specify the file.
Topics
Community Discussion
No community discussion yet for this question.