GOAD icon indicating copy to clipboard operation
GOAD copied to clipboard

vagrant halt error

Open ll3N1GmAll opened this issue 2 years ago • 1 comments

when running 'vagrant halt' after a successful launch, I get the following: ==> SRV03: Attempting graceful shutdown of VM... ==> SRV02: Attempting graceful shutdown of VM... ==> DC03: Attempting graceful shutdown of VM... Traceback (most recent call last): 79: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/bin/vagrant:248:in <main>' 78: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/environment.rb:301:in cli' 77: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/cli.rb:67:in execute' 76: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/plugins/commands/halt/command.rb:30:in execute' 75: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/plugin/v2/command.rb:232:in with_target_vms' 74: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/plugin/v2/command.rb:232:in each' 73: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/plugin/v2/command.rb:243:in block in with_target_vms' 72: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/plugins/commands/halt/command.rb:31:in block in execute' 71: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/machine.rb:203:in action' 70: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/machine.rb:203:in call' 69: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/environment.rb:631:in lock' 68: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/machine.rb:217:in block in action' 67: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/machine.rb:248:in action_raw' 66: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/runner.rb:101:in run' 65: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/util/busy.rb:19:in busy' 64: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/runner.rb:101:in block in run' 63: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/builder.rb:180:in call' 62: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/warden.rb:48:in call' 61: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/plugins/providers/virtualbox/action/check_virtualbox.rb:26:in call' 60: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/warden.rb:48:in call' 59: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/builtin/call.rb:53:in call' 58: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/runner.rb:101:in run' 57: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/util/busy.rb:19:in busy' 56: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/runner.rb:101:in block in run' 55: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/builder.rb:180:in call' 54: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/warden.rb:48:in call' 53: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/warden.rb:127:in block in finalize_action' 52: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/warden.rb:48:in call' 51: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/plugins/providers/virtualbox/action/check_accessible.rb:18:in call' 50: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/warden.rb:48:in call' 49: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/plugins/providers/virtualbox/action/discard_state.rb:15:in call' 48: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/warden.rb:48:in call' 47: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/builtin/call.rb:53:in call' 46: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/runner.rb:101:in run' 45: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/util/busy.rb:19:in busy' 44: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/runner.rb:101:in block in run' 43: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/builder.rb:180:in call' 42: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/warden.rb:48:in call' 41: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/warden.rb:127:in block in finalize_action' 40: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/warden.rb:48:in call' 39: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/warden.rb:127:in block in finalize_action' 38: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/warden.rb:48:in call' 37: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/builtin/call.rb:43:in call' 36: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/runner.rb:101:in run' 35: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/util/busy.rb:19:in busy' 34: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/runner.rb:101:in block in run' 33: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/builder.rb:180:in call' 32: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/warden.rb:48:in call' 31: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/action/builtin/graceful_halt.rb:50:in call' 30: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/lib/vagrant/machine.rb:283:in guest' 29: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/plugins/communicators/winrm/communicator.rb:106:in ready?' 28: from /opt/vagrant/embedded/lib/ruby/2.7.0/timeout.rb:110:in timeout' 27: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/plugins/communicators/winrm/communicator.rb:107:in block in ready?' 26: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/plugins/communicators/winrm/shell.rb:70:in cmd' 25: from /opt/vagrant/embedded/gems/2.3.2/gems/winrm-2.3.6/lib/winrm/connection.rb:42:in shell' 24: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/plugins/communicators/winrm/shell.rb:71:in block in cmd' 23: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/plugins/communicators/winrm/shell.rb:138:in execute_with_rescue' 22: from /opt/vagrant/embedded/gems/2.3.2/gems/vagrant-2.3.2/plugins/communicators/winrm/shell.rb:144:in handle_output' 21: from /opt/vagrant/embedded/gems/2.3.2/gems/winrm-2.3.6/lib/winrm/shells/base.rb:79:in run' 20: from /opt/vagrant/embedded/gems/2.3.2/gems/winrm-2.3.6/lib/winrm/shells/base.rb:128:in with_command_shell' 19: from /opt/vagrant/embedded/gems/2.3.2/gems/winrm-2.3.6/lib/winrm/shells/base.rb:168:in open' 18: from /opt/vagrant/embedded/gems/2.3.2/gems/winrm-2.3.6/lib/winrm/shells/retryable.rb:35:in retryable' 17: from /opt/vagrant/embedded/gems/2.3.2/gems/winrm-2.3.6/lib/winrm/shells/base.rb:170:in block in open' 16: from /opt/vagrant/embedded/gems/2.3.2/gems/winrm-2.3.6/lib/winrm/shells/cmd.rb:54:in open_shell' 15: from /opt/vagrant/embedded/gems/2.3.2/gems/winrm-2.3.6/lib/winrm/http/transport.rb:168:in send_request' 14: from /opt/vagrant/embedded/gems/2.3.2/gems/winrm-2.3.6/lib/winrm/http/transport.rb:236:in init_auth' 13: from /opt/vagrant/embedded/gems/2.3.2/gems/httpclient-2.8.3/lib/httpclient.rb:765:in post' 12: from /opt/vagrant/embedded/gems/2.3.2/gems/httpclient-2.8.3/lib/httpclient.rb:856:in request' 11: from /opt/vagrant/embedded/gems/2.3.2/gems/httpclient-2.8.3/lib/httpclient.rb:1014:in do_request' 10: from /opt/vagrant/embedded/gems/2.3.2/gems/httpclient-2.8.3/lib/httpclient.rb:1133:in protect_keep_alive_disconnected' 9: from /opt/vagrant/embedded/gems/2.3.2/gems/httpclient-2.8.3/lib/httpclient.rb:1019:in block in do_request' 8: from /opt/vagrant/embedded/gems/2.3.2/gems/httpclient-2.8.3/lib/httpclient.rb:1245:in do_get_block' 7: from /opt/vagrant/embedded/gems/2.3.2/gems/httpclient-2.8.3/lib/httpclient.rb:1299:in do_get_header' 6: from /opt/vagrant/embedded/gems/2.3.2/gems/httpclient-2.8.3/lib/httpclient/session.rb:561:in get_header' 5: from /opt/vagrant/embedded/gems/2.3.2/gems/httpclient-2.8.3/lib/httpclient/session.rb:784:in read_header' 4: from /opt/vagrant/embedded/gems/2.3.2/gems/httpclient-2.8.3/lib/httpclient/session.rb:801:in parse_header' 3: from /opt/vagrant/embedded/lib/ruby/2.7.0/timeout.rb:105:in timeout' 2: from /opt/vagrant/embedded/lib/ruby/2.7.0/timeout.rb:95:in block in timeout' 1: from /opt/vagrant/embedded/gems/2.3.2/gems/httpclient-2.8.3/lib/httpclient/session.rb:805:in block in parse_header' /opt/vagrant/embedded/gems/2.3.2/gems/httpclient-2.8.3/lib/httpclient/session.rb:805:in gets': execution expired (Timeout::Error)

ll3N1GmAll avatar Nov 16 '22 23:11 ll3N1GmAll

After I added the vagrant apt source and installed the winrm-elevated gem, vagrant worked without any erros:

install vagrant wget -O- https://apt.releases.hashicorp.com/gpg | gpg --dearmor | sudo tee /usr/share/keyrings/hashicorp-archive-keyring.gpg echo "deb [signed-by=/usr/share/keyrings/hashicorp-archive-keyring.gpg] https://apt.releases.hashicorp.com $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/hashicorp.list sudo apt update && sudo apt install vagrant=2.2.19

install missing vagrant dependency sudo gem install -r winrm-elevated

stub1t avatar Nov 20 '22 13:11 stub1t

@neon-schedule thx for the advice. I will take a look at this module to see what is doing.

Mayfly277 avatar Jan 20 '23 16:01 Mayfly277

https://github.com/Orange-Cyberdefense/GOAD/blob/main/docs/troubleshoot.md#vagrant-up---cannot-load-such-file----winrm-elevated-loaderror

Mayfly277 avatar Nov 25 '23 22:11 Mayfly277