LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 04-20-2021, 01:03 PM   #1
uyjjhak
LQ Newbie
 
Registered: Feb 2020
Posts: 11

Rep: Reputation: Disabled
NAS ext4 drives initialized with Win10 Computer manager :( guid parttable and ext4 filesystem loss


Hello,

TL;DR
1. Some ext4 filesystems on different drives was initiated in Windows 10 disk manager
2. Currently there is no ext4 partitons and I suppose the partition table was overwritten by Windows - currently I see GUID Partition Table and only small (abt 100MB) Microsoft Resevred partition on the begginning of the 10TB drive.

3. After that I do not tried any writing/changing tools, only scanning it by rstudio, dmde and testdisk without seeing the proper partitions
4. There is about 10 hdds affected on that problem, I have connected it to the HBA or Motherboard Sata controller.
5. I don't have backed up that before


From many years I am building home NAS from different old parts.
So, with 4th gen i5 CPU, ATX board and 4 SATA controllers I am having fun with keeping lot of wasting about 60TB space on different disks.
So, the current config is:
4xWD GOLD 10TB
4xWD GOLD 14TB
2xWD RED 6TB (old mdadm raid0)
2xWD RED 6TB (old, 2nd, mdadm raid0)
On each of that drives, before using only under Ubuntu, I have done mkfs.ext4 /dev/sda or /dev/md0 for example.
That was full config, rest of usage of this was through the SMB and NFS shares over the LAN. On this hardware I never had started Windows before.


And last days I have had to start computer with Windows 10 to make MB bios update. I have installed all drivers, and later I have go to the Computer management/Storage and next... I have clicked "initialize disks". I am fully sure that the problem had started then. For better understanding - I am writing about this dialog which I have completed without thinking.
https://www.windowscentral.com/sites...windows-10.jpg
As that was over the night and I am sure that I have clicked it for all on my ext4-formatted disks. These filesystems doesn't appeared under windows ofc.
So, after clicking on that I can saw the drives with "unknown" partition but even then I hadn't saw what I've had done...

Of course from that time I haven't had any changes in files or structure these drives.

Today I started my hardware with Ubuntu, like always. And.... what freezed me - I saw that all of my hard disks, which was visible in Windows before - currently are partitioned GUID partition table and has only one, about 100MB partition named "Microsoft Reserved".
And now... Maybe I am in biggest problem in my life. So, all of my ext4 filesystems created directly on block device are gone.

Previously I don't made paritions, just creating filesystems on device:
Code:
mkfs.ext4 /dev/sdb
for example.

As lastly I have many problems with raid devices I also have bought R-studio and DMDE apps which I am trying to use.
But on R-studio I don't see any well styled filesystem and list of files which would be covered only by another type of partitioning. There is a mess with files, directiories, inodes.
DMDE has had not finished scanning the drive yet, but as I checkced testdisk (without seeing the proper disk partitions) on another device I am affraid that also it could has a problem.

OMG... what can I do in that situation ?

Yes, I know, make a backup before. But I don't have backed up everything as currently I am trying to reorganize that. That was the reason of using of faster and safest WD GOLD drives to easier organize large photo assets, and almost everything from my digital life...
 
Old 04-20-2021, 02:35 PM   #2
Emerson
LQ Sage
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,665

Rep: Reputation: Disabled
Filesystem directly on sdb, I'd start with 'file -s /dev/sdb' and see what it tells me. Then I'd try and force mounting it as ext4, with 'ro,noload' - these options make sure even journal is not written. Then go from there, if it tells you there is a healthy superblock then use it to mount your drive and the data should become accessible, minus sectors which were overwritten by Windows.
 
Old 04-20-2021, 03:15 PM   #3
uyjjhak
LQ Newbie
 
Registered: Feb 2020
Posts: 11

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Emerson View Post
Filesystem directly on sdb, I'd start with 'file -s /dev/sdb' and see what it tells me. Then I'd try and force mounting it as ext4, with 'ro,noload' - these options make sure even journal is not written. Then go from there, if it tells you there is a healthy superblock then use it to mount your drive and the data should become accessible, minus sectors which were overwritten by Windows.
Thank you, unfortunately that doesn't work:

Code:
root@ubu-4690:~# mount -t ext4 -o ro,noload /dev/sde /mnt/
mount: /mnt: wrong fs type, bad option, bad superblock on /dev/sde, missing codepage or helper program, or other error.
root@ubu-4690:~# file -s /dev/sde

/dev/sde: DOS/MBR boot sector MS-MBR Windows 7 english at offset 0x163 "Invalid partition table" at offset 0x17b "Error loading operating system" at offset 0x19a "Missing operating system"; partition 1 : ID=0xee, start-CHS (0x0,0,2), end-CHS (0x178,254,63), startsector 1, 4294967295 sectors
root@ubu-4690:~#
 
Old 04-20-2021, 03:53 PM   #4
Emerson
LQ Sage
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,665

Rep: Reputation: Disabled
I thought you just need help to get started? Here is the next step.
 
Old 04-20-2021, 06:32 PM   #5
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,151

Rep: Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125
Where to start ...

If you originally created the raid devices and filesystems directly on the device nodes themselves, you destroyed all the meta-data when you let Win10 reformat them. All of it - hence the mess of files you mentioned. I haven't purchased R-Studio, but from their website it looks like it should be a good tool to use.
Typically it is a matter of scouring the files and trying to recreate the filenames if you consider that important. For photos the exif usually has enough to do the job. For text maybe grep will give you some hints - Office files need unzipping first. Just a lot of legwork, and you won't get it all done by scripts.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Switching from win10 to a linux distro with win10 vm kevgk Linux - Virtualization and Cloud 3 11-01-2018 05:36 AM
[SOLVED] ssh can not connect when I initialized bridge-utils on remote computer lindylex Linux - Networking 4 10-29-2015 02:47 AM
UEFI and GPT(GUID) and BIOS and drives and partitions SaintDanBert Linux - Hardware 4 05-15-2014 10:05 AM
automatically backup folder on Free NAS computer to another Free NAS computer tom treadway Linux - Newbie 1 01-26-2011 07:28 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 01:00 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration