当还原的文件路径超过最大路径长度限制 (MAX_PATH) 时,Windows VMware 文件级还原 (FLR) 会失败

Den här artikeln gäller för Den här artikeln gäller inte för Den här artikeln är inte kopplad till någon specifik produkt. Alla produktversioner identifieras inte i den här artikeln.

Symptom



使用深度递归的特定目录路径上的文件级还原作业失败。      FLR 日志显示一般错误日志 

 
--------------------------------------------------------------------------------------------------------
-----  START avvmwfile log <timestamp> UTC  [18.2.100-134 Linux-x86_64]
--------------------------------------------------------------------------------------------------------

<timestamp> avvmwfile Info <5008>: Logging to /usr/local/avamarclient/var/MOD-1565970042058-<cid>-3019-vmwfilew.log
<timestamp> avvmwfile Info <5174>: - Reading /usr/local/avamarclient/var/avvmwfile.cmd
<timestamp> avvmwfile Info <5174>: - Reading /usr/local/avamarclient/var/avvmwfileAll.cmd
<timestamp> avvmwfile Info <6673>: CTL listening on port 34258
<timestamp> avvmwfile Info <10684>: Setting ctl message version to 3 (from 1)
<timestamp> avvmwfile Info <16136>: Setting ctl max message size to 268435456
<timestamp> avvmwfile Info <5174>: - Reading /usr/local/avamarclient/var/avvmwfile.cmd
<timestamp> avvmwfile Info <5174>: - Reading /usr/local/avamarclient/var/avvmwfileAll.cmd
<timestamp> avvmwfile Info <19660>: targetlist contains <dir backup="true" date="1969-01-01 00:00:00" internal="0" group="unknown" protection="drwx------" name="C:/DFS_Shares/Users/Bob" size="65536" saveas="C:/DFS_Shares/users/restore" user="unknown" />

<timestamp> avvmwfile Error <0000>: Failed to restore files via network, check proxy log for details
<timestamp>  avvmwfile Error <0000>: assist_restore error. ret: 157

--------------------------------------------------------------------------------------------------------
----- END avvmwfile log <timestamp> UTC  (0 warnings, 2 errors, 0 fatal errors)
--------------------------------------------------------------------------------------------------------

 

Orsak

在虚拟机内部,Microsoft Windows 配置了具有非常深的文件树结构的 DFS(分布式文件系统)。  

还原到原始位置还原选项时,我们在代理上看到 FLR 脚本日志 (/usr/local/avamarclient/bin/logs/flr*.err) 以下内容:
 
>file name: file1.txt
>file name: files2 
>file name: <long-file>-example.txt
>fail to create file  C:\DFS_Shares\users\restore\folder1\folder2\folder3\....< file length bigger than 260 characters>-example.txt  error code:2

问题:超出了最大路径长度限制 (MAX_PATH)。  默认情况下,此限制为 260,如果保存位置和文件名路径的组合大于 260 个字符


,则会导致还原文件创建问题 有关详细信息,请参阅此Microsoft页面:https://docs.microsoft.com/en-us/windows/win32/fileio/naming-a-file

“在 Windows API 中(以下段落中讨论了一些例外情况),路径的最大长度为 MAX_PATH,定义为 260 个字符。
本地路径按以下顺序构建:驱动器号、冒号、反斜杠、名称组件(用反斜杠分隔)以及终止 null 字符”

Upplösning


1.在较新的 Windows作系统(Windows 10、版本 1607 及更高版本)中,启用启用长路径。     
以下 Microsoft 知识库文章包含说明: https://docs.microsoft.com/en-us/windows/win32/fileio/naming-a-file



2.执行重定向还原到缩短目录路径,而不是还原到原始位置。
示例:c:\restore\,这将减少整体文件路径。  

Berörda produkter

Avamar

Produkter

Avamar, Avamar Client for VMware
Artikelegenskaper
Artikelnummer: 000053607
Artikeltyp: Solution
Senast ändrad: 09 okt. 2024
Version:  3
Få svar på dina frågor från andra Dell-användare
Supporttjänster
Kontrollera om din enhet omfattas av supporttjänster.