Possible to mount a flash drive in Linux/Unix?
Page 1 of 3 123 LastLast
Results 1 to 10 of 27

Thread: Possible to mount a flash drive in Linux/Unix?

  1. #1
    Senior Member genXer's Avatar
    Join Date
    Jun 2005
    Posts
    252

    Possible to mount a flash drive in Linux/Unix?

    Hello all-

    We are trying something out and wanted to share but also ask a couple o'questions. We are working to mount a flash drive to Linux and found the below:

    http://www.extremetech.com/article2/...1256701,00.asp

    And we are working to test it out with our setup.

    Has anyone else gotten a flashdrive, with a Windows format, to be successfully mounted on a Linux box - and can it be read?

    I was thinking that if you have Samba on the machine it would work otherwise, if you just have the driver and the setup per the article, the drive would be recognized, but could not be read - am I right or wrong on this?

    Thanks in advance!
    \"We\'re the middle children of history.... no purpose or place. We have no Great War, no Great Depression. Our great war is a spiritual war. Our great depression is our lives. We\'ve all been raised by television to believe that one day we\'ll all be millionaires and movie gods and rock stars -- but we won\'t. And we\'re learning slowly that fact. And we\'re very, very pissed off.\" - Tyler (Brad Pitt) Fight Club.

  2. #2
    Jaded Network Admin nebulus200's Avatar
    Join Date
    Jun 2002
    Posts
    1,356
    I think flash runs its own file system, just like CD's use their own (i've seen it called alot of different things). I run Fedora Core 3 and it automatically detects the USB drive and mounts it under /media/usbdisk. Tried manually mounting it once but it was a major pain...
    There is only one constant, one universal, it is the only real truth: causality. Action. Reaction. Cause and effect...There is no escape from it, we are forever slaves to it. Our only hope, our only peace is to understand it, to understand the 'why'. 'Why' is what separates us from them, you from me. 'Why' is the only real social power, without it you are powerless.

    (Merovingian - Matrix Reloaded)

  3. #3
    Senior Member
    Join Date
    Sep 2005
    Posts
    221
    Definitions: Hacker vs. Cracker
    Gentoo Linux user, which probably says a lot about me..
    AGA member 14460 || KGS : Trevoke and games archived

  4. #4
    Master-Jedi-Pimps0r & Moderator thehorse13's Avatar
    Join Date
    Dec 2002
    Location
    Washington D.C. area
    Posts
    2,883
    When you say mount, are you speaking at the command line or within some X windows environment? Every recent distro I've tested (fedora, slackware, ubuntu, vector linux) all automatically mount flash drives when sitting in an Xwindows environment.

    The partition type should be automatically seen so there is no issue reading files that were dumped on them from windows and vice versa. If you run into trouble when mounting, you'll have to specify the file system. Also be sure to change the perms so that you can write to the drive. Do this using the umask switch ( -o umask=002 should do it).

    On Fedora, at the CLI, this is what I do to mount it.
    Code:
    mount /dev/sda1 [options] /media/USBdisk
    before you get to this point, you'll see a bunch of SCSI device info wiz by.

    When you're finished, simply do this:
    Code:
    umount /media/USBdisk
    Done.

    And finally, if you want to make this as easy as "mount /media/USBdisk"
    Simply type this at the CLI:
    Code:
    echo "/dev/sda1 /media/USBdisk vfat user,umask=002 0 0" >> /etc/fstab
    then just do:
    Code:
    mount /media/usbdisk
    and you can read/write at will.
    Our scars have the power to remind us that our past was real. -- Hannibal Lecter.
    Talent is God given. Be humble. Fame is man-given. Be grateful. Conceit is self-given. Be careful. -- John Wooden

  5. #5
    Senior Member kr5kernel's Avatar
    Join Date
    Mar 2004
    Posts
    347
    the only problem i could see you having, would be if the usb drive was formatted as ntfs and your linkux kernel did not have the ntfs file system built in.

    Othen than that it shoudl work as th13 said.
    kr5kernel
    (kr5kernel at hotmail dot com)
    Linux: Making Penguins Cool Since 1994.

  6. #6
    Senior Member genXer's Avatar
    Join Date
    Jun 2005
    Posts
    252
    Trevoke - thanks - that provided some more information for us!

    TH13 - from the command line - thanks much for the detail that helps - we will try out this pm.

    kr5kernel - that's what I was concerned about - the mismatch in the formats of the flash drive versus our linux machine - I am checking to see if SAMBA will bridge that gap - however TH13 also suggests that it should be no problem - so we will try it out and see what happens.

    Also - related to this topic but more procedural towards security in general. We are on an audit right now where the SA group went in over the weekend to "prepare for our coming" - so the SA group, among other preparatory activities, changed all their passwords - or so they thought, patched their servers, and locked down the shares - or so they thought. The passwords - we found an easily guessable password for the MS-SQL admin account; the shares - they locked down all the shares, except an FTP share that yielded a very sensitive and potentially damaging file - which we want to bring over to Linux for forensic analysis. They spent all weekend busting ahss and doing all this work and it took us about 2 hours to expose their weaknesses and a very high potential of risk to the organization.

    The moral? Well, in using the "securing the house" analogy used time and time again, make sure that if you lock the doors, windows, and activate the security system, do not leave the key under the welcome mat or leave the security code taped to the door.
    \"We\'re the middle children of history.... no purpose or place. We have no Great War, no Great Depression. Our great war is a spiritual war. Our great depression is our lives. We\'ve all been raised by television to believe that one day we\'ll all be millionaires and movie gods and rock stars -- but we won\'t. And we\'re learning slowly that fact. And we\'re very, very pissed off.\" - Tyler (Brad Pitt) Fight Club.

  7. #7
    Master-Jedi-Pimps0r & Moderator thehorse13's Avatar
    Join Date
    Dec 2002
    Location
    Washington D.C. area
    Posts
    2,883
    I'd do the echo command I gave you. This way you can easily and quickly mount and unmount USB flash drives.

    NTFS should not be a problem for a recent distro unless you went through and selectively removed kernel modules for FS support.

    Anyway, the command I gave you werkz on the distros I listed. Notice I specified VFAT in the command. Anyway, I swap filez between XP, 2000, 2003 and linuxen all the live long day. Never had an issue using the CLI syntax above.



    --TH13
    Our scars have the power to remind us that our past was real. -- Hannibal Lecter.
    Talent is God given. Be humble. Fame is man-given. Be grateful. Conceit is self-given. Be careful. -- John Wooden

  8. #8
    Senior Member genXer's Avatar
    Join Date
    Jun 2005
    Posts
    252
    I'd do the echo command I gave you. This way you can easily and quickly mount and unmount USB flash drives.

    NTFS should not be a problem for a recent distro unless you went through and selectively removed kernel modules for FS support.

    Anyway, the command I gave you werkz on the distros I listed. Notice I specified VFAT in the command. Anyway, I swap filez between XP, 2000, 2003 and linuxen all the live long day. Never had an issue using the CLI syntax above.
    Cool. The kernel modules should not be an issue, as I know we selected those mods for FS support. I want to try this out asap as we found some material we need to analyze and provide our and the client's management with an update post-haste with what we have. Thanks again!
    \"We\'re the middle children of history.... no purpose or place. We have no Great War, no Great Depression. Our great war is a spiritual war. Our great depression is our lives. We\'ve all been raised by television to believe that one day we\'ll all be millionaires and movie gods and rock stars -- but we won\'t. And we\'re learning slowly that fact. And we\'re very, very pissed off.\" - Tyler (Brad Pitt) Fight Club.

  9. #9
    Senior Member
    Join Date
    Sep 2005
    Posts
    221
    The writing to NTFS in the kernel is still very experimental and not to be used. The only way to maybe bridge that would be to mount the NTFS flash drive as a NFS somewhere to let you read it... But NTFS is not cool anyway, it's such a dirty filesystem. Fat32 is, believe it or not, better, although more limited as far as how big it can be (partitions are not your enemy!).
    Definitions: Hacker vs. Cracker
    Gentoo Linux user, which probably says a lot about me..
    AGA member 14460 || KGS : Trevoke and games archived

  10. #10
    Senior Member
    Join Date
    Oct 2001
    Posts
    748
    Originally posted here by Trevoke
    The writing to NTFS in the kernel is still very experimental and not to be used. The only way to maybe bridge that would be to mount the NTFS flash drive as a NFS somewhere to let you read it... But NTFS is not cool anyway, it's such a dirty filesystem. Fat32 is, believe it or not, better, although more limited as far as how big it can be (partitions are not your enemy!).
    Trevoke- Do you actually belief the stuff that you put in some of your messages or are you just trying to spread wrong information on purpose???

    Please explain why it is that you think fat32 is a better filesystem than NTFS. What makes NTFS dirty? I think you have had your head up a penguins ass for far to long..

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

 Security News

     Patches

       Security Trends

         How-To

           Buying Guides