Help recovering from device ID mismatch due to reuploading images to a new instance via CLI
In reference to this: https://github.com/immich-app/immich/discussions/2463#discussioncomment-5938690
tl;dr - I wiped my Immich install and reuploaded the photos to the new instance using the CLI tool. Now Immich isn't aware that the photos on my phone are the same as those on the server so the mobile app shows the photos as duplicates, one being "local only" and the other being "cloud only" for each pair.
According to Alex it sounds like I just need to edit the
deviceId
column of the assets
table so that all of rows use the device ID of my phone instead of the ID generated by the CLI tool.
Is that correct? Is there anything else I need to do?
Thanks.GitHub
Resynch local storage on mobile with server? · immich-app immich · ...
Due to some complications I had to reinstall Immich completely from scratch (after of course backing up my library). When I finally reconnected the mobile app I realized that the images must have d...
7 Replies
That should be correct yes
Hmm, so I did that and then even took a new photo to confirm the ID is still the same (top one is the latest photo)

But it still shows the unsynced duplicated on mobile. Is there perhaps something I need to do to force a recheck of this?
I restarted the server and mobile app (and logged out and back in)
I've just realised this approach wouldn't work since you uploaded from CLI - the deviceAssetId will be mismatched as well
No easy way to fix that I'm afraid
Ah ok, I figured as much tbh
Its fine, I'll just delete them off the phone and access via the network. Not a huge deal
Thanks anyway
Technically speaking I have a copy of the old database in a ZFS snapshot but meh
You could also delete them from immich and re-upload them from the phone, which would also fix the problem, fwiw