Page 1 of 1

userdata folder lost

Posted: Fri Oct 25, 2019 1:34 pm
by asouthernboy
i previously moved userdata to external usb. Which then crashed.
Now i cannot update diepti because "DietPi was unable to verify the existance of the userdata directory │
│ (/mnt/usb8gb/dietpi_userdata)"

I tried going to disk management and transfer userdata to a healthy disk but till gives me error and i cannot proceed.
Is there a way to manually recreate userdata folder somewhere?
I don't want to start from scratch as i have a lot of software already setup on my diepti.

Re: userdata folder lost

Posted: Fri Oct 25, 2019 4:21 pm
by MichaIng
You mean the userdata transfer to the external drive went through without issues first, but the drive crashed afterwards? Because we only remove the original userdata when the copy went through without error.

If the copy/transfer itself broke, then the userdata should still be placed at /mnt/dietpi_userdata.
If the drive broke afterwards, I would run some fsck on it, e.g. open dietpi-drive_manager, select the external drive/partition, select Check & Repair. Hopefully it can be mounted successfully afterwards.

If it is not recoverable on the external drive, I am afraid it is lost. It makes sense to always have a backup in place, especially when doing things like transferring root oder userdata to an exernal drive. Did you probably create a dietpi-backup previously, e.g. as choice when some DietPi-Update prompt on software reinstall?

Re: userdata folder lost

Posted: Fri Oct 25, 2019 9:39 pm
by asouthernboy
Thank you. USB is totally destroyed.
i found this backup folder but cant seem to find userdata inside

Re: userdata folder lost

Posted: Fri Oct 25, 2019 10:39 pm
by MichaIng
I'm sorry for that. That's the reason I run a backup of important user data and config every night.

Userdata is in /mnt/dietpi_userdata.
Which software titles did you have installed? Probably we can recover some configs as well.

Re: userdata folder lost

Posted: Sat Oct 26, 2019 12:03 am
by asouthernboy
It's outside of Dietpi supported software.
Specifically - Ambilight and HBO GO and Netflix for Kodi

Nevermind now. I'll start from scratch.:)
Appreciate you jumping in and try to help!!!

just one more question i believe my userdata was empty anyway and to me not important , as system is working flawlessly without it. i just want to pass that error and update dietpi, still cannot recreate it manually?

Re: userdata folder lost

Posted: Sat Oct 26, 2019 12:35 am
by MichaIng
Ah okay if it was empty anyway then there is no issue. As long as you don't install certain software via DietPi scripts it is indeed not used. Simply run:
mkdir /mnt/dietpi_userdata
chown dietpi:dietpi /mnt/dietpi_userdata

Not sure if either the symlink needs to be removed first or the command need to target the actual external drive location otherwise, since they might but follow symlinks ;).

Re: userdata folder lost

Posted: Sat Oct 26, 2019 3:02 am
by asouthernboy
That worked!
Thank you!! 8)