LoginSignup
3
5

More than 5 years have passed since last update.

Vagrant コマンド実行時の詳細なログの出し方

Posted at

Vagrant コマンド実行時の詳細なログの出し方

ターミナルなどで vagrant コマンド 実行時に、なにかよくわからずコマンドが終了してしまう場合。
たとえば、こんなエラー状況。

$ vagrant box add --name NewMyBox ./mybox-CentOS7.2-x86_64.box 
==> box: Box file was not detected as metadata. Adding it directly...
==> box: Adding box 'NewMyBox' (v0) for provider: 
    box: Unpacking necessary files from: file:///Users/precure/projects/magical/mybox-CentOS7.2-x86_64.box
An error occurred while downloading the remote file. The error
message, if any, is reproduced below. Please fix this error and try
again.



$ # なにもエラーメッセージがないやんけ!!

方法

環境変数 VAGRANT_LOG に値を設定すればよい。

Mac

$ VAGRANT_LOG=debug vagrant somecommand ...

Windows

> set VAGRANT_LOG=DEBUG
> vagrant somecommand ...
3
5
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
5