Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

Storage disk suddenly empty!-(SOLVED)

If none of the specific sub-forums seem right for your thread, ask here.
Post Reply
Message
Author
tsathoguah
Posts: 31
Joined: 2014-09-07 10:10

Storage disk suddenly empty!-(SOLVED)

#1 Post by tsathoguah »

Guys, i'm facing a massive problem. Suddenly, after playing with mount/umount, ran from a script, my storage (sdc5) disk shows up empy (1TB).Here's what fdisk -l returns:

Code: Select all

root@debian:/home/dagon# fdisk -l

Disk /dev/sda: 750.2 GB, 750156374016 bytes
255 heads, 63 sectors/track, 91201 cylinders, total 1465149168 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 identifier: 0x0009daf8

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *          63   145934459    72967198+   7  HPFS/NTFS/exFAT
/dev/sda2       145934521  1465144064   659604772    5  Extended
/dev/sda5       145934523   250806779    52436128+   7  HPFS/NTFS/exFAT
/dev/sda6       250806843  1465144064   607168611    7  HPFS/NTFS/exFAT

Disk /dev/sdc: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders, total 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
Disk identifier: 0x029e6350

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1           16065  1953520064   976752000    f  W95 Ext'd (LBA)
Partition 1 does not start on physical sector boundary.
/dev/sdc5           16128  1953520064   976751968+   7  HPFS/NTFS/exFAT

Disk /dev/sdb: 640.1 GB, 640135028736 bytes
255 heads, 63 sectors/track, 77825 cylinders, total 1250263728 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 identifier: 0x0a3e7090

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1            2048  1250256895   625127424   83  Linux
Here's the mounting script i ran:

Code: Select all

#!/bin/bash
cd /home/dagon/Files/
mkdir Partitions
cd ./Partitions
mkdir Windows Games Temp Storage
mount /dev/sda1 /home/dagon/Files/Partitions/Windows/
mount /dev/sda5 /home/dagon/Files/Partitions/Games/
mount /dev/sda6 /home/dagon/Files/Partitions/Temp/
mount /dev/sdc5 /home/dagon/Files/Partitions/Storage/
echo 'Disks are mounted!'
followed by the umounting one:

Code: Select all

#!/bin/bash
umount /dev/sda1
umount /dev/sda5
umount /dev/sda6 
umount /dev/sdc5 
rm -r /home/dagon/Files/Partitions
echo 'Disks are un-mounted!'
My storage disk (sdc-sdc5), and only that was affected
I'm under the impression that i did nothing wrong...What the h3ll is goin' on here?Perchance,disk is done for.
Is there any way to recover my data (close to 1 terra...)?
I apologise,beforehand,for i am at a loss.
Last edited by tsathoguah on 2014-11-21 00:49, edited 2 times in total.

User avatar
kiyop
Posts: 3983
Joined: 2011-05-05 15:16
Location: Where persons without desire to improve themselves fear to tread, in Japan
Been thanked: 3 times

Re: Storage disk suddently empty!

#2 Post by kiyop »

Execute the following with root privilege and post the results.

Code: Select all

blkid /dev/sdc5
df |grep sdc5
Are you sure that /dev/sdc5 is mounted correctly?
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/

tsathoguah
Posts: 31
Joined: 2014-09-07 10:10

Re: Storage disk suddenly empty!

#3 Post by tsathoguah »

First of all, i've tried both manually (via terminal) and automatically (via nautilus window manager) to mount that said disk. Both ways worked fine a few hours ago.Same results are given at windows 7...disk is empy apart from a few kb of folders.

blkid /dev/sdc:

Code: Select all

root@debian:/home/dagon# blkid /dev/sdc5
/dev/sdc5: LABEL="Storage" UUID="01CFE7D2AE09F3F0" TYPE="ntfs"

Code: Select all

df |grep sdc5:
root@debian:/home/dagon# df |grep sdc5
/dev/sdc5                                              976751968   133840 976618128   1% /media/Storage
Some additional info (using smartmontools,could help):

Code: Select all

