I have configured a CMS solution in my Linux Virtual Machine on Azure and want to add this VM with my Virtual Netork. I am unable to add my existing Linux Virual machine to Virtual Network.
Any help is greatly appreciated.
As your Linux VM was created first and Virtual Network (VNet) was created after, your Linux VM may not be able to see the Virtual Network.(This is a known issues with Linux VM)
You can follow given steps to achieve your objective:
This way you will have your VM ready and now to add it to VNet.
Now because you are using Linux VM to connect with VNet, there is one problem. You can not do it with your Linux VM as Windows Azure Manager Portal does not support this feature so you would need to use PowerShell command (on Windows) or Cross-Platform tools (on Mac and Linux) to achieve your objective.
Following are the command you will use to create a new VM using an OS Image and Virtual Network:
$vm = New-AzureVMConfig -Name $vmname -InstanceSize ExtraSmall -ImageName $image | Add-AzureProvisioningConfig -Linux –LinuxUser $linuxUser -Password $adminPassword | Set-AzureSubnet -SubnetNames $subnet
New-AzureVM -ServiceName $cloudSvcName -AffinityGroup $affinitygroup -VNetName $vnetname -VMs $vm