Closed SimonSK closed 6 years ago
For the DAO fork messages, I assume the log will contain the nodeid as well?
good catch. i totally screwed up the dao fork message. will push the change soon.
@sid1602 @zzma another logging format issue that's not too concerning.
ETH_NEW_BLOCK_HASHES
data is being logged like this:
data=["{\"Hash\":\"0x4a2b1434bdbfae...
With this PR, certain characters---including backslash but not quotes---are escaped, so the message now looks like:
data=["{\\"Hash\\":\\"0x4a2b1434bdbfae...
The first backslash comes from the following line escaping the double quote:
https://github.com/teamnsrg/go-ethereum/blob/85a1acbfd70a50d81fe6aba073689b6bbf912e06/eth/protocol.go#L150-L152
I think removing ~the inner ~ the for loop should fix this problem.MarshalObj
Send
now useSendDEVp2p
Send
now useSendEthSubproto
Send
now useSendDEVp2p
(as logging is the only difference between the two).SendItems
should callSendDEVp2p
. It is used by only p2p. Anywhere that previously usedSendItems
should continue to use it, not the other functions.datadir/geth-case-study/logs
. if not set, no logs are written to files, and only the ones withlog-level <= verbosity
are sent tostderr
geth-case-study.log
: all log messages withlog-level <= verbosity
go here.rlpx-received.log
:RLPXRX
- log level 6rlpx-sent.log
:RLPXTX
- log level 7devp2p-received.log
:DEVP2PRX
- log level 8devp2p-sent.log
:DEVP2PTX
- log level 9eth-received.log
:ETHRX
- log level 10eth-sent.log
:ETHTX
- log level 11daofork.log
:DAOFORK
- log level 12logrotate
occurred (eg log filenames changed).geth --exec 'admin.logrotate()' attach [/path/to/ipc]
Log message formats:
loglevel
|log timestamp in unix time
prefix
|received timestamp
|support=bool
|id=nodeid
|addr=ip:port
|conn=connection type
prefix
|sent/received timestamp
|message type
|size=int
|data=...
|err=...
|id=nodeid
|addr=ip:port
[|conn=connection type
]RLPX
messages don't haveconn