ext4magic - recover rm deleted file on ubuntu 18,04 server /dev/md0 RAID
Clash Royale CLAN TAG#URR8PPP
up vote
-1
down vote
favorite
I just accidentally deleted my file called backup.sh
which was located on /srv/SCRIPTS/backup.sh
My system has 3 Hdd's:
HDD1 -> SSD running OS
HDD2,HDD3 Software Raid1 on /dev/md0
formatted as ext4
/dev/md0
is mounted on /srv
Disk /dev/loop0: 86.9 MiB, 91099136 bytes, 177928 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/loop1: 87.9 MiB, 92123136 bytes, 179928 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/loop2: 87.9 MiB, 92114944 bytes, 179912 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sda: 1.8 TiB, 2000398934016 bytes, 3907029168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sdb: 1.8 TiB, 2000398934016 bytes, 3907029168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sdc: 111.8 GiB, 120040980480 bytes, 234455040 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 0A3C7F5C-709D-4224-8C2A-9ADE267784C9
Device Start End Sectors Size Type
/dev/sdc1 2048 1050623 1048576 512M EFI System
/dev/sdc2 1050624 234452991 233402368 111.3G Linux filesystem
Disk /dev/md0: 1.8 TiB, 2000263643136 bytes, 3906764928 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
I tried:
ext4magic /dev/md0 -a $(date -d "-24hours" +%s) -f /srv/SCRIPTS -l
and I got
Filesystem in use: /dev/md0
Using internal Journal at Inode 8
Activ Time after : Thu Nov 15 11:17:17 2018
Activ Time before : Fri Nov 16 11:17:17 2018
Error: Inode not found for "/srv/SCRIPTS"
Check the valid PATHNAME "/srv/SCRIPTS" and the BEFORE option "Fri Nov 16 11:17:17 2018"
ext4magic : EXIT_SUCCESS
root@anastasia:/srv/SCRIPTS#
How to get INODE of a file which i don'have?
extundelete
New contributor
add a comment |
up vote
-1
down vote
favorite
I just accidentally deleted my file called backup.sh
which was located on /srv/SCRIPTS/backup.sh
My system has 3 Hdd's:
HDD1 -> SSD running OS
HDD2,HDD3 Software Raid1 on /dev/md0
formatted as ext4
/dev/md0
is mounted on /srv
Disk /dev/loop0: 86.9 MiB, 91099136 bytes, 177928 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/loop1: 87.9 MiB, 92123136 bytes, 179928 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/loop2: 87.9 MiB, 92114944 bytes, 179912 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sda: 1.8 TiB, 2000398934016 bytes, 3907029168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sdb: 1.8 TiB, 2000398934016 bytes, 3907029168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sdc: 111.8 GiB, 120040980480 bytes, 234455040 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 0A3C7F5C-709D-4224-8C2A-9ADE267784C9
Device Start End Sectors Size Type
/dev/sdc1 2048 1050623 1048576 512M EFI System
/dev/sdc2 1050624 234452991 233402368 111.3G Linux filesystem
Disk /dev/md0: 1.8 TiB, 2000263643136 bytes, 3906764928 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
I tried:
ext4magic /dev/md0 -a $(date -d "-24hours" +%s) -f /srv/SCRIPTS -l
and I got
Filesystem in use: /dev/md0
Using internal Journal at Inode 8
Activ Time after : Thu Nov 15 11:17:17 2018
Activ Time before : Fri Nov 16 11:17:17 2018
Error: Inode not found for "/srv/SCRIPTS"
Check the valid PATHNAME "/srv/SCRIPTS" and the BEFORE option "Fri Nov 16 11:17:17 2018"
ext4magic : EXIT_SUCCESS
root@anastasia:/srv/SCRIPTS#
How to get INODE of a file which i don'have?
extundelete
New contributor
So why don't you have a backup of backup.sh anyway? If you remember some of the contents of this file,strings -w /dev/md0 | grep -F 'cool stuff' -C 100
or just write it again, things usually turn out better for a rewrite.
– frostschutz
2 days ago
add a comment |
up vote
-1
down vote
favorite
up vote
-1
down vote
favorite
I just accidentally deleted my file called backup.sh
which was located on /srv/SCRIPTS/backup.sh
My system has 3 Hdd's:
HDD1 -> SSD running OS
HDD2,HDD3 Software Raid1 on /dev/md0
formatted as ext4
/dev/md0
is mounted on /srv
Disk /dev/loop0: 86.9 MiB, 91099136 bytes, 177928 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/loop1: 87.9 MiB, 92123136 bytes, 179928 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/loop2: 87.9 MiB, 92114944 bytes, 179912 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sda: 1.8 TiB, 2000398934016 bytes, 3907029168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sdb: 1.8 TiB, 2000398934016 bytes, 3907029168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sdc: 111.8 GiB, 120040980480 bytes, 234455040 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 0A3C7F5C-709D-4224-8C2A-9ADE267784C9
Device Start End Sectors Size Type
/dev/sdc1 2048 1050623 1048576 512M EFI System
/dev/sdc2 1050624 234452991 233402368 111.3G Linux filesystem
Disk /dev/md0: 1.8 TiB, 2000263643136 bytes, 3906764928 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
I tried:
ext4magic /dev/md0 -a $(date -d "-24hours" +%s) -f /srv/SCRIPTS -l
and I got
Filesystem in use: /dev/md0
Using internal Journal at Inode 8
Activ Time after : Thu Nov 15 11:17:17 2018
Activ Time before : Fri Nov 16 11:17:17 2018
Error: Inode not found for "/srv/SCRIPTS"
Check the valid PATHNAME "/srv/SCRIPTS" and the BEFORE option "Fri Nov 16 11:17:17 2018"
ext4magic : EXIT_SUCCESS
root@anastasia:/srv/SCRIPTS#
How to get INODE of a file which i don'have?
extundelete
New contributor
I just accidentally deleted my file called backup.sh
which was located on /srv/SCRIPTS/backup.sh
My system has 3 Hdd's:
HDD1 -> SSD running OS
HDD2,HDD3 Software Raid1 on /dev/md0
formatted as ext4
/dev/md0
is mounted on /srv
Disk /dev/loop0: 86.9 MiB, 91099136 bytes, 177928 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/loop1: 87.9 MiB, 92123136 bytes, 179928 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/loop2: 87.9 MiB, 92114944 bytes, 179912 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sda: 1.8 TiB, 2000398934016 bytes, 3907029168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sdb: 1.8 TiB, 2000398934016 bytes, 3907029168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sdc: 111.8 GiB, 120040980480 bytes, 234455040 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 0A3C7F5C-709D-4224-8C2A-9ADE267784C9
Device Start End Sectors Size Type
/dev/sdc1 2048 1050623 1048576 512M EFI System
/dev/sdc2 1050624 234452991 233402368 111.3G Linux filesystem
Disk /dev/md0: 1.8 TiB, 2000263643136 bytes, 3906764928 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
I tried:
ext4magic /dev/md0 -a $(date -d "-24hours" +%s) -f /srv/SCRIPTS -l
and I got
Filesystem in use: /dev/md0
Using internal Journal at Inode 8
Activ Time after : Thu Nov 15 11:17:17 2018
Activ Time before : Fri Nov 16 11:17:17 2018
Error: Inode not found for "/srv/SCRIPTS"
Check the valid PATHNAME "/srv/SCRIPTS" and the BEFORE option "Fri Nov 16 11:17:17 2018"
ext4magic : EXIT_SUCCESS
root@anastasia:/srv/SCRIPTS#
How to get INODE of a file which i don'have?
extundelete
extundelete
New contributor
New contributor
edited 2 days ago
Mr Shunz
2,99311822
2,99311822
New contributor
asked 2 days ago
Luca
1
1
New contributor
New contributor
So why don't you have a backup of backup.sh anyway? If you remember some of the contents of this file,strings -w /dev/md0 | grep -F 'cool stuff' -C 100
or just write it again, things usually turn out better for a rewrite.
– frostschutz
2 days ago
add a comment |
So why don't you have a backup of backup.sh anyway? If you remember some of the contents of this file,strings -w /dev/md0 | grep -F 'cool stuff' -C 100
or just write it again, things usually turn out better for a rewrite.
– frostschutz
2 days ago
So why don't you have a backup of backup.sh anyway? If you remember some of the contents of this file,
strings -w /dev/md0 | grep -F 'cool stuff' -C 100
or just write it again, things usually turn out better for a rewrite.– frostschutz
2 days ago
So why don't you have a backup of backup.sh anyway? If you remember some of the contents of this file,
strings -w /dev/md0 | grep -F 'cool stuff' -C 100
or just write it again, things usually turn out better for a rewrite.– frostschutz
2 days ago
add a comment |
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Luca is a new contributor. Be nice, and check out our Code of Conduct.
Luca is a new contributor. Be nice, and check out our Code of Conduct.
Luca is a new contributor. Be nice, and check out our Code of Conduct.
Luca is a new contributor. Be nice, and check out our Code of Conduct.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f482132%2fext4magic-recover-rm-deleted-file-on-ubuntu-18-04-server-dev-md0-raid%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
So why don't you have a backup of backup.sh anyway? If you remember some of the contents of this file,
strings -w /dev/md0 | grep -F 'cool stuff' -C 100
or just write it again, things usually turn out better for a rewrite.– frostschutz
2 days ago