root@debian:/home/dagon# smartctl -i /dev/sdc
smartctl 5.41 2011-06-09 r3365 [x86_64-linux-3.2.0-4-amd64] (local build)
Copyright (C) 2002-11 by Bruce Allen, http://smartmontools.sourceforge.net

=== START OF INFORMATION SECTION ===
Device Model:     TOSHIBA DT01ACA100
Serial Number:    743GWMSMS
LU WWN Device Id: 5 000039 ffbd4dc72
Firmware Version: MS2OA750
User Capacity:    1,000,204,886,016 bytes [1.00 TB]
Sector Sizes:     512 bytes logical, 4096 bytes physical
Device is:        Not in smartctl database [for details use: -P showall]
ATA Version is:   8
ATA Standard is:  ATA-8-ACS revision 4
Local Time is:    Thu Nov 20 19:35:46 2014 EST
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

Code: Select all

root@debian:/home/dagon# smartctl -a /dev/sdc
smartctl 5.41 2011-06-09 r3365 [x86_64-linux-3.2.0-4-amd64] (local build)
Copyright (C) 2002-11 by Bruce Allen, http://smartmontools.sourceforge.net

=== START OF INFORMATION SECTION ===
Device Model:     TOSHIBA DT01ACA100
Serial Number:    743GWMSMS
LU WWN Device Id: 5 000039 ffbd4dc72
Firmware Version: MS2OA750
User Capacity:    1,000,204,886,016 bytes [1.00 TB]
Sector Sizes:     512 bytes logical, 4096 bytes physical
Device is:        Not in smartctl database [for details use: -P showall]
ATA Version is:   8
ATA Standard is:  ATA-8-ACS revision 4
Local Time is:    Thu Nov 20 19:39:32 2014 EST
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED

General SMART Values:
Offline data collection status:  (0x80)	Offline data collection activity
					was never started.
					Auto Offline Data Collection: Enabled.
Self-test execution status:      (   0)	The previous self-test routine completed
					without error or no self-test has ever 
					been run.
Total time to complete Offline 
data collection: 		( 7410) seconds.
Offline data collection
capabilities: 			 (0x5b) SMART execute Offline immediate.
					Auto Offline data collection on/off support.
					Suspend Offline collection upon new
					command.
					Offline surface scan supported.
					Self-test supported.
					No Conveyance Self-test supported.
					Selective Self-test supported.
SMART capabilities:            (0x0003)	Saves SMART data before entering
					power-saving mode.
					Supports SMART auto save timer.
Error logging capability:        (0x01)	Error logging supported.
					General Purpose Logging supported.
Short self-test routine 
recommended polling time: 	 (   1) minutes.
Extended self-test routine
recommended polling time: 	 ( 124) minutes.
SCT capabilities: 	       (0x003d)	SCT Status supported.
					SCT Error Recovery Control supported.
					SCT Feature Control supported.
					SCT Data Table supported.

SMART Attributes Data Structure revision number: 16
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  1 Raw_Read_Error_Rate     0x000b   100   100   016    Pre-fail  Always       -       0
  2 Throughput_Performance  0x0005   142   142   054    Pre-fail  Offline      -       70
  3 Spin_Up_Time            0x0007   127   127   024    Pre-fail  Always       -       180 (Average 180)
  4 Start_Stop_Count        0x0012   100   100   000    Old_age   Always       -       195
  5 Reallocated_Sector_Ct   0x0033   100   100   005    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x000b   100   100   067    Pre-fail  Always       -       0
  8 Seek_Time_Performance   0x0005   118   118   020    Pre-fail  Offline      -       33
  9 Power_On_Hours          0x0012   100   100   000    Old_age   Always       -       595
 10 Spin_Retry_Count        0x0013   100   100   060    Pre-fail  Always       -       0
 12 Power_Cycle_Count       0x0032   100   100   000    Old_age   Always       -       54
