check for bad blocks on a hard drive:
badblocks -vv /dev/sda3 > badblocks.log &
The command above will check for badblocks on the partition /dev/sda3 and save the results to the log file badblocks.log
checks for badblocks and it writes the results to: badblocks.log
If you want to check a specific drive or partition you should run:
fdisk -l|awk ‘{print $1}’|grep “/”
This command will provide you with a list of partitions on your system that you can check.