Results 1 to 9 of 9

Thread: Use USB flash memory as RAM

  1. #1
    Join Date
    Dec 2008
    Beans
    26

    Use USB flash memory as RAM

    Is it possible to use a flash drive as extra RAM in Linux? Is there a program out there for that?

  2. #2
    Join Date
    May 2007
    Location
    Ireland
    Beans
    Hidden!
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Re: Use USB flash memory as RAM

    It's possible if you could program it, but it would be pointless, because USB is much much much slower than DDR2/DDR3 memory.
    Native Linux Gamer
    Penumbra | Quake IV | Doom 3 | Quake Wars | Regnum Online | Savage 2 | Warsow | Prey
    Ubuntu Game Night

  3. #3
    Join Date
    Dec 2007
    Location
    *eating something*
    Beans
    702
    Distro
    Ubuntu 9.10 Karmic Koala

    Re: Use USB flash memory as RAM

    You'd be better off setting up a swap partition on a physical harddisk rather than using USB media.

    Aside from that, it is possible, but I'm not sure how.
    |>[HowTo] Bump The BUMP Thread<||>Stats<||>19k<||>23k<||>26k<||>34k<||>37k<||>38k<||>39k<||>40k<|

    Quote Originally Posted by lukjad007
    Backups are usually a good thing unless it's a sewer.

  4. #4
    Join Date
    Mar 2007
    Beans
    1,016

    Re: Use USB flash memory as RAM

    Format your USB flash drive as a swap partition by going to System-->Administration-->Partition Editor. However, as previously mentionned, you should either upgrade RAM or create a swap partition on your physical hard drive.
    Apps for Ubuntu (outdated) ---> http://cid-23a283fc1010a1bb.skydrive...%20Wine|6?uc=1
    Use Mnemosyne to Study for School!

  5. #5
    Join Date
    Feb 2005
    Location
    Melbourne, Australia
    Beans
    13,509
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Use USB flash memory as RAM

    Quote Originally Posted by acablue View Post
    Is it possible to use a flash drive as extra RAM in Linux? Is there a program out there for that?
    That is probably the best way known to severely shorten the life of any SSD device.

    It is basically so mindless that only an organisation with a short-term focus would even support it, BTW this sort of thing is used on Windows, innit?
    Regards, David.
    Please use the Forum search and Wiki search for immediate help
    Please mark your thread as Solved when appropriate
    New to technical forums?: How To Ask Questions The Smart Way

  6. #6
    Join Date
    Dec 2010
    Beans
    Hidden!

    Re: Use USB flash memory as RAM

    I have 512MB DDR1 RAM on my laptop. If I use two 1GB USB flash drives, how much faster would it make my laptop? Would it feel like 2.5 GB RAM?

  7. #7
    Join Date
    Jan 2011
    Beans
    1,151

    Re: Use USB flash memory as RAM

    Quote Originally Posted by brawnypandora0 View Post
    I have 512MB DDR1 RAM on my laptop. If I use two 1GB USB flash drives, how much faster would it make my laptop? Would it feel like 2.5 GB RAM?
    Never, ram is so much faster than usb drives. It might make your computer slower

    http://superuser.com/questions/14619...asible-concept

  8. #8
    Join Date
    Apr 2005
    Location
    Finland/UK
    Beans
    Hidden!
    Distro
    Ubuntu 15.04 Vivid Vervet

    Re: Use USB flash memory as RAM

    Quote Originally Posted by brawnypandora0 View Post
    I have 512MB DDR1 RAM on my laptop. If I use two 1GB USB flash drives, how much faster would it make my laptop? Would it feel like 2.5 GB RAM?
    As fast as it's now, and much slower if the system at some point actually runs out of RAM and starts using the USB drives.

    Flash memory and hard drives have nowhere near the transfer speeds of RAM memory. They can be used to store data that doesn't fit into RAM, but that's simply to allow the computer to do tasks that it couldn't do otherwise, not to improve performance. (The process is caled "swapping" ans it's something you really, really want to avoid if possible. It makes things horribly slow.)

  9. #9
    Join Date
    Dec 2007
    Location
    California
    Beans
    4,900
    Distro
    Ubuntu 13.04 Raring Ringtail

    Re: Use USB flash memory as RAM

    RAM access time is measured in nanoseconds.
    USB flash drive access time is measured in milliseconds.

    If I remember correctly there's 1,000 nanoseconds in a millisecond.

    Does that give you an idea of the difference? And why swapping is slow, particulary thrashing?

    AFAIK virtual memory is never a direct replacement for physical memory, the information still has to end up in physical memory to be used by the processor, so the ram "swaps" some of it's information and grabs the information in virtual memory.



    As an aside the only reason Windows does this I believe is to get the page file off the c drive, your primary drive. This minimizes fragmentation and the fact that swap is on a separate device ought to speed things up a notch.
    Last edited by jerome1232; March 21st, 2011 at 08:47 AM.
    "You can't expect to hold supreme executive power just because some watery tart lobbed a sword at you"

    "Don't let your mind wander -- it's too little to be let out alone."

Bookmarks

Posting Permissions

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