修复 Windows Subsystem Linux(WSL)中的未知权限

修复 Windows Subsystem Linux(WSL)中的未知权限

我在 Windows Subsystem Linux (WSL) 中的 Web 应用程序文件中发现了权限问题

我的系统是:Windows 10 64位上的Linux Ubuntu 18.04

我在 ubuntu 中运行我的 Web 服务器,当我使用非 sudo 帐户打印列表目录时,显示如下:

raydeon@LAPTOP-HF68R0VG:/var/www/html/fin-app/application/modules/accounting/controllers# ls -la 
ls: cannot access 'application/modules/accounting/controllers/Account.php': Permission denied
ls: cannot access 'application/modules/accounting/controllers/Account_receivable.php': Permission denied
total 0
drw-r--r-- 1 raydeon raydeon 4096 Oct  9 11:02 .
drwxr-xr-x 1 raydeon raydeon 4096 Oct  9 11:15 ..
-????????? ? ?       ?          ?            ? Account.php
-????????? ? ?       ?          ?            ? Account_receivable.php

当我使用 sudo 打印时,显示如下:

root@LAPTOP-HF68R0VG:/var/www/html/fin-app/application/modules/accounting/controllers$ ls -la 
total 0
drw-r--r-- 1 raydeon raydeon 4096 Oct  9 11:02 .
drwxr-xr-x 1 raydeon raydeon 4096 Oct  9 11:15 ..
-rw-r--r-- ? raydeon raydeon 2247 Oct  7 10:58 Account.php
-rw-r--r-- ? raydeon raydeon 3103 Oct  7 10:58 Account_receivable.php

我已尝试修复权限:

sudo chmod -R 644 *

并拥有:

sudo chown -hR raydeon:raydeon *

这没有帮助,当我通过非 sudo 帐户打印列表时,它仍然具有未知的权限

raydeon@LAPTOP-HF68R0VG:/var/www/html/fin-app/application/modules/accounting/controllers# ls -la 
ls: cannot access 'application/modules/accounting/controllers/Account.php': Permission denied
ls: cannot access 'application/modules/accounting/controllers/Account_receivable.php': Permission denied
total 0
drw-r--r-- 1 raydeon raydeon 4096 Oct  9 11:02 .
drwxr-xr-x 1 raydeon raydeon 4096 Oct  9 11:15 ..
-????????? ? ?       ?          ?            ? Account.php
-????????? ? ?       ?          ?            ? Account_receivable.php

尽管所有权属性是 raydeon(非 sudo),但仍然无法通过非 sudo 帐户访问,模块文件夹中的许多文件都发生这种情况。谢谢!

相关内容