loading

What's the best way to create a Linux server from solid state memory ?


I have a dead home server. It used two hard-disks, one for everything but /home and one for /home. /home is fine, as it was intended to be.

I'm about to rebuild it, but its occurred to me that virtually all of my data in there, apart from less than a gig is pretty well static - its the house email server, so there is a dynamic bit in there, but its tiny.

What's the best way to do this ? I've Googled a bit, but not found much guidance, except folks selling solid state servers.

The motherboard is a mini-ITX.

What about using Mint as the basis of something ?

Steve

sort by: active | newest | oldest
orksecurity6 years ago
Easiest: You could just design the system to boot from a flash disk, possibly even a flash memory key. I believe some ITX cards can now be convinced to do that. And I believe you can now buy off-the-shelf solid-state-disk units. Either of those approaches would avoid your having to write device driver code and/or design your own interfaces.

Of course, you will want to make sure that you have enough RAM. Swapping to flash is a bad idea; flash has a limited overwrite life, and is probably relatively slow as a disk. (Better than it used to be on both fronts, which is why solid-state disks are now practical, but I'm still biased against pushing it harder than I must.)
steveastrouk (author)  orksecurity6 years ago
My concern is the flash wear issue you point out, but I don't know what I need to configure to do this.

Steve
From a software point of view (not sure how much you know about Linux, probably more than I do (what little I do know is largely limited to server management and embedded systems) so this may well be useless, but here goes:)
The RAM is mapped (probably) as /dev/shm

1) Figure out which files are going to be accessed during run-time (booting/shutting down isn't an issue unless you attempt to test the durability of the power button)
2)Make an init script which copies the files into /dev/shm then mounts them (for example, say you want to copy over /root/)
mkdir -p /dev/shm/root && cp -a /root/* /dev/shm/root/ && mount /dev/shm/root /root
There are Linux builds specifically intended to boot from a flash drive, so clearly someone thinks it can be done...

Depends on how it's done.  Tin Hat Linux loads the image entirely from the disk into memory, then doesn't access the disk at all during normal OS execution.  With a million read/write cycles, or whatever they get these days, a flash drive/SSD would last a LONG time.

I would say the best thing to do would be have a good backup system in place.  All hard drives fail, and if you wear your SSD heavily enough, you might even get it replaced under warranty :)

If you must configure a flash drive as swap space, buy another than the one you're using for data.  They're cheap, and that way when the swap drive fails your other one will still be fine
Valid point.. Increasing RAM as much as possible, to minimize swapping, would also help.

And a good backup system is _always_ good advice. A 1.5G drive can be had for well under $100 these days, even with external enclosure and power supply.
("If it happens, it must be possible.")
kelseymh6 years ago
You might be interested in the PetaCache Project, run by some of my colleagues at SLAC.