Content-Length: 353938 | pFad | https://github.com/internetarchive/openlibrary/issues/9521

64 Data Dumps not auto-generated · Issue #9521 · internetarchive/openlibrary · GitHub
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Data Dumps not auto-generated #9521

Closed
neilt opened this issue Jul 3, 2024 · 9 comments · Fixed by #9538
Closed

Data Dumps not auto-generated #9521

neilt opened this issue Jul 3, 2024 · 9 comments · Fixed by #9538
Assignees
Labels
Lead: @mekarpeles Issues overseen by Mek (Staff: Program Lead) [managed] Priority: 1 Do this week, receiving emails, time sensitive, . [managed] State: Work In Progress This issue is being actively worked on. [managed] Type: Bug Something isn't working. [managed] Type: Post-Mortem Log for when having to resolve a P0 issue

Comments

@neilt
Copy link

neilt commented Jul 3, 2024

Problem

As of today July 3, https://archive.org/details/ol_exports?sort=-publicdate does not show a June 2024 data dump.

And https://openlibrary.org/data/ol_dump_latest.txt.gz is still downloading ol_dump_2024-05-31.txt.gz

The dumps usually generate by the 1st or 2nd day of the next month.

2024-12 Update

The problem is occurring again and @mekarpeles is investigating

@neilt neilt added Needs: Lead Needs: Triage This issue needs triage. The team needs to decide who should own it, what to do, by when. [managed] Type: Bug Something isn't working. [managed] labels Jul 3, 2024
@tfmorris
Copy link
Contributor

tfmorris commented Jul 3, 2024

The dump program was recently changed, so this could be related. #9127

@github-actions github-actions bot added the Needs: Response Issues which require feedback from lead label Jul 3, 2024
@mekarpeles mekarpeles added the Type: Post-Mortem Log for when having to resolve a P0 issue label Jul 5, 2024
@mekarpeles
Copy link
Member

