These may help you find a proper solution: https://github.com/ipfs/go-ipfs/issues/2692 https://github.com/ipfs/go-ipfs/blob/master/commands/reqlog.go https://github.com/ipfs/go-ipfs/blob/master/core/commands/log.go