[lxc-devel] [lxd/master] proxy: Only log errors

monstermunchkin on Github lxc-bot at linuxcontainers.org
Tue Sep 4 08:54:11 UTC 2018


A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 456 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20180904/bf3ddb14/attachment.bin>
-------------- next part --------------
From 5cbdcbb4b35f9fd5a311124e507c1ede3cf38ff1 Mon Sep 17 00:00:00 2001
From: Thomas Hipp <thomas.hipp at canonical.com>
Date: Tue, 4 Sep 2018 10:51:38 +0200
Subject: [PATCH] proxy: Only log errors

Signed-off-by: Thomas Hipp <thomas.hipp at canonical.com>
---
 lxd/main_forkproxy.go | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/lxd/main_forkproxy.go b/lxd/main_forkproxy.go
index 1e9310ad21..5a41fdfe02 100644
--- a/lxd/main_forkproxy.go
+++ b/lxd/main_forkproxy.go
@@ -141,8 +141,6 @@ void forkproxy()
 			strerror(errno));
 		_exit(EXIT_FAILURE);
 	}
-	fprintf(stderr, "Created anonymous pair {%d,%d} of unix sockets\n",
-		sk_fds[0], sk_fds[1]);
 
 	pid = fork();
 	if (pid < 0) {
@@ -337,7 +335,6 @@ func rearmUDPFd(epFd C.int, connFd C.int) {
 }
 
 func listenerInstance(epFd C.int, lAddr *proxyAddress, cAddr *proxyAddress, connFd C.int, lStruct *lStruct, proxy bool) error {
-	fmt.Printf("Starting %s <-> %s proxy\n", lAddr.connType, cAddr.connType)
 	if lAddr.connType == "udp" {
 		// This only handles udp <-> udp. The C constructor will have
 		// verified this before.
@@ -666,7 +663,6 @@ func (c *cmdForkproxy) Run(cmd *cobra.Command, args []string) error {
 		if ret < 0 {
 			return fmt.Errorf("Failed to add listener fd to epoll instance")
 		}
-		fmt.Printf("Added listener socket file descriptor %d to epoll instance\n", int(f.Fd()))
 	}
 
 	for {


More information about the lxc-devel mailing list