lbryio / lbryio/lbrycrd

Suspending system crashes lbrycrd

Open
#313 8 comments 0 reactions 0 assignees View on GitHub
hacktoberfest level: 2
Dominant language
C++
Stars
2.5k
Forks
173
PR merge metrics
No merged PRs in 30d

Description

On my Kubuntu 18.04 system
```
[niko:~/work/repositories/ansible] master(+107/-95)+ 10m13s ± uname -a
Linux nikubuntu 4.20.17-042017-generic #201903190933 SMP Tue Mar 19 13:36:11 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
```
I left lbrycrd running before suspending the system to RAM. After resuming I found this in the logs after realizing lbrycrd had crashed:
```
2019-09-04T03:08:49Z UpdateTip: new best=bef7f20382b621d936d07298ceac08288b777bf5496191c31e7d57dd94dcc332 height=627855 version=0x20000000 log2_work=73.213445 tx=5695597 date='2019-09-04T03:08:25Z' progress=0.997478 cache=592.0MiB(641103txo)
2019-09-04T12:07:41Z socket receive timeout: 32204s
2019-09-04T12:07:41Z socket receive timeout: 32210s
2019-09-04T12:07:41Z socket receive timeout: 32225s
2019-09-04T12:07:41Z socket receive timeout: 32203s
2019-09-04T12:07:41Z socket receive timeout: 32201s
2019-09-04T12:07:41Z socket receive timeout: 32201s
2019-09-04T12:07:41Z socket receive timeout: 32200s
2019-09-04T12:07:41Z socket receive timeout: 32223s
2019-09-04T12:07:41Z
************************
EXCEPTION: N5boost10wrapexceptINS_15condition_errorEEE
boost::condition_variable::do_wait_until failed in pthread_cond_timedwait: Invalid argument
lbrycrd in scheduler
************************
EXCEPTION: N5boost10wrapexceptINS_15condition_errorEEE
boost::condition_variable::do_wait_until failed in pthread_cond_timedwait: Invalid argument
lbrycrd in scheduler
terminate called after throwing an instance of 'boost::wrapexcept'
what(): boost::condition_variable::do_wait_until failed in pthread_cond_timedwait: Invalid argument
Aborted (core dumped)
```

The expected behavior would be that it continues operating normally

I had to reindex the whole chain to be able to start it again.

Contributor guide

Open the contributing guide

Research direction

Start with the scheduler and the pthread_cond_timedwait failure shown in the logs, then reproduce the issue by suspending and resuming a running lbrycrd process on Linux. Done means lbrycrd continues operating normally after resume without aborting or requiring a full chain reindex.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, linux
Domain
blockchain, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.