Recover data after upgrade from version 25 to version 28
I had the Fedora 25 on a Dell machine (dual boot). Recently I did an upgrade to Fedora 28. The old version held the most important data part:/OldDATA/mydata under the partition (/dev/sda8/). With the new version, the system automatically created /DATA, then placed the OldDATA under new /DATA, and mydata folder was seemingly erased, it disappeared. I used testdisk to fix the problem, but unfortunately, it does not work
What could you suggest me to recover the "mydata"?
$ls /DATA/OldDATA it gives me an empty folder, mydata are not here neither elsewhere
$ ls /DATA/
1 bin boot DATA dev etc home lib lib64 media mnt null opt proc root run sbin srv sys tmp usr var
$ ls /
1 bin boot DATA dev etc home lib lib64 lost+found media mnt null opt proc root run sbin srv sys tmp usr var
$ fdisk -l
$ Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors $ Units: sectors of 1 * 512 = 512 bytes $ Sector size (logical/physical): 512 bytes / 4096 bytes $ I/O size (minimum/optimal): 4096 bytes / 4096 bytes $ Disklabel type: gpt $ Device Start End Sectors Size Type $ /dev/sda1 2048 1050623 1048576 512M EFI System $ /dev/sda2 1050624 1083391 32768 16M Microsoft reserved $ /dev/sda3 1083392 200369095 199285704 95G Microsoft basic data $ /dev/sda4 200370176 202121215 1751040 855M Windows recovery environment $ /dev/sda5 202121216 221650943 19529728 9.3G EFI System $ /dev/sda6 221650944 260712447 39061504 18.6G Linux filesystem $ /dev/sda7 260712448 604506111 343793664 164G Linux LVM $ /dev/sda8 974176256 1953523711 979347456 467G Linux filesystem
Disk /dev/mapper/fedora_bachmachine-root: 74.5 GiB, 79997960192 bytes, 156246016 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/mapper/fedora_bachmachine-swap: 7.5 GiB, 8002732032 bytes, 15630336 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/mapper/fedora_bachmachine-var: 28 GiB, 30001856512 bytes, 58597376 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/mapper/fedora_bachmachine-home: 54 GiB, 58003030016 bytes, 113287168 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/sdb: 1.8 TiB, 2000398933504 bytes, 3907029167 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 4096 bytes I/O size (minimum/optimal): 4096 bytes / 33553920 bytes Disklabel type: dos Disk identifier: 0xf6d02017
Device Boot Start End Sectors Size Id Type /dev/sdb1 2048 3907024895 3907022848 1.8T 7 HPFS/NTFS/exFAT
A) stop using the partition something got lost on imediatly. Boot from a usb stick to recover it. B) No systemupgrade via dnf/yum will randomly delete a directory named /olddata . So you did not tell us the whole story yet. C) Are you sure that it "just" did not mount a partition to your mountpoint again? sdb8 seems to be a partition. "mount /dev/sdb8 /DATA/olddata " should bring it back.
mount /dev/sdb8 /DATA/olddata.
mount: /DATA/olddata: mount point does not exist.
The folder /DATA/DATA is empty.
This is wired, because after the command ls /DATA, i see dev, root, mnt, tmp, bin, 1, etc, run, usr, boot, home, null, sbin, var, lib. lib64, opt, srv, sys, media, proc, var.
/DATA/home is empty
I think I lost my data in olddata folder, I could not see the olddata physically. I see it as mounted partition in the sidebar of file manager but it leads me to /DATA
Do you have an idea, why?
"This is wired, because after the command ls /DATA, i see dev, root, mnt, tmp, bin, 1, etc, run, usr, boot, home, null, sbin, var, lib. lib64, opt, srv, sys, media, proc, var." means, you see a mounted system partition there.
can you provide the output of "df -h" and "ls -la /" and "ls -la /DATA" please?
df -h : Filesystem Size Used Avail Use% Mounted on devtmpfs 3.9G 0 3.9G 0% /dev tmpfs 3.9G 73M 3.8G 2% /dev/shm tmpfs 3.9G 2.1M 3.9G 1% /run tmpfs 3.9G 0 3.9G 0% /sys/fs/cgroup /dev/mapper/fedora_bachmachine-root 74G 11G 59G 16% / tmpfs 3.9G 196K 3.9G 1% /tmp /dev/sda8 460G 62G 376G 15% /DATA
/dev/sda6 19G 220M 18G 2% /boot /dev/mapper/fedora_bachmachine-home 54G 15G 36G 29% /home /dev/mapper/fedora_bachmachine-var 28G 6.4G 20G 25% /var /dev/sda5 9.4G 8.9M 9.3G 1% /boot/efi tmpfs 787M 16K 787M 1% /run/user/42 tmpfs 787M 6.9M 780M 1% /run/user/1000