# Issue getting VLAN if  network is Distribution virtual switch

**URL:** <https://forum.ansible.com/t/issue-getting-vlan-if-network-is-distribution-virtual-switch/27763>\
**Category:** Ansible Project\
**Created:** [June 11, 2018, 6:37am UTC](https://forum.ansible.com/t/issue-getting-vlan-if-network-is-distribution-virtual-switch/27763 "2018-06-11T06:37:47Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Umesh\_Gowda](https://avatars.discourse-cdn.com/v4/letter/u/8edcca/32.png) [@Umesh\_Gowda](https://forum.ansible.com/u/Umesh_Gowda)\
**Post date:** [June 11, 2018, 6:37am UTC](https://forum.ansible.com/t/issue-getting-vlan-if-network-is-distribution-virtual-switch/27763/1 "2018-06-11T06:37:47Z")

</div>

Having issue Deploy vm from template network is Distribution virtual switch standard switch works fine

Need help regrading issue  
I am able to deploy vm from the template successfully with out any issue if the network is standard switch also system will get the IP address .  
Below configuration if try in DVS switch vm will be deploying but it is network label is not attaching.  
Anything wrong in my code?

networks:

- vlan: “{{ vlan }}”  
type: “static”  
device\_type: vmxnet3  
ip: “{{ ip\_addr }}”  
gateway: X.X.X.X  
netmask: X.X.X.X  
network: dvSwitch Network  
network\_type: dvs
