-
Notifications
You must be signed in to change notification settings - Fork 859
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
apt-get upgrade fails - problems with udev #143
Comments
I am having this identical issue. |
thought the crash log I got might be useful, also note that I didnt install bash on windows until 2016-04-11 so I am not sure what the 2016-03-23 commands are from
|
If they're not explicit dependencies of something you need, remove systemd/upstart and autoremove --purge? at best, they would only no-op. udev seems likely to be irrelevant as well. |
I actually got this after trying to an If I try to remove upstart apt wants to install anacron, as well as remove a lot of things.
|
unless you're using one of them, they're not necessary. Plymouth is the little ubuntu splash screen that shows during boot of a ubuntu system (or the text [OK] messages)... the other ones are similarly unapplicable to the bash shell. maybe some day microsoft will wrap upstart in startup tasks, but until then, none of its jobs ever happen. If it is a dependency of something you actually need to have, you might have to package your own deb with neutered upstart support and without the dependency, or source install, that is, if you care about apt-get upgrading :-P |
I am on the preview fast track, if there is ANYTHING that I NEED, I am doing something extremely wrong. :) I am only reporting because of how easy this was to get to without doing really "anything" crazy. my entire history was
and then I got the message that i could do the autoremove So this really doesnt seem like something I did that would be out of the ordinary for anyone to have happen. My machine is completely for testing, so it is a very base system. I installed the browsers and atom. Other than that I dont have anything on this machine. |
much of the linux-y stuff's broken out of the box because the ubuntu-standard metapackage (which is installed by the bash for windows installer) has dependencies that break apt-get upgrade... but that aren't strictly necessary for a vast majority of the things that DO work |
This is an issue that everyone will start seeing. We need to add something on this in our official docs. As @nuclearmistake points out, udev is something that breaks in apt-get but the errors should not cause any issues in WSL. We have reached out to Canonical on this one asking for the best solution and they recommend the following changes: Write the following to /usr/sbin/policy-rc.d
chmod +x /usr/sbin/policy-rc.d I have tried this one myself and it looks to work quite well. |
copy+pasta-able version of canonical's fix via @russalex
Confirmed to allow apt-get upgrade with the ubuntu-standard metapackage installed. |
@nuclearmistake suggestion works for me. |
The suggestion works. Thanks. A fun project to hack on. It would be really, really cool if you somehow open sourced this project so the community could commit fixes/solutions. Just saying... |
Thanks for hacking away! We are humbled by the excitement the development community has shown thus far. Open sourcing the project is something we are investigating but nothing to share at this time. Stay tuned! |
I have a few installation scripts that normally is started from "real" Ubuntu servers and they are dependent on the upgrading part. Running that script in a "Windows Bash" may give quite big problems with broken dependencies, so I've built a very simple script that tries to find out if the instance is actually running from Windows (since I need to find out if it does). Since the version for Windows don't act the same way, I've found a way, but it would be interesting with getting some feedback on this, since there may be even better methods to find out if running from Windows. The implementation makes the script completely ignore upgrade steps, where they are normally automated. Feel free to comment at http://tornevalls.se/blog/2016/04/13/methods-to-find-out-if-we-are-running-bash-in-windows-subsystem-for-linux/ |
A fix for the udev apt update issues is on it's way to the flighting branch. When the fix reaches the branch new subsystem installs will no longer have this issue. The workaround provided above will continue to work for people who do not want to blow away their Ubuntu file system. |
@benhillis that's great to hear. Can you also explain the Also, to what are you referring on the remark of "blow away their Ubuntu file system?" I was not aware that there was anyone ever concerned about losing the Ubuntu installation (I'm assuming you're referring to the hierarchical installation of Ubuntu files since it lives on the Windows' file system vs its own isolated fs). |
By flighting branch I mean the Windows branch that Insider Preview builds come out of. Our changes slowly make their way to that branch and that is validated and then released publicly. I'm sorry if I'm being a bit vague, I'm not sure how much detail I'm allowed to go into regarding our branch structure and flight release cadence. The latter I don't even know myself :) For updates you won't have to worry about making any changes to apt. Think of it this way, when you get a new Windows Insider build install, it's effectively a kernel update. The usermode Ubuntu binaries are not touched. By Ubuntu file system I mean the user mode pieces that are downloaded and installed the first time you launch bash.exe. The only time we will delete these files is if the user runs "lxrun.exe /uninstall". It's possible to get yourself into a bad state (for example deleting glibc) and "lxrun.exe /uninstall" is meant to get you back to a pristine state so you can reinstall. Does that make things more clear? |
I also met, just only remove upstart and udev , |
@imxieke Well, if you have done the upgrade wrong, you will have a load of damaged packages that won't let itself get removed again :) |
I fixed it using this: http://superuser.com/questions/1064801/i-broke-the-windows-linux-subsystem-bash-on-ubuntu-on-windows-10-linux-help#
Although I'm still running into some odd pip issues |
Though being fixed (maybe with patching dpkg-divert way locally?) ... I'm trying to use WSL userland replacing from ubuntu 14 to debian sid. So, updating default ubuntu userland (16.04 or so) will also fix this without ad-hoc patch. |
I've verified this is fixed in build 14352 for fresh installs. If you continue to see this issue please use the workaround mentioned above or reinstall and install WSL by doing:
|
On bash newly installed on Win10 education (build 14390), the bug indeed exists. And my |
It seems that this issue is still here in Official Windows 10 Anniversary Update, just instlaled. Never had any Windows Insider build on this machine. Here's my log installing node (sorry it's in Italian, but I think it's pretty understandable anyway -- "Impossibile connettersi a Upstart" means "Unable to connect to Upstart", and "Connessione Rifiutata" means "Connection Refused"):
|
+1 for this issue as this error appears in anniversary update version. Trying to start nginx/docker (didn't test other things) results in |
I performed the lxrun.exe /uninstall /full and lxrun.exe /install just to start fresh as I was on the fast ring, but the apt-get remove udev upstart and auto-remove did the trick for me. After the fresh install, I did the remove and auto-remove, then update and upgrade. after that was all done i no longer saw upstart errors and was able to run openssh-server. |
Well... this will remove upstart, but I'm wondering whether it's safe to do so. |
i'm still able to start and stop services just fine. i was looking at installing systemd as that is what has replaced upstart anyway to see if there are any issues there. |
Just had a completely fresh upgrade to Anniversary Edition and can confirm I am still seeing this issue. In my particular case, I was/am simply trying to install redis-server (and run it) on my Bash Ubuntu on Windows. After reading through this thread I tried the first few suggested solutions, after no luck I went ahead and ran Here is the output (starting where it went funky):
The files and server appear to be installed, but I can not run the server. If I attempt redis-cli, I get Not sure where to go from here.. |
I believe that the error about connecting to If there is a script in If apt-get decides the error about not talking to The other complication about starting services yourself manually is that they get shut down when the last bash.exe window closes. So you have to leave at least one going, minimized or whatever. There are instructions for doing this with ssh, if you want to try to experiment. This is just a workaround, not meant to be a permanent replacement for |
From Ubuntu: SystemdForUpstartUsers Support status
So it's not safe to remove upstart as it will probably cause incompatibilities issues with other programs that rely on upstart |
I have this when doing |
@Benosika - I am not sure which issue you are referring to, but if it is the |
@russalex thank you so much |
Flawless kludge. It worked for me.
|
Still a problem and the solutions do not work:
Fixed the error by:
|
I have completely uninstalled and reinstalled and continue to receive the following errors:
root@localhost:/var# apt-get upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages were automatically installed and are no longer required:
libfreetype6 os-prober
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
4 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
E: Can not write log (Is /dev/pts mounted?) - openpty (2: No such file or directory)
Setting up udev (204-5ubuntu20.19) ...
initctl: Unable to connect to Upstart: Failed to connect to socket /com/ubuntu/upstart: No such file or directory
runlevel:/var/run/utmp: No such file or directory
...fail!
invoke-rc.d: initscript udev, action "restart" failed.
dpkg: error processing package udev (--configure):
subprocess installed post-installation script returned error exit status 1
dpkg: dependency problems prevent configuration of systemd-services:
systemd-services depends on udev (>= 175-0ubuntu23); however:
Package udev is not configured yet.
dpkg: error processing package systemd-services (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of libpam-systemd:amd64:
No apport report written because the error message indicates its a followup error from a previous failure. libpam-systemd:amd64 depends on systemd-services (= 204-5ubuntu20.19); however:
Package systemd-services is not configured yet.
dpkg: error processing package libpam-systemd:amd64 (--configure):
dependency problems - leaving unconfigured
dpkg: dependency problems prevent configuration of initramfs-tools:
No apport report written because the error message indicates its a followup error from a previous failure. initramfs-tools depends on udev (>= 147~-5); however:
Package udev is not configured yet.
dpkg: error processing package initramfs-tools (--configure):
dependency problems - leaving unconfigured
No apport report written because MaxReports is reached already
Errors were encountered while processing:
udev
systemd-services
libpam-systemd:amd64
initramfs-tools
E: Sub-process /usr/bin/dpkg returned an error code (1)
The text was updated successfully, but these errors were encountered: