Identify the stage before acting
| Evidence | More likely stage | Next step |
|---|---|---|
failed to publish the core and os error 32 after the download completes | Publishing or replacing the staged binary | Record the full error and both core versions; check whether the old core still runs |
failed to clean ... .tmp, but HTTPS pages still load through the proxy | Staged-file cleanup failed; the running core may be unaffected | Do not equate cleanup failure with a broken tunnel — verify the version actually running |
install service failed or program not found | Service installation | Use the service-install path |
| Core started, nodes selectable, but only TUN breaks connectivity | Capture and routing | Use the TUN path |
| Config validation failure or every node times out, with no publish error | Configuration or request stage | Read the first failure in the log; this page does not apply |
The report behind the error, and what it does not establish
Clash Verge Rev issue #8672 documents one Windows 11 machine on client 2.5.10 where updating the core produced failed to publish the core with os error 32. The reporter's timeline describes a security program opening the staged .tmp file with read-only sharing, after which the updater requested delete access, and both opens hit a sharing violation. The same report states that the restored verge-mihomo.exe hash matched the pre-update file, that cleanup of the staged file failed, and that a second core used by service mode was still running.
Those are the reporter's observations on one machine. The issue was marked as written with AI assistance and remained open at review time; the raw Process Monitor trace was not independently obtained. Treat it as a documented scenario, not a confirmed general defect.
The public source for 2.5.10 contains a branch that moves the old file to .old and attempts a restore if a second rename fails. That branch explains the intent; it does not guarantee every machine rolls back correctly.
Windows error 32 means a sharing conflict. It never names the process. The process names in that report describe that machine, not yours.
Safe checks on Windows
- Stop clicking update repeatedly. Record the client version, the current Mihomo version, the requested version, the exact error text and the local time. Mask the subscription URL, token, UUID, account name and local paths before sharing a screenshot.
- Confirm the proxy actually works. Check core status and the listening port in the client, send one HTTPS request explicitly to that local proxy entry, and confirm in the connection log that the current core handled it. A page loading in the browser only shows an outcome, not which core produced it. If no core is running, clear the system proxy first to restore direct access.
- Inspect the install directory without modifying it. Note whether
verge-mihomo.exe, a sibling.oldand a random-suffixed.tmpexist, with sizes and modification times. Do not rename or delete them while the service is running. - Locate the holder if you can. With Process Monitor, filter on the staged file path during one update attempt and observe the
CreateFileshare mode, theSHARING VIOLATIONevents and the order in which handles close. Without that trace, the honest statement is “a file may be held”, not “this specific program did it”. - Choose a recovery path. If the old core still works, defer the update and wait for a maintainer fix or for the other program to release the handle. If you do need to update, back up configuration and logs, then verify the new version through the official release channel. If the old file was not restored and the proxy is dead, stop hand-copying binaries: repair with the official installer and check service state.
Why a reboot is not a fix
The #8672 reporter states the failure recurred after a restart. The 2.5.10 source moves the old file and retries immediately after the first rename failure, with no visible backoff aimed at error 32. The reported timeline places the third-party read handle closing roughly 192 ms after the last failure. That timing supports the reporter's explanation of a short-lived conflict on that machine; it does not establish that every security product behaves the same way, and it is not a reason to disable real-time protection.
Limits and stopping conditions
This site has not reproduced #8672 on a user machine and has not verified whether a later release changes the behaviour. os error 32 can come from any incompatible file handle, so the code alone cannot identify a product. Do not obtain verge-mihomo.exe from an unofficial channel, do not grant write access on the whole install directory to all users, and do not treat disabling antivirus as a routine step. If the error names a configuration file, the service executable or another path, re-triage against that path instead of this page.
What to record
- Client version, current core version, target core version.
- The complete error text, including the path after “failed to publish the core”.
- Whether the previous core still runs, and which port it listens on.
- Whether the old binary was restored, by size and modification time.
- Whether a
.tmpor.oldfile remains in the install directory. - Whether the proxy carried a real HTTPS request immediately after the failure.
- Whether the same error returns after a restart or after a subscription update.