VM Provisioniong in Vcenter -> has FQDN -> should have short hostname as name of VM

Hi,

i have running our server provisioning via Foreman on VCenter. This works great, but the name of the new provisioned host is the full qualified name (serverxy.example.com). Our Vmware team now complains about that. So i have tried to find a solution how to define the VMs name, but i have no idea how to do achieve this.
I have checked the deployed vmware.rb file which is installed in our foreman. The name definitions in that code just parses the args. (Hope i have checked the correct ruby code)

Expected outcome:
Vm should just have the short hostname as name in Vcenter

Foreman and Proxy versions:
3.2.0

Other relevant data:
Log entry:
2022-12-22T12:50:34 [W|app|cc2efd77] Rolling back due to a problem: [#<Orchestration::Task:0x000000000d7f9718 @name=“Set up compute instance serverxy.lan.internal.net”, @id=“Set up compute instance serverxy.lan.internal.net”, @status=“failed”, @priority=3, @action=[#<Host::Managed id: nil, name: “serverxy.lan.internal.net”, last_compile: nil, last_report: nil, updated_at: nil, created_at: nil, root_pass: nil, architecture_id: 1, operatingsystem_id: 159, ptable_id: 86, medium_id: 15, build: true, comment: nil, disk: nil, installed_at: nil, model_id: nil, hostgroup_id: 32, owner_id: 38, owner_type: “User”, enabled: true, puppet_ca_proxy_id: 3, managed: true, use_image: nil, image_file: nil, uuid: nil, compute_resource_id: 11, puppet_proxy_id: 3, certname: nil, image_id: nil, organization_id: 2, location_id: 1, type: “Host::Managed”, compute_profile_id: nil, otp: nil, realm_id: nil, provision_method: “build”, grub_pass: nil, global_status: 0, lookup_value_matcher: [FILTERED], pxe_loader: nil, initiated_at: nil, build_errors: nil>, :setCompute], @created=1671709833.2572072, @timestamp=2022-12-22 11:50:34.997552758 UTC>]

Do you have any ideas how to fix this?

Thanks in advanced.
BR
Florian

In the WebUI, under “Administer” → “Settings” → “Provisioning”, you should find an option “Use short name for VMs”, set this to true and future VMs should be deployed with the shortname instead of the FQDN

1 Like

Perfekt,
many thanks!
BR

If your problem is solved, please mark my answer as solution, so that others can see there is no more help needed here and the problem is solved :slight_smile: