Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place! |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
|
05-04-2017, 11:13 PM
|
#1
|
Senior Member
Registered: Mar 2014
Location: Illinois
Distribution: Xubuntu
Posts: 2,034
Rep:
|
questions about a usb flash drive that might be corrupted
I'm suspecting my flash drive is corrupted. I looked at it in Gparted and indeed there's a warning icon (screenshot 279) but I don't know what it means.
And regarding the same drive (which I use to back up my stuff via Back In Time) I don't understand how the space usage works. (screenshot 278). The size says 22.8 GB. The usage says: 2.9 GB.
Lastly, I heard about using fsck to check the flash drive. When I do (I honestly don't know if I'm doing it right.) all it says is:
util-linux 2.7.1
And I don't know what that means.
Thanks.
|
|
|
05-05-2017, 03:14 AM
|
#2
|
LQ Guru
Registered: Mar 2016
Location: Harrow, UK
Distribution: LFS, AntiX, Slackware
Posts: 8,109
|
Apparently you need to run the Windows chkdsk on this to clear the error.
Quote:
Originally Posted by AskUbuntu
An exclamation mark beside a partition means that GParted encountered a problem when reading the partition. With NTFS the most common problem is that Windows was not shut down properly and that the NTFS file system is in an inconsistent state. An inconsistent NTFS file system can be fixed often by just booting into Windows (Windows should automatically run "chkdsk" on the partition) and then using the menu option Start -> Shutdown. If that doesn't work, you can also run "chkdsk /f /r" on the drive letter for the partition from a Windows command prompt and then reboot into Windows twice.
|
|
|
1 members found this post helpful.
|
05-05-2017, 08:02 AM
|
#3
|
LQ Guru
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,170
|
The 'fsck' command is used to do a filesystem check on "Linux" partitions and the partition you are showing is the proprietary microsoft windows "ntfs" so fsck won't do anything and as pointed out above, you need to run chkdsk from windows.
|
|
1 members found this post helpful.
|
05-05-2017, 08:29 AM
|
#4
|
Senior Member
Registered: Dec 2014
Location: Montreal, Quebec and Dartmouth, Nova Scotia CANADA
Distribution: Arch, AntiX, ArtiX
Posts: 1,364
|
Hey Gregg,
There's not necessarily anything wrong with your USB drive. You would have to look at the partition information in GParted to confirm what the warning icon is saying in your particular case. It may just be that you don't have ntfs functionality installed on your linux box.
If it does indeed turn out to be a corrupted file system issue, yancek and hazel are correct in saying that this has to be addressed in Windows using chkdsk (eventually with the /f switch to repair).
Finally, although I'm unfamiliar with the Back In Time application, backup software often applies proprietary compression algorithms when backing up files and achieves significant compression ratios. So it is not impossible that 22 GB of normal space usage would be reduced to 3 GB of actual used space on the backup media. I personally no longer use that type of backup system, since it requires the same application to retrieve backed up files in case of need. With storage space so inexpensive nowadays, I prefer straight-copy solutions.
Cheers, Gregg !
|
|
1 members found this post helpful.
|
05-05-2017, 09:59 AM
|
#5
|
LQ Guru
Registered: Nov 2008
Location: Pictland
Distribution: Linux Mint 21 MATE
Posts: 8,048
|
In order to check that disk, you should boot up into a Windows operating system and run chkdsk.
If you don't have such an operating system handy (even as a Virtual Machine or as part of a Windows install/rescue disk), then one possibility is to create a Windows PE boot media and boot up off that.
You can get a ready-made ISO of one of these, Gandalf's Windows 10 PE, at http://windowsmatters.com/category/windows-pes/. It's a hefty download, 4.3GB, but contains more Windows system tools than you can shake a stick at. Personally, I just boot off my Macrium Reflect ISO (which I use for imaging my partitions and which boots up in a Windows PE environment) and use chkdsk from that.
|
|
1 members found this post helpful.
|
05-05-2017, 01:20 PM
|
#6
|
Senior Member
Registered: Mar 2014
Location: Illinois
Distribution: Xubuntu
Posts: 2,034
Original Poster
Rep:
|
Quote:
Originally Posted by hazel
Apparently you need to run the Windows chkdsk on this to clear the error.
|
Thanks hazel. Before I try that (and when I run the chkdsk on Windows will I lose the data that's on there?) I found some info (per Rick's suggestion) which says I might need some software packages. I just figured I'd post it in case it changed the situation.
|
|
|
05-05-2017, 01:21 PM
|
#7
|
Senior Member
Registered: Mar 2014
Location: Illinois
Distribution: Xubuntu
Posts: 2,034
Original Poster
Rep:
|
Quote:
Originally Posted by yancek
The 'fsck' command is used to do a filesystem check on "Linux" partitions and the partition you are showing is the proprietary microsoft windows "ntfs" so fsck won't do anything and as pointed out above, you need to run chkdsk from windows.
|
Thanks yancek
|
|
|
05-05-2017, 01:28 PM
|
#8
|
LQ Guru
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,170
|
The Linux programs you refer to in the image in your last post (ntfs-3g, ntfsprogs) will allow you to read/write to a windows partition. It won't do anything to repair any windows filesystem. There is Linux software, ntfsfix which might repair very minor problems on a windows filesystem but to repair a corrupted windows filesystem you will almost always need to use chkdsk from windows.
|
|
1 members found this post helpful.
|
05-05-2017, 01:30 PM
|
#9
|
Senior Member
Registered: Mar 2014
Location: Illinois
Distribution: Xubuntu
Posts: 2,034
Original Poster
Rep:
|
Quote:
Originally Posted by Rickkkk
Hey Gregg,
There's not necessarily anything wrong with your USB drive. You would have to look at the partition information in GParted to confirm what the warning icon is saying in your particular case. It may just be that you don't have ntfs functionality installed on your linux box.
If it does indeed turn out to be a corrupted file system issue, yancek and hazel are correct in saying that this has to be addressed in Windows using chkdsk (eventually with the /f switch to repair).
Finally, although I'm unfamiliar with the Back In Time application, backup software often applies proprietary compression algorithms when backing up files and achieves significant compression ratios. So it is not impossible that 22 GB of normal space usage would be reduced to 3 GB of actual used space on the backup media. I personally no longer use that type of backup system, since it requires the same application to retrieve backed up files in case of need. With storage space so inexpensive nowadays, I prefer straight-copy solutions.
Cheers, Gregg !
|
Thanks Rick. I think I found the information you were talking about (screenhot). Does that change things at all or still run the Windows chkdsk?
And I have been using that pendrive for over a year and never had a problem with it including with BackInTime. (There's another post here with details: https://www.linuxquestions.org/quest...up-4175604826/ )
I always thought NTFS was the most sensible format for pendrives because it worked on Ubuntu and Windows. Is there a better format for doing that?
And I thought BackInTime was great, but obviously that 32 GB drive has enough room (and I do have a new 64GB pendrive too) to handle a direct copy situation, but what's the best way of doing that? (I should probably post on that.)
Thanks for the explanation about the compression.
|
|
|
05-05-2017, 01:33 PM
|
#10
|
LQ Guru
Registered: Nov 2008
Location: Pictland
Distribution: Linux Mint 21 MATE
Posts: 8,048
|
Gregg, can you paste the output from dpkg -l '*ntfs*' please.
|
|
1 members found this post helpful.
|
05-05-2017, 01:47 PM
|
#11
|
Senior Member
Registered: Mar 2014
Location: Illinois
Distribution: Xubuntu
Posts: 2,034
Original Poster
Rep:
|
Quote:
Originally Posted by yancek
The Linux programs you refer to in the image in your last post (ntfs-3g, ntfsprogs) will allow you to read/write to a windows partition. It won't do anything to repair any windows filesystem. There is Linux software, ntfsfix which might repair very minor problems on a windows filesystem but to repair a corrupted windows filesystem you will almost always need to use chkdsk from windows.
|
Thanks yancek. I ran the chkdsk and the 'scan and repair' and it fixed it. Thanks. Not sure what you meant by:
Quote:
The Linux programs you refer to in the image in your last post (ntfs-3g, ntfsprogs) will allow you to read/write to a windows partition.
|
Isn't NTFS a windows partition? (And I've been reading and writing to it all along.)
|
|
|
05-05-2017, 01:51 PM
|
#12
|
Senior Member
Registered: Mar 2014
Location: Illinois
Distribution: Xubuntu
Posts: 2,034
Original Poster
Rep:
|
Quote:
Originally Posted by hydrurga
Gregg, can you paste the output from dpkg -l '*ntfs*' please.
|
Thanks hydrurga. The chkdsk fixed the pen drive. Here's the results of your command:
Code:
gregory@gregory-GA-A55M-DS2:~/Desktop$ dpkg -l '*ntfs*'
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name Version Architecture Description
+++-=======================================-========================-========================-===================================================================================
un libntfs-3g861 <none> <none> (no description available)
ii ntfs-3g 1:2015.3.14AR.1-1ubuntu0 amd64 read/write NTFS driver for FUSE
gregory@gregory-GA-A55M-DS2:~/Desktop$
And I'm wondering why I had the problem with the pen drive in the first place.
I don't understand that Windows' PE site but it looks amazing!
|
|
|
05-05-2017, 01:57 PM
|
#13
|
LQ Guru
Registered: Nov 2008
Location: Pictland
Distribution: Linux Mint 21 MATE
Posts: 8,048
|
Ah, all is good. Thanks, Gregg. The ntfs-3g package should be auto installed in Ubuntu to allow you to talk to NTFS filesystems - I just wanted to check that this was the case and that nothing was awry. Don't worry about the ntfprogs package, it was superseded by ntfs-3g.
I'm glad all worked out ok!
|
|
1 members found this post helpful.
|
05-05-2017, 02:00 PM
|
#14
|
Senior Member
Registered: Mar 2014
Location: Illinois
Distribution: Xubuntu
Posts: 2,034
Original Poster
Rep:
|
Quote:
Originally Posted by hydrurga
Ah, all is good. Thanks, Gregg. The ntfs-3g package should be auto installed in Ubuntu to allow you to talk to NTFS filesystems - I just wanted to check that this was the case and that nothing was awry. Don't worry about the ntfprogs package, it was superseded by ntfs-3g.
I'm glad all worked out ok!
|
Awesome! Thanks for the check and thanks everyone for the help!
|
|
|
05-05-2017, 07:10 PM
|
#15
|
LQ Guru
Registered: Apr 2008
Distribution: Slackware, Ubuntu, PCLinux,
Posts: 11,170
|
Quote:
Isn't NTFS a windows partition? (And I've been reading and writing to it all along.)
|
Yes, that's true but your initial post indicated a problem with the windows ntfs filesystem on the flash drive partition and my understanding was that you posted because you were having problems with it. To fix that, you need to do it in windows which you say you did and in all likelihood, the ntfs-3g and ntfsprogs were already installed. In any case, the purpose of that sofware is to allow read/write to ntfs and would do nothing to resolve a corrupted filesystem. Glad you got it working.
Last edited by yancek; 05-05-2017 at 07:17 PM.
|
|
1 members found this post helpful.
|
All times are GMT -5. The time now is 12:03 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|