Comments (7)
This is actually an issue with WSL, since lxrun
is the one running the adduser --quiet
command.
One possible workaround for this would be to create a hook script which replaces adduser
during installation with a wrapper that removes the unsupported --quiet
argument. That, or it updates adduser
to one which supports it.
from wsl-distribution-switcher.
Why not use CentOS 7?
from wsl-distribution-switcher.
@thebitstick I'm trying to run some legacy software I use at work. The programs exist in binary form and run on CentOS 6 (well, Scientific Linux 6 which is the same). On every other OS like Centos 7 or Ubuntu, I would have to do a lot of hacks with LD_LIBRARY_PATH and so on. It would be very complicated to compile everything from scratch.
@RoliSoft It's tricky... the hook script only runs after switching to the new OS, which is too late. I can't run bash.exe
do do anything with CentOS. I am trying to replace adduser
during install.py
, but that is quite hard. lxrun
doesn't run adduser
if it is a script, so I have to compile a binary (on another CentOS 6 system). Also, on CentOS, adduser
is a link to useradd
, which is a different program on Ubuntu...
from wsl-distribution-switcher.
@jdmansour @RoliSoft you could try adding to the install.py something that checks if installing CentOS 6 or other out-of-date distros and change the command from adduser --quiet
to to adduser
from wsl-distribution-switcher.
The adduser
command gets called by lxrun
, not directly by the installation script. Anyway, I believe this is not the core problem. I can sidestep this issue by using lxrun /setdefaultuser root
before running the install script. In this case there is no error message, but I still can't enter WSL. bash.exe
doesn't work, nor does anything like bash.exe ls
. Strangely enough, lxrun.exe
can successfully start binaries (like adduser
, usermod
, passwd
) in the CentOS image, but bash.exe
refuses to do anything, and gives no error message.
from wsl-distribution-switcher.
@jdmansour Writing to files outside of WSL is very tricky indeed. One thing I found that mostly works, is to not create/delete the file, but rather append to it.
Truncation works with some applications, but not with others. I haven't been able to consistently and successfully truncate files and replace their content from outside of WSL yet.
That being said, files like /etc/passwd
are truncated and overwritten by the installer script, and they seem to work.
It would really save a lot of trouble if Microsoft would release some documentation or expose new APIs to write VoIFs metadata to regular files.
from wsl-distribution-switcher.
I'm running into the same problem, for the same reasons (legacy compatibility).
I wounder if this can be bypassed by copying the centos:6.x root under another minimal root and then chroot-ing into the centos:6.x directory?
Yes, this would probably work on 1703/RS2/Creators-Update and forward only.
from wsl-distribution-switcher.
Related Issues (20)
- [!] Failed to fetch manifest info for cetos: HTTP Error 401: Unauthorized HOT 1
- "[!] The Linux subsystem is not installed. Please go through the standard installation procedure first." HOT 3
- Unable to find lxrun.exe in the expected locations. HOT 4
- [!] Failed to find tag 12.04 for image ubuntu.
- my_lookupdev: socket: Socket type not supported HOT 2
- WSL2 docker on centos7.6 not good
- gentoo install failed
- no such file or directory HOT 1
- `python install.py rootfs_kalilinux_kali-linux-docker_latest.tar.gz` with python 3.7 HOT 3
- bash - command not found HOT 1
- APT Key Expired and Unable to Update / Install HOT 4
- How can i install 3 different distros ?
- Instead of Centos 6 dowloading Centos 7 HOT 1
- Set default os in WSL
- With the Fall Creators update, is this dead? HOT 1
- Persistent "You do not seem to have the default distribution installed anymore."
- no lxss HOT 3
- python3 install.py rootfs_kalilinux_kali-linux-docker_ latest.tar.gz errors in files:
- get.prebuild.py fails on SSLError error [SSL: CERTIFICATE_VERIFY_FAILED]
- Unable to find lxrun.exe in the expected locations. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wsl-distribution-switcher.