【问题标题】:rsync error: received SIGINT, SIGTERM, or SIGHUP (code 20) at rsync.c(544) [sender=3.0.6]rsync 错误:在 rsync.c(544) [sender=3.0.6] 收到 SIGINT、SIGTERM 或 SIGHUP(代码 20)
【发布时间】:2021-09-24 03:41:23
【问题描述】:

我正在尝试使用 rsync 命令删除大量数据(〜在 TiBs 中)。 该命令使用 nohup 在后台进程中运行。但是它仍然失败,没有成功完成该过程,并在日志文件中出现下面提到的错误。

rsync error: received SIGINT, SIGTERM, or SIGHUP (code 20) at rsync.c(544) [sender=3.0.6]

请建议在这种情况下应该怎么做。 这是我正在执行的命令。

nohup rsync -a --delete empty_dir/ dir_to_be_deleted/ &

【问题讨论】:

    标签: linux unix


    【解决方案1】:

    rsync 不适用于 nohup,但使用 screen 我们可以在后台成功运行 rsync。 下面是命令

    1) 打开一个屏幕

     screen -S rsync
    

    2) 运行rsync进程

    rsync -rvz --delete syncing_to_empty_dir/ folder_marked_for_deletion/
    

    3) 分离屏幕

    ctrl+A+d  
    

    这解决了我的问题,希望对其他人也有用。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2018-03-07
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-09-21
      • 2023-03-16
      • 2016-11-09
      • 1970-01-01
      相关资源
      最近更新 更多