View previous topic :: View next topic |
Author |
Message |
rabcor Apprentice
![Apprentice Apprentice](/images/ranks/rank_rect_2.gif)
![](images/avatars/1697128378505dc6b246101.jpg)
Joined: 05 Apr 2012 Posts: 200
|
Posted: Fri May 30, 2014 4:40 am Post subject: Booting to RAM |
|
|
I was wondering about ways to make gentoo boot from RAM.
There is one cross-distro method here which simply loads the root partition to RAM as it is.
But I think this method is a lot more elegant as it zips up (with GZIP, I would prefer LZMA) the root partition and then booots off of the zip as if it were an initramfs or so I think. I really like this method because I think if I use this, I can update my system while it is loaded to RAM by simply upadting it as I normally would, and then zipping it up again from there before I reboot. However this method is not cross distro, would it work with Gentoo? If not is there a Gentoo alternative or can I somehow just make it work with Gentoo?
PS: I would also like to load certain files to other hard drive partitions, like for example /usr/portage can get pretty huge so I can save a lot of space by storing it on a HDD/SSD partition, can I do this somehow with fstab or should I just use symlinks to do something like this? _________________ This picture was my biggest reason for ever trying Gentoo <3 |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
chithanh Developer
![Developer Developer](/images/ranks/rank-dev.gif)
![](images/avatars/3210501551dc02a09eeb8.png)
Joined: 05 Aug 2006 Posts: 2158 Location: Berlin, Germany
|
Posted: Fri May 30, 2014 9:33 am Post subject: |
|
|
One option is to stay in initramfs even after boot. You never need to leave your initramfs, and it can be compressed to reduce on-disk size. A downside is that the decompressed initramfs needs to fit into LOWMEM (which is 896 MB by default on 32-bit systems).
Another option is to create a ramdisk which has the size of your root filesystem during early boot, then copy everything there and continue to boot from the ramdisk. You can use zram on memory-constrained systems to preserve memory.
There are some older threads here and here which might give you some pointers to get started. |
|
Back to top |
|
![](templates/gentoo/images/spacer.gif) |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|