LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 12-30-2022, 10:15 AM   #1
grumpyskeptic
Member
 
Registered: Apr 2016
Posts: 483

Rep: Reputation: Disabled
How to check that a new external USB hard drive does not have any hardware disk faults?


Using Linux Mint 20.2 Uma, with a desktop computer.

I have bought a new external hard drive, which connects via USB. Before starting to use it to backup data I would like to check that there are not any physical faults in the physical disk media, so that I can return it and get a refund if it has. Even though the chance may be low, I would still like to check.

I would have expected to use "SMART data & self tests" in the menu of the Disks application, but that is greyed out and not available. The HD has been plugged in to the computer for the past two or three hours. The option to "benchmark disk" is available, but that is not what I want.

My question: is there another easy way to check/scan the external HD for physical errors?

Thanks.
 
Old 12-30-2022, 10:27 AM   #2
jailbait
LQ Guru
 
Registered: Feb 2003
Location: Virginia, USA
Distribution: Debian 12
Posts: 8,346

Rep: Reputation: 552Reputation: 552Reputation: 552Reputation: 552Reputation: 552Reputation: 552
Quote:
Originally Posted by grumpyskeptic View Post
Using Linux Mint 20.2 Uma, with a desktop computer.

I have bought a new external hard drive, which connects via USB. Before starting to use it to backup data I would like to check that there are not any physical faults in the physical disk media, so that I can return it and get a refund if it has. Even though the chance may be low, I would still like to check.

I would have expected to use "SMART data & self tests" in the menu of the Disks application, but that is greyed out and not available. The HD has been plugged in to the computer for the past two or three hours. The option to "benchmark disk" is available, but that is not what I want.

My question: is there another easy way to check/scan the external HD for physical errors?

Thanks.
1. Some unscrupulous dealers (Chinese) will format a hard drive with a false partition table that shows the advertised size rather than the actual size of the hard drive. To check this possibility format the file system. Then use gparted or something similar to make sure that the amount of space on the hard drive is equal to the advertised size of the hard drive.

2. Set up a loop to copy a large file over and over to the hard drive under different names until the hard drive is full. Check it with gparted again.

3. Set up a loop to copy all of the files on the hard drive to the bit bucket.

4. Format the hard drive again to get rid of all of the garbage. Check it with gparted again.

Last edited by jailbait; 12-30-2022 at 10:34 AM.
 
Old 12-30-2022, 10:48 AM   #3
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,797

Rep: Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002
Quote:
Originally Posted by grumpyskeptic View Post
Using Linux Mint 20.2 Uma, with a desktop computer.
I have bought a new external hard drive, which connects via USB. Before starting to use it to backup data I would like to check that there are not any physical faults in the physical disk media, so that I can return it and get a refund if it has. Even though the chance may be low, I would still like to check.

I would have expected to use "SMART data & self tests" in the menu of the Disks application, but that is greyed out and not available. The HD has been plugged in to the computer for the past two or three hours. The option to "benchmark disk" is available, but that is not what I want. My question: is there another easy way to check/scan the external HD for physical errors?
Not through a USB enclosure. Plug it directly in to your motherboard, and you should be able run the SMART tests.
 
Old 12-30-2022, 11:14 AM   #4
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,813

Rep: Reputation: 5958Reputation: 5958Reputation: 5958Reputation: 5958Reputation: 5958Reputation: 5958Reputation: 5958Reputation: 5958Reputation: 5958Reputation: 5958Reputation: 5958
Depending on manufacture the USB SATA bridge on modern USB external drives is soldered to the drive's electronics and not possible to plug it into a motherboard like a typical desktop drive. Some USB bridges are now supported by smartctl so you can try it from the command line and see what happens.
 
Old 12-30-2022, 11:52 AM   #5
beachboy2
Senior Member
 
Registered: Jan 2007
Location: Wild West Wales, UK
Distribution: Linux Mint 21 MATE, EndeavourOS, antiX, MX Linux
Posts: 4,011
Blog Entries: 33

Rep: Reputation: 1471Reputation: 1471Reputation: 1471Reputation: 1471Reputation: 1471Reputation: 1471Reputation: 1471Reputation: 1471Reputation: 1471Reputation: 1471
grumpyskeptic,

Your external drive should be shown under Disks.

What is showing for Mode, Assessment and Size?

Did you actually install SMART?

Code:
sudo apt install gsmartcontrol smartmontools
Find the name of your external drive (NOT sda) which may be sdb or sdc etc.

Let's call it sdc.

To run an Extended test (about 55 minutes):

Code:
sudo smartctl -t long /dev/sdc

To display output (after 55 mins or so):

Code:
sudo smartctl -a /dev/sdc
 
Old 12-30-2022, 11:54 AM   #6
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,797

Rep: Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002
Quote:
Originally Posted by michaelk View Post
Depending on manufacture the USB SATA bridge on modern USB external drives is soldered to the drive's electronics and not possible to plug it into a motherboard like a typical desktop drive. Some USB bridges are now supported by smartctl so you can try it from the command line and see what happens.
Quite true. I'd bet, though, that it's just a SATA drive plugged in to a bridge adapter, and you can just unplug it from the enclosure.
 
Old 12-31-2022, 06:07 AM   #7
Arnulf
Member
 
