Wine updates and the registry

Open forum for end-user questions about Wine. Before asking questions, check out the Wiki as a first step.
Forum Rules
Locked
User avatar
malonn
Level 2
Level 2
Posts: 27
Joined: Tue Oct 05, 2021 12:10 pm

Wine updates and the registry

Post by malonn »

When I install apps, etc. with Wine, sometimes entries get written to the registry for my prefix. When Wine updates, and I subsequently update my prefix, the registry gets overwritten.

My question is, if I want to keep those old registry entries, can I just back up the registry, and overwrite? (I know there's more to it than backing up regedit.exe) I mean, does a new version of Wine write new registry entries to a prefix built from an old version each time there is an update?

Am I making sense?
jkfloris
Level 12
Level 12
Posts: 3136
Joined: Thu Aug 14, 2014 10:10 am

Re: Wine updates and the registry

Post by jkfloris »

I'm not entirely sure, but I think you can prevent this by changing the content of .update-timestamp to disable.

Code: Select all

echo disable > "${WINEPREFIX}/.update-timestamp"
User avatar
malonn
Level 2
Level 2
Posts: 27
Joined: Tue Oct 05, 2021 12:10 pm

Re: Wine updates and the registry

Post by malonn »

Cool. I'll look into it. 'Preciate it.
User avatar
malonn
Level 2
Level 2
Posts: 27
Joined: Tue Oct 05, 2021 12:10 pm

Re: Wine updates and the registry

Post by malonn »

Under Windows, hives are stored in the following locations:

Code: Select all

HKEY_LOCAL_MACHINE\SYSTEM : \system32\config\system

HKEY_LOCAL_MACHINE\SAM : \system32\config\sam

HKEY_LOCAL_MACHINE\SECURITY : \system32\config\security

HKEY_LOCAL_MACHINE\SOFTWARE : \system32\config\software

HKEY_USERS\UserProfile : \winnt\profiles\username

HKEY_USERS.DEFAULT : \system32\config\default
These directories are not present under Wine. Before I attempt the suggestion made by @jkfloris, I'd like to make a backup of my registry. Are all of the registry entries stored in Wine's regedit.exe? Will backing up regedit.exe save old entries? I will test, but someone's insight might be valuable.
jkfloris
Level 12
Level 12
Posts: 3136
Joined: Thu Aug 14, 2014 10:10 am

Re: Wine updates and the registry

Post by jkfloris »

Wine stores the registry in the following files:

Code: Select all

"${WINEPREFIX}/system.reg"
"${WINEPREFIX}/user.reg"
"${WINEPREFIX}/userdef.reg"
https://wiki.winehq.org/Wine_User%27s_G ... stry_Files
User avatar
malonn
Level 2
Level 2
Posts: 27
Joined: Tue Oct 05, 2021 12:10 pm

Re: Wine updates and the registry

Post by malonn »

Good link, @jkfloris. That answers my initial question too. New versions of Wine do (could) update the registry.

I think in order to keep application registry entries across new versions (and maintain any version specific changes), I should back up/export my entries for apps I have installed. That may be a chore to hunt them down, but that's life. Life's a chore.
Locked