From ecb2ec9b069c1b29bdadf5e27f4845d3bf200269 Mon Sep 17 00:00:00 2001 From: Martin Dawson Date: Tue, 18 Dec 2018 23:28:48 +0000 Subject: [PATCH] added the log.warn for the ipc endpoint --- rpc/ipc_unix.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/rpc/ipc_unix.go b/rpc/ipc_unix.go index 0851ea61e1..8b9a844a83 100644 --- a/rpc/ipc_unix.go +++ b/rpc/ipc_unix.go @@ -23,10 +23,17 @@ import ( "net" "os" "path/filepath" + + "github.com/ethereum/go-ethereum/log" ) // ipcListen will create a Unix socket on the given endpoint. func ipcListen(endpoint string) (net.Listener, error) { + if len(endpoint) > 107 { + log.Warn("The ipc endpoint is longer than 107 characters and is restricted to this size by linux. "+ + "Shorten this path to less than 108 characters.", "endpoint", endpoint) + } + // Ensure the IPC path exists and remove any previous leftover if err := os.MkdirAll(filepath.Dir(endpoint), 0751); err != nil { return nil, err