Ramroot – Run Arch Linux Entirely From RAM!

Ramroot - Run Arch Linux Entirely From RAM

6 Responses

  1. Miguel Mayol i Tur says:

    Questions:
    Does it CREATE or REPLACE the GRUB entry?
    Can you setup a user session?
    Can you mount HDD and SDD drives? so then save things

    • sk says:

      Question 1 – No, it doesn’t change anything. It simply loads the filesystem into RAM

      Question 2 – You can set user session and switch to the new user.

      Question 3 – I haven’t tested this yet. I suppose it should work.

  2. Anonymous says:

    The logic dictates that any Linux that can mount a filesystem on read & write can do changes to such filesystem.

    Since your question 3 is ambiguos (what thigs to be saved?) i answer with what i thing it could be… actually i will investigate this “ramroot” as soon as i can… it seems to be just what i am most interested upon years (be able to run a full distro on my 64GiB Ryzen 7 2700X fully from RAM), yes i did not recieve yet all pieces of my new computer but i was searching for howto since years, prior to buy the hardware, even prior than the hardware even exists… other main goal i was looking for was loading VirtualBOX from RAM with Winodws10 virtual disk image file on RAM (more than 32GiB).

    Answering to your question 3: Yes and No.

    If you mount a filesystem you can save files, so downloaded PDFs can be saved to such filesystem, etc… just DATA.

    But if you pretend to save applications configuration changes, or new installed apps, i am afraid will NOT be saved upon reboot, this does not seem like some LiveCD that uses a special file to save your session among reboots.

    This must be much more powerfull from what i can thing of its uses:

    1.- Boot with all your system on ram is equivalent to make system inmutable, so you can intentionally infect your system with a VIRUS (just the concept as a drastic example, i know how impossible is for a Linux to be infected) and on next boot no change persist, it will boot as it did, nothing had changed since all changes where done on RAM… except what you change by mounting filesystem in read & write mode… for example you can work with Gimp, Blender, LibreOffice or whatever, your work will be saved, but changes on such programs configurations will not persist upon a reboot (like historical opened/saved files, etc.)

    2.You can chroot to system on real storage and there make changes, like install packages, etc… very usefull because you can prepare an install script, tested (see what fail, fix it, etc) on your RAM root, once you have it working (you can use reboots to test it multiple times) then you can chroot and run it there with the confidence it will do the same as when on RAM root… so you can failsafe install things on your system because you can try them on inmutable copy of your system (without the need to clone/restore since on boot it copies all to ram)… great use, since some installs can ruin a system; warning: anything that needs reboot will void this idea until a persistent next boot could be implemented.

    3.-Also copy to ram VirtualBOX machines and run them enterly from ram, after shutdown just be sure to copy back to physical media from ram drive or you loose all changes… again one more extra use of this, no need to make inmutable disk image on VirtualBOX and loose disk speed, since if you want it to be inmutable, you just do not save the modified image… very usefull for Windows guest updates that fails and ruin Windows system, not to mention the disk speed, it will be RAM speed, not such very slow NVMe that can write 5Gib/s, yes RAM is a lot more fast than the fastest NVMe.

    4.-Also if you want to make changes to installed apps, etc, there is the option to boot normal, without copy to ram.

    I want to test it as soon as i can, it will help me a lot… if it does what it say it does… copy the whole root onto RAM and run from there.

    Extra: Some motherboards let you how-swap SATA drives, some has SIX ports, imagine SIX fast SSD in LVM2 Striped (i know cost is arround 500 €), at each boot you only read from them and at speeds near best NVMe gives, but after boot you can put out them from your PC (with NVMe you can not, at least actually i do not know of any hot-swapable NVMe motherboard), so after that no matter what command is run, such SSD will not be able to be written (since they are not connect to the PC anymore), so you can do whatever ‘dd’ you want being sure you will not damage the data on them, as opposite if you ‘dd’ your NVMe you can ruin it.

    SuperExtra: Imagine you boot fully to RAM and then have no storage space available (no storage connected), you can let your son or an extranger to use your PC, you know whatever do will got lost or not saaved to your storage, since tour storage is far away and off-line… it is similar to use a LiveCD without any storage drive on the system, but tons faster.

    I can not wait to put my hands on this piece of softare, it is does such ‘copy root to ram’ and ‘continue to boot from ram’ it would be my best day ever.

    Sorry to be so detailed and so happy that finally something like this exists, but most people do not image what the concept of this piece of software allows… i had only commented the top most usefull/importatn ones… like: makeing your system inmutable, ensure no write go to your disks after eject sata drives (if sata ports are hot-swapable) after copy to ram ends, probe new updates / installs prior to deploy them on the real system, etc.

    P.D.: I know this piece exists just today… but i was preparing my self for a day like this one since more than ten years… wishing i have money on time (for 4x16GiB=64GiB DDR4 3200MHz) and all knownledge to reach it…. till today i was trying with Grub2 ISO files Boot, like SystemRescueCD but with my own made distro… this aproach is much more easy, just install a package and at boot time select yes… luckly anyone could find how to make ‘yes’ as default.

    • sk says:

      OMG, thanks for your detailed comment Mr.Anonymous. Your comment is much more clear than my article. This should be added in the Ramroot official wiki page.

  3. zahoor ahmed says:

    Hi, I am running arch linux from a couple of weeks now, having used other distros over a long time, i will be trying this implementation of ramroot, i have tried out similar stuff in windows in previous years, also for anonymous above there are a no of linux distros already available that run entirely from ram, google for distros that run from ram and u will find them, I think this should allow one to still give access to disk and not be fully virtual. Very good site and lots of good info on arch linux by sk. thanks.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.