コンテンツにスキップ

Manually Resetting the Identity of a Porta On Prem VM

このコンテンツはまだ日本語訳がありません。

Each Porta VM is a copy made from the same image, so any virtual machines created from this image will all have the same identity. This will cause problems when it requests an IP address from the network.

We want to be able to uniquely identify this virtual machine, so we need to reset its identity and then reboot the machine.

  1. Open Windows Powershell or Terminal.
  2. Connect to the VM using SSH (replace the command below with your own values):
    • portavm is the username you will be connecting as
    • VM-IP is the VM’s IPv4 address on the network
    Terminal window
    ssh portavm@<VM-IP>
    # Example: ssh portavm@192.168.50.9
  3. Run the following command to reset the VM’s identity:
    Terminal window
    ./scripts/reset_identity.sh
  4. You will be prompted to enter a new hostname for the VM.
    • To use the default suggested hostname, simply hit Enter.
      • The suggestion is usually the current hostname appended with a random number, e.g., Porta-VM-1234.
    • To use a custom hostname, type it in and hit Enter.
      • You can simply use with its Windows hostname appended with -VM (e.g. PXLAB-VM), as long as this is a unique name.
    • The hosts file of the virtual machine will be automatically updated with this new hostname.
  5. The terminal will then output various information as it resets the identity.
  6. When prompted to reboot, type y and hit Enter to reboot the VM.
  7. While the machine is rebooting, your current connection will be disconnected, which is normal.
  8. Once the reboot is finished, your VM will be using its new hostname and machine identity!
    • You can verify its new hostname by reconnecting using SSH again, replacing the command below with your own values. -portavm is the username you will be connecting as
      • VM-IP is the VM’s IPv4 address on the network
      Terminal window
      ssh portavm@<VM-IP>
    • The terminal prompt on successful connection should now show the new hostname, for example:
      Terminal window
      portavm@Porta-VM-1234:~$