Plan 9 from Bell Labs’s /usr/web/sources/contrib/cinap_lenrek/old/linuxemu.old/README

Copyright © 2021 Plan 9 Foundation.
Distributed under the MIT License.
Download the Plan 9 distribution.


Simple Linux emulator for Plan 9.

"i see linuxemu as an excercise in creative masochism, just like wine"
 - uriel <uriel@cat-v.org>


Initial work on linuxemu was done by Russ Cox.

/n/sources/contrib/rsc/linuxemu

Russ Cox
rsc@plan9.bell-labs.com

---

RUNNING

mk
8.out /path/to/some/linux/binary

To run linux-prgrams on Plan9, you need the shared objects that your
program depends on (if its not static linked).  For networking, the
resolver expects /etc/resolv.conf containing the ip-address of your
nameserver.

I suggest to make a rc-script that constructs your linux-namespace
by binding your shared objects directory to /lib and generates some
config-files.


CURRENT STATUS

Only ELF x86 binaries are supported for now. It is NOT possible to run 
x86-64 hwith linuxemu!

Dynamic loading works thanks to segattach/segbrk based mmap
implementation. Execve()ing native Plan9 programs from 
linux-program is possible.

Here is initial networking/sockets support now for UDP and TCP.
DNS-resolver works, and you can run tcp servers and clients.


BUGS

Memory mapped files are just read in memory. Modified pages
are not written back to file. Here is no way i know of to do it in 
userspace.

On Linux, a file can be opend and then unlinked while the 
filedescriptor stays valid. Plan9 lets the fileserver decide what
todo on this case, but most invalidate the fid on remove.

pthreads (linux-thread/ntpl) doesngt work yet. some initial
work was done on linux-threads, but it is unfinished.

... just look at systab-file and see whats missing :-)

and expect a lot more bugs...

Have fun!
cinap_lenrek@gmx.de

Bell Labs OSI certified Powered by Plan 9

(Return to Plan 9 Home Page)

Copyright © 2021 Plan 9 Foundation. All Rights Reserved.
Comments to webmaster@9p.io.