[ale] Rebooting remotely without a usable /

Michael B. Trausch mbt at zest.trausch.us
Mon Sep 21 10:37:47 EDT 2009


On Mon, 2009-09-21 at 09:46 -0400, Matt Rideout wrote:
> Good thinking! It's running 64-bit Intel Xeon MP 3.66GHz CPUs.
> Nothing 
> located on the disk that isn't already loaded into RAM is usable, so 
> compiling on the box isn't an option. I wouldn't be able to scp a
> binary 
> over, or execute the commands to mount a memory filesystem in the 
> traditional sense either, since those would access files on the
> drive. 
> Would there be anyway to make that syscall purely from memory? 

Hrm.

I suppose the question is, can you make binary, send it to the remote
host, keep it in memory, and execute it.  If you can somehow use a file
descriptor to house the code, you can use fexecve to execute the program
from the file descriptor directly.  A statically linked version of the
program I wrote earlier would work, though an even smaller assembly
version would be better if you don't have 700k of RAM to put it in a
pipeline or store it in a ramdisk.

Even if the disk is failing, shouldn't you be able to push the file over
and read it from the filesystem cache, which would not have hit the disk
yet?  Or can you not get that far even?  Is there only a single disk?
Is any of /tmp or /var/tmp in RAM?  I'm trying to think of as many
things as possible...

	--- Mike

-- 
Blog:  http://mike.trausch.us/blog/
Misc. Software:  http://mike.trausch.us/software/

“The greater danger for most of us lies not in setting our aim too
high and falling short; but in setting our aim too low, and achieving
our mark.” —Michelangelo



More information about the Ale mailing list