[RFC][PATCH 3/3] Embed vmcoreinfo into kernel file

Bernhard Walle bwalle at suse.de
Tue Aug 14 17:59:22 EDT 2007


Hello,

* Ken'ichi Ohmichi <oomichi at mxs.nes.nec.co.jp> [2007-08-13 09:39]:
> +#define FILENAME_VMCOREINFO		"/tmp/vmcoreinfo.tmp"

Wouldn't it be better to use mkstemp() here? It also makes sense to
copy the whole vmcore first and run makedumpfile after this in a full
featured system, e.g. before sending the dump file via FTP.

Then, you have the well-known security problems when using a temporary
file with a static name -- as well as two makedumpfile processes
running in parallel. While this all is not very likely, it's also not
guaranteed that this doesn't happen.


Thanks,
   Bernhard



More information about the kexec mailing list