Skip to content

"Element not found" when launching #3785

Closed

Description

Please fill out the below information:

  • Your Windows build number: (Type ver at a Windows Command Prompt)

    • Microsoft Windows [Version 10.0.17763.253]
  • What you're doing and what's happening: (Copy&paste the full set of specific command-line steps necessary to reproduce the behavior, and their output. Include screen shots if that helps demonstrate the problem.)

    • After installing Ubuntu 16.04 and 18.04 (at various times) via the Microsoft store, it works for a while. After a number of reboots, WSL completely stops functioning. Launching "bash.exe" displays "Element not found." with no additional information.
  • What's wrong / what should be happening instead:

    • WSL should actual launch
  • For WSL launch issues, please [collect detailed logs]

I've had this happen now with both Ubuntu 16.04 and 18.04. I've uninstalled and reinstalled the distros, as well as disabled and reenabled the Windows Subsystem for Linux in Apps / Features. I'm really at a loss at what to do here.

Thanks in advance for any assistance!

Activity

  1. benhillis commented on Feb 1, 2019

    @benhillis
    Member

    Thanks for filing. It looks like creating /etc/hosts failed with ENOENT. This probably means that the /etc directory was deleted. This probably shouldn't be a fatal error, I will change that.

  2. jcherniak commented on Feb 1, 2019

    @jcherniak
    Author

    So what might be happening here is that since I use vagrant with Hyper-V, I had deleted the /etc/hosts file and created a symlink to /mnt/c/Windows/system32/drivers/etc/hosts. I'm guessing at some point that link got mangled, causing this error?

    If that's the case, I'd agree, missing a hosts file shouldn't be fatal.

    Also, is there a way, other than closing all WSL windows and reopening a new one to get the /etc/hosts file to update, aside from what I did? Since Hyper-V / Vagrant doesn't let you specify a static IP for your VMs, I use the Vagrant Hostmanager plugin which updates the hosts file as you boot VMs. As such, is there a way to get the WSL environment to reread the hosts file?

  3. benhillis commented on Feb 20, 2019

    @benhillis
    Member

    Fixed in 18342.

  4. benhillis commented on Feb 20, 2019

    @benhillis
    Member

    Justin Cherniak (@jcherniak) - easiest way is to restart the lxssmanager service, or use wslconfig to terminate the distro (might not be available in your version).

  5. lucndm commented on Jun 11, 2019

    @lucndm

    you have recreate file hosts at : %localappdata%\Packages\CanonicalGroupLimited.Ubuntu18.04onWindows_79rhkp1fndgsc\LocalState\rootfs\etc

  6. ajkessel commented on Dec 15, 2021

    @ajkessel

    I've been unable to launch wsl2 recently - "element not found" every time. I've tried restarting lxssmanager and rebooting. I don't have KB4571756 in my list of updates, but I believe this started after some recent patch, possibly KB5007253 or KB5007289 which were both installed last week. Tried to install KB4577063 but the OS told me it was not installable. I'm unable to access the filesystem at \wsl$\ubuntu . Any workarounds for getting wsl2 to launch again?

    Also posted to #5880 as it seems to describe the same problem.

  7. ajkessel commented on Dec 15, 2021

    @ajkessel

    Update: the resolution described here fixed this problem for me. Specifically, downloading and running the https://aka.ms/easyfix20159 easy fix, followed by a reboot. Hopefully this will help others.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions