-
Notifications
You must be signed in to change notification settings - Fork 0
Updating BakaLoader
This page is about BakaLoader updating itself. Updating Valheim is a different job with its own page, Server updates and the launch guard.
BakaLoader is a folder you unzipped, and an update is that folder being rewritten. The app has to be closed while that happens, and closing the app stops any server it is running. Everything on this page follows from that one fact. New in 1.0.7, BakaLoader tells you a release is waiting, shows you what installing it would cost, and lets you pick the moment, instead of picking one for you.
Three places say the same thing, because all three read the same answer. When there is nothing newer, none of them show anything at all.

A pill appears in the Server card's button row, beside the Valheim server's own Update available pill, reading BakaLoader 1.0.9 ready. It is ember rather than amber and it names the version, so the two are never mistaken for each other. Click it to open the update dialog.
Its tooltip already tells you what to expect. With a server up, "A newer BakaLoader is ready. Open it to choose when it installs." With nothing running, "A newer BakaLoader is ready. Open it to install now."

The version at the foot of the left rail normally reads the release you are on and nothing else. When a newer one has been found the line grows: your version, the one that is waiting, and the word ready, and it smoulders. Hovering stills the glow and brightens it.
Click it, or tab to it and press Enter or Space, and the same dialog opens. With no update waiting it is a plain version string and does nothing at all.

Title BakaLoader update. It names the version and then says what will actually happen, which depends on your two Upkeep switches and on whether a world is up.
- Both switches on: "It installs the next time you close the app."
- Checking on, installing off, a server running: "It will not install while a world is up. Open Update BakaLoader to set it for the next restart, or turn auto-update on in Upkeep."
- Checking on, installing off, nothing running: "It will not install on its own. Install it now with Update BakaLoader, or turn auto-update on in Upkeep and it goes in the next time you close the app."
- Checking off: "Update checking is off in Upkeep, so nothing installs itself until you turn it back on."
Update BakaLoader opens the dialog. Upkeep settings opens the Upkeep card on the Dashboard. Dismiss hides the row.
The sentence follows the server. Start or stop a world and the row is rewritten, so it never promises an install that cannot happen. Flip either Upkeep switch and it is rewritten too. When a later check finds nothing newer, the row goes entirely.
A dismissed row is not raised again every few hours for the same release. Only a newer one asks again. Reloading the page does bring it back, because the app replays the announcement on every load.
At launch, during the splash, before any window is shown. Then a timer ticks every hour while the app is open, and a tick asks GitHub only if it has been at least six hours since the last time. Most ticks cost nothing.
That six hour floor is new in 1.0.7. It used to be a day, so a release published while you were hosting could wait until your next launch.
Every tick reads Check for BakaLoader updates fresh, so turning it off in Upkeep stops the next one with nothing else to do. Those two, the launch check and the hourly timer, are the only things that go looking on their own. An update that is actually being installed asks GitHub again at that moment, so what goes in is the release that is there then.
Opened from the pill, from the sidebar version, or from Update BakaLoader on the standing row. It asks the app for a fresh answer every time it opens, so it is never showing you something that stopped being true an hour ago.
It says what it will do before it does anything, and there is no button in it that stops a server.

Nothing is running, so this can happen now. BakaLoader closes, swaps itself for the new version and opens again.
Your profiles, worlds and mods are left alone.
The button is Update and relaunch now. Press it and BakaLoader downloads the release, closes every window, swaps the files and starts the new version. A toast confirms it on the way out: "Fetched. BakaLoader closes and opens again on the new version". Any profile with Autostart on comes back up as usual.
Stopped means every server in the app, not just the one in the window you clicked from. Several windows, further down, has the detail.

Installing it restarts BakaLoader, and that stops your server, so BakaLoader will not do it while a world is up.
Set it for the next restart and the new version installs itself the next time BakaLoader closes.
The only offer is Update on the next restart. It does not invent a schedule of its own: it turns on Auto-update BakaLoader in Upkeep, which is the switch that already does this job, and you will see that switch flip. The toast reads "BakaLoader installs the new version the next time it closes". If the setting cannot be written the dialog says "That setting could not be saved. Try the Upkeep card." and leaves the button where it was.
On a default install that switch is already on, so the button is confirming what is already true.
Stopping the server is your call, made from the server controls. The dialog will not make it for you and does not offer to.
View release notes opens the GitHub page for the release this check actually found, in your browser, so what you read is the version you were just offered rather than whatever is newest on the repository today. When the check handed over no address, the button falls back to the releases page. When neither can be opened, the dialog says "The release page could not be opened from here." instead of doing nothing.
Later closes the dialog and changes nothing. The pill, the sidebar line and the standing row are all still there.
A line under the body says why, in a sentence rather than a code.
| What it says | What it means |
|---|---|
| "A server or a Steam update is still running. Try again once it has finished." | A server somewhere in the app is not fully stopped, or steamcmd is rewriting some profile's Valheim install. |
| "Update checking is off in Upkeep. Turn it back on and BakaLoader can fetch this." |
Check for BakaLoader updates is off, so nothing may reach out. |
| "BakaLoader just checked. Give it a minute and try again." | The sixty second cooldown on an update you asked for. |
| "Nothing newer came back. BakaLoader is already on the newest release it can see, or the release has not finished publishing yet." | GitHub answered and had nothing newer, or the release has no files on it yet. |
| "BakaLoader could not reach GitHub. Check the connection and try again." | The request failed. |
| "BakaLoader could not fetch the update right now. Try again later." | Anything else. |
One of them is said before you press anything. With Check for BakaLoader updates off, the button is disabled the moment the dialog opens, its tooltip reads "Update checking is off in Upkeep.", and the sentence is already written, rather than waiting for a click that was always going to fail.
They live in the Upkeep card on the Dashboard. Both are on in a fresh install.
Check for BakaLoader updates decides whether BakaLoader may ask GitHub anything at all. Auto-update BakaLoader decides whether a run with nobody watching may install what it found. The second is dimmed while the first is off, because there would be nothing to install from.
| Check for BakaLoader updates | Auto-update BakaLoader | What you get |
|---|---|---|
| On | On | The default. It finds releases, tells you, and installs one the next time the app closes with no server running. You can also install on the spot from the dialog with everything stopped. |
| On | Off | It finds releases and tells you, and installs nothing by itself. The dialog's Update and relaunch now still works with every server stopped, because you asked for that one yourself. |
| Off | either, and dimmed | Nothing new is looked for and nothing is installed. A release found earlier in the same run still shows, with the row saying so and the dialog's button disabled. Watch the releases page yourself and unzip over the folder when you want to. |
There is one deliberate gap between the two. An update you ask for in the dialog needs only Check for BakaLoader updates, because pressing the button is you answering the question the second switch exists to answer. An update nobody asked for needs both.
The check asks GitHub for the latest release of the BakaLoader repository and compares its tag with the version you are running. Newer means an update is available. Anything else, including a repository with no releases at all, counts as up to date. The version you see quoted in the pill, the sidebar and the row is that tag.
The release page address it hands on is kept only when it starts with this project's own releases address, so the notes button cannot be sent somewhere else.
That one answer, the version, the address, whether a server is running and the state of both switches, is built once and read by the pill, the sidebar line, the standing row and the dialog. That is why no two of them can disagree about what is waiting.
The first time a version is seen it raises the row. Later checks that find the same version keep the answer fresh and say nothing, which is what stops a row you dealt with coming back every few hours. A check that gets through and finds nothing newer clears that memory, so a release that was pulled and put back can announce itself again. A check that failed does not clear it, so an outage cannot make the app repeat itself.
Anything that is not fully stopped. Running, Starting and Stopping, obviously. Also a restart in the gap between the old process exiting and the relaunch firing, which is where a crash with Restart on Crash on sits: the status already reads Stopped and a relaunch is scheduled. Also a launch the launch guard has not been given an answer for yet, and an automatic launch that was held and has a retry armed.
A Valheim server update counts too. While steamcmd is rewriting any profile's install, a BakaLoader update waits, for the same reason the server update itself cannot be called off: a half written install is worse than a slow one.
The check is deliberately generous, and it answers "yes, something is running" whenever it cannot work the answer out. Saying a server is up when none is costs you an update that waits a little longer than it had to. Saying none is up when one is costs somebody their world under a file swap.
Whether you pressed the button or an unattended run decided to install, the work is the same, and in this order.
- Read both switches.
- Ask GitHub for the latest release and compare the tag with the running version.
- Take the first release asset whose download address ends in
.zip. - Make
%TEMP%\BakaLoaderUpdateand download the zip into it. - Open the zip and confirm it really contains
ValheimBakaLoader.exe. - Work out the folder the running app lives in.
- Start the watchdog described below.
Only when all of that has worked is the update staged, and only then does BakaLoader close. Nothing has been written to the install yet: the download is sitting in a temp folder. Anything that throws anywhere in there is reported as a connection problem, and nothing is touched.
BakaLoader opens one window per profile with Autostart on, so closing a window is not the same as closing the app: the app stays up while any window remains.
A staged update now shuts the whole thing down. The exit is marked first, before anything is asked to close, because a window can go down between the first ask and the last. Then every open window is asked in turn, each inside its own guard, so one window that will not take the message does not strand the others. Each window shuts its own servers down the proper way, saving the world and stopping the server, rather than being closed out from under them. When the last window has gone, the app exits explicitly rather than trusting the message loop to end on its own.
Before 1.0.7 only the window you clicked in closed. The process stayed alive, and the watchdog eventually wrote the new release over a running install.
The swap cannot be done by the app, because the app is the thing being replaced. So staging leaves behind a small PowerShell script, windowless and self deleting, with every path written into it as a literal, depending on nothing beyond stock PowerShell and robocopy. It does this.
- Wait up to 120 seconds for BakaLoader's process id to disappear, then one more second.
- Look again. If the process is still there, exit and write nothing at all.
- Extract the zip fresh.
- Find the folder inside it that actually holds the exe, since a zip may nest it one level deep.
- Copy everything except
ValheimBakaLoader.exeinto the install folder, then copy the exe last. - Start the updated app.
- Delete the temp working folder.
Step 2 is new in 1.0.7 and it is the one that matters. Writing over an app that is still holding its own files replaces the unlocked ones and fails on the locked exe, and what is left on disk is half one version and half the other. Skipping costs you nothing, because the update is staged again the next time BakaLoader looks.
The copy goes into the folder BakaLoader runs from, which is why that has to be a folder you can write to. Program Files is not. See Install and first run.
An update you ask for goes out straight away instead of waiting for the six hour floor the quiet checks honour. Sixty seconds is the floor under that. Press the button twice inside a minute and the second press says "BakaLoader just checked. Give it a minute and try again."
The clock belongs to the app rather than to a window, so every window's button shares it.
It only starts once a request is really about to go out. A press that was turned down because a server is running does not burn a minute you never spent.
Every server session, in every window, registers itself with one list that belongs to the whole app. A profile that is removed, a profile that is renamed and a window that closes all take their sessions back out of it. The list is keyed by the session itself rather than by name, because two profiles in two windows can carry the same name and both of their servers are real.
When something asks whether a server is running, it reads that list together with the window's own. Before 1.0.7 it read only the window's own, so with two profiles set to Autostart the second window answered "nothing is running" while the first had a live world, and the update went ahead on that answer.
See Multiple servers.
Two paths, both needing Auto-update BakaLoader on.
At launch. The splash checks for a release before any window is shown. If one was staged, the app closes instead of opening windows, and the watchdog brings the new version up.
On a restart. Every restart path asks first. If the switch is on, no other server anywhere in the app is busy, and no Valheim update is running, it stages the update, closes every window and abandons the restart. The new version comes up and starts the server itself. If any of those is not true the restart happens normally, and the update waits for another one.
Will it stop my server to install an update? No. With a world up the dialog's only offer is the next restart, and no automatic path installs while anything is running either. Stopping is yours to do.
It says a server is still running and I only have one. Check the other windows: BakaLoader opens one per profile with Autostart on. Then check that the one you know about is really stopped rather than mid restart, held by the launch guard, or waiting on an armed retry after a crash. A Valheim server update running for any profile also counts.
The update button is greyed out. Check for BakaLoader updates is off in Upkeep. The dialog says so in the line under the body and in the button's own tooltip.
It closed for an update and came back on the old version. The watchdog waits two minutes for the app to exit and then refuses to write anything if the process is still there. That is the safe outcome rather than a broken one, and nothing was half written. Try again, and if it keeps happening look for a window or a server process that is not going away.
Where does the download go? %TEMP%\BakaLoaderUpdate. The watchdog deletes it when it is finished.
Does updating touch my worlds, mods or profiles? No. None of those live inside the BakaLoader folder. The update rewrites the app folder and nothing else.
Can I just update it by hand? Yes. Turn both switches off, download the zip from the releases page and unzip it over the folder with the app closed. It is the same files the watchdog would copy.
What is the difference between this and the Update available pill next to it? That one is Valheim. This one is BakaLoader. See Server updates and the launch guard.
Screens
Dashboard (Hearth) Players (Vikings) Mods Hexium Configs (Runes) Settings (World) World modifiers Map (Atlas) Log (Saga) Discord (Herald) Statistics (Skald)
Guides
Running the server Automatic restarts Server updates and the launch guard Updating the server Updating BakaLoader Worlds, backups and restore Deleting a world Multiple servers Custom domain The condition bar Command palette and shortcuts Privacy and network
Reference
Settings reference How mods are matched and updated The bundled plugins World file formats How the map is drawn For mod authors
Help