192 Power-Off_Retract_Count 0x0032   100   100   000    Old_age   Always       -       203
193 Load_Cycle_Count        0x0012   100   100   000    Old_age   Always       -       203
194 Temperature_Celsius     0x0002   176   176   000    Old_age   Always       -       34 (Min/Max 20/43)
196 Reallocated_Event_Count 0x0032   100   100   000    Old_age   Always       -       0
197 Current_Pending_Sector  0x0022   100   100   000    Old_age   Always       -       0
198 Offline_Uncorrectable   0x0008   100   100   000    Old_age   Offline      -       0
199 UDMA_CRC_Error_Count    0x000a   200   200   000    Old_age   Always       -       0

SMART Error Log Version: 1
No Errors Logged

SMART Self-test log structure revision number 1
No self-tests have been logged.  [To run self-tests, use: smartctl -t]


SMART Selective self-test log data structure revision number 1
 SPAN  MIN_LBA  MAX_LBA  CURRENT_TEST_STATUS
    1        0        0  Not_testing
    2        0        0  Not_testing
    3        0        0  Not_testing
    4        0        0  Not_testing
    5        0        0  Not_testing
Selective self-test flags (0x0):
  After scanning selected spans, do NOT read-scan remainder of disk.
If Selective self-test is pending on power-up, resume after 0 minute delay.





On a side note, i keep coming across Testdisk as a possible solution.Should i go for it? At this point i have absolutely nothing to lose!
Last edited by tsathoguah on 2014-11-21 00:52, edited 1 time in total.

divbyzero
Posts: 62
Joined: 2014-11-18 16:20

Re: Storage disk suddently empty!

#4 Post by divbyzero »

if your partition is suddenly cleared testdisk is the way to go - it might just be as easy as repairing the partition table
else you can get your data of it with testdisk

its not the most user-friendly tool but i have used it often in similar cases

User avatar
makh
Posts: 651
Joined: 2011-10-09 09:16

Re: Storage disk suddently empty!

#5 Post by makh »

Your bash script isnt good or for production use.

Add a functionality of confirming the umount(s), ie if not mounted drive(s) then use the danger command rm -r, else the lazy umount would be still much better.

Perhaps testdisk can save your day, use the latest grml. May help you recover.
ThinkPad E14: Arch, Debian Stable
GUI: Xfce

For new: Try MX Linux, Linux Mint; later join Debian Stable

Bulkley
Posts: 6386
Joined: 2006-02-11 18:35
Has thanked: 2 times
Been thanked: 39 times

Re: Storage disk suddently empty!

#6 Post by Bulkley »

If you don't have testdisk try a live-CD; anything that will mount all hardware and let you look at it.

My guess is that your machine is no longer mounting the drive. I hope you didn't mess with the boot sector; that can get difficult to recover.

tsathoguah
Posts: 31
Joined: 2014-09-07 10:10

Re: Storage disk suddenty empty!

#7 Post by tsathoguah »

Ok,recovered a whole bunch of "accidentally" deleted data using testdisk (fairly simple even for retards,such as myself,apparently).Thank you all for your help.

User avatar
kiyop
Posts: 3983
Joined: 2011-05-05 15:16
Location: Where persons without desire to improve themselves fear to tread, in Japan
Been thanked: 3 times

Re: Storage disk suddenly empty!-(SOLVED)

#8 Post by kiyop »

To tsathoguah,

As makh wrote,
makh wrote:Your bash script isnt good or for production use.

Add a functionality of confirming the umount(s), ie if not mounted drive(s) then use the danger command rm -r, else the lazy umount would be still much better.
tsathoguah wrote:followed by the umounting one:

Code: Select all

#!/bin/bash
umount /dev/sda1
umount /dev/sda5
umount /dev/sda6 
umount /dev/sdc5 
rm -r /home/dagon/Files/Partitions
Your script is too dangerous!
If I were you, I would remove the line "rm -r /home/dagon/Files/Partitions".
Otherwise, I would replace the line with the following

Code: Select all

for i in Windows Games Temp Storage;do rmdir /home/dagon/Files/Partitions/$i;done
rmdir /home/dagon/Files/Partitions
Read

Code: Select all

man rmdir
Openbox, JWM: Jessie, Sid, Arch / Win XP (on VirtualBox), 10
http://kiyoandkei.bbs.fc2.com/

Post Reply