title: Why Ansible keeps giving me error "Could not find the requested service httpd: cannot check nor set state"?
body: <p>I am doing a dry run on installing apache web server on a centos 7 box.
  This is the webserver.yml file:</p>
  
  <pre><code>--- # Outline to Playbook Translation
  - hosts: apacheWeb
    user: aleatoire
    sudo: yes
    gather_facts: no
    tasks:
    - name: date/time stamp for when the playbook starts
      raw: /bin/date &gt; /home/aleatoire/playbook_start.log
    - name: install the apache web server
      yum: pkg=httpd state=latest
    - name: start the web service
      service: name=httpd state=started
    - name: install client software - telnet
      yum: pkg=telnet state=latest
    - name: install client software - lynx
      yum: pkg=lynx state=latest
    - name: log all the packages installed on the system
      raw: yum list installed &gt; /home/aleatoire/installed.log
    - name: date/time stamp for when the playbook ends
      raw: /bin/date &gt; /home/aleatoire/playbook_end.log
  </code></pre>
  
  <p>When I do a dry run with:</p>
  
  <pre><code>ansible-playbook webserver.yml --check
  </code></pre>
  
  <p>I keep getting this error:</p>
  
  <pre><code>fatal: [&lt;ip_address&gt;]: FAILED! =&gt; {"changed": false, "failed": true, "msg": "Could not find the requested service httpd: cannot check nor set state"}
      to retry, use: --limit @/home/aleatoire/Outline/webserver.retry
  </code></pre>
  
  <p>I tried adding ignore_issues: true and that did not work either.</p>