While running through our diagnosing cron failures guide (https://github.com/internetarchive/olsystem/wiki/Crons#diagnosing-cron-failures) we discovered:

DEBUG    : stats.py    :  46 :  Postgres Database : coverstore
Exception ignored in atexit callback: <function AtexitIntegration.setup_once.<locals>._shutdown at 0x7fa304df2660>
Traceback (most recent call last):
  File "/home/openlibrary/.local/lib/python3.12/site-packages/sentry_sdk/integrations/atexit.py", line 61, in _shutdown
    client.close(callback=integration.callback)
  File "/home/openlibrary/.local/lib/python3.12/site-packages/sentry_sdk/client.py", line 580, in close
    self.flush(timeout=timeout, callback=callback)
  File "/home/openlibrary/.local/lib/python3.12/site-packages/sentry_sdk/client.py", line 604, in flush
    self.transport.flush(timeout=timeout, callback=callback)
  File "/home/openlibrary/.local/lib/python3.12/site-packages/sentry_sdk/transport.py", line 525, in flush
    self._worker.submit(lambda: self._flush_client_reports(force=True))
  File "/home/openlibrary/.local/lib/python3.12/site-packages/sentry_sdk/worker.py", line 117, in submit
    self._ensure_thread()
  File "/home/openlibrary/.local/lib/python3.12/site-packages/sentry_sdk/worker.py", line 42, in _ensure_thread
    self.start()
  File "/home/openlibrary/.local/lib/python3.12/site-packages/sentry_sdk/worker.py", line 70, in start
    self._thread.start()
  File "/home/openlibrary/.local/lib/python3.12/site-packages/sentry_sdk/integrations/threading.py", line 56, in sentry_start
    return old_start(self, *a, **kw)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/threading.py", line 992, in start
    _start_new_thread(self._bootstrap, ())
RuntimeError: can't create new thread at interpreter shutdown

@mekarpeles mekarpeles added Priority: 1 Do this week, receiving emails, time sensitive, . [managed] Lead: @mekarpeles Issues overseen by Mek (Staff: Program Lead) [managed] and removed Needs: Triage This issue needs triage. The team needs to decide who should own it, what to do, by when. [managed] Needs: Lead Needs: Response Issues which require feedback from lead labels Jul 5, 2024
@cdrini
Copy link
Collaborator

cdrini commented Jul 8, 2024

This was also added which might cause the error: #9369

@mekarpeles mekarpeles self-assigned this Jul 8, 2024
@mekarpeles
Copy link
Member

@mekarpeles to manually run data dumps script according to
https://github.com/internetarchive/olsystem/wiki/Crons#monthly-data-dumps

@mekarpeles
Copy link
Member

@mekarpeles mekarpeles assigned cdrini and unassigned mekarpeles Jul 8, 2024
mekarpeles added a commit that referenced this issue Jul 8, 2024
@mekarpeles mekarpeles assigned mekarpeles and unassigned cdrini Jul 8, 2024
@mekarpeles mekarpeles added this to the Sprint 2024-07 milestone Jul 8, 2024
@mekarpeles mekarpeles changed the title Data Dumps not auto-generated for June 2024 Data Dumps not auto-generated Dec 20, 2024
@mekarpeles mekarpeles reopened this Dec 20, 2024
@mekarpeles
Copy link
Member

We manually ran for 2024-12 and everything worked but we need to look back at more logs and also verify things work for 2025-01 before we close.

@mekarpeles mekarpeles added the State: Work In Progress This issue is being actively worked on. [managed] label Dec 23, 2024
@mekarpeles
Copy link
Member

mekarpeles commented Jan 2, 2025

Our logs reveal dumps failed from cron container because the container did not correctly mount /olsystem and thus configs and scripts are unavailable to it:

+ log '=== Step 7 ==='
++ date '+%Y-%m-%d %H:%M:%S'
+ echo '2025-01-01 00:01:25 [openlibrary.dump] * === Step 7 ==='
2025-01-01 00:01:25 [openlibrary.dump] * === Step 7 ===
++ compgen -G 'ol_dump_*_2024-12*.txt.gz'
+ [[ ! -f ol_dump_ratings_2024-12-31.txt.gz
ol_dump_covers_metadata_2024-12-31.txt.gz
ol_dump_reading-log_2024-12-31.txt.gz ]]
+ mkdir -p /1/var/tmp/oldumpsort
+ log 'splitting the dump: ol_dump_%s_2024-12-31.txt.gz -- takes approx. 85 minutes for 68,000,000+ records...'
++ date '+%Y-%m-%d %H:%M:%S'
+ echo '2025-01-01 00:01:25 [openlibrary.dump] * splitting the dump: ol_dump_%s_2024-12-31.txt.gz -- takes approx. 85 minutes for 68,000,000+ records...'
2025-01-01 00:01:25 [openlibrary.dump] * splitting the dump: ol_dump_%s_2024-12-31.txt.gz -- takes approx. 85 minutes for 68,000,000+ records...
+ gzip -cd ol_dump_2024-12-31.txt.gz
+ python /openlibrary/scripts/oldump.py split --format ol_dump_%s_2024-12-31.txt.gz
Couldn't find statsd_server section in config
2025-01-01 00:01:27 [openlibrary.dump] ['/openlibrary/scripts/oldump.py', 'split', '--format', 'ol_dump_%s_2024-12-31.txt.gz'] on Python 3.12.2
Traceback (most recent call last):
  File "/openlibrary/scripts/oldump.py", line 37, in <module>
    load_config(ol_config)
  File "/openlibrary/openlibrary/config.py", line 41, in load_config
    infogami.load_config(config_file)
  File "/openlibrary/infogami/__init__.py", line 188, in load_config
    with open(config_file) as in_file:
         ^^^^^^^^^^^^^^^^^
FileNotFoundError: [Errno 2] No such file or directory: '/olsystem/etc/openlibrary.yml'

Once we deploy and ensure the cron container has access to olsystem and manually (one more time) run dumps, we should be in good shape to close this issue for now... And #10206 is a reasonable followup (on the milestone) to make sure we identify cron issues like this faster moving forward.

@mekarpeles
Copy link
Member

@cdrini recently fixed olsystem on this machine so the cron container (and other containers) have it.

I am going to patch-deploy an update to the cron that runs a db dump once today (and only once) and this will disappear with our next deploy.

So let's hold off on deploys for a bit, which shouldn't be hard given #10255

@mekarpeles
Copy link
Member

Ran successfully

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Lead: @mekarpeles Issues overseen by Mek (Staff: Program Lead) [managed] Priority: 1 Do this week, receiving emails, time sensitive, . [managed] State: Work In Progress This issue is being actively worked on. [managed] Type: Bug Something isn't working. [managed] Type: Post-Mortem Log for when having to resolve a P0 issue
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://github.com/internetarchive/openlibrary/issues/9521

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy