チュートリアルに従って、人生で初めてvagrantをセットアップしようとしています。 WordPressで作業したいので、VVCWボックスを使用しています。そこで、Zipファイルをダウンロードして/ homeのフォルダーに解凍しましたが、デフォルトは変更しませんでした。 ymlファイル。
それが結果です:(私はXubuntu18.04を使用しています)
_fabio@thinkpad:~/Vagrant/vccw$ vagrant up
_
_Bringing machine 'vccw.test' up with 'libvirt' provider...
_ #<Thread:0x000055ef7b1cc6c0@/usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/batch_action.rb:71 run> terminated with exception (report_on_exception is true): Traceback (most recent call last): 25: from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/batch_action.rb:82:in
block(2 level)in run '24:from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/machine.rb:188 :in _action' 23: from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/machine.rb:188:in
_ call '22:from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/environment.rb:592:in _lock' 21: from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/machine.rb:202:in
_ block in action '20 :from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/machine.rb:227:in _action_raw' 19: from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/runner.rb:66:in
_ run '18:from/usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/util/busy.rb:19:in _busy' 17: from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/runner.rb:66:in
_ block in run '16:from /usr/share/rubygems-integration/all/gems/vagrant-2.0 .2/lib/vagrant/action/builder.rb:116:in _call' 15: from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/warden.rb:34:in
_ call '14:/usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/からbuiltin/config_validate.rb:25:in _call' 13: from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/warden.rb:34:in
_ call '12:from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/builtin/box_check_outdated.rb:31 :in _call' 11: from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/warden.rb:34:in
_ call '10:/usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagからrant/action/builtin/call.rb:52:in _call' 9: from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/builder.rb:170:in
_ to_app '8:/usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/builder.rbから:170:in _new' 7: from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/warden.rb:20:in
_ initialize '6:from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/warden.rb:20:in _map' 5: from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/warden.rb:20:in
_ block in initialize '4:from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/warden.rb:90:in _finalize_action' 3: from /usr/share/rubygems-integration/all/gems/vagrant-2.0.2/lib/vagrant/action/warden.rb:90:in
_ new' 2:from/usr/share/rubygems-integration/all/gems/vagrant-libvirt-0.0.43/lib/vagrant-libvirt/action/create_networks.rb:26:in _initialize' 1: from /usr/share/rubygems-integration/all/gems/vagrant-libvirt-0.0.43/lib/vagrant-libvirt/driver.rb:40:in
_ connection '/ usr/share/rubygems-integration/all/gems/vagrant-libvirt-0.0.43/lib/vagrant-libvirt/driver.rb:43:in rescue in connection': Error while connecting to libvirt: Error making a connection to libvirt URI qemu:///system?no_verify=1&keyfile=/home/fabio/.ssh/id_rsa: (VagrantPlugins::ProviderLibvirt::Errors::FogLibvirtConnectionError) Call to virConnectOpen failed: Failed to connect socket to '/var/run/libvirt/libvirt-sock': No such file or directory Error while connecting to libvirt: Error making a connection to libvirt URI qemu:///system?no_verify=1&keyfile=/home/fabio/.ssh/id_rsa: Call to virConnectOpen failed: Failed to connect socket to '/var/run/libvirt/libvirt-sock': No such file or directory
別のボックスで試したところ、同じエラーが発生しました。
誰かが私を助けることができますか?どうもありがとう!
編集-1:他の場所でエラーを探して、vagrant-libvirtプラグインをインストールしました。
fabio@thinkpad:~/Vagrant/teste$ vagrant plugin install vagrant-libvirt Installing the 'vagrant-libvirt' plugin. This can take a few minutes... Installed the plugin 'vagrant-libvirt (0.0.43)'!
しかし、_vagrant up
_を実行すると、同じエラーが表示されました。 :(
編集-2:私は指示に従い、それを行いました:
_$ vagrant plugin install vagrant-libvirt $ Sudo apt install qemu-kvm libvirt-clients libvirt-daemon-system bridge-utils virt-manager $ Sudo adduser fabio libvirt $ Sudo adduser fabio libvirt-qemu $ Sudo /etc/init.d/libvirtd restart
_
エラーは同じままです... :(
問題を発見しました
リポジトリのVirtualBoxバージョン6.0を使用していますが、リポジトリのVagrantバージョンは最新バージョンではないため、競合が発生します。
だから最初に私はvagrantを削除しました
_Sudo apt --purge remove vagrant
_
_Sudo apt autoremove
_
その後、Vagrantの最終リリースを ここ からダウンロードしてインストールしました:
_Sudo dpkg -i vagrant_x.x.x_x86_64.deb
_
インストールはかなり速かったので、Vagrantバージョンを呼び出してインストールされていることを確認します。
_vagrant version
_
私はこの出力を得ました:
_Vagrant failed to initialize at a very early stage:
_
_The plugins failed to initialize correctly. This may be due to manual modifications made within the Vagrant home directory. Vagrant can attempt to automatically correct this issue by running:
_
_vagrant plugin repair
_
_If Vagrant was recently updated, this error may be due to incompatible versions of dependencies. To fix this problem please remove and re-install all plugins. Vagrant can attempt to do this automatically by running:
_
_vagrant plugin expunge --reinstall
_
_Or you may want to try updating the installed plugins to their latest versions:
_
_vagrant plugin update
_
Error message given during initialization: Unable to resolve dependency: user requested 'vagrant-libvirt (= 0.0.43)'
そこで、vagrant-libvirtをアンインストールすることにしました(実際に覚えています)。
_Sudo apt --purge remove vagrant-libvirt
_
_Sudo apt update
_をしました-念のため...
そして再び_vagrant up
_。
そしてそれは動作します!!!!!!! :)