LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
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


Reply
  Search this Thread
Old 05-14-2016, 08:01 PM   #1
greenace92
Member
 
Registered: Nov 2015
Posts: 70

Rep: Reputation: Disabled
Transferring files from Linux to Windows, flashdrive usually ends up being corrupted


I'm just wondering why this might be happening. I was transferring files from a phone to Linux computer to flash drive to windows computer and usually the drive ends up being broken, having to be "repaired" in Windows and then the files I transferred don't work.

Why might that be happening?

I hit the eject button in my file manager, and the drive doesn't say any warnings and when I remove it I get an error message.

Any thoughts? I'm using Debian LXDE with pcmanfm for file manager.
 
Old 05-15-2016, 02:31 AM   #2
alor23
LQ Newbie
 
Registered: May 2016
Posts: 7

Rep: Reputation: Disabled
I think that you can format the flash deive in FAT32 format, using windows operating system, and after that use it for transforming file between Linux and windows. Hope that it'll work.
 
Old 05-15-2016, 08:56 AM   #3
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 4,654

Rep: Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255Reputation: 1255
One problem I've run across with some USB flash drives is that they don't necessarily tell you when they are busy.

I've had no trouble with those that have an activity light - you just have to wait until the light goes out to know you can remove it.

The filesystem used on the device makes a difference too - don't use NTFS or most of the linux native filesystems. Both of these keep state in memory for the purpose of maintaining throughput, but doing that also allows the activity light to go out. With the Linux native filesystems, a dismount will force the state to the device. Unfortunately, some devices will turn out the light when the transfer is finished, not when the device has finished re-writing changed blocks.

Unplugging at that time can cause corruption.

The advantage FAT/FAT32 has is that no state is maintained in memory, and if you wait a couple of seconds after closing the updates and the light goes out the device SHOULD be clean.

For those with no activity light... wait another 5-10 seconds and it should have finished the updates and any internal activity as well.

As always, be sure the device is dismounted before removing it.

Last edited by jpollard; 05-15-2016 at 08:58 AM.
 
Old 05-15-2016, 11:31 PM   #4
sgosnell
Senior Member
 
Registered: Jan 2008
Location: Baja Oklahoma
Distribution: Debian
Posts: 1,054

Rep: Reputation: 276Reputation: 276Reputation: 276
Slightly off topic, maybe, but you're doing this in the most convoluted way possible. To transfer files from an Android phone to any computer, use Airdroid. It's in the Google Play Store, and you install it on your phone, run it, and it will give you a URL, something like 192.168.1.45:8888. Put that URL into the address window of your browser, any browser, on any OS, and it will connect to your phone. You can transfer files in either direction, plus do lots of other things with your phone. No need for wires, flash drives, or anything else. You do need them both connected to the same network, of course.
 
Old 05-16-2016, 12:26 AM   #5
notKlaatu
Member
 
Registered: Sep 2010
Location: Wellington, New Zealand
Distribution: Slackware, Fedora
Posts: 921

Rep: Reputation: 585Reputation: 585Reputation: 585Reputation: 585Reputation: 585Reputation: 585
Two thoughts:

1. before unmounting the drive, use the <pre>sync</pre> command.

2. don't use FAT. Try UDF (the universal disk format) or exfat (Microsoft's proprietary but cross-platform and updated FAT)
 
Old 05-17-2016, 06:03 PM   #6
RockDoctor
Senior Member
 
Registered: Nov 2003
Location: Minnesota, US
Distribution: Fedora, Linux Mint, Ubuntu
Posts: 1,514

Rep: Reputation: 326Reputation: 326Reputation: 326Reputation: 326
Another vote for Airdroid. A $1 micro-USB to USB cable works well for me, too, but requires the presence of the appropriate drivers on any computer to which I am transferring data.
 
Old 05-17-2016, 10:25 PM   #7
mostlyharmless
Senior Member
 
Registered: Jan 2008
Distribution: Arch/Slackware/Knoppix
Posts: 1,766
Blog Entries: 14

Rep: Reputation: 269Reputation: 269Reputation: 269
You didn't mention he Windows version or age of the Windows computer. Some
XP era computers, running XP, have SDcard drives that really don't work well, particularly for larger ( > 1GB for that era) cards.
 
Old 05-18-2016, 04:47 PM   #8
ondoho
Senior Member
 
Registered: Dec 2013
Posts: 4,658

Rep: Reputation: 985Reputation: 985Reputation: 985Reputation: 985Reputation: 985Reputation: 985Reputation: 985Reputation: 985
do NOT "repair" the flash drive when windows asks for it.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Transferring Files from Linux to Windows bigmac15 Linux - Newbie 8 06-14-2011 10:23 PM
transferring files to from Windows machine to Linux bbb125 Linux - Newbie 21 08-17-2010 07:51 AM
Transferring files corrupted while doing multiple activities? SentralOrigin Linux - General 3 05-10-2009 04:12 PM
Transferring files from Linux onto Windows paragkalra Linux - Networking 1 08-08-2008 04:56 AM
Transferring Files from linux to windows on floppys? rverlander Linux - General 6 06-23-2002 01:45 AM


All times are GMT -5. The time now is 07:32 AM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration