samba – rsync失败并显示错误:无法统计目标…无法分配内存(12)

前端之家收集整理的这篇文章主要介绍了samba – rsync失败并显示错误:无法统计目标…无法分配内存(12)前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
我试图将我的 Linux服务器上的一些目录rsync到位于/ mnt / backups的Linux服务器上本地安装的Windows 7共享.

我的rsync命令如下所示:

rsync -avz --progress --partial --modify-window=1 --temp-dir=/tmp /home /mnt/backups

当它执行时,我得到这个:

building file list ...
165048 files to consider
rsync: ERROR: cannot stat destination "/mnt/backups": Cannot allocate memory (12)
rsync error: errors selecting input/output files,dirs (code 3) at main.c(507) [receiver=2.6.9]
rsync: connection unexpectedly closed (8 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(453) [sender=2.6.9]

我一直在搜索,我发现的唯一提示添加–modify-window和–temp-dir选项但这些没有任何区别.

为了记录,我在尝试将备份文件tar到此安装位置时遇到了类似的问题,这就是我想切换到rsync的原因.我怀疑Samba造成了这些问题,但表面上看起来一切都很好.不确定从这里做什么…

解决方法

似乎是Windows 7端的问题.修复是更新以下两个reg键.

将以下注册表项设置为“1”:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management\LargeSystemCache

并将以下注册表项设置为“3”:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters\Size

参考文献:
http://frankooh.wordpress.com/2012/01/02/smbrsync-cannot-allocate-memory/
http://ubuntuforums.org/showthread.php?t=869994&page=2&p=8251122#post8251122
http://www.decuslib.com/decus/vmslt99a/nt/tips.txt
https://groups.google.com/forum/#!topic/microsoft.public.windows.vista.networking_sharing/NF3jEW2VlmQ

原文链接:https://www.f2er.com/linux/396856.html

猜你在找的Linux相关文章