2.3. Starting, Stopping, Restarting, and Querying Status of Virtual Machines and Containers

After a virtual machine or container has been created, it can be managed like a usual computer.

2.3.1. Starting Virtual Machines and Containers

You can start virtual machines and containers with the prlctl start command. For example:

  • To start the container MyCT:

    # prlctl start MyCT
    
  • To start the virtual machine MyVM:

    # prlctl start MyVM
    

2.3.2. Stopping Virtual Machines and Containers

You can stop virtual machines and containers with the prlctl stop command. For example:

  • To stop the container MyCT:

    # prlctl stop MyCT
    
  • To stop the virtual machine MyVM:

    # prlctl stop MyVM
    

2.3.3. Restarting Virtual Machines and Containers

You can restart virtual machines and containers with the prlctl restart command. For example:

  • To restart the container MyCT:

    # prlctl restart MyCT
    
  • To restart the virtual machine MyVM:

    # prlctl restart MyVM
    

    Note

    Restarting virtual machines requires a guest OS and Virtuozzo guest tools to be installed.

2.3.4. Checking Status of Virtual Machines and Containers

You can check the status of a virtual machine or container with the prlctl status command. For example:

  • To check the status of the container MyCT:

    # prlctl status MyCT
    CT MyCT exists running
    
  • To check the status of the virtual machine MyVM:

    # prlctl status MyVM
    Vm MyVM exists stopped