AlmaLinux / wsl-images

Visual Studio solution and kickstart file to generate WSL images and the associated appx.
MIT License
39 stars 11 forks source link

where is fstab #25

Closed tlsalex closed 2 years ago

tlsalex commented 2 years ago

Hi team,

Could I know where is fstab ? If I want to mount a NFS share I need to use fstab.

[root@xx:~]# ll /etc/fstab
ls: cannot access '/etc/fstab': No such file or directory
crramirez commented 2 years ago

Hello @tlsalex,

You must create it yourself:

  1. Create the file with touch /etc/fstab
  2. Enable fstab mounting in /etc/wsl.conf adding
    [automount]
    mountFsTab = true

Check this: https://docs.microsoft.com/en-us/windows/wsl/wsl-config#wslconf

Mounting a networking filesystem using just Linux with WSL can be a complicated task. I would suggest mounting it in Windows as a drive letter and access it from WSL using /mnt/

srbala commented 2 years ago

@tlsalex @crramirez comments helped?

srbala commented 2 years ago

@tlsalex Closing the issue now. Feel free to reopen the issue if needed and continue the discussion.