WSL icon indicating copy to clipboard operation
WSL copied to clipboard

file created on window side are not seen in Linux side

Open fdu123 opened this issue 10 years ago • 30 comments

Create a file with Notepad in C:\Users\xxx\AppData\Local\lxss\rootfs\tmp

File created can be displayed in Exporer but it doesn't appear in linux root@localhost:/mx6# cd /tmp root@localhost:/tmp# ls root@localhost:/tmp# ... nothing ...

even if I reboot my system Regards,

fdu123 avatar Apr 07 '16 18:04 fdu123

Have you tried ls -a?

crutchcorn avatar Apr 07 '16 19:04 crutchcorn

Yes of course Regards,

fdu123 avatar Apr 07 '16 19:04 fdu123

While this is an interesting phenomenon, should probably take note of the comment by @bitcrazed on issue #44 , to paraphrase: manipulating the Linux filesystem from Windows may cause issues/corruption and should not be done.

mphaney avatar Apr 07 '16 19:04 mphaney

This is known and expected - please don't modify the "Linux filesystem" from Windows - here be dragons!

bitcrazed avatar Apr 07 '16 20:04 bitcrazed

This is interesting. Since we can't use Unix style permissions on the Windows mounts, how is one supposed to transfer and share data between the Linux and Windows environments? We're forced to manually cp back and forth from ~ to /mnt/*/?

Wouldn't it be at all possible in future to have newly placed files from the Windows host side inherit it's parent permissions? As someone who uses Samba to share data on a virtualized Ubuntu OS right now, this is fairly disappointing to hear.

cosmicdan avatar Apr 09 '16 12:04 cosmicdan

You did show on the demo of bash that we have full fidelity of the filesystem between the two subsystems, and now you say it isn't so. It would be great with the guidance on how we are meant to use this. On the demo you mentioned that you can use any editor to edit file under the Linux sub system and was one of the pitches.

NiclasLindgren avatar Apr 24 '16 10:04 NiclasLindgren

I'm not sure what the issue-handling norms are on this project, but closing an issue without solving it would seem to imply "won't fix", which, in turn, would seem to render the bash-on-windows feature almost pointless. Understood that this is in beta, and that patience is in order. But not on the roadmap? If normal cross-OS file write will always be not only unsupported but potentially destabilizing, then what's the point?

jdmarch avatar May 17 '16 20:05 jdmarch

Interoperability is a big topic and something that we are well aware and conscious about. We understand the frustration here from lack of full interoperability and appreciate all the feedback. For the first beta release, our focus was delivering a strong developer focused scenario. Having said that, we do provide some basic interop today in terms of access to Windows volume through WSL.For the next release, we will be taking all of this feedback into account and try to incorporate in our planning. To help us prioritize for future release, please also provide this feedback through our User Voice Page.

Regarding the topic of destabilizing, while it represents the current affairs, it is not an indication of the future state of the project. Please bear with us while we iterate on the project in its beta phase.

sunilmut avatar May 17 '16 21:05 sunilmut

Thanks, @sunilmut . Happy to be patient in the service of future progress! Could you explain, though, what developer-focused scenario you have in mind with the current capabilities? The primary one that occurs to me is being able to use git properly on a Windows machine, and that seems sketchy at present.

jdmarch avatar May 17 '16 21:05 jdmarch

@jdmarch - Here is what we have focused on for this release. But, let that not limit your WSL playground area and do give us feedback on other areas as well. It is mostly useful for setting expectations.

sunilmut avatar May 17 '16 22:05 sunilmut

confirmed that when using mklink /J to create a windows link to the Lxss/rootfs path, files could be updated but newly created files weren't visible in WSL.

JSMike avatar Jun 01 '16 17:06 JSMike

For records, adding link to user voice for the issue on this specific topic for people to vote up

pavelbulanov avatar Jul 15 '16 13:07 pavelbulanov

@bitcrazed Have you considered using UnionFS? https://github.com/rpodgorny/unionfs-fuse

Manouchehri avatar Jul 17 '16 04:07 Manouchehri

How does one go about determining whether this behaviour is "buggy" or not? As it stands, the current integration behaviour is "unexpected" at best, and by reasonable people would be considered "buggy" regardless of status in the bug tracker.

Can someone please positively or negatively confirm that this behaviour is still: "Working as Designed, WONTFIX"?

ramses0 avatar May 01 '18 04:05 ramses0

Can someone please positively or negatively confirm that this behaviour is still: "Working as Designed, WONTFIX"?

If you mean mucking with C:\Users\xxx\AppData\Local\lxss\rootfs\ or C:\Users\xxx\AppData\Local\Packages\CanonicalGroupLimited.UbuntuonWindows_79rhkp1fndgsc\LocalState\rootfs\, that's a negatory. Blog post is here.

You can, however, modify files in /mnt/c (DrvFs) with impunity.

therealkenc avatar May 01 '18 07:05 therealkenc

In this case how should we go about editing/creating files? I don't really wanna have to create/edit stuff in my bash, would much rather use my IDE

Cyan101 avatar Aug 04 '18 12:08 Cyan101

@Cyan101 The recommendation as per the blog post covering this issue (Do not change Linux files using Windows apps and tools), is to create your project files under <drive>:\<path> which is thus reachable from Linux via /mnt/<drive>/<path>, e.g. c:\dev\project1 --> /mnt/c/dev/project1.

bitcrazed avatar Aug 06 '18 17:08 bitcrazed

Eh, you guys would all be better off running Linux in Hyper-V (assuming you're on Windows 10 Pro) for now - if you're not interested or able to directly contribute to the WSL project. It's pretty good, much faster than VMWare or VirtualBox since MS added the whole Enhanced Linux Guest stuff :D

cosmicdan avatar Aug 19 '18 09:08 cosmicdan

Unbelievable!

Even cygwin has done a better job.

I thought I will drop cygwin and msys for our users and replace them with the WSL, but it seems like WSL and Windows have not been integrated properly as other tools.

alonbl avatar Mar 08 '19 13:03 alonbl

There are work-arounds for this, just set your home folder to a different path and enable metadata on automount. Can't remember the exact steps but if you Google for it you'll find a guide. Sharing files between Linux and Windows works perfectly fine now, similar to using SMB in my experience.

On 9 Mar 2019, Alon Bar-Lev [email protected] wrote:

Unbelievable!

Even cygwin has done a better job.

I thought I will drop cygwin and msys for our users and replace them with the WSL, but it seems like WSL and Windows have not been integrated properly as other tools.

-- Sent with K-@ Mail - the evolution of emailing.

cosmicdan avatar Mar 08 '19 13:03 cosmicdan