LifterLMS Stripe Webhook Errors: How to Find and Fix Them
What LifterLMS Stripe uses webhooks for, how to read failed deliveries in Stripe, what each error code means on a WordPress site, and how to fix and…
Read articleYou updated LifterLMS and a notice says the database is being upgraded in the background. An hour later it still says that. Or the notice asking you to run the updater keeps coming back after you click the button. A LifterLMS database update that seems stuck is worrying, because it is the one part of an update that changes your data.
The good news is that the updater is built to stop and resume, and it records what it is doing. This guide explains how LifterLMS database updates work, how to check whether yours is really stuck, and how to get it to finish without deleting anything you should not.
It is written for site owners comfortable with the LifterLMS Status screens, and for developers with WP-CLI access.
Some LifterLMS releases need to change stored data as well as code: moving settings, adding columns, cleaning up old values. Each of these releases has a list of update tasks. When you install a new version, LifterLMS compares the database version it last recorded, stored in the lifterlms_db_version option, with the list, and queues every task newer than that version.
There are two kinds of update:
Once started, the work happens in the background. While it runs you see "Your database is being upgraded in the background. Feel free to leave this page." When it finishes you see "The LifterLMS database update is complete."
The updater processes its queue in short bursts. Each burst runs for about 20 seconds, or until PHP uses 90% of its memory limit, then saves its place and starts the next burst with a request from your server to itself (a loopback request to admin-ajax.php). As a safety net it also schedules a WP-Cron health check every five minutes that restarts processing if the chain of requests breaks. After the last task it records the new database version and shows the completion notice.
That design explains almost every stuck update: either the loopback requests fail and cron is not running, or one task keeps failing.
Large sites legitimately take a while. Before you intervene, check these:
updater. You will see lines like "Queuing", "Running ... callback", "Finished ... callback" and finally "Update complete".The log also tells you how it stopped:
manage_options capability, normally an administrator.This is the common case. The burst-and-restart chain depends on loopback requests and WP-Cron, and both are often broken on real sites.
admin-ajax.php, and firewall rules that block the server's own IP are the usual suspects.The WP-CLI checks below show the state of the updater. They only read data, apart from the last command, which runs due cron events, including the updater's health check:
# The database version LifterLMS last recorded, and the plugin version.
wp option get lifterlms_db_version
wp plugin get lifterlms --field=version
# Queued updater work (one row per saved batch).
wp option list --search="wp_llms_bg_updater_batch_*" --fields=option_name
# Is a burst running right now? This lock expires on its own after a minute.
wp transient get wp_llms_bg_updater_process_lock --network
# Is the health check scheduled?
wp cron event list --fields=hook,next_run_relative | grep llms_bg_updater
# Run whatever cron events are due.
wp cron event run --due-now
If batches exist, no lock is held and the health check runs, the update should move again within a few minutes. Watch the updater log to confirm.
If one task crashes every time, the updater retries it on every burst and never gets past it. Find out why:
WP_DEBUG_LOG as described in the WordPress debugging guide.wp-content/debug.log for a fatal error at that time.Memory and time limits are the most common on sites with years of student data. Raise them for the duration of the update; our guide to LifterLMS memory limit and timeout errors covers how. If the error names another plugin, deactivate that plugin until the update finishes.
Some tasks change database tables. If the log shows a database permission error, ask your host to confirm the WordPress database user can create and alter tables.
lifterlms_db_version by hand to skip an update. LifterLMS will believe the data is in a state it is not.admin-ajax.php while the update runs.If you maintain several sites, our guide to customising LifterLMS without breaking updates covers the wider update routine.
Most automatic updates finish within a few minutes. Updates that touch every student or order can take longer on large sites. Progress in the updater log is the real measure.
Yes. The update runs in the background and the site stays online. For large manual updates, a quiet period is still wise.
Either the update never completes, so LifterLMS asks again, or a caching layer is serving an old copy of the admin page. Check the database version in the System Report and the updater log.
Under LifterLMS > Status > Logs, in the file whose name starts with updater. LifterLMS stores its logs in the llms-logs folder inside your uploads directory.
Read the updater log first. It tells you whether the update is working, waiting or failing, and which of the sections above applies. In most cases fixing loopback requests or cron is enough.
If the log shows a failing task, or the site has a lot of data and you cannot afford a long outage, our LifterLMS support team can complete the update safely, and our migration team handles upgrades from very old versions. Contact us with a copy of the updater log.
What LifterLMS Stripe uses webhooks for, how to read failed deliveries in Stripe, what each error code means on a WordPress site, and how to fix and…
Read article
Find and fix the cause of a LifterLMS login loop or "too many redirects" error: Force SSL, membership restriction redirects, cookie and domain…
Read article
Why LifterLMS student progress looks wrong, resets or disappears, where progress is actually stored, and how to fix stale percentages, lost quiz…
Read articleSkip the trial and error. Get specialist LifterLMS help and ship faster.