Segmentation fault while running 'yum update'
Description
Attempting to run 'yum update' results in segmentation fault. I am using the default user created during the installation of WSL.
Expected results
Yum must start updating all installed packages.
Actual results (with terminal output if applicable)
Running 'yum update' results in a segfault.

Sample output
; Bash says there are updates available for 51 package.
Может быть обновлён 51 пакет.
; 28 of available updates are security patches.
28 обновлений касаются безопасности системы.
; running update
Recover@computer:~$ yum update
; Bash reports that there was a segmentation fault and a memory dump is created.
Ошибка сегментирования (сделан дамп памяти)
Windows build number
14393.103.amd64fre.rs1_release_inmarket.160819-1924
Steps / commands required to reproduce the error
Exectute the following:
Recover@computer:~$ yum update
- Strace of the failing command
Required packages and commands to install
Packages:
- The yum package.
Commands:
yum update
Comments
Where do I find the created dump file?
Thanks for trying WSL.
A few questions here:
- What Windows build are you on (Insider build 14915 or the Anniversary Update 14393)?
- Did you apt-get install yum for Ubuntu or have you installed RedHat / Fedora?
If you are running Ubuntu (the distro installed with WSL), I highly recommend running "apt-get" as your package manager. Canonical has a good list of yum to apt-get equivalent commands here.
@russalex
What Windows build are you on (Insider build 14915 or the Anniversary Update 14393)?
It is 14393.103.amd64fre.rs1_release_inmarket.160819-1924 I've somehow missed this in the initial post.
Did you apt-get install yum for Ubuntu or have you installed RedHat / Fedora?
Yep. I've initially deployed YUM through apt-get install yum
And it seems like deployment went flawless:
Recover@computer:~$ apt list --installed | grep 'yum'
WARNING: apt does not have a stable CLI interface yet. Use with caution in scripts.
yum/trusty,now 3.4.3-2ubuntu1 all [installed]
However using yum afterwards is not possible. Most of the time it just freezes on performing commands like
yum update
or
yum list installed
Looking up the %appdata%\Local\lxss\rootfs\var\log\apt\history.log confirms yum has been installed by using apt-get:
Start-Date: 2016-09-06 12:55:51
Commandline: apt-get install yum
Install: python-urlgrabber:amd64 (3.9.1-4ubuntu3.14.04.1, automatic), rpm2cpio:amd64 (4.11.1-3ubuntu0.1, automatic), python-sqlite:amd64 (1.0.1-11, automatic), libnspr4:amd64 (4.12-0ubuntu0.14.04.1, automatic), yu
m:amd64 (3.4.3-2ubuntu1), python-libxml2:amd64 (2.9.1+dfsg1-3ubuntu4.8, automatic), rpm-common:amd64 (4.11.1-3ubuntu0.1, automatic), libnss3-nssdb:amd64 (3.23-0ubuntu0.14.04.1, automatic), libsqlite0:amd64 (2.8.17
-10ubuntu2, automatic), python-sqlitecachec:amd64 (1.1.4-1, automatic), libnss3:amd64 (3.23-0ubuntu0.14.04.1, automatic), rpm:amd64 (4.11.1-3ubuntu0.1, automatic), librpm3:amd64 (4.11.1-3ubuntu0.1, automatic), deb
ugedit:amd64 (4.11.1-3ubuntu0.1, automatic), librpmsign1:amd64 (4.11.1-3ubuntu0.1, automatic), liblua5.2-0:amd64 (5.2.3-1, automatic), librpmbuild3:amd64 (4.11.1-3ubuntu0.1, automatic), librpmio3:amd64 (4.11.1-3ub
untu0.1, automatic), python-rpm:amd64 (4.11.1-3ubuntu0.1, automatic)
End-Date: 2016-09-06 12:56:19
Thanks
I have repro'd this on the latest insider build (14915) but can not get it to repo on the latest development branch. Possible there is a fix on the way. I'll need to check.
I have not found a yum repo for Ubuntu packages so I have only tested against yum update and yum list installed.
russ@russalex-book:/mnt/c/Temp$ sudo yum update There are no enabled repos. Run "yum repolist all" to see the repos you have. You can enable repos with yum-config-manager --enable
russ@russalex-book:/mnt/c/Temp$ sudo yum list installed russ@russalex-book:/mnt/c/Temp$ sudo yum repolist all repolist: 0
If there are issues I must warn that supporting yum as a package manager on Ubuntu isn't terribly high on the priority list. If this is blocking I would suggest putting a request on our User Voice page. It is the best place for users to vote on issues and we do use it when prioritizing work.
Well, on Ubuntu, the expected results for yum would never be to update the packages on system.
At best yum would inidicate that rpm database has not been initialiazed or that there on not any configured repos, as indicated by russalex If one were to configure the rpm database globally in the way that yum expects it, they would wreck their system when they tried to used yum.
On Ubuntu yum is really only useful when bootstrapping a distro that uses yum as it's package manager (such as fedora or centos). Something like http://prefetch.net/articles/yumchrootlinux.html
I just tried now tried yum on WSL/ubuntu-trusty, it did not segfault.
$ yum update
You need to be root to perform this command.
$ sudo yum update
There are no enabled repos.
Run "yum repolist all" to see the repos you have.
You can enable repos with yum-config-manager --enable <repo>
That is the expected behavior on Ubuntu (not to work, unless you specify a target directory with --installroot= which most certainly would not be the top level / that Ubuntu is installed in).
The Expected results for this issue: "Yum must start updating all installed packages." is not valid as Ubuntu is not a yum managed distribution.
I fixed yum in a post Creators update insider build. Please reopen if you continue to have issues.