Comments (7)
/dev/null should be a character device with major 1 and minor 3, but it isn't in lxss, so tests like this fail:
[ -c /dev/null ] || echo broken
from wsl.
Maybe the whole idea behind the Linux/Ubuntu subsystem hasn't been fully implemented yet. The UNIX philosophy is that EVERYTHING is a file. For example, /dev/null is a virtual device file. This means that nothing, is something, and that something is represented in userland as a file.
On my Debian system, I get the following:
john@phobos:~$ stat /dev/null
File: '/dev/null'
Size: 0 Blocks: 0 IO Block: 4096 character special file
Device: 6h/6d Inode: 1037 Links: 1 Device type: 1,3
Access: (0666/crw-rw-rw-) Uid: ( 0/ root) Gid: ( 0/ root)
Access: 2016-04-06 20:33:12.884276144 -0700
Modify: 2016-04-06 20:33:12.884276144 -0700
Change: 2016-04-06 20:33:12.884276144 -0700
Birth: -
It looks like the Ubuntu subsystem doesn't see /dev/null as a "character special file" which I would think would redirect to >NUL on Windows.
from wsl.
Shouldn't it be fine if /dev/null was simply a symlink to \Device\Null?
from wsl.
One side-effect of this breaks sshd (openssh-server), as also mentioned here: MicrosoftDocs/WSL#17
from wsl.
The weird file is a known issue and something we intend to fix. It is currently on our backlog.
from wsl.
Another side-effect: I can't build a different version of Perl, either manually or using the perlbrew package, because its configure script checks for /dev/null's usability.
from wsl.
anybody want to take a guess at why this is in all of the binaries? https://gist.github.com/cloudkitsch/6f8bcb05f4006b5ea168eb6169ecbf12#file-gistfile1-txt-L335 quality control?
from wsl.
Related Issues (20)
- WSL --shutdown and --terminate not working sometime...need restart HOT 3
- WSL Catastrophic Failure after Exhausting Disk Space HOT 1
- wsl.2.1.3.0.x64.msi package does not install or update windows Subsystem for Linux. HOT 6
- WSL crashed when compiling OpenSSL HOT 3
- Understanding the WSL release mode HOT 1
- Enable USB mass storage in kernel HOT 2
- UDP port forwarding in WSL2 HOT 1
- WSL crashes when loading can.ko HOT 3
- Launching executables from WSL that touch filesystem makes new process on windows host very slow for many minutes, then gets back to normal or a reboot is necessary HOT 1
- Accessing \\wsl.localhost results in logon failures being logged while \\wsl$ does not HOT 2
- Mirrored Network: Local DNS resolution does not work HOT 1
- [Bug] Can not install WSL on the latest Windows Version HOT 2
- git clone https://github.com/benqzq/ulcwe.git cd ulcwe sudo apt install dos2unix dos2unix install.sh git commit -a -m "change line endings to unix-style" git push``` HOT 1
- Wsl/Service/CreateInstance/0xd0000034 HOT 5
- WSL version 2 hangup after enable systemd in Rocky Linux HOT 1
- Add NixOS to WSL Linux distros HOT 1
- Expose Windows SSH-Agent inside WSL environments HOT 1
- Intel arc igpu not working properly. (Ultra 7 155h). OpenGL rendering not working.
- System has not been booted with systemd as init system (PID 1). Can't operate. Failed to connect to bus: Host is down when systemctl start virtqemud HOT 6
- Random Process Constantly Becomes Not Responsive and Takes 100% CPU HOT 5
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.