Two days ago I had two nodes, A and B, with a channel between them. I wanted to close the channel and transfer all funds from A to B at once. @renepickhardt suggested me to republish an old channel state.
I did the following on A:
The I started to see messages in the logs and in the listpeers output on A that I think I can't reproduce anymore because my logs were cleared and the channel is closed so there's no output regarding it anymore. The messages mentioned stuff like "onchain", I didn't quite understand them at the time. I'm only message I'm sure I saw was chan #1: Cannot broadcast our commitment tx: they have a future one.
One day later I checked node A again and the channel was closed, and I had this output on listfunds:
{
"outputs": [
{
"txid": "ded41df108c4d3b14d68604b9aca4277bfbdeb658cc8d9f04c8e536269fb8f75",
"output": 0,
"value": 25390,
"status": "confirmed"
}
],
"channels": [
]
}
Now I'm pasting all logs since 2018-11-28 on node B containing chan #0 (is there something else I should be looking for in these logs? Most stuff there is block-getting bitcoin-cli logs):
Nov 28 20:07:00 cantillon lightningd[14094]: 2018-11-28T20:07:00.979Z lightningd(14094): lightning_channeld-03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer connection lost
Nov 28 20:07:00 cantillon lightningd[14094]: 2018-11-28T20:07:00.980Z lightningd(14094): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer transient failure in CHANNELD_NORMAL: lightning_channeld: Owning subdaemon lightning_channeld died (9)
Nov 28 21:32:34 cantillon lightningd[14094]: 2018-11-28T21:32:34.814Z lightningd(14094): lightning_channeld-03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer connection lost
Nov 28 21:32:34 cantillon lightningd[14094]: 2018-11-28T21:32:34.814Z lightningd(14094): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer transient failure in CHANNELD_NORMAL: lightning_channeld: Owning subdaemon lightning_channeld died (9)
Nov 28 21:40:40 cantillon lightningd[14094]: 2018-11-28T21:40:40.363Z lightningd(14094): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer transient failure in CHANNELD_NORMAL: Reconnected
Nov 28 21:45:16 cantillon lightningd[14094]: 2018-11-28T21:45:16.050Z lightningd(14094): lightning_channeld-03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer connection lost
Nov 28 21:45:16 cantillon lightningd[14094]: 2018-11-28T21:45:16.052Z lightningd(14094): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer transient failure in CHANNELD_NORMAL: lightning_channeld: Owning subdaemon lightning_channeld died (62208)
Nov 28 21:46:12 cantillon lightningd[14094]: 2018-11-28T21:46:12.605Z lightningd(14094): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in CHANNELD_NORMAL: lightning_channeld: sent ERROR bad reestablish revocation_number: 127 vs 131
Nov 28 21:46:12 cantillon lightningd[14094]: 2018-11-28T21:46:12.633Z lightningd(14094): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from CHANNELD_NORMAL to AWAITING_UNILATERAL
Nov 28 22:08:38 cantillon lightningd[14094]: 2018-11-28T22:08:38.358Z lightningd(14094): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in AWAITING_UNILATERAL: Funding transaction spent
Nov 28 22:08:38 cantillon lightningd[14094]: 2018-11-28T22:08:38.390Z lightningd(14094): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from AWAITING_UNILATERAL to AWAITING_UNILATERAL
Nov 28 22:08:38 cantillon lightningd[14094]: 2018-11-28T22:08:38.393Z lightningd(14094): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from AWAITING_UNILATERAL to FUNDING_SPEND_SEEN
Nov 28 22:08:38 cantillon lightningd[14094]: 2018-11-28T22:08:38.817Z lightningd(14094): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 28 22:28:03 cantillon lightningd[19698]: 2018-11-28T22:28:03.365Z lightningd(19698): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 28 22:28:03 cantillon lightningd[19698]: 2018-11-28T22:28:03.370Z lightningd(19698): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 28 22:28:03 cantillon lightningd[19698]: 2018-11-28T22:28:03.557Z lightningd(19698): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 28 22:49:52 cantillon lightningd[20916]: 2018-11-28T22:49:52.291Z lightningd(20916): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 28 22:49:52 cantillon lightningd[20916]: 2018-11-28T22:49:52.296Z lightningd(20916): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 28 22:49:52 cantillon lightningd[20916]: 2018-11-28T22:49:52.478Z lightningd(20916): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 01:44:42 cantillon lightningd[25751]: 2018-11-29T01:44:42.576Z lightningd(25751): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 01:44:42 cantillon lightningd[25751]: 2018-11-29T01:44:42.579Z lightningd(25751): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 01:44:42 cantillon lightningd[25751]: 2018-11-29T01:44:42.783Z lightningd(25751): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 04:43:43 cantillon lightningd[324]: 2018-11-29T04:43:43.156Z lightningd(324): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 04:43:43 cantillon lightningd[324]: 2018-11-29T04:43:43.158Z lightningd(324): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 04:43:43 cantillon lightningd[324]: 2018-11-29T04:43:43.275Z lightningd(324): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 07:44:10 cantillon lightningd[3732]: 2018-11-29T07:44:10.629Z lightningd(3732): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 07:44:10 cantillon lightningd[3732]: 2018-11-29T07:44:10.632Z lightningd(3732): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 07:44:10 cantillon lightningd[3732]: 2018-11-29T07:44:10.930Z lightningd(3732): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 08:52:34 cantillon lightningd[5380]: 2018-11-29T08:52:34.639Z lightningd(5380): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 08:52:34 cantillon lightningd[5380]: 2018-11-29T08:52:34.642Z lightningd(5380): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 08:52:34 cantillon lightningd[5380]: 2018-11-29T08:52:34.793Z lightningd(5380): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 10:04:59 cantillon lightningd[6874]: 2018-11-29T10:04:59.627Z lightningd(6874): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 10:04:59 cantillon lightningd[6874]: 2018-11-29T10:04:59.630Z lightningd(6874): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 10:04:59 cantillon lightningd[6874]: 2018-11-29T10:04:59.794Z lightningd(6874): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 10:33:28 cantillon lightningd[7734]: 2018-11-29T10:33:28.197Z lightningd(7734): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 10:33:28 cantillon lightningd[7734]: 2018-11-29T10:33:28.200Z lightningd(7734): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 10:33:28 cantillon lightningd[7734]: 2018-11-29T10:33:28.409Z lightningd(7734): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 11:12:12 cantillon lightningd[8703]: 2018-11-29T11:12:12.076Z lightningd(8703): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 11:12:12 cantillon lightningd[8703]: 2018-11-29T11:12:12.082Z lightningd(8703): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 11:12:12 cantillon lightningd[8703]: 2018-11-29T11:12:12.194Z lightningd(8703): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 11:26:51 cantillon lightningd[9479]: 2018-11-29T11:26:51.427Z lightningd(9479): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 11:26:51 cantillon lightningd[9479]: 2018-11-29T11:26:51.430Z lightningd(9479): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 11:26:51 cantillon lightningd[9479]: 2018-11-29T11:26:51.612Z lightningd(9479): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 11:48:06 cantillon lightningd[10227]: 2018-11-29T11:48:06.433Z lightningd(10227): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 11:48:06 cantillon lightningd[10227]: 2018-11-29T11:48:06.436Z lightningd(10227): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 11:48:06 cantillon lightningd[10227]: 2018-11-29T11:48:06.653Z lightningd(10227): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 15:15:51 cantillon lightningd[19547]: 2018-11-29T15:15:51.108Z lightningd(19547): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 15:15:51 cantillon lightningd[19547]: 2018-11-29T15:15:51.110Z lightningd(19547): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 15:15:51 cantillon lightningd[19547]: 2018-11-29T15:15:51.309Z lightningd(19547): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 17:24:45 cantillon lightningd[21853]: 2018-11-29T17:24:45.750Z lightningd(21853): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 17:24:45 cantillon lightningd[21853]: 2018-11-29T17:24:45.751Z lightningd(21853): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 17:24:45 cantillon lightningd[21853]: 2018-11-29T17:24:45.936Z lightningd(21853): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 18:15:30 cantillon lightningd[22933]: 2018-11-29T18:15:30.525Z lightningd(22933): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 18:15:30 cantillon lightningd[22933]: 2018-11-29T18:15:30.528Z lightningd(22933): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 18:15:30 cantillon lightningd[22933]: 2018-11-29T18:15:30.700Z lightningd(22933): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 19:37:39 cantillon lightningd[25961]: 2018-11-29T19:37:39.234Z lightningd(25961): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 19:37:39 cantillon lightningd[25961]: 2018-11-29T19:37:39.237Z lightningd(25961): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 19:37:39 cantillon lightningd[25961]: 2018-11-29T19:37:39.317Z lightningd(25961): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 19:51:39 cantillon lightningd[26607]: 2018-11-29T19:51:39.112Z lightningd(26607): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 19:51:39 cantillon lightningd[26607]: 2018-11-29T19:51:39.121Z lightningd(26607): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 19:51:39 cantillon lightningd[26607]: 2018-11-29T19:51:39.414Z lightningd(26607): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 29 22:51:51 cantillon lightningd[29794]: 2018-11-29T22:51:51.973Z lightningd(29794): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 29 22:51:51 cantillon lightningd[29794]: 2018-11-29T22:51:51.976Z lightningd(29794): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 29 22:51:52 cantillon lightningd[29794]: 2018-11-29T22:51:52.022Z lightningd(29794): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 30 01:52:28 cantillon lightningd[2907]: 2018-11-30T01:52:28.532Z lightningd(2907): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 30 01:52:28 cantillon lightningd[2907]: 2018-11-30T01:52:28.536Z lightningd(2907): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 30 01:52:28 cantillon lightningd[2907]: 2018-11-30T01:52:28.786Z lightningd(2907): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 30 04:52:59 cantillon lightningd[8133]: 2018-11-30T04:52:59.810Z lightningd(8133): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 30 04:52:59 cantillon lightningd[8133]: 2018-11-30T04:52:59.813Z lightningd(8133): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 30 04:52:59 cantillon lightningd[8133]: 2018-11-30T04:52:59.914Z lightningd(8133): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 30 07:53:31 cantillon lightningd[12477]: 2018-11-30T07:53:31.314Z lightningd(12477): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 30 07:53:31 cantillon lightningd[12477]: 2018-11-30T07:53:31.318Z lightningd(12477): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 30 07:53:31 cantillon lightningd[12477]: 2018-11-30T07:53:31.509Z lightningd(12477): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 30 10:53:55 cantillon lightningd[19378]: 2018-11-30T10:53:55.068Z lightningd(19378): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 30 10:53:55 cantillon lightningd[19378]: 2018-11-30T10:53:55.071Z lightningd(19378): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 30 10:53:55 cantillon lightningd[19378]: 2018-11-30T10:53:55.319Z lightningd(19378): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
Nov 30 11:29:42 cantillon lightningd[20791]: 2018-11-30T11:29:42.526Z lightningd(20791): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: Peer permanent failure in ONCHAIN: Funding transaction spent
Nov 30 11:29:42 cantillon lightningd[20791]: 2018-11-30T11:29:42.529Z lightningd(20791): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from ONCHAIN to FUNDING_SPEND_SEEN
Nov 30 11:29:42 cantillon lightningd[20791]: 2018-11-30T11:29:42.663Z lightningd(20791): 03f4154f423524e20d5a17ecd9193934dbc72a3120aeaf3e6e0df7741a9aa64f26 chan #1: State changed from FUNDING_SPEND_SEEN to ONCHAIN
When you brought your node back online, the state of its commitment transactions was behind its peer node (that's what chan #1: Cannot broadcast our commitment tx: they have a future one. means). You lost the current commitment transaction when you did the backup maneuver -- paying an invoice through a channel updates the commitment transaction state.
When your commitment transactions are behind, the node closes the channel (another word for closing a channel is to go 'onchain').
That is why your node has its funds and no open channels (your listfunds output).
I'm not sure I understand your goal: "I wanted to close the channel and transfer all funds from A to B at once". What did you have in mind by 'at once'?
Presently, if you want to transfer these funds to B, you can either
newaddr, send from node A with withdraw ...)I'd recommend the first option, as it'll take less time and cost you less in fees.
Right. I understand that. But forget my initial goals, they're not relevant.
The basic thing I thought would happen here was:
I believe we already implement option_data_loss_protect which will let a node detect if it is behind, then ask the other node to unilaterally close without publishing any cheat or punishment txes. @rustyrussell to confirm.
Right, option_data_loss_protect will make sure that if we reconnect, we'll notice that we're out of date and ask the other side to be nice and close on our behalf. The other side in this case was nice and helped us out.
So this works as expected, you just can't rely on it working always (i.e., when the counterparty is not this nice). Sorry to break your cheat attempts :wink:
But doesn't that create an incentive for people to try to cheat? I mean, the entire purpose of having this punishment thing was that by trying to steal funds an attacker would be risking his own funds. Now there is less risk because sometimes even if his attack fails he just keeps the correct state.
@fiatjaf no, because this "ask the other side" part is a cooperative case. I notice my data is old and you have the ability to revoke it, so I ask you to close it. If I attempt to use my old data, I know you can revoke it and you are online to do so (I am talking to you right now to do this checking), so it would be rather daft of me to attempt it.
Now suppose you know my latest data is something you can revoke. You can then try a revoked state that is after my old state, but before the latest state. BUT! I could be lying: maybe I still know every state up to the latest state, and in particular the revocation of your intermediate state. If you move honestly and use only the latest state, then you have no risk. If you move dishonestly and use a state between my claimed old state and the latest state, you run the risk that I was lying and testing your behavior. "Impossible to cheat an honest man".
I don't understand this, you're considering the case of a node that gets cheated and then tries to cheat back? Why would it, if it could just publish the punishment transaction?
So this thing cooperation thing is just a conversation before node A actually tries to cheat and only if it finds out it has an old state and B is online?
Suppose I try the same move, but now with node B offline, then I go back online with it some minutes later, then there will be no cooperation?
No the flow is like this:
Only if the connection fails and we can't double-check that we're not cheating, i.e., exposing ourselves to potential loss if the counterparty is ready to retaliate, then we may end up publishing an old state.
If you really want to provoke a cheat attempt you need to use the dev-fail command, which skips all the safety checks.
Makes sense. Thank you!
Most helpful comment
No the flow is like this:
Only if the connection fails and we can't double-check that we're not cheating, i.e., exposing ourselves to potential loss if the counterparty is ready to retaliate, then we may end up publishing an old state.
If you really want to provoke a cheat attempt you need to use the
dev-failcommand, which skips all the safety checks.