mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
Use C locales and use_mlockall for clvmd.
Use same steps for clvmd as for dmeventd - using C locales to avoid reading large mmaps and use mlockall() for threaded version.
This commit is contained in:
parent
fc63498c49
commit
b409df00a9
@ -1,5 +1,6 @@
|
||||
Version 2.02.63 -
|
||||
================================
|
||||
Use C locales and use_mlockall for clvmd.
|
||||
Refactor code related to vg->pvs list and add pv->vg link.
|
||||
Mask LCK_HOLD flag in cluster VG locks for compatibility reasons.
|
||||
Add activation/polling_interval to lvm.conf as --interval default.
|
||||
|
@ -360,6 +360,13 @@ int main(int argc, char *argv[])
|
||||
return debug_clvmd(debug, clusterwide_opt)==1?0:1;
|
||||
}
|
||||
|
||||
/*
|
||||
* Switch to C locale to avoid reading large locale-archive file
|
||||
* used by some glibc (on some distributions it takes over 100MB).
|
||||
* Daemon currently needs to use mlockall().
|
||||
*/
|
||||
setenv("LANG", "C", 1);
|
||||
|
||||
/* Fork into the background (unless requested not to) */
|
||||
if (debug != DEBUG_STDERR) {
|
||||
be_daemon(start_timeout);
|
||||
|
@ -878,13 +878,16 @@ int init_lvm(int using_gulm)
|
||||
|
||||
/* Trap log messages so we can pass them back to the user */
|
||||
init_log_fn(lvm2_log_fn);
|
||||
memlock_inc_daemon(cmd);
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
void destroy_lvm(void)
|
||||
{
|
||||
if (cmd)
|
||||
if (cmd) {
|
||||
memlock_dec_daemon(cmd);
|
||||
destroy_toolcontext(cmd);
|
||||
}
|
||||
cmd = NULL;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user