Grin 4.1.1 Crashing

Hoping someone can assist with a new technical issue I am having:

I’ve been mining Grin for about a year now & all has gone well until today. I’m not sure what happened.

I think some new update to my firewall caused it to not like some connection my Grin node was making & it’s caused something in the background to go screwy. Here is the sequence of events that I ran into today:

  1. I started up Grin 4.1.1 and it started normally
  2. Grin was synching up and about 2 minutes in, it crashed. I got a popup from my firewall that said it blocked a connection. That’s never happened before
  3. I figured I would troubleshoot the firewall junk later because it’s a pain, so I simply shut it down completely and made sure it was off & then I restarted Grin
  4. After about 15 seconds, Grin simply crashed without ever really starting up
  5. I repeated a couple of times, same behavior. It simply crashes with no error messages (except in logs)
  6. I tried running grin-wallet 4.0.0 just to see if maybe it was behaving odd as well & I also got some error messages there. When I enter my wallet password, it crashes too

I am totally guessing blind here, but I figure maybe some file got corrupted when my firewall killed Grin the 1st time, I really don’t know. I’m not sure what to do at this point

Looking at my grin-server.log file, it definitely shows some problems. Here is an excerpt:

-------trim--------
20201027 12:22:39.023 INFO grin - This is Grin version 4.1.1 (git v4.1.1), built for x86_64-pc-windows-msvc by rustc 1.46.0 (04488afe3 2020-08-24).
20201027 12:22:39.023 INFO grin - Chain: Mainnet
20201027 12:22:39.023 INFO grin - Feature: NRD kernel enabled: false
20201027 12:22:39.023 WARN grin::cmd::server - Starting GRIN in UI mode…
20201027 12:22:39.024 INFO grin_servers::grin::server - Starting server, genesis block: 40adad0aec27
20201027 12:23:27.709 ERROR grin_util::logger -
thread ‘main’ panicked at 'called Result::unwrap() on an Err value: Chain(Error { inner: NotFoundErr(“Block with hash: 0000918aa0f6”)

Store Error: NotFoundErr(“Block with hash: 0000918aa0f6”), reason: DB Not Found Error: Block with hash: 0000918aa0f6 })’: src/bin\cmd\server.rs:58 0:
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15: BaseThreadInitThunk
16: RtlUserThreadStart

Is this because my wallet was corrupted or something? Should I do a restore?

I’m not one to resolve the issue, but I might as well suggest that you edit your grin-server.toml file such that: stdout_log_level = "Debug" and then post the relevant log here again.

Yeah, thanks for the suggestion. Done. Slight difference in the output

20201028 09:43:22.383 INFO grin_util::logger - log4rs is initialized, file level: Info, stdout level: Debug, min. level: Debug
20201028 09:43:22.383 INFO grin - Using configuration file at C:\xxx.grin\main\grin-server.toml
20201028 09:43:22.383 INFO grin - This is Grin version 4.1.1 (git v4.1.1), built for x86_64-pc-windows-msvc by rustc 1.46.0 (04488afe3 2020-08-24).
20201028 09:43:22.383 INFO grin - Chain: Mainnet
20201028 09:43:22.383 INFO grin - Feature: NRD kernel enabled: false
20201028 09:43:22.383 WARN grin::cmd::server - Starting GRIN in UI mode…
20201028 09:43:22.384 INFO grin_servers::grin::server - Starting server, genesis block: 40adad0aec27
20201028 09:43:31.302 ERROR grin_util::logger -
thread ‘main’ panicked at 'called Result::unwrap() on an Err value: Chain(Error { inner:

TxHashSetErr: failed to open kernel PMMR })’: src/bin\cmd\server.rs:58 0:
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15: BaseThreadInitThunk
16: RtlUserThreadStart

Update: So I was able to resolve & get back to mining. Was a pain, but it worked. I had to delete .grin, start over from scratch, and then recover my wallet

Thanks for your help, Paouky

Glad to hear. Probably was some database corruption, sorry I wasn’t of too much help.