Skip to content

Adding "bosh reset-vm" or "bosh reboot-vm" command? #702

Description

@scottgai

Sometimes the user might need to hard reset or soft reset (reboot) Virtual Machine on cloud (e.g. vSphere) without getting the VM recreated on cloud. The existing bosh recreate command would cause the VM to be recreated. And bosh restart command is only to restart all jobs on the VM.
Is it possible to have commands like bosh reset-vm and bosh reboot-vm command to hard and soft reset the VM on cloud respectively?
Take vSphere as example,
bosh reset-vm could simulate the "Power -> Reset" operation on vSphere client
bosh reboot-vm could simulate the "Power -> Restart Guest OS" operation on vSphere client.

Activity

  1. beyhan commented on Nov 27, 2025

    @beyhan
    Member

    Thanks for the feature request! I understand the use case, but I'd like to point out some existing BOSH commands that might help with your scenarios:

    Existing alternatives:

    1. bosh cck (CloudCheck) - This can detect and repair VM issues. When run, it will identify VMs in problematic states and offer remediation options, including recreating VMs if needed.

    2. bosh delete-vm <CID> - This allows you to delete a specific VM by its Cloud ID. The BOSH resurrector (if enabled) will automatically detect the missing VM and recreate it, effectively giving you a "hard reset" behavior.

    Concerns with the proposed commands:

    1. Resurrector confusion - If we add bosh reset-vm or bosh reboot-vm that perform hard/soft resets at the IaaS level, the BOSH resurrector might misinterpret these actions. During a reset, the VM might appear unresponsive, triggering the resurrector to unnecessarily recreate the VM, causing conflicts.

    2. State inconsistency - BOSH maintains expected state for all managed VMs. IaaS-level resets bypass BOSH's state management, which could lead to inconsistencies between what BOSH thinks is happening and the actual VM state.

    3. CPI variations - Not all Cloud Provider Interfaces (CPIs) support equivalent reset/reboot operations, which would make this feature inconsistent across different IaaS platforms.

    Could you share more details about your specific use case? Understanding why you need to reset VMs without recreation might help us suggest better workflows or consider whether this feature aligns with BOSH's design principles of declarative infrastructure management.

  2. moved this from Inbox to Pending Review | Discussion in Foundational Infrastructure Working Groupon Nov 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions