Slashdot Mirror


Boot Linux In Your Browser

An anonymous reader writes "Fabrice Bellard, the initiator of the QEMU emulator, wrote a PC emulator in JavaScript. You can now boot Linux in your browser, provided it is recent enough (Firefox 4 and Google Chrome 11 are reported to work)."

393 comments

  1. Interisting by CTU · · Score: 0

    That is rather cool, but I'd rather not upgrade FF to v4. Although, now I have a reason to install Chrome :)

    1. Re:Interisting by Hazel+Bergeron · · Score: 1

      FF4 is hopeless over RDP. FF3 is reasonably pleasant. What's the bug?

    2. Re:Interisting by SharpFang · · Score: 1

      Prolly hardware acceleration.

      Tools-options-advanced-general-browsing,
      [ ] use hardware acceleration

      Totally fucked up the menus for me. But even after switching it off, it works nicely fast.

      --
      45 5F E1 04 22 CA 29 C4 93 3F 95 05 2B 79 2A B2
    3. Re:Interisting by Lumpy · · Score: 1

      And a lot of plugins dont work.

      --
      Do not look at laser with remaining good eye.
    4. Re:Interisting by _0xd0ad · · Score: 1

      I've personally found FF4 to have some pretty bad memory leaks. If I leave it open for longer than a day I've found it upward of 500-700 MB, sometimes even a gigabyte of virtual memory. This on a computer running Win XP with 1 GB of RAM. Totally kills the performance of everything until I exit it and restart it.

      On Win 7 with ... 2 GB of RAM I think? ... it still balloons pretty quickly but having twice as much RAM does at least help it not kill everything else due to the slowness of paging it all.

      It's mainly just a big inconvenience having to exit and restart it daily, sometimes twice a day. But even so, it's nothing I can't put up with for a while longer, until the bugs get worked out anyway. I keep telling myself the next update will hopefully make things better.

    5. Re:Interisting by The+Archon+V2.0 · · Score: 1

      "I keep telling myself the next update will hopefully make things better."

      So did I. And then FF2 didn't fix it. And then FF3 didn't fix it. And then FF4 didn't fix it....

    6. Re:Interisting by Hamsterdan · · Score: 1

      Yeah... had to do the same thing in order to be able to use it on my secondary monitor. I mean, sure, multiple monitors are something too recent, they just came out with that in Win98...

      --
      I've got better things to do tonight than die.
    7. Re:Interisting by SharpFang · · Score: 1

      The problem is it's not a single leak, never was. It's thousands of tiny leaks, many of them occurring once in a blue moon. Observing and fixing them is a gargantuan task, because you have to hunt them one by one, and while killing one is quite doable, killing enough to make a difference is difficult. Also, extensions leak memory left and right, their authors don't feel obliged to fix them, and Mozilla authors can't do much about it.

      --
      45 5F E1 04 22 CA 29 C4 93 3F 95 05 2B 79 2A B2
  2. But... by Anonymous Coward · · Score: 4, Funny

    ...does it run BSD?

    1. Re:But... by hduff · · Score: 1

      ...does it run BSD?

      And can it run Quake?

      --
      "I believe in Karma. That means I can do bad things to people all day long and I assume they deserve it." : Dogbert
    2. Re:But... by Kwpolska · · Score: 1

      and can we patch KDE2 under it?

    3. Re:But... by Anonymous Coward · · Score: 0

      Does it run Quake?

    4. Re:But... by davesag · · Score: 1

      More importantly, can I run Duke Nukem Forever on it?

      --
      I used to have a better sig than this, but I got tired of it
    5. Re:But... by amirulbahr · · Score: 1

      You don't need JS for that, HTML will do.

      Wait... you meant BSoD right?

  3. You win Slashdot by Anonymous Coward · · Score: 0

    No cooler story is possible.

    1. Re:You win Slashdot by rs79 · · Score: 1

      Sure it is. What if somebody got Apache to run under it?

      --
      Need Mercedes parts ?
    2. Re:You win Slashdot by SanityInAnarchy · · Score: 1

      Or a browser? ...nah, Apache is more feasible.

      --
      Don't thank God, thank a doctor!
    3. Re:You win Slashdot by niftydude · · Score: 1

      Or a browser?

      Compiling up lynx would probably be not too hard...

      --
      You can never know everything, and part of what you do know will always be wrong. Perhaps even the most important part.
    4. Re:You win Slashdot by Skrynesaver · · Score: 1

      Tried to, but wget doesn't see the outside world from within it :(

      --
      "Linux is for noobs"-The new MS fud strategy
    5. Re:You win Slashdot by Pikoro · · Score: 1

      I think it would trigger the next big bang. Endless recursion?

      --
      "Freedom in the USA is not the ability to do what you want. It is the ability to stop others from doing what THEY want"
  4. Re:The burning question. by Anonymous Coward · · Score: 1

    The answer. Why not?

    Why not make something cool and interesting. It's a proof of concept. Showing how powerful our browsers and computers have become that we can emulate a full computer inside of it.

    I find it quite fun to write a small C program, compile, and run it, all inside a javascript emulation.

  5. Re:The burning question. by jra · · Score: 4, Interesting

    Like Everest, because it was there.

    There was a GIF out several years back, which I haven't been able to find any time recently (and would love a pointer to) of some guy who had something like *19* hardware emulators running on one monitor simultaneously, in 4 or 5 separate stacks.

    TRS-80, C-64, T/S-1000; everything you've ever seen an emulator for, he had running on Linux all at the same time; some hosting others.

  6. Nice by Anonymous Coward · · Score: 0

    Very nice, but how much use is this?

    1. Re:Nice by GPLHost-Thomas · · Score: 4, Insightful

      How can someone be so damned silly enough to think there's no use for it... Man, a FULL x86 EMULATOR written in Javascript! Possibilities are endless. The point isn't just to run Linux, but anything that is written in C, and that you want to run in your browser. ANYTHING. Running Linux is just a proof of concept.

      Bellard wrote FF-Mpeg, Qemu, and now this. I have no words to express my admiration for his talent.

    2. Re:Nice by slim · · Score: 1

      Yes, but there are already PC emulators that will run in your browser as Java applets. I strongly suspect those will always be more efficient.

      This is a cool demo of how fast Javascript has become, but it has very little practical use.

    3. Re:Nice by bluefoxlucid · · Score: 2

      Yes, but there are already PC emulators that will run in Java and export their display data to glue code that allows a plug-in to display the window in your browser.

      Fixed that for you. Java Applets do not "run in your browser," nor does Flash; that is an illusion. These are entire platforms that run programs, and can export the display independently; your browser provides a windowing manager for them, like Sawfish.

    4. Re:Nice by rickb928 · · Score: 1

      Very little of what we love and use on the Internet would have survived the "Very nice, but how much use is this?" test. Fortunately, most of it didn't even consider the question.

      --
      deleting the extra space after periods so i can stay relevant, yeah.
    5. Re:Nice by NNKK · · Score: 1

      Any particular reason for this "strong" suspicion? Java and JavaScript both eventually end up as native code. The dynamic nature poses interesting challenges, but shouldn't constitute a fundamental barrier to development of an JavaScript engine that's competitive with top JVMs.

    6. Re:Nice by slim · · Score: 1

      My first reaction to this was that you were pointing out an implementation detail. The parent of the Java process is the browser, and that's a good enough definition of "running in" for me.

      However, I think I see what you're getting at. Extend this PC emulator so that it has some visibility of the DOM and JS input events, and you could use X86 binaries as the logic behind interactive web pages.

      It's a fairly niche requirement -- where you have a binary and no access to the source -- but it could certainly have uses.

    7. Re:Nice by bluefoxlucid · · Score: 1

      It doesn't need extension; do I/O through the serial port or through MMIO registers. Pass data back and forth, make callbacks. I/O gives you a way to say "call function X with parameters ${PARMS}" and get the thing to pull up a symbol table and do what you want. It then emits the output as a binary stream out a serial port.

  7. Yo dawg, by pecosdave · · Score: 1, Funny

    Yo dawg, we hear you liked Linux and virtual machines so we wrote a virtual machine for the Java Virtual Machine so you can run Linux while you run Linux.

    --
    The preceding post was not a Slashvertisement.
    1. Re:Yo dawg, by Zontar+The+Mindless · · Score: 5, Funny

      Yo dawg, JavaScript and the JVM have less to do with each other than an Orthodox rabbi and a porkchop.

      --
      Il n'y a pas de Planet B.
    2. Re:Yo dawg, by pecosdave · · Score: 0

      mmmmmm porkchops

      --
      The preceding post was not a Slashvertisement.
    3. Re:Yo dawg, by grcumb · · Score: 3, Funny

      Yo dawg, we hear you liked Linux...

      Yeah, but does it run Lin - hang on....

      ... Oh My God. It's penguins all the way down!

      --
      Crumb's Corollary: Never bring a knife to a bun fight.
    4. Re:Yo dawg, by Anonymous Coward · · Score: 0

      You're still a moron.

    5. Re:Yo dawg, by kvvbassboy · · Score: 1

      HAHAHAHA!! :D Off topic, but you sir, made my day!

    6. Re:Yo dawg, by Aeternitas827 · · Score: 2

      less to do with each other than an Orthodox rabbi and a porkchop.

      This will now replace 'What does X have to do with the price of tea in China' in my daily conversation. You almost got a beverage spray from me because this bit of wit.

      --
      I don't post AC. I like my -1, Flamebaits. Trump/Sheen 2012 on the Batshit Insane ticket!
    7. Re:Yo dawg, by ynp7 · · Score: 1

      mmmmmm porkchop sandwiches

    8. Re:Yo dawg, by ynp7 · · Score: 2

      You can run X in this thing? OMFG!!!

    9. Re:Yo dawg, by Anonymous Coward · · Score: 0

      ... Oh My God. It's penguins all the way down!

      Wait? Is that a Pratchett-Clarke-crossover?

    10. Re:Yo dawg, by Palmsie · · Score: 1

      We need to go deeper.

      --
      Carl Sagan quotes get you an automatic +5 on all posts.
    11. Re:Yo dawg, by rusl · · Score: 2

      The days of programming a turtle are over!

      --
      Stupidity is its own reward.
    12. Re:Yo dawg, by Yvanhoe · · Score: 1

      No, you can't. There is no graphical device emulated yet. You could compile X though. It would say that there are no screens/graphical devices connected.

      --
      The Wise adapts himself to the world. The Fool adapts the world to himself. Therefore, all progress depends on the Fool.
    13. Re:Yo dawg, by SharpFang · · Score: 1

      Are there network devices? You could compile vnc server and access the X remotely.

      --
      45 5F E1 04 22 CA 29 C4 93 3F 95 05 2B 79 2A B2
    14. Re:Yo dawg, by Anonymous Coward · · Score: 0

      that isn't funny. come up with something more unique please

      or age a few years, honestly im sorry for the troll but you ought to know

    15. Re:Yo dawg, by Anonymous Coward · · Score: 0

      V I R T U A L I Z A T I O N

    16. Re:Yo dawg, by Anonymous Coward · · Score: 1

      You have obviously never tasted Orthodox rabbi.

    17. Re:Yo dawg, by Yvanhoe · · Score: 1

      Neither. More informations there : http://bellard.org/jslinux/tech.html

      Interesting read by the way.

      --
      The Wise adapts himself to the world. The Fool adapts the world to himself. Therefore, all progress depends on the Fool.
    18. Re:Yo dawg, by Pikoro · · Score: 1

      Deeper? ok, try this:

      vi forkbomb.sh
      i

      #/bin/sh
      $0 &
      $0

      ZZ
      chmod 777 ./forkbomb.sh ./forkbomb.sh

      Fork bomb works just fine in there. :)

      --
      "Freedom in the USA is not the ability to do what you want. It is the ability to stop others from doing what THEY want"
    19. Re:Yo dawg, by Anonymous Coward · · Score: 0

      ROFL @ penguins all the way down... I wish I had mod points to give you.

    20. Re:Yo dawg, by Henk+Poley · · Score: 1

      I vaguely remember somebody writing a text only X11 frontend driver for the console. I can't seem to find it though. It think it would emulate the display of a virtual framebuffer via AAlib by displaying characters that approximate the pixels.

    21. Re:Yo dawg, by Anonymous Coward · · Score: 0

      mmmmmm Orthodox long pork

    22. Re:Yo dawg, by Anonymous Coward · · Score: 0

      5 point funny for this guy and 1 point funny for the parent post.

      This is why slashdot is going down the crapper.

    23. Re:Yo dawg, by Kompressor · · Score: 1

      Wellp, there's your stress-test / Javascript benchmark :D

      I managed to get Chrome to sit on an entire CPU core with that little gem, and it vomited this all over the terminal:

      Active:4063 inactive:1 dirty:0 writeback:0 unstable:0 free:195 slab:1811 mapped:58 pagetables:1113
      DMA free:420kB min:360kB low:448kB high:540kB active:7748kB inactive:0kB present:16256kB
      pages_scanned:39714 all_unreclaimable? yes
      lowmem_reserve[]: 0 15
      Normal free:360kB min:360kB low:448kB high:540kB active:8504kB inactive:4kB present:16256kB pages_scanned:64768 all_unreclaimable? yes
      lowmem_reserve[]: 0 0
      DMA: 1*4kB 0*8kB 0*16kB 1*32kB 0*64kB 1*128kB 1*256kB 0*512kB 0*1024kB 0*2048kB 0*4096kB = 420kB
      Normal: 0*4kB 1*8kB 0*16kB 1*32kB 1*64kB 0*128kB 1*256kB 0*512kB 0*1024kB 0*2048kB 0*4096kB = 360kB
      Swap cache: add 0, delete 0, find 0/0, race 0+0
      Free swap = 0kB
      Total swap = 0kB
      Free swap: 0kB
      8192 pages of RAM
      0 pages of HIGHMEM
      580 reserved pages
      9060 pages shared
      0 pages swap cached
      0 pages dirty
      0 pages writeback
      58 pages mapped
      1811 pages slab
      1113 pages pagetables

      Too bad I couldn't get it to recognize the magic-sys-rq key combos.

      --
      kmem russian roulette: Aquillar> dd if=/dev/urandom of=/dev/kmem bs=1 count=1 seek=$RANDOM
    24. Re:Yo dawg, by shutdown+-p+now · · Score: 1

      You can't, but it would be so awesome. Someone should really go ahead and write an HTML5 canvas-based X implementation for it.

      (what? no, I didn't volunteer!)

    25. Re:Yo dawg, by Anonymous Coward · · Score: 0

      5 point funny for this guy and 1 point funny for the parent post.

      This is why slashdot is going down the crapper.

      Since the OP was WRONG, it seems plenty fair to me. (And 2 of those 5 points were Insightful mods, BTW.)

      P.S. A special message for losers who think they've the God-given right to override my browser's preferences by posting everything inside <tt>...</tt> tags: YOU SUCK, AND I HAVE MOD POINTS.

    26. Re:Yo dawg, by ynp7 · · Score: 1

      Whoosh.

  8. Re:The burning question. by roman_mir · · Score: 1

    New type of virus vector of-course.

  9. Fun guy by Anonymous Coward · · Score: 5, Interesting

    Fabrice also wrote his own version of emacs in his own realtime C compiler, and he also at one time held the record for calculating pi.

    1. Re:Fun guy by snl2587 · · Score: 1

      And, sure enough, it runs in the js version of Linux.

    2. Re:Fun guy by wagnerrp · · Score: 2

      Emacs and C compilers? Pah! A virtual machine running in javascript is mad genius unheard of since using graphics cards as software driven DVB modulators.

    3. Re:Fun guy by mukund · · Score: 2

      Fabrice is also the reason for Qemu, FFmpeg and LZEXE.

      I hope he has a lot of kids :)

      --
      Banu
    4. Re:Fun guy by Anonymous Coward · · Score: 0

      Also he started and led FFmpeg for many years, which is in the heart of many video sites.

    5. Re:Fun guy by grewil · · Score: 2

      Both his emacs and his c-compiler are installed on that js/linux! Try commands qemacs and tcc.

    6. Re:Fun guy by proverbialcow · · Score: 1

      ...which means someone will eventually have network support up and running, and from there, apt-get (or the like). =)

      I look forward to the day when someone manages to bootstrap Gentoo in the browser.

      --
      The only surefire protection against Microsoft infections is abstinence. - The Onion
    7. Re:Fun guy by proverbialcow · · Score: 1

      ...and then someone will emulate a modem (complete with bandwidth throttled to 57k, and handshaking sounds), get DOSBox running, and load in the images for Windows 3.1, thus recreating my computer from my freshman year of college in JavaScript - except much faster.

      --
      The only surefire protection against Microsoft infections is abstinence. - The Onion
    8. Re:Fun guy by Anonymous Coward · · Score: 0

      He also started ffmpeg.

    9. Re:Fun guy by Anonymous Coward · · Score: 0

      Bellard is a fantastic programmer. Probably one of, if not the most, under-appreciated programmer in the world. He does excellent work without ego or hype as far as I can tell.

    10. Re:Fun guy by jonescb · · Score: 1

      I tried this earlier and I noticed the hello.c file in the home dir. I tried compiling it with gcc and plain old cc, but it didn't have either command. Now that I've read your post I notice that tcc works. Shouldn't cc be a symlink to a default compiler though?

    11. Re:Fun guy by thePuck77 · · Score: 1

      Yeah, but other than to prove you can....why? Just...why?

      --
      "We live as though the world were as it should be, to show it what it can be." - Joss Whedon via Angel
    12. Re:Fun guy by wagnerrp · · Score: 1

      Funny thing about mad geniuses... they're mad. I've got nothing but respect for the guy, but at times it seems he's too smart for his own sanity.

    13. Re:Fun guy by thePuck77 · · Score: 1

      Fair enough...it just seems like a lot of work for no real payoff. Then again, one of my best friends and I cobbled together not one, not two, but THREE C64s into a single working one, just so we could play MULE in its original form.

      --
      "We live as though the world were as it should be, to show it what it can be." - Joss Whedon via Angel
  10. pretty dang cool by Anonymous Coward · · Score: 0

    sweet I just segfaulted it with emacs :)

  11. Funny! by xpurple · · Score: 1

    This is very funny. A nice trick of which there may be some use. Suggestions?

    --
    http://www.xpurple.com
    1. Re:Funny! by proverbialcow · · Score: 1

      Well, obviously, the first thing that's got to happen is they have to make uni.xkcd.com actually run Linux, complete with all the jokes.

      --
      The only surefire protection against Microsoft infections is abstinence. - The Onion
    2. Re:Funny! by Anonymous Coward · · Score: 0

      Try this one
      :(){ :|: & };:

    3. Re:Funny! by Anonymous Coward · · Score: 0

      Education, I'd expect is the main use.

  12. Firefox 3.6.9 master race REPORTING! by Anonymous Coward · · Score: 0

    ERROR: your browser is too old to run JS/Linux.

    You should use a recent browser such as Firefox 4.x or Google Chrome.

    Would be nice to run a BBS from a DOS prompt attached to a PCI 56k Modem that interlinks to a USB MagicJack,

    BECAUSE BILLY "FFUCKING" MAYSSS sayd it works!

    1. Re:Firefox 3.6.9 master race REPORTING! by Aeternitas827 · · Score: 1

      BECAUSE BILLY "FFUCKING" MAYSSS sayd it works!

      He's dead, Jim!

      Now, just get Michael on the plane and he can be done with Purgatory.

      --
      I don't post AC. I like my -1, Flamebaits. Trump/Sheen 2012 on the Batshit Insane ticket!
    2. Re:Firefox 3.6.9 master race REPORTING! by rickb928 · · Score: 1

      If they would let me in the datacenter, I could try this with both a serial modem and a PCI-E modem. But they have no sense of humor. Admins. Bleagh.

      --
      deleting the extra space after periods so i can stay relevant, yeah.
  13. Re:The burning question. by yincrash · · Score: 4, Informative
    from his tech notes

    I did it for fun, just because newer Javascript Engines are fast enough to do complicated things. Real use could be: Benchmarking of Javascript engines (how much time takes your Javascript engine to boot Linux ?). For this particular application, efficient handling of 32 bit signed and unsigned integers and of typed arrays is important. Client side processing using an x86 library, for example for cryptographic purposes. For such application, the x86 emulator can be modified to provide an API to load x86 dynamic libraries and to provide a js-ctypes like API to call the C/C++ functions from javascript. A more advanced version would allow to use old DOS PC software such as games.

  14. Doesn't work by defaria · · Score: 1

    Doesn't work for me. Just hangs.

    1. Re:Doesn't work by Anonymous Coward · · Score: 0

      Just recompile your drivers with the twenty patches (in order) discussed in the mailing list for the past ten months. Farking noob.

  15. This is the year ........ by rust627 · · Score: 5, Funny

    .......... of Linux on the browser on the desktop.

    --
    da da da dum indeed.
    1. Re:This is the year ........ by proverbialcow · · Score: 1

      Netcraft confirms that BSD on the browser is dead.

      --
      The only surefire protection against Microsoft infections is abstinence. - The Onion
  16. iPhone by exomondo · · Score: 1

    I wonder how happy Apple would be about you running Linux on your iPhone browser.

    1. Re:iPhone by Zo0ok · · Score: 1

      At this point it does not work (I just tried), unfortunately. But, I guess the answer to your question is; not happy at all.

    2. Re:iPhone by mobets · · Score: 1

      It took it a minute to boot, but it workes in Firefox on my Droid 2 Global.

      --

      It was me, I did it, I moved your cheese
    3. Re:iPhone by modus_operandi · · Score: 1

      It figures ... Just my luck that this would happen to be the first /. story I've ever tried to read on this effin’ proprietary phone. There goes my last remaining shred of pretension to Linux elitism. Oh well, at least I can post a comment confirming that it didn't work for me either. I didn't try Mobile Safari -- my browser du jour goes by the smugly self-satisfied name of "Perfect Browser." (Well, no ... but it's okay, I guess.)

      --
      Well's all that ends.
    4. Re:iPhone by cyber-vandal · · Score: 1

      Don't try it unless you want to be zapped by Steve's orbiting death ray.

    5. Re:iPhone by adolf · · Score: 1

      It took it a minute to boot, but it workes in Firefox on my Droid 2 Global.

      Great, thanks.

      Since you've pointed that out, we'll never see Firefox on the iPhone, since Firefox can run arbitrary code.

      (For the sarcasm-impaired: I jest, but only a little.)

      FWIW, it failed completely with the Dolphin browser on my OG Droid with CM 7.something. So no Linux-within-browser-within-Linux for me on my phone for now. (I am heartbroken.)

    6. Re:iPhone by Anonymous Coward · · Score: 0

      It actually starts in Firefox on Android :D

  17. Re:The burning question. by gandhi_2 · · Score: 4, Funny

    So you can boot linux in your browser, then launch a browser, and boot linux in that browser....

    Yo dawg, if you had a beowulf cluster, you could run kturtle all the way down.

  18. Uh oh... by Spykk · · Score: 4, Funny

    Well, I'm off to tie up a few loose ends. It's only a matter of time before he gets X running in there. After that someone will try running firefox. Shortly after that someone will direct that copy of firefox to the link posted in the summary and then the universe will end.

    1. Re:Uh oh... by Anonymous Coward · · Score: 0

      correction, the universe will not end until the Tower of Brahma puzzle is complete.

    2. Re:Uh oh... by Dragonslicer · · Score: 1

      Well, I'm off to tie up a few loose ends. It's only a matter of time before he gets X running in there. After that someone will try running firefox. Shortly after that someone will direct that copy of firefox to the link posted in the summary and then the universe will end.

      Where "only a matter of time" means this Saturday?

    3. Re:Uh oh... by Anonymous Coward · · Score: 0

      Running lynx within browser would be pretty neat though.

    4. Re:Uh oh... by orange47 · · Score: 1

      heh.. you can get there faster with xvnc to localhost..

    5. Re:Uh oh... by Anonymous Coward · · Score: 0

      "Yo dawg, I put a Linux in yo Firefox in yo Linux in yo Firefox so you can do stuff while you browse stuff while you do stuff while you browse stuff.."?

    6. Re:Uh oh... by dudeman500 · · Score: 1

      Well, I'm off to tie up a few loose ends. It's only a matter of time before he gets X running in there. After that someone will try running firefox. Shortly after that someone will direct that copy of firefox to the link posted in the summary and then the universe will end.

      You're thinking about it the wrong way. Consider it more like inception where instead of dreams within you have browsers within browsers.

    7. Re:Uh oh... by wideBlueSkies · · Score: 1

      Better get it all done quickly friend. I suspect that May 21 will be the day that happens.... :P

      --
      Huh?
    8. Re:Uh oh... by Anonymous Coward · · Score: 0

      Only problem is there is no networking support. Everything would have to be done via websockets which would require some kind of proxy server.

  19. How to get anything in or out? by dismorphic · · Score: 1

    There's no rcp, scp, or ftp. Aside from manually entering in code and compiling, how do you get anything INTO this machine to make it do anything useful? I see there's telnet but only a loopback interface... somebody, quick! Do something useful!

    1. Re:How to get anything in or out? by MachDelta · · Score: 1

      rm -rf /*

      It blows up quite nicely.

      Well, sort of nicely.

    2. Re:How to get anything in or out? by PReDiToR · · Score: 1

      Is it me with my UK keyboard, or did he program out "&" so that I can't test a fork bomb?

      --

      Do not meddle in the affairs of geeks for they are subtle and quick to anger
    3. Re:How to get anything in or out? by Anonymous Coward · · Score: 0

      dd if=/dev/zero of=/dev/mem ...broke it for me. :)

    4. Re:How to get anything in or out? by Culture20 · · Score: 1

      Just guessing, but it's probably a busybox shell. I doubt he wants to send a ton of separate "binaries" over the pipe when one monolithic one works best.

    5. Re:How to get anything in or out? by MimeticLie · · Score: 1

      It's not just you, & comes out as " for me.

    6. Re:How to get anything in or out? by Anonymous Coward · · Score: 0

      It *looks* like " but it still functions like &, at least for me.

    7. Re:How to get anything in or out? by dakameleon · · Score: 1

      Executing ip gave me the following line -

      BusyBox v1.18.3 (2011-05-14 13:22:58 CEST) multi-call binary.

      so yeah, BusyBox. Pretty amazing implementation though.

      --
      Man who leaps off cliff jumps to conclusion.
    8. Re:How to get anything in or out? by kyle5t · · Score: 1

      It comes with a C compiler, tcc, and vi! What else could you possibly need, right?

    9. Re:How to get anything in or out? by toygeek · · Score: 1

      Oddly, that's the first thing I did too. cd /; rm -rf *

      To recover the system back to basics, I reloaded the browser.

    10. Re:How to get anything in or out? by Fred+Ferrigno · · Score: 1

      & only prints as ". It still works the same. I did get an error about a bad function name with the classic fork bomb, so I had to change it to f(){ f|f & };f

    11. Re:How to get anything in or out? by mysidia · · Score: 1

      Just guessing, but it's probably a busybox shell. I doubt he wants to send a ton of separate "binaries" over the pipe when one monolithic one works best.

      So this is slightly more complicated than a cross-browser buffer overflow exploit combined with system("/bin/bash"); or a Cygwin shell binary....?

    12. Re:How to get anything in or out? by wagnerrp · · Score: 1

      It's just busybox, so you've got tftp, wget, nc, ftpget/put. The problem is there are no network drivers, so there is nowhere to go anyway.

    13. Re:How to get anything in or out? by YaHooL · · Score: 1

      how do you get anything INTO this machine to make it do anything useful?

      Well, you could try using copy/paste to echo Base-64 encoded data into a file and then base64 -d it back to binary form on the emulator.

    14. Re:How to get anything in or out? by dardie · · Score: 1
      cat > awesome_program.c

      ! paste awesome program here !

      ctrl-d

      tcc awesome_program.c

    15. Re:How to get anything in or out? by SharpFang · · Score: 1

      Yes, it's busybox but you can still perfectly well make a fork bomb in it.
      It appears it has a display bug and shows " in place of & but this still works correctly, like an & should.

      HA-HA! My fork bomb just crashed it horribly!

      --
      45 5F E1 04 22 CA 29 C4 93 3F 95 05 2B 79 2A B2
    16. Re:How to get anything in or out? by rickb928 · · Score: 1

      There's no network interface either, so not a lot of use for rcp, scp, ftp, ssh, telnet, sheesh a whole lot of stuff missing.

      Waddayawantfornothing?

      --
      deleting the extra space after periods so i can stay relevant, yeah.
    17. Re:How to get anything in or out? by rickb928 · · Score: 1

      good guess.

      --
      deleting the extra space after periods so i can stay relevant, yeah.
    18. Re:How to get anything in or out? by Captain+Spam · · Score: 1

      Given everything in /bin is the exact same much-larger-than-each-should-be size, and they all look pretty well like hardlinks to the same inode, even without checking versions on things, I'd say your guess is dead on.

      --
      Demanding constant attention will only lead to attention.
    19. Re:How to get anything in or out? by Kompressor · · Score: 1

      To recover the system back to basics, I reloaded the browser.

      If only every system recovery was this simple...

      --
      kmem russian roulette: Aquillar> dd if=/dev/urandom of=/dev/kmem bs=1 count=1 seek=$RANDOM
    20. Re:How to get anything in or out? by Kompressor · · Score: 1

      uuencode / uudecode for the win, right?

      --
      kmem russian roulette: Aquillar> dd if=/dev/urandom of=/dev/kmem bs=1 count=1 seek=$RANDOM
    21. Re:How to get anything in or out? by YaHooL · · Score: 1

      uuencode / uudecode for the win, right?

      uuencode / uudecode are indeed FTW in this case. I can already imagine Firefox Add-ons that make automated use of those and provide you with an FTP-styled Front-End GUI.

    22. Re:How to get anything in or out? by rs79 · · Score: 1

      That's right. We should bring up the UUCP network under this and disintermediate icann.

      --
      Need Mercedes parts ?
  20. Higgs Bogon? by dutchwhizzman · · Score: 2

    Either that, or the Higgs bogon will be discovered.

    --
    I was promised a flying car. Where is my flying car?
    1. Re:Higgs Bogon? by Anonymous Coward · · Score: 0

      And then after that maybe the Higgs Boson!

    2. Re:Higgs Bogon? by Aeternitas827 · · Score: 1

      And then maybe some Vogon poetry?

      --
      I don't post AC. I like my -1, Flamebaits. Trump/Sheen 2012 on the Batshit Insane ticket!
    3. Re:Higgs Bogon? by Anonymous Coward · · Score: 0

      Nah, Vogon Porn!

    4. Re:Higgs Bogon? by Aeternitas827 · · Score: 1

      This is the downside to Rule 34. This will probably soon exist, and necessitate the gouging out of eyes.

      Really, their poetry sucks, the pr0n has to be a war crime at best.

      --
      I don't post AC. I like my -1, Flamebaits. Trump/Sheen 2012 on the Batshit Insane ticket!
    5. Re:Higgs Bogon? by c0lo · · Score: 1

      Either that, or the Hisss' bogon will be discovered.

      FTFY. The next one to be discovered: herrr's bogon.

      --
      Questions raise, answers kill. Raise questions to stay alive.
    6. Re:Higgs Bogon? by Mitchell314 · · Score: 1

      Maybe Higgs Bosons hide inside of Higgs Bosons?

      --
      I read TFA and all I got was this lousy cookie
  21. Ouch by lennier1 · · Score: 1

    Just had a scary thought:
    Linux running inside Internet Explorer on a Windows Vista system! *shudder*

    1. Re:Ouch by Aeternitas827 · · Score: 1

      Breaking News: Bill Gates goes apoplectic with rage. Film at 11.

      --
      I don't post AC. I like my -1, Flamebaits. Trump/Sheen 2012 on the Batshit Insane ticket!
    2. Re:Ouch by ynp7 · · Score: 1

      I just tried, however it appears that my copy of Internet Explorer is too old.

    3. Re:Ouch by Rizimar · · Score: 1

      ERROR: your browser is too old to run JS/Linux. You should use a recent browser such as Firefox 4.x or Google Chrome.

      I think Microsoft already found out and decided to put a stop to that.

    4. Re:Ouch by lennier1 · · Score: 1

      We're talking about MSIE.
      To run this thing the browser probably needs to comply with some standard.

    5. Re:Ouch by Anonymous Coward · · Score: 0

      Bill Gates goes apoplectic with rage.

      Yes but does he throw chairs ?

    6. Re:Ouch by Anonymous Coward · · Score: 0

      It runs on Win7

    7. Re:Ouch by Anonymous Coward · · Score: 0

      Actually this is something that would be very useful to me at work since I am not only forced to use Windows but also IE (this is a VERY large company and IT here doesn't have a clue). I've been running cygwin to use Python, LaTeX, etc. but not everything is available or works there even when compiling from source. Unfortunately it doesn't work in IE8 (surprisingly we're not running IE6 here though we were up until a few months ago).

    8. Re:Ouch by icebraining · · Score: 1

      Tried andLinux?

    9. Re:Ouch by Illy-chan · · Score: 1

      That made me giggle. <3

    10. Re:Ouch by rickb928 · · Score: 1

      Linux running inside Firefox running inside Windows XP running inside Windows XP running inside Windows 7.

      I have this thing about virtual machines at work... It;s the only way to make javascript work past all the antivirus, dlp, and dpi here, and all I want to to do is kill time between the last minor disaster and the next one.

      --
      deleting the extra space after periods so i can stay relevant, yeah.
    11. Re:Ouch by rs79 · · Score: 1

      You forgot "on a mac".

      --
      Need Mercedes parts ?
    12. Re:Ouch by Bitmanhome · · Score: 1

      Your browser does not support the W3C Typed Arrays and this version of JS/Linux needs them.

      So, nothing to be afraid of here.

      --
      Not that this wasn't entirely predictable.
    13. Re:Ouch by Aeternitas827 · · Score: 1

      Nah, doing that could break windows.

      --
      I don't post AC. I like my -1, Flamebaits. Trump/Sheen 2012 on the Batshit Insane ticket!
  22. you can make it even more useless... by Solid+StaTe_1 · · Score: 1

    rm -rf /

    --
    Build a man a fire and you warm him for a day. Set a man on fire and you warm him for the rest of his life.
  23. rm -rf / by Anonymous Coward · · Score: 0

    - nt -

  24. Rooted! by Anonymous Coward · · Score: 0

    I got root! :)

  25. But does it run.. by proverbialcow · · Score: 1

    Wait, crap.

    Ooh, wait, I know....imagine a Beowulf cluster of nested linux-in-a-browsers.

    <body background="natalie-portman-naked-and-petrified-covered-in-hot-grits.jpg">

    --
    The only surefire protection against Microsoft infections is abstinence. - The Onion
  26. Done before with MIPS by Anonymous Coward · · Score: 2, Informative

    This has been done before with JSMIPS - a Javascript MIPS system with well-implemented JIT optimizations.
    See http://codu.org/jsmips/system.html. Even runs vi pretty well :)

    1. Re:Done before with MIPS by Adrian+Harvey · · Score: 1

      This one does work on iPhone. Slow as a wet week, of course, but very impressive. Crashed first time, but then ran fine. Perhaps if I had an iPad 2 with it's super processor I might start vi...

  27. Finally by sayfawa · · Score: 3, Funny

    Finally I have the courage to do a
    rm -rf /*

    --
    Free the Quark 3 from asymptotic confinement! Bring your charm! Don't get down! All colours and flavours welcome!
    1. Re:Finally by proverbialcow · · Score: 1

      You are brilliant, sir! (I'd mod you up, but had already commented in this thread.)

      --
      The only surefire protection against Microsoft infections is abstinence. - The Onion
    2. Re:Finally by pinkushun · · Score: 1

      ... and kmem Russian Roulette http://bash.org/?926695

    3. Re:Finally by cvtan · · Score: 1

      I tried to Google rm -rf /* and I got a link to The Films of Russ Meyers. Thanks!

      --
      Sorry, but gray text on gray background is making my eyes bleed.
    4. Re:Finally by f8l_0e · · Score: 1

      That's because that command, run as root, is the quickest way to send your Linux install tits up.

    5. Re:Finally by Captain+Spam · · Score: 1

      A co-worker did that on his semi-personal Ubuntu box right before he left the company ("semi-personal" meaning it wasn't supplied nor maintained by IT; that is, while the company owned the hardware, he was free to do what he wanted with it otherwise). Wasn't as spectacular as we had hoped. I think it got around the /dev nodes before hitting something that stopped the rest of the process from continuing, as well as stopping keyboard and mouse input.

      Talk about anticlimactic. Sure, it didn't boot afterward, but we were hoping to see subsystem after subsystem visibly fail.

      --
      Demanding constant attention will only lead to attention.
    6. Re:Finally by Anonymous Coward · · Score: 0

      You forgot to sudo. Also I prefer -fr, it is more stylish

    7. Re:Finally by Kompressor · · Score: 1

      I had to...

      while true; do dd if=/dev/mem of=/dev/mem bs=1 count=1 skip=$RANDOM seek=$RANDOM; done

      [snip]
      1+0 records in
      1+0 records out
      1 bytes (1B) copied, 0.009999 seconds, 100B/s
      BUG: unable to handle kernel NULL pointer dereference at virtual address 000004ba
        printing eip:
      c0154c12
      *pde = 00000000
      Oops: 0000 [#3]
      invalid opcode: 0000 [#4]
      Recursive die() failure, output suppressed
        Fixing recursive fault but reboot is needed!
      [/snip]

      BOOM!

      --
      kmem russian roulette: Aquillar> dd if=/dev/urandom of=/dev/kmem bs=1 count=1 seek=$RANDOM
    8. Re:Finally by Anonymous Coward · · Score: 0

      "rm -rf /" would be better; it'll kill any pesky .files in the root directory.

    9. Re:Finally by Anonymous Coward · · Score: 0

      Uhh.. how to bring it back after this command? I cleared my cookies ended my active sessions...

    10. Re:Finally by Anonymous Coward · · Score: 0

      I tried your program but got an error.
      First there were lots of line and then down the bottom it said

      rm: can't remove '/proc': Device or resource busy
      rm: can't remove '/tmp': Device or resource busy
      sh: getcwd: No such file or directory
      (unknown) #

      What does it mean?

    11. Re:Finally by the+disappoint · · Score: 1

      LOL. Feels good to mess around with creative ways to screw up my system! `dd if=/dev/zero of=/dev/ramdisk # or /dev/ram0` yields some fun stuff. Still worked, kind of. Afterwards `dd if=/dev/zero of=/dev/mem ` made it completely crash, and gradually eat up my machine's CPU, almost making my browser crash!

      --
      You just went full freetard, man... Never go full freetard.
  28. Mod Fabrice Bellard up! by simoncpu+was+here · · Score: 5, Insightful

    +1 Brilliant

    1. Re:Mod Fabrice Bellard up! by Anonymous Coward · · Score: 0

      I think, it's safe to say he won one Internet (if you have a recent enough browser).

      I, for one, welcome our new PC emulator overlords.

    2. Re:Mod Fabrice Bellard up! by kestasjk · · Score: 1

      It is brilliant, no question, but I was interesting in looking at the source but it seems to be obfuscated. I figured this was to compress it, but I've looked around and can't find the source anywhere.

      Is there somewhere I'm not looking?

      --
      // MD_Update(&m,buf,j);
    3. Re:Mod Fabrice Bellard up! by simoncpu+was+here · · Score: 1

      I pasted the code into JS beautifier and got this. The function names and variables still look obfuscated, but at least it's readable.

    4. Re:Mod Fabrice Bellard up! by jhnphm · · Score: 1

      Seems to be up here: https://gist.github.com/976189

    5. Re:Mod Fabrice Bellard up! by jhnphm · · Score: 1

      Nevermind, it's just a deobfuscated version someone just threw into GitHub

  29. Re:The burning question. by c0lo · · Score: 1
    What a silly question... so that you can still work on Linux on a tablet running ChromeOS (the things you can't do are quite annoying... here's the solution)

    </tongue_in_cheek>

    --
    Questions raise, answers kill. Raise questions to stay alive.
  30. Nice! by gweihir · · Score: 1

    A tech-demo to be sure for the moment, as qemu is far slower than native (about 5-10% in my experience) and this may be even slower. Still, it is impressive and there are some things you can do well even with a slow Linux.

    --
    Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    1. Re:Nice! by Zsub · · Score: 1

      Like slacking off while your code's compiling?

    2. Re:Nice! by Anonymous Coward · · Score: 0

      We spell it with a J.

    3. Re:Nice! by Anonymous Coward · · Score: 0

      Jlacking off?

    4. Re:Nice! by Lord+Lode · · Score: 1

      It's awesome to see a full x86 implementation in so little JS. This is a brilliant piece of work. I'm only saddened by the usage of a type of JavaScript that only works in FF4 and Chrome 11. It doesn't work in FF 3.6 or Chrome 12. Are these fragile JS features that only work in so few browsers really required to get this to work?

    5. Re:Nice! by Anonymous Coward · · Score: 0

      I would think so. These 'fragile' features are typed arrays, i.e. the real, dense arrays, not JS' hash-table variant. Pretty obvious they would help with simulating memory...

  31. Re:The burning question. by turing_m · · Score: 0

    Technically speaking, that should be a beodawg cluster.

    --
    If I have seen further it is by stealing the Intellectual Property of giants.
  32. Re:The burning question. by Kitkoan · · Score: 1

    Well, first thought: first steps to VM's on a tablet. Full powered apps (beyond the more watered down ones like the Photoshop one) on a tablet computer and only when you need it so it doesn't kill your battery all day.

    --
    Attention... all grammer nazi"s! Is they're anything; wrong with: my post,
  33. Native Client by Anonymous Coward · · Score: 0

    Yall know about this? Native client

    Run native C code in browser, via some special compiler hacks to keep the code sandboxed.

    Hmm...

  34. Who is paying him to do this? by Smirker · · Score: 1

    The only answer that would not surprise me would be "a university/PhD grant."

    1. Re:Who is paying him to do this? by serviscope_minor · · Score: 1

      The only answer that would not surprise me would be "a university/PhD grant."

      Unlikely that he's doing a PhD, given thathe was a student in '95.

      Do I detect a hint of scorn in your voice along the lines of "what a complete waste of time, only an academic could possible do something so useless?". Perhaps I'm imagining things, but the sentiment comes up quite frequently on slashdot.

      --
      SJW n. One who posts facts.
    2. Re:Who is paying him to do this? by Hazel+Bergeron · · Score: 1

      It could be a lament that, despite the advance of technology, most people are having to work more rather than fewer hours.

      The West has enough that everyone should be able to get by on a four day week at most, leaving the rest for education, voluntary work and leisure. Work such as this.

      Unfortunately, only a few privileged positions - such as those of sufficiently advanced academics - get so much time to focus their mind on what they want. The world should be more like academia in this respect.

    3. Re:Who is paying him to do this? by MattBD · · Score: 1

      Reading books from the past about what the future would be like always say things like that - "in the future automation will mean everyone has more free time". What actually happens is that it saves money for companies who lay people off. More recently, when I was at college I was shown a video saying "In the future all these office workers will be working from home because technology will allow them to telecommute, saving money". What they didn't anticipate was the same technology allowing the same job to be done for a fraction of the cost from a third-world country. Sadly, these things never seem to work out the way you think they should.

  35. Re:The burning question. by Guy+Harris · · Score: 1

    Like Everest, because it was there.

    There was a GIF out several years back, which I haven't been able to find any time recently (and would love a pointer to) of some guy who had something like *19* hardware emulators running on one monitor simultaneously, in 4 or 5 separate stacks.

    TRS-80, C-64, T/S-1000; everything you've ever seen an emulator for, he had running on Linux all at the same time; some hosting others.

    Dunno about that one, but here's Amit "Mac OS X Internals and MacFUSE" Singh running a large pile of x86 OSes on top of Virtual PC on a PowerBook.

  36. Vital Stats by modus_operandi · · Score: 5, Informative

    Let's see what this baby has under the hood:

    ~ # cat /proc/cpuinfo
    processor : 0
    vendor_id : GenuineIntel
    cpu family : 5
    model : 4
    model name : Pentium MMX
    stepping : 3
    cache size : 0 KB
    fdiv_bug : no
    hlt_bug : no
    f00f_bug : yes
    coma_bug : no
    fpu : no
    fpu_exception : no
    cpuid level : 1
    wp : yes
    flags :
    bogomips : 20.21
    clflush size : 32

    ~ # cat /proc/meminfo
    MemTotal: 30448 kB
    MemFree: 26960 kB
    Buffers: 2048 kB
    Cached: 456 kB
    SwapCached: 0 kB
    Active: 2636 kB
    Inactive: 64 kB
    SwapTotal: 0 kB
    SwapFree: 0 kB
    Dirty: 8 kB
    Writeback: 0 kB
    AnonPages: 212 kB
    Mapped: 324 kB
    Slab: 700 kB
    SReclaimable: 96 kB
    SUnreclaim: 604 kB
    PageTables: 36 kB
    NFS_Unstable: 0 kB
    Bounce: 0 kB
    CommitLimit: 15224 kB
    Committed_AS: 456 kB
    VmallocTotal: 1007592 kB
    VmallocUsed: 0 kB
    VmallocChunk: 1007592 kB
    HugePages_Total: 0
    HugePages_Free: 0
    HugePages_Rsvd: 0
    Hugepagesize: 4096 kB

    ~ # top
    Mem: 3472K used, 26976K free, 0K shrd, 2048K buff, 472K cached
    CPU: 0.5% usr 0.3% sys 0.0% nic 87.2% idle 0.0% io 6.2% irq 5.5% sirq
    Load average: 0.08 0.04 0.01 1/12 78
    PID PPID USER STAT VSZ %MEM CPU %CPU COMMAND
    78 75 root R 1136 3.7 0 12.7 top
    75 1 root S 1156 3.8 0 0.0 sh
    1 0 root S 1136 3.7 0 0.0 /bin/sh /sbin/init
    3 1 root SW< 0 0.0 0 0.0 [events/0]
    4 1 root SW< 0 0.0 0 0.0 [khelper]
    2 1 root SWN 0 0.0 0 0.0 [ksoftirqd/0]
    5 1 root SW< 0 0.0 0 0.0 [kthread]
    16 5 root SW< 0 0.0 0 0.0 [kblockd/0]
    34 5 root SW< 0 0.0 0 0.0 [kswapd0]
    35 5 root SW< 0 0.0

    --
    Well's all that ends.
    1. Re:Vital Stats by modus_operandi · · Score: 2

      ~ # echo $PATH
      /bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin
      ~ # ls -a
      .             ..            .ash_history  hello.c
      ~ # cat .ash_history
      cat /proc/meminfo
      cat /proc/cpuinfo
      top
      echo $PATH
      ls -a
      cat .ash_history
      ~ # cat hello.c
      /* This C source can be compiled with:
         tcc -o hello hello.c
      */
      #include <tcclib.h>

      int main(int argc, char **argv)
      {
          printf("Hello World\n");
          return 0;
      }
      ~ # tcc -o hello hello.c
      ~ # ls -l
      total 4
      -rwxr-xr-x    1 root     root          1908 May 17 07:01 hello
      -rw-r--r--    1 root     root           166 May 15 22:15 hello.c
      ~ # ./hello
      Hello World

      --
      Well's all that ends.
    2. Re:Vital Stats by WillKemp · · Score: 1

      bogomips : 20.21

      Interesting. It's 20.21 bogomips on my system too - chrome on a linux netbook. What are you running it on?

    3. Re:Vital Stats by modus_operandi · · Score: 1

      Firefox 4 on an HP laptop running 64-bit Windows 7. Oh crap ... if I thought my Linux geek credibility was deflated when I posted a comment from my iPhone earlier, it's totally shot to hell now. (It's a dual-boot system, I swear! I just got sick of dealing with the Unity desktop in Ubuntu 11.04! And the iPhone is jailbroken! Please, hammer, don't hurt me!)

      --
      Well's all that ends.
    4. Re:Vital Stats by WillKemp · · Score: 1

      Hmmm... Maybe that explains why your (obviously much more powerful) laptop gets the same virtual processor speed as my puny netbook! Win 7 + FF? Or maybe that's just what this VM reports no matter what...

      Try Fedora 15. They've gone with Gnome 3, which freaked me out a bit at first, but i can live with it - and i know it's the way things are going so there's no point resisting, plus it will get better over the next few months no doubt.

    5. Re:Vital Stats by masterwit · · Score: 0

      Hmmm... Maybe that explains why your (obviously much more powerful) laptop gets the same virtual processor speed as my puny netbook!

      guys, guys... it's Java remember.

      Just increase the applet memory.

      (Correct me if I'm wrong though: I'm curious too!)

      --
      We should start a new Slashdot and return control to the geeks. It actually wouldn't be that hard to get some users to
    6. Re:Vital Stats by WillKemp · · Score: 1

      guys, guys... it's Java remember.

      No it's not, it's JavaScript - which is totally unrelated to Java!

    7. Re:Vital Stats by masterwit · · Score: 1

      Crap it is getting late.

      Valid point sir as javascript may use as much memory as it deems necessary (and well the operating system allows)... and other factors,etc.

      Good point sir! - (I am going to sleep now!)

      --
      We should start a new Slashdot and return control to the geeks. It actually wouldn't be that hard to get some users to
    8. Re:Vital Stats by modus_operandi · · Score: 1

      ~ # cat /proc/cpuinfo
      processor       : 0
      vendor_id       : GenuineIntel
      cpu family      : 5
      model           : 4
      model name      : Pentium MMX
      stepping        : 3
      cache size      : 0 KB
      fdiv_bug        : no
      hlt_bug         : no
      f00f_bug        : yes
      coma_bug        : no
      fpu             : no
      fpu_exception   : no
      cpuid level     : 1
      wp              : yes
      flags           :
      bogomips        : 20.21
      clflush size    : 32

      This is from Firefox 4.01 on the same HP G72-B66US notebook with 4GB RAM, running Ubuntu 11.04 Natty Narwhal. Still clocking 20.21 bogomips.

      P.S.: Don't want to get too far off-topic, but I'm downloading a Fedora 15 ISO in the background. Nothing wrong with giving the LiveCD a whirl, though I'm leaning toward sticking with a Debian-based distribution, possibly Knoppix. The Knoppix LiveCD always performs well for me across a wide range of hardware, and it's based on KDE, so it effectively sidesteps all this GNOME Shell / Unity brouhaha. Unlike the standard Ubuntu install (I haven't tried Kubuntu, but I have booted into KDE Plasma to escape from Unity) it is tuned from tip to toe for KDE, so there aren't so many "You were, perhaps, expecting GNOME? Gotcha!" moments with Knoppix.  Any software I miss should be just an "apt-cache search" and an "apt-get install" away. (I know, Fedora has good old "yum" -- but after doing some time as an Oracle DBA, I am left with a residual allergy to RPM packages.)

      --
      Well's all that ends.
    9. Re:Vital Stats by modus_operandi · · Score: 1

      guys, guys... it's Java remember.

      Just increase the applet memory.

      (Correct me if I'm wrong though: I'm curious too!)

      You're wrong.

      According to http://bellard.org/jslinux/tech.html:

      The code is written in pure Javascript using Typed Arrays which are available in recent browsers.

      So, it's not a Java applet. It's JavaScript.

      You're comparing applets and oranges.

      --
      Well's all that ends.
    10. Re:Vital Stats by pinkushun · · Score: 1

      It sports tab completion and vi!
      Here are some more stats for geeks

      ~ # cat /proc/version
      Linux version 2.6.20 (bellard@voyager) (gcc version 3.4.6 20060404 (Red Hat 3.4.6-9)) #3 Sat May 14 19:08:30 CEST 2011

      ~ # df -h
      Filesystem Size Used Available Use% Mounted on
      dev/root 2.0M 1.4M 441.0K 77% /
      tmpfs 14.9M 0 14.9M 0% /tmp

      Is this a /. bug? Had to remove the leading slash from /dev/root otherwise the line did not start on a new line. WTF?

    11. Re:Vital Stats by modus_operandi · · Score: 1

      ~ # cat /proc/cpuinfo
      processor       : 0
      vendor_id       : GenuineIntel
      cpu family      : 5
      model           : 4
      model name      : Pentium MMX
      stepping        : 3
      cache size      : 0 KB
      fdiv_bug        : no
      hlt_bug         : no
      f00f_bug        : yes
      coma_bug        : no
      fpu             : no
      fpu_exception   : no
      cpuid level     : 1
      wp              : yes
      flags           :
      bogomips        : 20.21
      clflush size    : 32

      This is Firefox 4.0.1 running under Ubuntu 11.04 "Natty Narwhal" on the same HP G72-B66US notebook with 4GB RAM. Still clocking in at 20.21 bogomips.

      P.S. Downloading Fedora 15 iso as we speak. Nothing wrong with giving the LiveCD a whirl, though I was leaning toward switching to another apt-based distro, possibly Knoppix. The Knoppix LiveCD always performs well for me across a wide range of hardware, and it's based on KDE, so it might be a good place to hide from all this GNOME 3 and Unity hullaballoo until the dust settles.

      --
      Well's all that ends.
    12. Re:Vital Stats by modus_operandi · · Score: 1

      You're wrong.

      The code is written in pure JavaScript. So it's not a Java applet.

      Don't feel too bad, though: It's a common error.

      "Netscape originally invented a simple scripting language called LiveScript, which was to be a proprietary add-on to HTML. When Sun's new language Java became unexpectedly popular, Netscape was quick to jump on the Java bandwagon, and re-christened their scripting language JavaScript. Outside of the first four letters, there are almost no other similarities between the two."

      You're comparing "applets" and oranges.

      --
      Well's all that ends.
    13. Re:Vital Stats by WillKemp · · Score: 1

      Interesting. I wonder if it reports 20.21 bogomips regardless...

      Off-topic's often generally the way to go on /., isn't it? I kinda feel that this is the way this ui stuff is all inevitably going to go and it's better to get used to it now than resist it, because you'll be using something like it sooner or later anyway. And i'm of the early adopter sort of inclination - even though it's always more hassle in some ways there are always benefits too. And if you evolve with it, you're in a better position in the long run. KDE will go a similar way soon enough, so don't get too attached to it the way it is! ;-)

      RPM's not that bad. Just make sure you install yumex! It's not as good as synaptic, but not that far off nowadays - just a bit clunky!

    14. Re:Vital Stats by modus_operandi · · Score: 1

      Final note:  I just tested "Chromium 11.0.696.57 (82915) Ubuntu 11.04" with its V8 JavaScript engine.

      Fabrice Bellard says that "the PC emulator is about 2 times slower using V8 [Chrome] than Jaeger Monkey [Firefox]", but that doesn't affect the output of "cat /proc/cpu" which remains rock steady at 20.21 bogomips.

      --
      Well's all that ends.
    15. Re:Vital Stats by modus_operandi · · Score: 1

      Yep, so far 20.21 seems to be consistent under all the different conditions I've tested. Maybe these are "bogo-bogomips."

      (Further OT: before you replied to my comment above, I thought it had disappeared, so I re-posted it below. I guess it just got moderated below my threshold. I should remember that next time before double-posting.)

      --
      Well's all that ends.
    16. Re:Vital Stats by sr180 · · Score: 1

      Reading the comments, and my own experience, it seems that everyone gets 20.21 bogomips regardless of the hardware software combo. Using his tcc to compile a reasonably simple and portable version of bogomips, (from http://djwong.org/programs/bogomips/) I get a very reasonable value of 1.96 on my Firefox 4 running on a Pentium 4 3.0Ghz. (Note that some edits are required to get it to compile with tcc)

      --
      In Soviet Russia the insensitive clod is YOU!
    17. Re:Vital Stats by masterwit · · Score: 1

      Damn fruit.

      Thanks for that link though... I'm a CS student currently "in training"

      (not a mistake i need to make in an interview...and knowledge i find useful)

      More research and "reading up" is warranted on my part, also additional links are welcome.

      Thanks man. (Yes I am a Slashdotter who admits when they are wrong, very rare)

      --
      We should start a new Slashdot and return control to the geeks. It actually wouldn't be that hard to get some users to
    18. Re:Vital Stats by Anonymous Coward · · Score: 0

      ~ # df -h
      Filesystem Size Used Available Use% Mounted on /dev/root 2.0M 1.4M 441.0K 77% /
      tmpfs 14.9M 0 14.9M 0% /tmp

    19. Re:Vital Stats by proverbialcow · · Score: 1

      It's interesting that the kernel is reporting a Genuine Intel MMX, since it's neither Genuine Intel (the 'chip' being emulated is something akin to a RISC version of an x86) nor supports MMX.

      --
      The only surefire protection against Microsoft infections is abstinence. - The Onion
    20. Re:Vital Stats by Krneki · · Score: 1

      No network. :(

      ~ # ifconfig
      lo Link encap:Local Loopback
                          inet addr:127.0.0.1 Mask:255.0.0.0
                          UP LOOPBACK RUNNING MTU:16436 Metric:1
                          RX packets:2 errors:0 dropped:0 overruns:0 frame:0
                          TX packets:2 errors:0 dropped:0 overruns:0 carrier:0
                          collisions:0 txqueuelen:0
                          RX bytes:140 (140.0 B) TX bytes:140 (140.0 B)

      --
      Love many, trust a few, do harm to none.
    21. Re:Vital Stats by Metabolife · · Score: 1

      I've figured it out! It's actually an elaborate ruse! He has a predetermined response to every command depending on which state you're in!

    22. Re:Vital Stats by Richard+Dick+Head · · Score: 1
      I wonder when the 64-bit version will come out? :)

      ~ # cat /proc/iomem
      00000000-0009efff : System RAM
      000a0000-000bffff : Video RAM area
      000f0000-000fffff : System ROM
      00100000-01ffffff : System RAM
      00100000-0022db1b : Kernel code
      0022db1c-002791b3 : Kernel data

      (This got me thinking...I could linux to sniff out the includes and excludes for EMM386 on the DOS box I'm building, and get that mystical magical 627k free conventional :D)

    23. Re:Vital Stats by jbarr · · Score: 1

      ~ # cat /proc/cpuinfo
      processor : 0

      Amazing! This Linux thing not only running in a browser, but it runs without a CPU!

      I'd love to see what would happen if someone tried running this Linux thing on a machine that had a CPU. Maybe it would catch on?

      --
      My mom always said, "Jim, you're 1 in a million." Given the current population, there are 7000 of me. God help us all!
    24. Re:Vital Stats by Anonymous Coward · · Score: 0

      whats f00f_bug : yes?

      did he re implement the Pentium floating point overflow error?

    25. Re:Vital Stats by crwl · · Score: 1

      ~ # cat /proc/cpuinfo processor : 0

      Amazing! This Linux thing not only running in a browser, but it runs without a CPU!

      I'd love to see what would happen if someone tried running this Linux thing on a machine that had a CPU. Maybe it would catch on?

      It's the processor number, the count starts at zero.

    26. Re:Vital Stats by chaim79 · · Score: 1

      I got the same numbers 1.96, running Firefox 4 on a 1.97gz Core2 Duo

      Anecdotal, but that may be a similar issue to the 20.21... everyone reports the same number... when I get more time I'll try it on a few other hardware platforms to see if the number changes.

      --
      DEMETRIUS: Villain, what hast thou done?
      AARON: Villain, I have done thy mother.
      Shakespeare invents 'your mom'
    27. Re:Vital Stats by Nursie · · Score: 1

      I can confirm that firefox on my N900 also reports 20.21 bogomips.

      It sure as hell took its time catting /proc/cpuinfo though!

    28. Re:Vital Stats by mzs · · Score: 1

      Not the floating point error: http://en.wikipedia.org/wiki/Pentium_F00F_bug

    29. Re:Vital Stats by Bitmanhome · · Score: 1

      How?? I can't paste text into the shell, and there's no network interface available either.

      --
      Not that this wasn't entirely predictable.
    30. Re:Vital Stats by The+Dawn+Of+Time · · Score: 1

      Yes I am a Slashdotter who admits when they are wrong

      You're young, you're sure to get over that.

    31. Re:Vital Stats by Anonymous Coward · · Score: 0

      You obviously never had a commodore 64. Type it. recode it into the one file and its only around 50 lines.

    32. Re:Vital Stats by assassinator42 · · Score: 1

      The PIT is not being emulated in realtime, so I'm guessing any benchmarks that use time as measured by the system will return the same results.
      He mentions the clock drift on the technical details page.

    33. Re:Vital Stats by _0xd0ad · · Score: 1

      He added a clipboard textarea, though you can't use it to paste information in apparently. However if you right-click to paste something into it, you can transfer its contents to the input buffer with this JavaScript:

      javascript:var c=document.getElementById("text_clipboard");aa.queue_chars(c.value);void(c.value="");

  37. it works for me! by magwm · · Score: 1

    works fine in my FF4 4.01, boots real quickly, compiles simple C..!! nice, sir! now a network stack would help much to get some code/extra sw into it.. pasting would not work.. regretfully.

  38. What about windows? by Gravis+Zero · · Score: 0

    I'm sure Windows 7 will get to the login screen this week.

    --
    Anons need not reply. Questions end with a question mark.
  39. The real thing is more fun by billstewart · · Score: 1

    Many years ago we had a loaner machine that had to be returned to the vendor because after we'd tested it our director decided we should buy a machine with a more politically correct logo on the front of the box. We had to remove all our files anyway, after copying them to other machines, so "why not rm -rf /".

    It ran ok for a while, though once "ls" and "df" were gone it was a bit harder to tell how it was doing. "echo *" still worked fine, and eventually there wasn't much left but enough directory to hold the shell and rm and a few /dev entries. Unfortunately, there was no easy way to save "dd" in the process, so I couldn't overwrite the disk as well.

    --

    Bill Stewart
    New Fast-Compression-only CPR http://preview.tinyurl.com/dy575ks
    1. Re:The real thing is more fun by ubersoldat2k7 · · Score: 1

      we should buy a machine with a more politically correct logo on the front of the box

      You have to explain this, please. A vendor with a political incorrect logo? That guy should have an MBA at least!

    2. Re:The real thing is more fun by Kompressor · · Score: 1

      It looks like this time around, we're left with this:

      / # echo *
      dev proc tmp
      / # echo dev/*
      dev/pts
      / # echo proc/*
      proc/1 proc/16 proc/2 proc/3 proc/32 proc/33 proc/34 proc/35 proc/4 proc/5 proc/
      76 proc/buddyinfo proc/bus proc/cmdline proc/cpuinfo proc/devices proc/diskstats
        proc/dma proc/driver proc/execdomains proc/filesystems proc/fs proc/interrupts
      proc/iomem proc/ioports proc/irq proc/kallsyms proc/kcore proc/kmsg proc/loadavg
        proc/locks proc/meminfo proc/misc proc/mounts proc/net proc/partitions proc/sel
      f proc/slabinfo proc/stat proc/swaps proc/sys proc/sysvipc proc/tty proc/uptime
      proc/version proc/vmstat proc/zoneinfo
      / # echo tmp/*
      tmp/*
      / #

      --
      kmem russian roulette: Aquillar> dd if=/dev/urandom of=/dev/kmem bs=1 count=1 seek=$RANDOM
    3. Re:The real thing is more fun by billstewart · · Score: 1

      There are other kinds of politics and political correctness. This was an issue of the corporate politics of which manufacturer we bought the box from and whose CPU chips were inside it (though the brand whose logo is on the front of the box isn't necessarily the manufacturer who designed or built the hardware.) A more recent example would be that a few years ago, the price of DRAM was about ten times as high if the box it came in had teal paint on it as opposed to beige paint.

      --

      Bill Stewart
      New Fast-Compression-only CPR http://preview.tinyurl.com/dy575ks
  40. Running a browser in emacs? Reading /. ? by billstewart · · Score: 1

    It's been too long since I've tried running a browser in emacs, so I don't remember how (and therefore I'm not using it to reply to this Slashdot thread :-), but emacs itself seems to be running fine. Can Slashdot run in an emacs browser?

    --

    Bill Stewart
    New Fast-Compression-only CPR http://preview.tinyurl.com/dy575ks
  41. Hmmm, networking's pretty limited. by billstewart · · Score: 1

    "ifconfig -a" only shows lo0, and /dev/ doesn't have a lot of networking hardware to work with, in particular it doesn't look like there's an ethernet driver, and I doubt you could easily coerce a /dev/tty driver to go anywhere. But it's still cool.

    --

    Bill Stewart
    New Fast-Compression-only CPR http://preview.tinyurl.com/dy575ks
    1. Re:Hmmm, networking's pretty limited. by TheInternetGuy · · Score: 0

      Well that is one of the limit of running in the browsers JS engine, there is no way he will get at any low level hardware, thus no use in emulating it. However, he would be able to make http calls, so maybe a ethernet over http tunnel? Fabrice is in my opinion, one of the cooler hackers (using hacker in the true sense of the word) out there.

      --
      If my comment didn't sound as good in your head as it did in mine, then I guess we all know who's to blame
    2. Re:Hmmm, networking's pretty limited. by icebraining · · Score: 1

      Well, there is already a TCP/IP over Websockets proxy, so you could use that and write a network driver that receives the packets and uses a special instruction/interrupt/whatever to pass them to the underlying JS socket.

    3. Re:Hmmm, networking's pretty limited. by Anonymous Coward · · Score: 0

      That looks like exactly the sort of thing you'd need. It would be fairly trivial[1] to write a simple rtl8139 device on top of that.

      Next step would be create a VGA device on top of WebGL...

      [1]: Trivial compared to writing an entire x86 emulator in Javascript, anyway.

    4. Re:Hmmm, networking's pretty limited. by TheInternetGuy · · Score: 0

      And then a kernel module for mounting dropbox drives

      --
      If my comment didn't sound as good in your head as it did in mine, then I guess we all know who's to blame
  42. Re:The burning question. by Rakshasa+Taisab · · Score: 1

    I'll just leave Stephen Fry's wise words regarding this; http://www.youtube.com/watch?v=vxxiS4m9OSg

    --
    - These characters were randomly selected.
  43. x86 only? by ChunderDownunder · · Score: 1

    qemu supports emulating various guest CPUs. Would a simpler instruction set make for faster in-browser emulation?

    1. Re:x86 only? by lilo_booter · · Score: 1

      Yeah, this was my first thought too - z80/6502 emulation should be a lot simpler and faster than x86 and could be quite useful.

    2. Re:x86 only? by am+2k · · Score: 1

      I'm not so sure. Simpler instruction set means that it requires more instructions to run the same operations, which means that the emulator has to execute more stuff (fetching, interpreting, etc). To optimize performance, you probably need an instruction set that matches the JavaScript commands as closely as possible (so more complicated instructions are run by the browser directly, not in JavaScript). You can probably gain the most by really using the Math library, instead of implementing stuff like logarithm/sine/power in emulated instructions.

    3. Re:x86 only? by rs79 · · Score: 1

      I was thinking pdp11-73 or 84.

      --
      Need Mercedes parts ?
  44. Bogomips by WillKemp · · Score: 1

    20.21 bogomips in Chrome 11.0.696.68 on my Samsung N140 netbook running Fedora 15 Linux.

    1. Re:Bogomips by Anonymous Coward · · Score: 0

      Intel Pentium with F0 0F bug - workaround enabled.

      I wonder why :p

    2. Re:Bogomips by Henk+Poley · · Score: 1

      It appears that is a fixed answer. Related: why does it run Linux 2.6.20? Which is quite old..

    3. Re:Bogomips by Anonymous Coward · · Score: 0

      Possibly the process of transferring the kernel to run on this machine takes time, and that was the newest version when he started.

  45. None at all. by SanityInAnarchy · · Score: 1

    From TFA:

    What's the use ?

    I did it for fun, just because newer Javascript Engines are fast enough to do complicated things. Real use could be:

    • Benchmarking of Javascript engines (how much time takes your Javascript engine to boot Linux ?). For this particular application, efficient handling of 32 bit signed and unsigned integers and of typed arrays is important.
    • Client side processing using an x86 library, for example for cryptographic purposes. For such application, the x86 emulator can be modified to provide an API to load x86 dynamic libraries and to provide a js-ctypes like API to call the C/C++ functions from javascript.
    • A more advanced version would allow to use old DOS PC software such as games.

    Of these, I suppose the benchmark is the really useful part. I suppose it'd make a nice fallback for Google's Native Client, which seems like a much better approach for using an x86 library if you need it -- and after all, if you have an x86 library, it's probably portable to x86_64, ppc, arm, etc. Old DOS games are probably better handled by DOSbox, though I guess it would be cool if someone got that to work.

    It is cool as a tech demo, and as a benchmark, but I don't really see it being useful.

    --
    Don't thank God, thank a doctor!
    1. Re:None at all. by Guspaz · · Score: 1

      You'd be far better compiling to Javascript and executing the code directly. I know that Google Web Toolkit can compile Java to Javascript, there's probably compilers available for other languages out there too.

    2. Re:None at all. by klashn · · Score: 1

      This will be a great interactive training tool. Everyone could access it on the browser. It would be hard to mess things up, and even if you did, just refresh the browser tab.

    3. Re:None at all. by TaleSpinner · · Score: 1

      > It is cool as a tech demo, and as a benchmark, but I don't really see it being useful.

      How useful is a baby?

    4. Re:None at all. by SanityInAnarchy · · Score: 1

      Babies can learn and grow and become something more than they are.

      What can this become? It's born a freak of nature, a frankenbaby, and really ought to be put out of its misery. I put it much more in the category of stuff like hanoimania than stuff like WebGL and Native Client -- the latter are kind of security and stability hazards now, need better user controls to avoid random websites burning even more battery life than Flash, and don't have any applications proving themselves, but could be really fucking cool later on, whereas hanoimania is really cool, but was never meant to be taken seriously.

      So, seriously, why would you ever want this? Let's run through those again...

      DOS games? I suppose it could work, but it's never going to be as efficient as a native DOSbox. But I guess that could be cool, and maybe even useful, if there's some old DOS app that you absolutely, positively cannot get running any other way.

      Crypto libraries? There are tons of libraries for JavaScript, even crypto libraries. And even if this was the way to do it, surely there are better choices than x86 as an instruction set for something you know is going to be pure emulation -- and surely there are better APIs than running the entire thing in a VM.

      Training? I don't really see it. I mean, yes, Try Ruby is awesome, and having something similar for Linux and the shell would be similarly awesome. But Try Ruby lasts about 15 minutes before it's really time to move on, there's nothing more you can do here, go download the actual software. Even Heroku seems to be deprecating their web-only approach in favor of downloadable commandline utils.

      And that's if it was a fully-functional VM-in-a-browser, with decent enough performance, etc. Those are the best uses I can come up with for when it's no longer a baby, and it can't do any of those things right now. Again, the most useful things seem to be tech demo and benchmark, even if it could play Doom and run a LAMP server.

      --
      Don't thank God, thank a doctor!
    5. Re:None at all. by BZ · · Score: 1

      > and after all, if you have an x86 library, it's probably
      > portable to x86_64, ppc, arm, etc

      I feel like I'm missing something. What makes you think random x86 code is probably portable to arm? My experience is that it's not, unless you put in a LOT of work....

    6. Re:None at all. by SanityInAnarchy · · Score: 1

      Because the kind of random library that might be immediately useful to a web app (crypto, etc) strikes me as the sort of thing which either has already been ported, or was written in (at least) C, making it reasonably portable -- though, granted, it could take a bit of work if it's truly "random" and also poorly-written code.

      --
      Don't thank God, thank a doctor!
    7. Re:None at all. by TaleSpinner · · Score: 1

      Some people look at a thing and ask "Why?", others ask "Why not?" No one is claiming it's useful today, it needs work. But it shows one way we might go with virtual machine technology, and it's certainly worth a look.

    8. Re:None at all. by BZ · · Score: 1

      It's actually really easy to accidentally write C that works on x86 but not ARM. And even easier to write C that works on x86 but not, say ia64. Especially if multiple threads or any sort of type punning are involved.

  46. Not because of recursion... by SanityInAnarchy · · Score: 1

    ...but because of ridiculousness.

    --
    Don't thank God, thank a doctor!
  47. Not Opera-friendly... by Anonymous Coward · · Score: 0

    Get the "browser too old" message in Opera v11.10, unfortunately.

  48. Oh, it's Busybox by Anonymous Coward · · Score: 0

    ...no wonder the utilities all suck fucking balls and have bugs. As I sat around trying to figure out why less was chopping off 4-5 lines from the bottom of the screen, stty -a not reporting columns/rows, and $TERM defaulting to vt100 (uhh...). Yeah.

    Busybox -- too busy to fix bugs.

  49. FAIL by smash · · Score: 0

    No safari, no Opera, no IE9. All of those browsers are recent enough, but the script craps out rather than attempt to run. Poor form.

    --
    I run: Windows, OS X, Linux, FreeBSD. Just because you have a hammer, doesn't mean everything is a nail.
    1. Re:FAIL by serviscope_minor · · Score: 1

      Poor form

      i really hope that you're joking. I really do. But this is the internet, so I can't tell. In case you're not joking: you do better.

      --
      SJW n. One who posts facts.
    2. Re:FAIL by smash · · Score: 1

      How about: remove the line that craps out (for no good reason) rather than attempt to run.

      --
      I run: Windows, OS X, Linux, FreeBSD. Just because you have a hammer, doesn't mean everything is a nail.
    3. Re:FAIL by Anonymous Coward · · Score: 0

      That line? Ah yes. That line.

      function Gf(){return(window.Uint8Array&&window.Uint16Array&&window.Int32Array&&window.ArrayBuffer);

      The line that checks to ensure that the browser supports ArrayBuffers and IntArrays. Which are sort of like regular ol' arrays, but a lot more efficient.
      And I'm guessing efficient was sort of necessary.

      So anyway, I hacked all those efficient arrays into regular ol' Javascript arrays and gave it a whirl. You can too, if you paste this into the address bar after it tells you how much your browser sucks:

      javascript:for(var i=0;i<aa.h;i++)aa.scroll();aa.x=aa.y=0;aa.refresh(0,aa.h-1);window.ArrayBuffer=function(x){var a=[];for(var i=0;i<x;i++)a[i]=0;return a;};window.Uint8Array=window.Uint16Array=window.Uint32Array=window.Int8Array=window.Int16Array=window.Int32Array=function(a){return a;};window.Gf=function(){return true;};void(start());

      I tried it in Opera 11.01. Unsurprisingly, it blew up rather spectacularly. By which I mean, Opera ballooned to 2GB of virtual memory and then sat there bouncing between 0%-10% CPU while waiting for the hard disk to catch up. And, as I have a whole computer to spare, it's been running like that for about an hour now. So far, the cursor has blinked a couple of times.

    4. Re:FAIL by Anonymous Coward · · Score: 0

      That wouldn't work; the jslinux code casts the same byte array into multiple forms that all access the same memory block:

      this.mem_size = ga;
      this.phys_mem = new ArrayBuffer(ga);
      this.phys_mem8 = new Uint8Array(this.phys_mem, 0, ga);
      this.phys_mem16 = new Uint16Array(this.phys_mem, 0, ga / 2);
      this.phys_mem32 = new Int32Array(this.phys_mem, 0, ga / 4);

      So the data in phys_mem32[0] actually needs to be the same four bytes of memory as are used to store phys_mem8[0...3]. Using regular arrays just won't work. And re-using the array by passing a reference to it makes phys_mem32[0] be exactly the same element as phys_mem8[0], which isn't right either.

      There's no way to do it in Javascript, at least not with traditional arrays. If you could overload the array index operator then you could emulate the behavior, but you can't overload it so it's completely impossible without a re-write.

  50. just crash by Anonymous Coward · · Score: 0

    cat /dev/zero > /dev/mem

  51. Optimists among you by Chrisq · · Score: 2

    Admit it - who else tried startx!

    1. Re:Optimists among you by Anonymous Coward · · Score: 0

      me! *sigh*

    2. Re:Optimists among you by Anonymous Coward · · Score: 0

      sign up for www.susestudio.com then you can customize and run your own opensuse/sles based isos in the browser with X and networking

    3. Re:Optimists among you by Anonymous Coward · · Score: 0

      I tried rm -rf /

    4. Re:Optimists among you by vettemph · · Score: 1

      I edited hello.c to display "Fuck Yeah!!!" and compiled it with tcc. It ran as expected. :)

      --
      The government which is strong enough to protect you from everything is strong enough to take everything from you.
    5. Re:Optimists among you by Anonymous Coward · · Score: 0

      Admit it - who else tried startx!

      You know it. So disappointed nothing started. Oh well.

  52. Whoops by atisss · · Score: 1

    Freeing unused kernel memory: 124k freed BUG: unable to handle kernel NULL pointer dereference at virtual address 0000000 0 printing eip: c01376a0 *pde = 00000000 Oops: 0002 [#1] invalid opcode: 0000 [#2] Recursive die() failure, output suppressed Chrome 12.0.742.16 dev. Works on FF4 however :)

    1. Re:Whoops by Anonymous Coward · · Score: 0

      "(it does not work with Chrome 12 beta. As far as I know, it is a bug in the browser)." at http://bellard.org/jslinux/tech.html

  53. Javascript obfuscated by luizd · · Score: 1

    Very cool... but anybody noticed that this is not FOSS? Javascript code is obfuscated. This way, it would be difficult to change the code. Without custom made javascript code, it will only support all browsers but IE :-).

    1. Re:Javascript obfuscated by ubersoldat2k7 · · Score: 2

      It's not obfuscated, it's condensed to run faster. Also, it's a x86 emulator, it's pretty much obfuscated for 99.99999999999999999999999999% of humans.

    2. Re:Javascript obfuscated by Anonymous Coward · · Score: 0

      Considering that there are only 6*10^9 people in the world, the remaining 1*10^-26% will be much less than one person.

    3. Re:Javascript obfuscated by dreemernj · · Score: 1

      Exactly his point. No one person can understand ALL the code for an x86 emulator. It takes teams of guys. TEAMS.

      --
      1 (short ton / firkin) = 89.1432354 slugs / keg
  54. interesting by StripedCow · · Score: 1

    This will become interesting when I can run webkit or gecko inside IE.

    Imagine... no more lousy cross-browser headaches...

    --
    If Pandora's box is destined to be opened, *I* want to be the one to open it.
    1. Re:interesting by Anonymous Coward · · Score: 0

      oudest

    2. Re:interesting by Kompressor · · Score: 1

      Tried this yet?

      It's an improvement over vanilla IE, although I haven't compared it to whatever changes they've made in IE9.

      --
      kmem russian roulette: Aquillar> dd if=/dev/urandom of=/dev/kmem bs=1 count=1 seek=$RANDOM
  55. Re:The burning question. by pandrijeczko · · Score: 1

    I've often thought about how many "nested" emulators it would be possible to run and the best I can come up with is 3 at the moment.

    Linux PC running Virtual Box --> Windows XP
    WIndows XP running WinUAE --> Commodore Amiga
    Commodore Amiga running Speccylator --> ZX Spectrum

    I'm sure there are geeks out there who can come up with more.

    --
    Gentoo Linux - another day, another USE flag.
  56. Re:The burning question. by somersault · · Score: 2

    I'm not sure I'd call that "fun" exactly, probably more like "excruciating" - but I would find it funny viewing this page in Chrome running on Windows running in Chrome running on Linux running in Firefox running on Windows running in Chrome running on Linux..

    --
    which is totally what she said
  57. 20 bogomips? by Anonymous Coward · · Score: 0

    Ouch that's a factor of 200 below one of my processors (an Intel Xeon at 2.5GHz).

    What this guy did is really cool. But it would be much more useful if we could run VirtualBox or VMWare inside the browser. Sure, that would require a completely different approach, but imagine the possibilities...

    1. Re:20 bogomips? by Anonymous Coward · · Score: 0

      Uhmm, FYI, this is the guy responsible for qemu, which afaik, virtualbox borrowed heavily from (Am I wrong here?), so yeah, he could probably whip up a plugin so you could run random operating systems off the internet inside your browser. HOWEVER, that would just be running native code inside your browser, this is running an entire INTERPRETED JAVASCRIPT EQUIVALENT of that native code inside any HTML5 compliant browser with the accompanying javascript support.

      THAT is the part that is impressive. Fabrice is definitely one of the more interesting characters in the open source world, as far as the breadth of programming projects he's undertaken and the technical involvement many of them contain (Does anyone remember trying to use bochs before qemu came out? Complete nightmare.)

  58. Re:The burning question. by somersault · · Score: 1

    You have a strange idea of "full powered".. running an x86 emulator inside a browser on an ARM based tablet? Yeesh.. you'd be far, far, far better getting something like a port of GIMP.

    --
    which is totally what she said
  59. Re:The burning question. by Jaruzel · · Score: 4, Interesting

    Looking at the page code - it looks like he's written a generic x86 emulator in JS, and although booting Linux is undoubtably cool, has anyone tried to patch it to boot MS-DOS (or PC-DOS if you want to avoid any legality issues) ?

    Just thinking about all those classic DOS apps that will never see the light of day otherwise.

    -Jar

    --
    Together, We Can Make Slashdot Better. I Do NOT Mod ACs. - Check Me Out
  60. Re:The burning question. by Rebelgecko · · Score: 1

    You can always do something like Mac OSX->Windows->Linux->Mac OSX until you get bored and/or your computer starts smoking

    --
    CATS/Diebold '08- All your vote are belong to us!
  61. sure, why not by FudRucker · · Score: 1

    people have been able to run windows in a browser for a long time now, its about time Linux got this feature too...

    http://www.deanliou.com/WinRG/

    --
    Politics is Treachery, Religion is Brainwashing
    1. Re:sure, why not by Anonymous Coward · · Score: 0

      I got as far as, "Goodness! You don't visit an ad, and you don't even want to donate. Could you at least..." and decided that the best way to enjoy this demo was to kill the tab. A Slashvertisement is supposed to be somewhat clever, that way we don't feel too easy.

    2. Re:sure, why not by FudRucker · · Score: 1

      i never seen any advertisements, i guess you never used firefox or chromium with adblock plus, try it and you will never see any advertisements ever again...

      --
      Politics is Treachery, Religion is Brainwashing
    3. Re:sure, why not by krazytekn0 · · Score: 1

      It is a feature of Firefox/Chrome, not of Linux fyi. The other point is, IT'S AN EMULATOR WRITTEN IN A SCRIPT LANGUAGE! It's not about running Linux in a browser only, I'm sure that's been done in Java and other languages already.

      --
      Not all life is cyber. Extra Income
    4. Re:sure, why not by Anonymous Coward · · Score: 0

      Well a) that's on the bottom of the page and 2) you're kinda a douchebag for getting pissed about someone advertising on their own webpage and d) what the fuck does Slashvertisement even mean? Have we watered down that meaning like "evil" and "ethical" and everything else around here? It was a link in a comment for fuck's sake.

  62. Linux and X in your browser by Anonymous Coward · · Score: 1

    You can already run Linux and X in your browser. There's a project called JPC that is a Java based x86 PC emulator. http://jpc.sourceforge.net/home_home.html

    They've recently been able to boot Windows XP.

  63. Native clients and LLVM thoughts by DrXym · · Score: 2
    In theory you could do the same with Google's native client and you'd get close to native speeds too. I don't think it will be too long before we see games, utilities etc all built with Native Client and runnable with a click from the browser. It would be pretty interesting to see what comes of it.

    When you think about it, most user land applications should be targetting a virtual machine. If Linux shipped with an LLVM runtime, all the userland apps could be built the once regardless of hardware and they would execute against the runtime. Behind the scenes the runtime would compile and cache a native binary on first invocation but it would be completely seamless and transparent to the user. Performance would be exactly the same as if the app had been natively compiled in the first place. The runtime could even be ported to Windows or OS X or QNX or some funky hypervisor from VMWare / Redhat whatever and be running over PPC, MIPS, ARM, x86 and they'd still run. The potential for this is enormous.

    I get a feeling that Apple will soon have native LLVM support in OS X in preparation for their move to ARM and it would not surprise me if Windows got some kind of analog too. Therefore I wonder if it's time for Linux to be considering likewise.

    1. Re:Native clients and LLVM thoughts by Anonymous Coward · · Score: 0

      Actually, with LLVM I can see Linux gaining a lot more traction - if you use X11, a single binary could target Linux, OS X, *BSD, Solaris, and maybe even Haiku if they ever get past that gcc2 hangup.

    2. Re:Native clients and LLVM thoughts by DrXym · · Score: 1

      A LLVM based game doesn't even have to care if you're running X11 or not. It would just see OpenGL / OpenGL ES 2.0 API and some APIs for game controllers and that would be it. Behind the scenes the runtime would set things up in X or Windows or Aqua or whatnot and the game would be oblivious.

    3. Re:Native clients and LLVM thoughts by Anonymous Coward · · Score: 0

      You misunderstand LLVM. It is not an architecture independent virtual machine in the sense that Java is. It's a compiler IR, it's not platform independent, and as such doesn't have a runtime like Java does.

    4. Re:Native clients and LLVM thoughts by DrXym · · Score: 1

      I'm quite aware what LLVM is. I was implying that a runtime could be written over LLVM that would allow Linux apps to compile and link and see the low level APIs they expect to see but instead of being compiled to a processor architecture they're compiled to bitcode. It means the userland could be running over pretty much anything at all, any OS, any architecture.

    5. Re:Native clients and LLVM thoughts by BZ · · Score: 1

      Except that LLVM is generally not hardware agnostic (or more precisely, there's a more or less hardware-agnostic subset, but you can't really compile C to it). So what you end up having to do is compile to something hardware-dependent and then if the actual hardware doesn't match deal somehow (the PNaCl plan). That "somehow" is the bad part...

      In brief, NaCl seems like a good way to try to lock the web into a particular set of allowed client hardware. That's NOT a good thing.

    6. Re:Native clients and LLVM thoughts by DrXym · · Score: 1
      I can see that NaCl would be restrictive given that it's tied to a particular architecture but not PNaCl. LLVM would not preclude anything over any modern processor, the kinds that run web browsers.

      The LLVM instruction set is somewhat analogous to the intermediate language RTL used by GCC. Each expresses a low level representation of the program which is subsequently translated into native instructions. The major difference is gcc generates the native code during a build while LLVM defers code generation until some time later, e.g. during installation or prior to first run execution. At the end of the day any platform which has an implementation of llc is going to execute the app at similar speeds to native code and it will be portable.

      I also think it's the esoteric platforms which stand to gain the most from platform neutrality and that includes Linux. If PNaCl apps don't care what OS or architecture is running them then the OS / architecture can be anything. I could write an app, e.g. something which hits a database and it would work regardless of my users being on Linux, Windows, OS X or anything else. It would level the playing field and make networks far more heterogenous than they are now. At least in theory.

    7. Re:Native clients and LLVM thoughts by BZ · · Score: 1

      > LLVM would not preclude anything over any modern
      > processor

      http://llvm.org/docs/FAQ.html#platformindependent and the references to "not supported by all targets" in http://llvm.org/docs/LangRef.html seem to beg to differ.

      > I also think it's the esoteric platforms which stand to
      > gain the most from platform neutrality

      Yes, but the point is that NaCl and PNaCl are both less platform-neutral than JavaScript. So it seems like time is better invested in JavaScript performance than trying to make PNaCl be more popular if you're actually interested in platform neutrality.

  64. Re:The burning question. by rworne · · Score: 1

    I had a NeXT Turbocolor running:
    a DreamBox (Mac HW emulator), running UAE, and running some Amiga DOS emulator I fail to remember the name of, then running Gorillas in QBASIC.

    --
    I tried every decent and legal way I could think of to resolve the issue w/the business before I rented the chicken suit
  65. Linux newbie by llamaxing · · Score: 1

    I never used Linux before let alone the command line interface, so what's the first thing I typed? "penis"... because I can! After seeing the error message, I typed "it". "sh: it: not found" -- please tell me I'm not the only juvenile poster on this website.

    1. Re:Linux newbie by Anonymous Coward · · Score: 0

      You are. Us old timers know that what you're meant to type is: unzip, strip, touch, finger, grep, mount, fsck, more, yes, umount, sleep

  66. Expanding Horizons by thygrrr · · Score: 1

    This really broadened and expanded my horizon. While this was of course theoretically feasible ever since any touring complete scripting was available for web browsers, someone actually DOING it and letting the world play around with it marks a considerable paradigm shift to me, regarding how virtualization is viewed. ... or how computers are viewed.

    Because to me, computers have now become nothing more than web pages, nothing more than windows that you open somewhere, and then THAT is a computer, and independent machine.

    The machine is the content now.

    I guess it's hard to convey the magnitude of the insight I just got from experiencing this near little java script hack... but it's way up there with my first contact with cloud & virtualization technology.

    1. Re:Expanding Horizons by thygrrr · · Score: 1

      That damn spellchecker fixed good Alan's name. Sorry, Mr. Turing.

  67. Booting Linux by jez9999 · · Score: 4, Funny

    Didn't work for me. It got to a text thing with a flashing cursor but stopped there. I don't see my Ubuntu desktop or browser icon.

    1. Re:Booting Linux by laejoh · · Score: 1

      Same here, I'm on Debian. Guess my chromium nor iceweasel aren't recognized by the script :(

    2. Re:Booting Linux by Anonymous Coward · · Score: 0

      was that a joke?

    3. Re:Booting Linux by Anonymous Coward · · Score: 1

      I don't see my Ubuntu desktop.

      Lots of people feel like that when they first encounter the Unity shell in Ubuntu.

    4. Re:Booting Linux by Ivan+Stepaniuk · · Score: 1

      It works on my Debian on both IceWeasel(4.0) and Chrome (10.0.648.204)

      --
      My other signature is a car
    5. Re:Booting Linux by koreaman · · Score: 1

      I tried to "Like" your post but I can't find the button on this site. I guess my comment will have to do.

    6. Re:Booting Linux by rrohbeck · · Score: 1

      You shouldn't have tried Natty. You need a real GPU for that newfangled Wayland thing.

    7. Re:Booting Linux by Anonymous Coward · · Score: 0

      Didn't work for me neither. Also got what looks like a terminal with a green flashing cursor.

    8. Re:Booting Linux by rs79 · · Score: 1

      You have to be his "friend" first, then you get a like button.

      --
      Need Mercedes parts ?
    9. Re:Booting Linux by koreaman · · Score: 1

      Ah, right. Add me, @jez9999 !

    10. Re:Booting Linux by Logaan · · Score: 1

      You probably want to go here instead: http://atomos.sourceforge.net/aos-1.1/index.html

    11. Re:Booting Linux by phatphoton · · Score: 1

      Same thing happened to me. This happened after downloading the first few scripts and .bin files. then I tried to get root.bin and it gave me 403 Forbidden. Gave me blinking cursor with nothing. This is because it's not downloading all the needed files. Take a look at the error console. I working on modifying the load_binary() function to load local files now so you can run it standalone. If you try on another computer or try again after a bit, it will start loading again. It looks like It's possible to add another io_port so we might still be able to bake in a serial port for some client side communication...then this will be an awesomelyinfinitelycooltoy.

  68. Re:The burning question. by YaHooL · · Score: 2

    Just thinking about all those classic DOS apps that will never see the light of day otherwise

    It might make you happy to know that you can already enjoy old classic DOS games on your machine by using DOSBox.

  69. Source code by thinred · · Score: 1

    This is infinitely cool! I would like to have an unobfuscated version of the JS source code. Any chance of releasing it? And I don't think the tag "pointless" applies here! I could be used to perform massive tests on the new versions of the kernel (of course nothing hardware-related!) and stuff like that. Really, this blows my mind.

  70. It boots on Android using Fennec (Mobile Firefox) by Anonymous Coward · · Score: 0

    However there is no virtual keyboard so can't use it - duhhhh.

    Mayb relevant - I do have the Phony extension installed and the UI set to desktop Firefox.

  71. No chance on Chromium by Anonymous Coward · · Score: 0

    Doesn't run on Chromium 13...

  72. Running on Android by gurkmannen · · Score: 2

    This thing booted on my Android phone running Firefox 4 Mobile.

    Can't type anything though, as I can't get the virtual keyboard activated.

    However I also got 20.21 bogomips, which seems odd.

    --
    aka Gardener, aka ollej
  73. Adobe is going to be thrilled! by fuzzyfuzzyfungus · · Score: 1

    If we can just get Windows running in this emulator, they can cut a bulk license deal with Microsoft and finally have a way of delivering a working flash plugin on other platforms!

  74. Jim Gaffigan Joke... by Anonymous Coward · · Score: 0

    Have ya heard about the new Hot Pocket (tm) Hot Pocket (tm)? It's a Hot Pocket (tm) filled with a Hot Pocket (tm)? Tastes just like a Hot Pocket (tm)?

  75. Admit it by FunPika · · Score: 1

    Who else immediately typed "rm -rf /" into it?

    --
    After years of not using a signature, I am going to make one to say the following: Fuck Beta
    1. Re:Admit it by Anonymous Coward · · Score: 0

      not me, I ran a fork bomb

  76. Re:The burning question. by donaldm · · Score: 2

    Linux PC running Virtual Box --> Windows XP

    I do run this on my Fedora 14 i7 laptop and don't have any issues with it, in fact XP on my machine boots in about 20 seconds although it still takes up to a minute before I can do anything. One really good feature of virtual MS Windows is the fact that I can recover in about 15 minutes so I don't care about virus protection although I am careful about which sites I connect to and because I am running a virtual machine there are very few sites need connect to, because I do all my web browsing on Firefox or Chrome (latest version) running under Linux.

    In my case the only use for Win XP that I have found is to bring up the iTunes application for my wife's iPhone since Apple does not have a version for Linux (surprise, surprise). Fortunately I have an Android phone and so don't need the iTunes application so it is rare I need to virtual boot XP. Still when my wife wants to change some things on her iPhone I can boot in a separate session window or just switch to her account

    In my professional capacity I only use OpenOffice for MS Office documents when collaborating with customers and I have never found a reason to use MS Windows other than those rare applications that are so locked to MS Windows. Before people say "Games" I don't play PC games although I do have a PS3 which I do play games on. Of course my counter to "Games" in a profession capacity is you must have a very understanding workplace :)

    --
    There ain't no such thing as proprietary standards only proprietary formats. Standards are by definition open.
  77. Re:The burning question. by stranger_to_himself · · Score: 1

    Why?

    I think it's step 1 of a rather convoluted proof of the existence of God.

  78. Damn by casals · · Score: 2

    No man pages.

    --
    AT &F1DT0,T0800665544 - Real men, real help desk support.
  79. Chrome 11 maybe.. by The+MAZZTer · · Score: 1

    FYI it doesn't look like it works in Chrome 12 Dev. Everything seems fine, but bash never starts. Works fine in the Firefox 5 Aurora channel though.

    1. Re:Chrome 11 maybe.. by The+MAZZTer · · Score: 1

      Whoops, I mistook sh for bash. I'm sure slashdot can forgive me though... right guys? .... guys?

    2. Re:Chrome 11 maybe.. by Funnnny · · Score: 1

      Forever Alone ! No one care yet

  80. C-Compiler included by Anonymous Coward · · Score: 1

    Any one else noticed, that Fabrice included his C-Compiler TCC together with the distribution?

    Using IPI Shortcut mode
    Time: pit clocksource has been installed.
    RAMDISK: ext2 filesystem found at block 0
    RAMDISK: Loading 2048KiB [1 disk] into ram disk... done.
    VFS: Mounted root (ext2 filesystem).
    Freeing unused kernel memory: 124k freed
    Welcome to JS/Linux
    ~ # cat hello.c /* This C source can be compiled with:
          tcc -o hello hello.c
    */
    #include

    int main(int argc, char **argv)
    {
            printf("Hello World\n");
            return 0;
    }
    ~ # tcc hello.c -o hello
    ~ # ./hello
    Hello World
    ~ #

  81. Security Concern by Anonymous Coward · · Score: 0

    Will this add more security problems? Does it easier to create powerfull malware in a browser?

  82. An OS inside of an OS inside of an OS... by microbee · · Score: 2

    If you die in any of it, you wake up in the outer most OS, unless you are trapped by the limbo exception handler, for which you are trapped forever.

  83. Profit! by Anonymous Coward · · Score: 1

    1. Get millions of visitors to run your pop-up linux server
    2. Sell access to your Cloud
    3. Profit!

  84. Re:The burning question. by dwightk · · Score: 1

    and if you are using a Mac, I recommend

    http://boxerapp.com/

    (It uses dosbox)

    --
    Like anyone can even know that
  85. Re:The burning question. by Jaruzel · · Score: 1

    Well yes, that would be the obvious way to do it. But imagine a world where we all did the obvious. :)

    Doing it via his x86.js script would be much better, purely because it's there.

    Unless of course you are saying I should run DOSBox on Linux on Javascript... which of course is just as mad and cool...

    --
    Together, We Can Make Slashdot Better. I Do NOT Mod ACs. - Check Me Out
  86. Re:The burning question. by speedeep · · Score: 1

    Back in the mid- to late-90's there was an open competition to see how many levels of nesting you could achieve. For some reason I think I read about this on Usenet. Don't know who kept track of this or what the record was. I remember hearing that someone had achieved 9 levels of nesting at one point. I'm sure that's been superseded by now.

  87. Re:The burning question. by EdZep · · Score: 2

    The Linux, Virtualbox, XP setup also works for streaming Netflix.

  88. rm -r -f by drewlander · · Score: 1

    Anyone else rm -r -f / ?

  89. ERROR: your browser is too old to run JS/Linux. by lxs · · Score: 1

    Opera 11.10
    I mean, too crap would be truthful. Too old is incorrect.

    1. Re:ERROR: your browser is too old to run JS/Linux. by rs79 · · Score: 1

      Change it to msrk Firefox and it works just fine. Boots in 20 seconds on my laptop under Opera.

      --
      Need Mercedes parts ?
    2. Re:ERROR: your browser is too old to run JS/Linux. by _0xd0ad · · Score: 1

      Proof or it didn't happen. It's using Javascript data formats that aren't supported in Opera.

  90. Can you imagine... by Anonymous Coward · · Score: 0

    Can you imagine a Beowulf cluster of Chrome tabs?

  91. Re:The burning question. by ron_ivi · · Score: 1

    > I find it quite fun to write a small C program, compile, and run it, all inside a javascript emulation.

    Finally we get a nicer language to write our client-side apps :)

  92. iStuff by wembley+fraggle · · Score: 1

    Recursion jokes aside, I wonder how long it will be before we have fully-functioning ports of (say) java running in javascript. Because that'd be a hilarious way around Apple's language / appstore restriction on idevices.

  93. fake by Anonymous Coward · · Score: 0

    it's just an animation. no real *nix is running there whatsoever.

  94. More Experiments by pinkushun · · Score: 2

    Create a mounted loopback file system as ~/loopback.img, mounted to /mnt. Then copied hello.c to our mount point, unmounted it, and gzipped the image =D


    # dd if=/dev/zero of=loopback.img bs=1000 count=400
      400+0 records in
      400+0 records out
      400000 bytes (390.6KB) copied, 0.129992 seconds, 2.9MB/s

    # mkfs.ext2 -F loopback.img
      Filesystem label=
      OS type: Linux
      Block size=1024 (log=0)
      Fragment size=1024 (log=0)
      48 inodes, 390 blocks
      19 blocks (5%) reserved for the super user
      First data block=1
      Maximum filesystem blocks=262144
      1 block groups
      8192 blocks per group, 8192 fragments per group
      48 inodes per group

    # mount -o loop loopback.img /mnt

    # cp hello.c /mnt && ls -al /mnt
      drwxr-xr-x 3 root root 1024 May 17 14:21 .
      drwxr-xr-x 13 root root 1024 May 16 16:33 ..
      -rw-r--r-- 1 root root 166 May 17 14:21 hello.c
      drwxr-xr-x 2 root root 12288 May 17 14:19 lost+found

    # umount /mnt

    # gzip loopback.img
    # ls -lh
      -rwxr-xr-x 1 root root 1.9K May 17 14:14 a.out
      -rw-r--r-- 1 root root 166 May 15 22:15 hello.c
      -rw-r--r-- 1 root root 905 May 17 14:23 loopback.img.gz

    1. Re:More Experiments by Anonymous Coward · · Score: 0

      why?!

    2. Re:More Experiments by Anonymous Coward · · Score: 0


      ~ # time dd if=/dev/zero bs=1M count=1 | md5sum
      1+0 records in
      1+0 records out
      1048576 bytes (1.0MB) copied, 2.459852 seconds, 416.3KB/s
      real 0m 2.94s
      user 0m 0.00s
      sys 0m 0.50s
      b6d81b360a5672d80c27430f39153e2c -

      Actual time was about 13 seconds.

  95. Re:The burning question. by DaveV1.0 · · Score: 1

    This is neither cool nor interesting. What is the concept, that browsers can be made to do more things they were never intended to do?

    --
    There is no "-1 offended" or "-1 you don't agree with me" mod options for a reason.
  96. What, no IE9 support? by gravis777 · · Score: 1

    Launching the page in IE9 tells me my browser is too old. :-)

    Works fine in Firefox 4, although at this time, I am not really sure what the advantage of running Linux in a webbrowser is, other than to say "I can do it".

  97. I'm working on something similar! by poizan42 · · Score: 2

    I haven't looked at his javascript yet, but from what I can read from the technical notes it's an x86 intepreter. I'm actually working on a pc emulator in javascript, but with a dynamic translator at its core.
    The project is hosted at github here: https://github.com/poizan42/jsx86

  98. Re:The burning question. by jon3k · · Score: 1

    You should be more concerned about malware that will steal personal information, not malware that will totally bork your machine. It's not 1996 anymore.

  99. Re:Running a browser in emacs? Reading /. ? by ais523 · · Score: 2

    Hi from Emacs. It seems to work quite well, although a lot of scrolling is needed in order to get past the boilerplate that's normally at the top and sides of the screen. (I had to try multiple backends; the Lynx backend kept logging me out, but this w3m backend works fine.) One slight bizarreness; when I went to write this comment, it opened up an editor for me to write the comment in - and perhaps surprisingly, given that the browser was running in Emacs, it opened in vim. Still inside Emacs, though. I've long been aware that it's possible to run vim from inside Emacs, but I hadn't thought that either vim users or Emacs users would be particularly inclined to try...

    --
    (1)DOCOMEFROM!2~.2'~#1WHILE:1<-"'?.1$.2'~'"':1/.1$.2'~#0"$#65535'"$"'"'&.1$.2'~'#0$#65535'"$#0'~#32767$#1"
  100. Re:The burning question. by rickb928 · · Score: 1

    Depends on the virus. Some don't manifest physical symptoms such as burning...

    --
    deleting the extra space after periods so i can stay relevant, yeah.
  101. Re:The burning question. by klashn · · Score: 1

    Well yes, that would be the obvious way to do it. But imagine a world where we all did the obvious. :)

    goforit.exe or AstroTit ?

  102. No Vim by Anonymous Coward · · Score: 0

    only vi...

  103. Already by hduff · · Score: 1

    got root

    --
    "I believe in Karma. That means I can do bad things to people all day long and I assume they deserve it." : Dogbert
  104. Works great in WebKit nightly as well. by CousinDave · · Score: 2

    But not the latest Safari.

    --
    It's too late to lose the weight you used to need to throw around.
  105. Inception by Andrewkov · · Score: 2

    I'm going to run Firefox inside Linux which is running inside Firefox. I'm going for Inception!!

  106. Re:The burning question. by Anonymous Coward · · Score: 0

    This is neither cool nor interesting.

    Who died and made you the arbiter of cool and interesting?

    What is the concept, that browsers can be made to do more things they were never intended to do?

    Yes. "Making things do what they were not intended to do" is what we call "Hacking". Perhaps you should try another website instead?

  107. Zombie by mrnick · · Score: 1

    True because that would make you a zombie!!

    --

    Encryption: I may not agree with what you say, but I will defend your right to encrypt it...
  108. This is fun by bhassel · · Score: 2

    Oh man, I have a strong desire to get apache running in this, just so I can have the web browser serving pages to itself =) We just need a network driver...

  109. Far Slower by Anonymous Coward · · Score: 0

    far slower than native (about 5-10% in my experience)

    Well, make up your mind. Is it "far" slower, or only 5-10%? Because if it's only 5-10% I can fix that by buying a computer 3 months later or buying it now but spending an extra $40 on the CPU.

    1. Re:Far Slower by gweihir · · Score: 1

      You math is far from accurate and your understanding of CPU speeds if far from realistic and your interpretation of "far" is far from what other people use.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
  110. tools by Vorpix · · Score: 2

    now where is network support, ssh, nmap and other tools that could make this actually useful to the roaming sysadmin?

    --
    frog blast the vent core
  111. Re:The burning question. by Kitkoan · · Score: 1

    Well, to start with, I meant it literally as a start to VMs on a tablet, maybe moving in the end to something like a cloud to do the VMing. As for porting something like GIMP, thats one program, there are how many different Windows/Linux/OSX programs out there and expecting them all to be ported is just not possible, while VMing an OS online would be much more realistic to use these programs. Use them with maybe an on screen keyboard and Bluetooth mouse when you need those then close it all down when your finished to save your battery.

    --
    Attention... all grammer nazi"s! Is they're anything; wrong with: my post,
  112. This is the year... by Anonymous Coward · · Score: 1

    This is the year for Linux in the browser...

  113. Re:The burning question. by somersault · · Score: 1

    A VM is only any use for running OSes that are designed for the same instruction set as your processor has, so unless you have an x86 tablet you're out of luck with Windows and Photoshop in a VM (though they have run test builds of Windows to ARM, and Photoshop will presumably follow if that gets released).

    Plus touch screens would be an awful way to use desktop apps even if you had a keyboard attached. They're not designed for touch in the same way that the old Windows mobile interface sucked (worked okay with a stylus, but was a PITA otherwise).

    Also, you don't need all Windows/OSX/Linux programs ported anyway. You just need one that does your desired task well, and a purposely written or thoughtfully ported app is going to be best for that.

    --
    which is totally what she said
  114. Re:The burning question. by YaHooL · · Score: 1

    and if you are using a Mac, I recommend

    http://boxerapp.com/

    (It uses dosbox)

    Thanx, it looks very polished and comes bundled with some cool stuff like Commander Keen 4, demo version of X-COM: UFO Defense.
    Will try it out on my MacBook.

  115. Imagine... by the+grace+of+R'hllor · · Score: 2

    ... a beowulf cluster of tabs!

    Or is that joke a little too 20th century these days? Been out of touch with /.

  116. Re:The burning question. by YaHooL · · Score: 1

    Unless of course you are saying I should run DOSBox on Linux on Javascript... which of course is just as mad and cool...

    Hehe, true. Yet it does sound like an impending performance trouble. I would have started off with Ally-Cat It wouldn't demand much and it was my first PC game ever :)

  117. Re:The burning question. by khellendros1984 · · Score: 1

    I'm fairly certain that VMs are useful for running any darn instruction set that you want.

    --
    It is pitch black. You are likely to be eaten by a grue.
  118. Re:The burning question. by somersault · · Score: 1

    Fair enough, I was led to believe otherwise and would just call that an emulator. Doing x86 processor emulation on an ARM based tablet would be a woefully bad idea though.. until they start making 10Ghz tablets perhaps..

    --
    which is totally what she said
  119. Bypassing the need for Apple Appstore by RichM · · Score: 2

    This would be amazing if if had an eth0 interface with an SSH client.
    That would mean that you could SSH to any of your servers from within Safari on an iPhone with no need for paid-for apps.

    1. Re:Bypassing the need for Apple Appstore by rs79 · · Score: 1

      Somebody really should get the network stack going. This thing isn't even that slow, and being able to drop into unix anywhere any time is really really handy.

      --
      Need Mercedes parts ?
    2. Re:Bypassing the need for Apple Appstore by Anonymous Coward · · Score: 0

      Surely it would make more sense to write a javascript ssh client rather than use a javascript VM to run a SSH client. In fact that may have been done already. A quick search turned up Anyterm which is basically a terminal emulator running on your web server and accessible through your web browser, it also has a nice comparisons page on that site which lists and compares alternatives.

  120. Re:Running a browser in emacs? Reading /. ? by shutdown+-p+now · · Score: 1

    Given that "ifconfig" only shows a loopback interface, it would be helpful if you explained how you got Internet connectivity working in that thing.

  121. Now your OS boots-up in Emacs now. by Anonymous Coward · · Score: 0

    You better believe it.

  122. a few tech details by spage · · Score: 2

    http://bellard.org/jslinux/cpux86.js calls ya.load_binary() that makes XMLHttpRequest()s for "vmlinux26.bin", "root.bin", and "linuxstart.bin". For the latter two his HTTP server responds with root.bin.en.gz and linuxstart.bin.en.gz. After gunzip you can mount root.bin.en as a loopback ext2 filesystem to see the ramdisk FS contents; most binaries are hardlinks to the same 768kB BusyBox ELF 386 binary. I'm not sure what the 14,858 byte linuxstart.bin file is.

    --
    =S
    1. Re:a few tech details by rs79 · · Score: 1

      They were all easily obtained as files via http using wget. Except for root.bin which was 403 forbidden.


      76002325 86 -rw-r--r-- 1 sexton www 88024 May 17 10:42 cpux86.js
      76002326 2 -rw-r--r-- 1 www www 549 May 18 00:15 home.html
      76002327 16 -rw-r--r-- 1 sexton www 14858 May 16 14:14 linuxstart.bin
      76002328 6 -rw-r--r-- 1 sexton www 5379 May 16 14:14 tech.html
      76002323 8 -rw-r--r-- 1 sexton www 6534 May 17 05:26 term.js
      76002324 1664 -rw-r--r-- 1 sexton www 1679494 May 16 14:13 vmlinux26.bin

      % wget http://bellard.org/jslinux/root.bin
      --2011-05-18 00:39:07-- http://bellard.org/jslinux/root.bin
      Resolving bellard.org (bellard.org)... 88.191.75.179
      Connecting to bellard.org (bellard.org)|88.191.75.179|:80... connected.
      HTTP request sent, awaiting response... 403 Forbidden
      2011-05-18 00:39:07 ERROR 403: Forbidden.

      But I noticed if I asked for this file via a web browser then root.bin got translated to root.bin.en.gz and you can ask for this by name with wget and it works.
      unzip it and call it root.bin and then it all works.

      vi works in this thing. manpages don't. Probably should be there though, easily added.

      "wait 10 seconds while I boot linix in a browser window to look up the manpage". Hysterical. Course, I should have seen this coming, 10 years ago IBM RAID controllers made you boot linux on your pc *just* to configure the device.

      I'm not sure where thing is in the range from "slick" to "game changer". But it's inbetween those two somewhere.

      --
      Need Mercedes parts ?
  123. reboot by Anonymous Coward · · Score: 0

    press f5 to reboot

  124. Re:The burning question. by The+Dawn+Of+Time · · Score: 1

    I'm not on it, and it's not even your lawn anyway.

  125. That was awesome by Anonymous Coward · · Score: 0

    Best thing ever! Mind-blowing.

  126. relatively straightforward JavaScript by spage · · Score: 1

    Although he's using JavaScript typed arrays (U?Int{8,16,32}Array), the JavaScript isn't using other recent language features like let and const. "Just" tons of switch statements and bitwise operations (and the mind of a brilliant hacker). That it runs so fast demonstrates how fantastic V8 and JaegerMonkey are at optimizing JavaScript.

    --
    =S
  127. PHP instead of JS? by Anonymous Coward · · Score: 0

    What about running a remote VM from your browser based on a PHP or Perl app? Then it wouldn't be limited by client abilities, only the connection speed required to return results. As long as you had a fairly simple output (plain text in an iframe with some basic javascript RPC) it should be responsive enough with a broadband connection. Not good for running X obviously, but more processor-hungry apps might benefit.

    I don't see much benefit in running anything on Linux using client resources anyway (it will always be slower than the client), but being able to better harness a more powerful server in a datacenter (usually decent spec blades) for computationally-intesive tasks (finite element, medical image processing, etc) would be useful.

    Perhaps someone could try a virtualized Linux/Apache box with a PHP-driven psuedo-shell exposed to the outside, driving some basic shell tools like nano, gcc, etc. There would be plenty of people who would be more than happy to screw it up so maybe put a password on it or something.

    Then you could have limited access to a true dinks native i386 Linux machine from your iPad without ssh software and overhead.

    Might have a go myself at home. I'm a "gunna-do" though so don't hold your breath.

  128. What happened afterwards by Anonymous Coward · · Score: 0

    sh: getcwd: No such file or directory
    (unknown) # exit /sbin/init: line 21: /bin/true: not found
    Kernel panic - not syncing: Attempted to kill init!

  129. Truly, by UtterCoward · · Score: 1

    this is legendary high geekery. *slow clap*

  130. Re:Running a browser in emacs? Reading /. ? by ais523 · · Score: 1

    Oh, I wasn't running inside that thing, I was working from my own computer. I thought it was a question about Emacs generally, not about the browser simulator in question. Sorry if there was a misunderstanding.

    --
    (1)DOCOMEFROM!2~.2'~#1WHILE:1<-"'?.1$.2'~'"':1/.1$.2'~#0"$#65535'"$"'"'&.1$.2'~'#0$#65535'"$#0'~#32767$#1"
  131. Re:Running a browser in emacs? Reading /. ? by billstewart · · Score: 1

    I was in fact asking in the context of the browser simulator (since it does have emacs), but it's interesting to know that a text-based browser can still read Slashdot given the excessive amount of Javascript that's gotten into everything the last few years.

    --

    Bill Stewart
    New Fast-Compression-only CPR http://preview.tinyurl.com/dy575ks
  132. OS in browsers by sglines · · Score: 1

    This is almost as interesting as the OS written in Postscript and said to be able to run on HP printers.

  133. Re:Do you get paid to promote xkcd? by proverbialcow · · Score: 1

    I just couldn't see any other reason for you to make that post unless you are constantly reading Slashdot to find some reason, however vague, to post some xkcd promotion.

    Busted! Nothing spells profiteering like posting a link to a year-old April Fool's joke on a free website that doesn't display ads.

    --
    The only surefire protection against Microsoft infections is abstinence. - The Onion