Registered: Jan 2022
Location: Hanover, Germany
Distribution: Slackware
Posts: 276

Rep: Reputation: 89
Quote:
Originally Posted by grumpyskeptic View Post
I have bought a new external hard drive, which connects via USB.
[…]
My question: is there another easy way to check/scan the external HD for physical errors?
Depending on drive's capacity, test described below will take a long time, e. g. > 1 d for a 4 TB drive. Therefore use your second computer for this test if possible. USB 3.0 or higher is highly recommend.
  1. Unplug all other SSDs/HDDs from the system. Your plugged new USB drive will become /dev/sda
  2. Start a recent live Linux, e.g. Knoppix or grml, without GUI (Knoppix command line for start without GUI: knoppix64 2 noswap)
  3. Run on console: badblocks -wsv /dev/sda    # This do a read-write test and wipes all data incl. any partition tables on /dev/sda.
  4. If badblocks throws errors return this drive. Otherwise …
  5. … run fdisk or another partitioning tool and create desired partitions and filesystems.
 
Old 01-04-2023, 06:24 AM   #8
grumpyskeptic
Member
 
Registered: Apr 2016
Posts: 483

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by beachboy2 View Post
Your external drive should be shown under Disks.

What is showing for Mode, Assessment and Size?
I cannot find Mode, Assessment, or Size within Disks 3.38.2, not even for my internal HD. Where would I find them please?


Quote:
Originally Posted by beachboy2 View Post
Did you actually install SMART?
"SMART Data & Self Tests" is an entry in the Disks menu, so I assume SMART is installed. It is greyed-out for the external HD, only available for the internal HD.

It seems the answer probably is that there is no easy way to check the external HD.

Thanks to all replies.
 
1 members found this post helpful.
Old 01-04-2023, 08:05 AM   #9
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,797

Rep: Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002
Quote:
Originally Posted by grumpyskeptic View Post
I cannot find Mode, Assessment, or Size within Disks 3.38.2, not even for my internal HD. Where would I find them please?
In the gsmartcontrol package, as you were advised to load. Did you??
Quote:
"SMART Data & Self Tests" is an entry in the Disks menu, so I assume SMART is installed. It is greyed-out for the external HD, only available for the internal HD. It seems the answer probably is that there is no easy way to check the external HD.
Aside from (as suggested) opening the USB enclosure and looking at what's in there. Because there are three options:
  1. Hard-drive soldered to the wiring
  2. Hard drive plugged in to a USB adapter (good chance)
  3. Cheap knock-off, and you bought a USB flash drive in a case
meaning:
  • Cannot test further
  • Can easily test by plugging it in
  • Cannot test further, but no need, since you should return it.
 
Old 01-05-2023, 11:11 AM   #10
grumpyskeptic
Member
 
Registered: Apr 2016
Posts: 483

Original Poster
Rep: Reputation: Disabled
I now realise that Assessment is one of the "SMART Data & Self Test" spreadsheet columns in Disks.

I did install GSmartControl. For the external HD it says "Unknown model", "SMART status: Unsupported".

On the other hand Disks gives the correct model and size for it, but the "SMART Data & Self Test" in the Disks menu is greyed out and unusable.

Last edited by grumpyskeptic; 01-05-2023 at 12:27 PM.
 
Old 01-05-2023, 12:31 PM   #11
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,797

Rep: Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002Reputation: 8002
Quote:
Originally Posted by grumpyskeptic View Post
I now realise that Assessment is one of the "SMART Data & Self Test" spreadsheet columns in Disks.

I did install GSmartControl. For the external HD it says "Unknown model", "SMART status: Unsupported".

On the other hand Disks gives the correct model and size for it, but the "SMART Data & Self Test" in the Disks menu is greyed out and unusable.
...which takes us full-circle, back to "open up the USB enclosure and proceed from there".

It will *STILL* fall in one of the three options previously given to you. Until you do something and look, not sure what else you think can be done. Smart is telling you, explicitly, that it cannot perform diagnostics via that USB adapter. So either you can remove it from the equation or not, and you won't know until you look.
 
Old 01-05-2023, 02:05 PM   #12
Arnulf
Member
 
Registered: Jan 2022
Location: Hanover, Germany
Distribution: Slackware
Posts: 276

Rep: Reputation: 89
Quote:
Originally Posted by grumpyskeptic View Post
I did install GSmartControl. For the external HD it says "Unknown model", "SMART status: Unsupported".

Rule of thumb: SMART doesn't work over USB.
 
  


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
Installing Linux Mint 19.1 cinnamon to an external hard drive & backing up to another external hard drive. bluelakecompany@yahoo.co Linux - Newbie 1 01-23-2019 06:30 PM
Which External Hard disk 1 TB suitable to transfer or copy file from Linux Fedora 8 OS ? The following External Hard Disk wil be suitable RAJIB BNG Linux - Hardware 2 09-23-2017 02:12 AM
ubuntu installed on external hard drive, can't startup without external hard drive. Vanostaajen Linux - Software 23 01-20-2009 09:59 AM
external enclosure for an internal hard drive vs external USB hard drive powah Linux - Hardware 1 03-10-2006 09:03 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 01:41 PM.

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