Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/redis/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
为什么redis 3.2拒绝创建后台fsync?_Redis_Fsync - Fatal编程技术网

为什么redis 3.2拒绝创建后台fsync?

为什么redis 3.2拒绝创建后台fsync?,redis,fsync,Redis,Fsync,下面是aof.c中flushAppendOnlyFile函数末尾的代码片段,该函数将aof缓冲区写入磁盘 /* Perform the fsync if needed. */ if (server.aof_fsync == AOF_FSYNC_ALWAYS) { server.aof_last_fsync = server.unixtime; } else if ((server.aof_fsync == AOF_FSYNC_EVERYSEC &&

下面是aof.c中
flushAppendOnlyFile
函数末尾的代码片段,该函数将aof缓冲区写入磁盘

/* Perform the fsync if needed. */
if (server.aof_fsync == AOF_FSYNC_ALWAYS) {
    server.aof_last_fsync = server.unixtime;
} else if ((server.aof_fsync == AOF_FSYNC_EVERYSEC &&
            server.unixtime > server.aof_last_fsync)) {
    // Why create fsync job only while sync_in_progress is false?
    if (!sync_in_progress) aof_background_fsync(server.aof_fd);
    server.aof_last_fsync = server.unixtime;
}
Redis bio为fsync实现了一个后台作业列表。函数
aof_background\u fsync
将新的fsync作业追加到列表中

为什么redis仅在
sync\u in\u progress
为false时才在此文件上创建fsync作业?如果
sync\u in\u progress
为true,则有多个fsync作业等待执行。为什么redis拒绝在这种情况下附加此fsync作业

(这是全部)