running freebsd completely from memory : possible?

Polytropon freebsd at
Fri Dec 14 20:08:39 UTC 2018

On Fri, 14 Dec 2018 11:37:22 +0000, Mayuresh Kathe wrote:
> hello, is it possible to run freebsd-12 completely from memory?

More or less, everything runs from memory.

Yes, I know: The memory content has to come from somewhere,
but the CPU executes stuff only from memory, not directly
from the hard disk. A PC is not an AS/400, right? ;-)

> basically the system would boot off my 'ssd' and get loaded up fully in 
> memory and run from there and only write back to the 'ssd' on shutdown.

This is, more or less, how a FreeBSD live file system works.
Historically, the live system CD (#2 in the set) will boot
from non-writable media, as the CD is read-only. It will then
extract the neccessary structures into a memory file system
mounted as /. With a specific configuration, the CD could then
even be removed - if all binaries have been copied to RAM,
which holds the complete file system (including all the stuff
in /usr and even /usr/local). Of course, the more complex
such a system is, the more RAM it will require.

Many years ago, I have created a "maintenance system" that
boots from a USB stick, and upon finishing the process, the
USB stick could be removed as the whole system (and all its
programs) were in a memeory file system, and the USB stick
as initial source for booting, was entirely unmounted. The
system would continue to run until it was rebooted (from
external "control terminal" via network), and then the system
would reboot into its normal environment.

Of course, such a memory-based system cannot store anything
permanently. RAM content is lost at system shutdown. So you
have to make sure you can store stuff (if needed) to a USB
stick or a network location (for example via NFS).

> my current use-case involves learning to develop under freebsd using c89 
> and i have a quad-core intel i5 at 2.9ghz with 16gib of memory under a 
> lenovo thinkpad.

With 16 GB RAM, you should definitely be able to hold such
a development system, including the libraries and header
files, all the compiler stuff, editor, debugger...

> i don't run a 'gui' and browse the web using lynx and intend to work 
> with emails using mailx, fetchmail and sendmail (in a personal user 
> configuration).

Have a look at alpine or mutt. Those are text-mode MUAs
which are very comfortable to use in a text only environment,
and a welcome replacement for mailx. :-)

Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...

More information about the freebsd-questions mailing list