Re: netmsg can now exec files (sort of)

2016-08-30 Thread Richard Braun
On Mon, Aug 29, 2016 at 03:56:00PM -1000, Brent W. Baccala wrote:
> I've figured out why the patched exec server didn't work with mmap, and
> just opened a bug on it, with a fix attached.
> 
> So now I've got a working, mmap-less exec server that burns a lot of extra
> RAM (each process gets its own private copy of the C library), but lets me
> execute files across a netmsg TCP/IP session.
> 
> I think the next logical step is to get it to attempt an mmap, and only
> fall back if that doesn't work.

You might also want to consider making the mmap-less case more
efficient by carefully copying the data. I didn't insist on
COW zero-copy for no reason.

-- 
Richard Braun



Re: netmsg can now exec files (sort of)

2016-08-29 Thread Brent W. Baccala
I've figured out why the patched exec server didn't work with mmap, and
just opened a bug on it, with a fix attached.

So now I've got a working, mmap-less exec server that burns a lot of extra
RAM (each process gets its own private copy of the C library), but lets me
execute files across a netmsg TCP/IP session.

I think the next logical step is to get it to attempt an mmap, and only
fall back if that doesn't work.

agape
brent


netmsg can now exec files (sort of)

2016-08-26 Thread Brent W. Baccala
Aloha -

I've gotten 'netmsg' to the point where files in the mounted, remote
filesystem can be executed on the local machine.  This isn't remote
execution - it's just copying the files to the local machine and executing
them there.  Nothing more than what you'd expect from NFS or Samba, but it
works.

'libpager', as we've discussed, can't handle multiple clients, and some
extra effort is required to avoid this limitation.  You need a custom exec
server that doesn't attempt any mmap()'s.  It's a simple patch, but not one
we want in the mainline code, except perhaps for testing purposes.  Anybody
see any reason for a --no-mmap flag to the exec server?

Unfortunately, my patched exec server doesn't work as /hurd/exec.  The
system freezes right after the "Hurd server bootstrap" line, and I've spent
the afternoon trying to figure out why.  At first I thought it was a
problem with my exec server executing shell scripts (runsystem.sysv, to be
specific), but I now realize that this is a bug in the standard exec server
executing shell scripts.  I filed a bug report; it has to do with
re-authentication, so I'd rather somebody else sign off on how to fix it.

In the mean time, I'm still wondering why an mmap-less exec server won't
boot my Hurd.

Obviously, this is a Band-Aid.  We don't want a mmap-less exec server; we
want libpager to handle multiple clients, right?

agape
brent