Radish alpha
r
rad:zwTxygwuz5LDGBq255RA2CbNGrz8
Radicle CI broker
Radicle
Git
CI index report is empty
Closed { reason: Solved } arnaud.mbp opened 7 months ago

My local cib instance ended up in the following situation:

$ ls -l /var/www/ci.punkachien.net/public_html/state
total 196
drwxr-xr-x 2 curry curry  4096 Aug 31 17:25 1cc1fcef-fbb9-4bd2-863c-26cf2cdd5d54
drwxr-xr-x 2 curry curry  4096 Aug 31 12:31 2c051ed2-5fee-49e8-8147-3a6576f32d65
drwxr-xr-x 2 curry curry  4096 Aug 31 16:39 4363b66e-05ca-4ee8-81cf-e02f479ce1c6
drwxr-xr-x 2 curry curry  4096 Aug 31 16:34 5d309101-94ea-41e9-b4e2-38015a08ea2e
drwxr-xr-x 2 curry curry  4096 Aug 31 16:01 613ec883-ed79-42c3-a0b3-810c24ebe39d
drwxr-xr-x 2 curry curry  4096 Aug 31 12:34 86920b08-4121-4a8b-b19c-95a06ea1bad9
drwxr-xr-x 2 curry curry  4096 Aug 31 12:23 87db57aa-85e9-42ff-872a-905a5d57cacc
drwxr-xr-x 2 curry curry  4096 Sep  2 09:23 8890e8a8-9601-48d2-befb-2e64715d2036
drwxr-xr-x 3 curry curry  4096 Sep  2 08:24 88e8fc1a-fb97-4539-8f18-6c34be69d2c8
drwxr-xr-x 2 curry curry  4096 Sep  1 22:29 895f3f61-8562-4609-a9b4-774d32fb801c
drwxr-xr-x 2 curry curry  4096 Aug 31 15:46 89d33e91-f1ef-4e46-afc0-419f242d5009
drwxr-xr-x 2 curry curry  4096 Aug 31 12:47 a839af48-c54e-4202-b1df-d5133f70ea7c
drwxr-xr-x 2 curry curry  4096 Aug 31 15:26 b25dc5d2-ecd6-4960-bcc4-2ad868e36c5a
drwxr-xr-x 2 curry curry  4096 Aug 31 13:20 baef24ac-deaf-41d3-accc-974d68d6f4f5
drwxr-xr-x 2 curry curry  4096 Sep  1 22:17 d6e9d1c5-1377-40d5-8c59-879f39e57c09
drwxr-xr-x 2 curry curry  4096 Sep  1 21:25 df0f6b68-d5f4-47ba-8520-359b00a47c9d
drwxr-xr-x 2 curry curry  4096 Aug 31 12:41 f711c0be-444c-4372-aa29-452659a797f1
-rw-r--r-- 1 curry curry 39096 Sep  3 12:56 failed.rss
-rw-r--r-- 1 curry curry     0 Sep  3 12:56 index.html
-rw-r--r-- 1 curry curry  7112 Sep  3 12:56 index.rss
-rw-r--r-- 1 curry curry   231 Sep  3 12:56 status.json
-rw-r--r-- 1 curry curry   977 Sep  3 12:56 unfinished.rss
-rw-r--r-- 1 curry curry 46988 Sep  3 12:56 z3gqcJUoA1n9HaHKufZs5FCSGazv5.html
-rw-r--r-- 1 curry curry 12214 Sep  3 12:56 z3PQYrvBT8B2zP3XdGoXdUd2Enftc.html
-rw-r--r-- 1 curry curry  2253 Sep  3 12:56 z3qg5TKmN83afz2fj9z3fQjU8vaYE.html
-rw-r--r-- 1 curry curry  5047 Sep  3 12:56 zkw8cuTp2YRsk1U68HJ9sigHYsTu.html

The index.html file is empty! I think what happened is that at the time mentioned in the timestamp, the machine ran out of disk space (because docker…), and perhaps the broker tried to refresh or rewrite the page but it couldn’t and left it in that state.

arnaud.mbp commented 7 months ago

Not sure if there’s a way for the broker to reconstruct that page from the structure of the directory?

arnaud.mbp commented 7 months ago

Note the index page gets recreated once the CI runs again so possibly not a big deal?

liw commented 7 months ago

If the disk filled up, then yes, it’s possible for index.html to become empty. I could avoid that by writing index.html.new and renaming that to index.html. That would mean the index file isn’t ever empty, at least. It just won’t update.

Given the HTML pages are about the only way the CI broker has to communicate with the outside world, if the disk fills up, there’s nothing much it can do, so the temp+rename approach is about the best.

If cib continues to run, or is restarted, and disk space is freed, then the HTML pages get updated whenever anything changes. I hope that means it’s not a big deal.

Meanwhile, you can also run cibtool --db ci.db pages to generate the HTML pages, including index.html, at will.

liw commented 7 months ago

Fixed-in: 62f1ded7e6f5e5f5c36eca1ad4dfd8eb75e14fbb