# msg: hostname module cannot be used on platform Linux (Neon)

**URL:** <https://forum.ansible.com/t/msg-hostname-module-cannot-be-used-on-platform-linux-neon/24581>\
**Category:** Ansible Project\
**Tags:** ansible-project, ubuntu\
**Created:** [May 26, 2017, 4:59pm UTC](https://forum.ansible.com/t/msg-hostname-module-cannot-be-used-on-platform-linux-neon/24581 "2017-05-26T16:59:03Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kai\_Stian\_Olstad](https://avatars.discourse-cdn.com/v4/letter/k/e19adc/32.png) [@Kai\_Stian\_Olstad](https://forum.ansible.com/u/Kai_Stian_Olstad)\
**Post date:** [May 26, 2017, 4:59pm UTC](https://forum.ansible.com/t/msg-hostname-module-cannot-be-used-on-platform-linux-neon/24581/1 "2017-05-26T16:59:03Z")

</div>

> I recently upgraded to Ansible 2.3 for KDE Neon support and ran into the  
> following failure when running a playbook against it:
> 
> msg: hostname module cannot be used on platform Linux (Neon)

There is noting about Neon in the source  
[https://github.com/ansible/ansible/blob/devel/lib/ansible/modules/system/hostname.py](https://github.com/ansible/ansible/blob/devel/lib/ansible/modules/system/hostname.py)

> And this is the task it failed on:
> 
> &nbsp;&nbsp;&nbsp;- name: set hostname  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hostname:  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;name: "{{ host }}"
> 
> Has anyone found a solution or workaround to this?

IIRC Neon is based on Ubuntu, then you should be able to do this

- name: set hostname  
&nbsp;&nbsp;&nbsp;copy:  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;content: "{{ host }}"  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;dest: /etc/hostname
