command line boot + tmpfs + ram disk/cache
Posted: Sun Jun 28, 2020 1:03 am
I'm new to the pi world. While waiting for my 8gb pi4 to arrive, I've been reading up the online documentations and I have several questions about setup/config.
(1) I plan to use the pi sometimes in the headless mode, and sometimes with full desktop. One of the forum member mentioned that I can first install the desktop raspberry OS, and then upon login, config the pi to CLI (and then run startx as needed). But
https://www.raspberrypi.org/documentati ... xt/boot.md
does not seem to mention that. Did I overlook something obvious or should I proceed differently?
(2) I recall reading somewhere that one can change a setting so pi does not write log files/write them to the ram to save the sdcard. Unfortunately I can't find that post and
https://www.raspberrypi.org/documentati ... /memory.md
don't seem to mention this. Again, did I overlook something obvious or should I proceed differently?
(3) I came across several references to "ram disk" or "ram cache" to spend up programs. I assume that means by loading a big program (e.g. mathematica) into the ram once per session, we save time by no longer having to load it again, right? Or perhaps there's a way to use the ram to speed up the execution of the program? In any case, where I can find out more about it (what ram disk does and how to set up it).
(4) On a related note: Is there a way to setup gcc/make etc so that intermediate files/outputs are stored in the ram, both to save the sdcard and to help speed things up? Where can I find out more (about setting this up)? And how do I save the file executable in the sdcard?
Thanks!
(1) I plan to use the pi sometimes in the headless mode, and sometimes with full desktop. One of the forum member mentioned that I can first install the desktop raspberry OS, and then upon login, config the pi to CLI (and then run startx as needed). But
https://www.raspberrypi.org/documentati ... xt/boot.md
does not seem to mention that. Did I overlook something obvious or should I proceed differently?
(2) I recall reading somewhere that one can change a setting so pi does not write log files/write them to the ram to save the sdcard. Unfortunately I can't find that post and
https://www.raspberrypi.org/documentati ... /memory.md
don't seem to mention this. Again, did I overlook something obvious or should I proceed differently?
(3) I came across several references to "ram disk" or "ram cache" to spend up programs. I assume that means by loading a big program (e.g. mathematica) into the ram once per session, we save time by no longer having to load it again, right? Or perhaps there's a way to use the ram to speed up the execution of the program? In any case, where I can find out more about it (what ram disk does and how to set up it).
(4) On a related note: Is there a way to setup gcc/make etc so that intermediate files/outputs are stored in the ram, both to save the sdcard and to help speed things up? Where can I find out more (about setting this up)? And how do I save the file executable in the sdcard?
Thanks!