Tag Info

Hot answers tagged

2

"ICRC error" means that data was corrupted during the transfer; given the age of your drive, the most likely cause is a bad cable. All told the possible causes seem to be: a bad cable (try re-seating your cable, and changing it if that doesn't fix things); a bad chipset (unlikely if your motherboard isn't very old); a bad drive. If you get to the last ...


2

I'm not sure that you can get all of this information from the ext4 driver, because it does not responsible for the disk sectors and other disk geometry, but block device layer sub-sytem in the Linux kernel. I don't see one way to get all information in which you are interesting, because as I see you are in teresting as in low-level stuff and also in high ...


1

Your question is unclear. If you want raw disk I/O profiling (then file system is irrelevant, and you want also to measure swap disk IO) you might have to configure or patch the kernel (I don't know how). Perhaps running Linux thru an hypervisor (like xen) might help. Look also into oprofile On the other hand, if you are interested by file system activity, ...


1

GETGEO returns bios drive geometry, which is obsolete. IDENTITY returns the raw ATA device identification sector. You shouldn't use either one. Instead, simply read from the files /sys/block/sda/size and /sys/block/sda/queue/hw_sector_size. The former gives the size in "sectors" as if the sector size were 512 bytes, even if it isn't, and the latter gives the ...


1

Testdisk helped me more than once. It will search for filesystem and/or files. Give it a try: http://www.cgsecurity.org/wiki/TestDisk


1

As @fd0 has pointed out, change the pass value to 2 Why? Answer: pass – A number indicating the order in which the fsck program will check the devices for errors at boot time; this is 1 for the root file system and either 2 (meaning check after root) or 0 (do not check) for all other devices.


1

You cannot sync(2) a device, and that does not have any sense. You are syncing a file system (not the device mounting it) with syncfs or the entire page cache with sync. The sync(2) syscall is called by the sync(1) command. (I don't know of any usual command doing a syncfs) However, you could flush the buffers for a file system by using the Linux ...


1

I understand, there are no files you want to keep. To be sure, you are working on the right harddisk run lsblk to list all connected drives. I would use wipefs on it first: wipefs -a /dev/sdb1 and wipefs -a /dev/sdb Then start gdisk /dev/sdb and press x and then z to wipe the mbr and gpt. Maybe zero the first megabytes: dd if=/dev/zero of=/dev/sdb ...


1

You can zero-fill the drive with dd if=/dev/zero of=/dev/sdb bs=1M Make sure /dev/sdb is actually the correct device name!


1

You need kernel level tracing to achieve that. There is a large number of tools available to do it with various levels of features, usability and stability including sysdig, ftrace, perf, dtrace4linux, ktap, systemtap and others. You might start with tpoint which, being based on ftrace, shouldn't need anything to be installed (outside the script itself), ...


1

Might be a bit overkill, but SystemTap could help you identify what process is doing i/o on that disk. Prepare SystemTap [root@localhost ~]# stap-prep snip Install trace script [root@localhost ~]# cat >/tmp/traceio2.stp #! /usr/bin/env stap global device_of_interest probe begin { /* The following is not the most efficient way to do this. One ...


1

Had the same problem: Disk that is about to die, with NTFS partition that I wanted to rescue first and fix after (before the disk is totally gone). Was able to resolve it with ntfsclone: Connect the two disks - old and new Boot with Live-Linux from USB (can use Parted Magic for that as well) Create a big-enough partition on the new disk (use gparted for ...


1

http://lxr.free-electrons.com/source/drivers/ata/libata-core.c?v=3.5#L1987 The code makes a call to ata_dev_set_feature(dev, SETFEATURES_SPINUP, 0);



Only top voted, non community-wiki answers of a minimum length are eligible