Hello,
When coroipcc_service_connect() starts creating temporary files but is unable to write all of them, it returns an error without cleaning the temporary files. In the end they are never removed. The most common case where this can happen is when temporary files are created on a disk already full -> In my case, it happened on a BSD system (where there isn't a /dev/shm dir) with temporary files written in a (too) small /tmp partition.
diff --git corosync/lib/coroipcc.c corosync/lib/coroipcc.c
index bbeb95f..1cbdcbf 100644
--- corosync/lib/coroipcc.c
+++ corosync/lib/coroipcc.c
@@ -399,7 +399,7 @@ memory_map (char *path, const char *file, void **buf,
size_t bytes)
char *buffer;
int32_t i;
int32_t written;
- long page_size;
+ long page_size;
snprintf (path, PATH_MAX, "/dev/shm/%s", file);
@@ -453,9 +453,8 @@ retry_write:
#endif
res = close (fd);
- if (res) {
- return (-1);
- }
+ if (res)
+ goto error_close_unlink;
*buf = addr_orig;
return 0;
@@ -758,12 +757,16 @@ error_exit:
semctl (ipc_instance->control_buffer->semid, 0, IPC_RMID);
#endif
memory_unmap (ipc_instance->dispatch_buffer, dispatch_size);
+ unlink(dispatch_map_path);
error_dispatch_buffer:
memory_unmap (ipc_instance->response_buffer, response_size);
+ unlink(response_map_path);
error_response_buffer:
memory_unmap (ipc_instance->request_buffer, request_size);
+ unlink(request_map_path);
error_request_buffer:
memory_unmap (ipc_instance->control_buffer, 8192);
+ unlink(control_map_path);
error_connect:
close (request_fd);
smime.p7s
Description: S/MIME Cryptographic Signature
_______________________________________________ Openais mailing list [email protected] https://lists.linux-foundation.org/mailman/listinfo/openais
