我正在尝试将 ADLS Gen2 挂载到 databricks,但我无法在 Databricks 上使用 bash/shell 脚本获取某个目录后的文件列表。 DBUILS 工作正常。
import os
os.listdir('/dbfs/mnt/temp')
mount.err
%sh
ls /dbfs/mnt/temp
mount.err
#using dbtuits work
for files in dbutils.fs.ls(external_path):
print(files.path)
dbfs:/mnt/temp/test1/
我尝试卸载并重新安装,但问题仍然存在。 我无法在 temp 中列出任何内容,但可以看到最多 /mnt。 请让我知道,通过其他答案,但没有人在 Gen2 上遇到过这个问题。