Linux without swap?

Discussion in 'Computer Science & Culture' started by Fen, May 12, 2003.

Thread Status:
Not open for further replies.
  1. Fen Registered Senior Member

    Messages:
    292
    There's been some talking about running your computer without hard disks. I like it--hard disks are noisy and slow. There's even a new carbon-based memory that could be denser than hard disks and faster than ram, while being non-volatile too! When that comes, the whole primary-secondary storage paradigm will fall--good riddance, right? But for now, what can we do in this direction? I'd like 6000,0000h bytes of RAM in my next system. So why would I need swap? I've actually done this under Windows (just disable virtual memory). System has 3000,0000h bytes of RAM and runs just fine under XP. Can you just remove the swapfile from linux alltogether? Would be interesting to hack the kernel to clean all the swapping code out--make it much more elegant.
     
  2. Google AdSense Guest Advertisement



    to hide all adverts.
  3. Fen Registered Senior Member

    Messages:
    292
    Hey this is kinda interesting.
     
  4. Google AdSense Guest Advertisement



    to hide all adverts.
  5. Stryder Keeper of "good" ideas. Valued Senior Member

    Messages:
    13,105
    Ram driven systems isn't exactly new, as after there was Commodores Amiga that ran on RAM, you'd load your programs from disk.

    As for cutting a Linux distro into a RAM hack, there might be some problems there, afterall those swap files come in handy for storing data that might be used to recreate information should the system fail/shutdown.

    Otherwise I'm sure you could run the whole distro on RAM if you make sure that you Border the RAM area's correctly to stop Buffer Overflowing crashing the system. (I've seen too many PID kills cased by buffer overflows in the past)
     
  6. Google AdSense Guest Advertisement



    to hide all adverts.
  7. AntonK Technomage Registered Senior Member

    Messages:
    1,083
    I have a Sharp Zaurus SL-5500 PDA, which is actually not a PDA at all but a really small computer. It runs a version of Linux and, being a PDA, has no harddrive or swapfile. Everything is done using the internal memory (64 megs). So, it is obviously possible to do what you're saying, since Sharp did it for their PDA.

    -AntonK
     
  8. everneo Re-searcher Registered Senior Member

    Messages:
    2,621
    probably they must be having the swap area in the memory itself.
     
  9. AntonK Technomage Registered Senior Member

    Messages:
    1,083
    No...no swap...just memory and a ramdrive.

    -AntonK
     
  10. mouse can't sing, can't dance Registered Senior Member

    Messages:
    671
    Aside from the mentioned PDA, i do not think that swapping as a principle has become unnecessary with increasing RAM sizes. E.g. instead of swapping between RAM and harddrive, you'd want to swap between fast and slow RAM chips.

    With current p.c. this really is not the case as cache memory is controlled by the cpu (if i'm not mistaken?) and not by the OS, but it does not take away the notion that the future could be just as well swamped with slower and larger and cheaper mass storages versus faster and smaller and more expensive storages.
     
  11. Rick Valued Senior Member

    Messages:
    3,336
    <I>As for cutting a Linux distro into a RAM hack, there might be some problems there, afterall those swap files come in handy for storing data that might be used to recreate information should the system fail/shutdown.</I>

    There are Linux Systems that work like that.For example Mapix(requires a Floppy),Minix(By A.S Tanaenbaum,which is essentially for PDAs) that work without Swap partitions.

    thanks.
    bye!
     
  12. mouse can't sing, can't dance Registered Senior Member

    Messages:
    671
    Minix for PDAs? No, Minix is just an OS for educational and research purposes... i should know, i've worked with it and learned to avoid it at all cost.
     
  13. Rick Valued Senior Member

    Messages:
    3,336
    Minix is for educational purpose,yes.


    bye!
     
  14. Fen Registered Senior Member

    Messages:
    292
    Yes, cache memory is essentially transparent to the software. This may have changed with something like IA-64, which offers a lot more ability to give hints on what to save. This is a good argument, but it would seem it should be extended to multiple layers of swap. Maybe it would be even more complicated? Oh well, it's already done in CPUs, so it must work. But for now, all RAM is essentially equal to software, so you really shouldn't need swap.
     
Thread Status:
Not open for further replies.

Share This Page