{"record":{"id":"89de8e1ddb63d439","repo":"hashicorp/vagrant","slug":"vagrant-was-unable-to-determine-the-recommended-na-89de8e","errorCode":null,"errorMessage":"Vagrant was unable to determine the recommended name for your\nVirtualBox VM. This is usually an issue with VirtualBox. The output\nfrom VirtualBox is shown below, which may contain an error to fix.\nThe best way to fix this issue is usually to uninstall VirtualBox,\nrestart your computer, then reinstall VirtualBox.\n\nVirtualBox output:\n\n%{output}","messagePattern":"Vagrant was unable to determine the recommended name for your\nVirtualBox VM\\. This is usually an issue with VirtualBox\\. The output\nfrom VirtualBox is shown below, which may contain an error to fix\\.\nThe best way to fix this issue is usually to uninstall VirtualBox,\nrestart your computer, then reinstall VirtualBox\\.\n\nVirtualBox output:\n\n%(.+?)","errorType":"exception","errorClass":"Vagrant::Errors.VirtualBoxNoName","httpStatus":null,"severity":"error","filePath":"plugins/providers/virtualbox/driver/version_5_0.rb","lineNumber":434,"sourceCode":"        end\n\n        def halt\n          execute(\"controlvm\", @uuid, \"poweroff\", retryable: true)\n        end\n\n        def import(ovf)\n          ovf = Vagrant::Util::Platform.windows_path(ovf)\n\n          output = \"\"\n          total = \"\"\n          last  = 0\n\n          # Dry-run the import to get the suggested name and path\n          @logger.debug(\"Doing dry-run import to determine parallel-safe name...\")\n          output = execute(\"import\", \"-n\", ovf)\n          result = /Suggested VM name \"(.+?)\"/.match(output)\n          if !result\n            raise Vagrant::Errors::VirtualBoxNoName, output: output\n          end\n          suggested_name = result[1].to_s\n\n          # Append millisecond plus a random to the path in case we're\n          # importing the same box elsewhere.\n          specified_name = \"#{suggested_name}_#{(Time.now.to_f * 1000.0).to_i}_#{rand(100000)}\"\n          @logger.debug(\"-- Parallel safe name: #{specified_name}\")\n\n          # Build the specified name param list\n          name_params = [\n            \"--vsys\", \"0\",\n            \"--vmname\", specified_name,\n          ]\n\n          # Extract the disks list and build the disk target params\n          disk_params = []\n          disks = output.scan(/(\\d+): Hard disk image: source image=.+, target path=(.+),/)\n          disks.each do |unit_num, path|","sourceCodeStart":416,"sourceCodeEnd":452,"githubUrl":"https://github.com/hashicorp/vagrant/blob/35f3160f4ad6edc3a9f3aa9570adfc1a4d73aaa5/plugins/providers/virtualbox/driver/version_5_0.rb#L416-L452","documentation":"During `vagrant up`, the VirtualBox 5.x driver dry-runs `VBoxManage import -n <ovf>` and parses the line `Suggested VM name \"...\"` from the output to build a parallel-safe unique VM name. If that regex does not match (because VBoxManage printed an error or unexpected output), Vagrant raises VirtualBoxNoName with the raw VBoxManage output embedded in the message. It almost always indicates a broken or mismatched VirtualBox installation rather than a Vagrantfile problem.","triggerScenarios":"Calling the provider's import path (first `vagrant up` / `vagrant box add` + up) where `execute(\"import\", \"-n\", ovf)` returns output that does not contain /Suggested VM name \"(.+?)\"/ — e.g. VBoxManage itself errors out, the .ovf inside the box is unreadable, or the installed VBoxManage version emits a different dry-run format than the 5.x driver expects.","commonSituations":"Corrupted VirtualBox install after an OS upgrade; VirtualBox 5.x CLI tools partially removed or a version mismatch between VBoxManage and the driver Vagrant selected; a damaged/truncated box download; paths with unusual encoding on Windows causing import to fail before printing the suggested name.","solutions":["Read the 'VirtualBox output:' section of the error — it contains the actual VBoxManage failure to fix","Verify VirtualBox works: run `VBoxManage import -n <box.ovf>` manually and confirm it prints a Suggested VM name","Re-download / re-add the box (`vagrant box remove <box> && vagrant up`) in case the .ovf was truncated","As the message suggests: uninstall VirtualBox, reboot, reinstall the latest 5.x/6.x build, then retry","Upgrade Vagrant so its VirtualBox driver matches the installed VirtualBox major version"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"out = `VBoxManage import -n /path/to/box/box.ovf 2>&1`\nabort 'VirtualBox import dry-run broken - reinstall VirtualBox' unless out.match?(/Suggested VM name \"/)","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Keep VirtualBox and Vagrant versions in lockstep; upgrade both together","Verify a new box imports cleanly before writing Vagrantfiles against it: `VBoxManage import -n box.ovf`","Prefer full VirtualBox installer over partial package upgrades"],"tags":["virtualbox","vboxmanage","import","vm-name","driver-5-0"],"backgroundTag":"virtualbox-import-failed","analyzedSha":"35f3160f4ad6edc3a9f3aa9570adfc1a4d73aaa5","analyzedAt":"2026-08-21T13:34:32.514Z","schemaVersion":2},"datasetVersion":"2026-08-21T18:17:14.833Z"}