[lxc-devel] [PATCH] Move lxc-monitord.log out of /var/lib/lxc/

Stéphane Graber stgraber at ubuntu.com
Fri Apr 4 17:30:35 UTC 2014


On Fri, Apr 04, 2014 at 07:04:03PM +0200, Robert Vogelgesang wrote:
> Place log file into LOGPATH instead of LXCPATH (but still use the
> given lxcpath if the latter differs from LXCPATH).

Hmm, isn't logpath the per-container logfile storage?
If so, this seems wrong as lxc-monitord itself is a per-system thing not
per-container.

> 
> Signed-off-by: Robert Vogelgesang <vogel at users.sourceforge.net>
> 
> diff -up lxc-1.0.2/src/lxc/lxc_monitord.c.monitordlogpath lxc-1.0.2/src/lxc/lxc_monitord.c
> --- lxc-1.0.2/src/lxc/lxc_monitord.c.monitordlogpath	2014-03-27 20:10:33.000000000 +0100
> +++ lxc-1.0.2/src/lxc/lxc_monitord.c	2014-04-03 18:28:49.509852307 +0200
> @@ -348,7 +348,7 @@ int main(int argc, char *argv[])
>  	}
>  
>  	ret = snprintf(logpath, sizeof(logpath), "%s/lxc-monitord.log",
> -		       lxcpath);
> +		       (strcmp(LXCPATH, lxcpath) ? lxcpath : LOGPATH ) );
>  	if (ret < 0 || ret >= sizeof(logpath))
>  		return EXIT_FAILURE;
>  
> _______________________________________________
> lxc-devel mailing list
> lxc-devel at lists.linuxcontainers.org
> http://lists.linuxcontainers.org/listinfo/lxc-devel

-- 
Stéphane Graber
Ubuntu developer
http://www.ubuntu.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20140404/e251ad1f/attachment.pgp>


More information about the lxc-devel mailing list