Linux In JavaScript, With Persistent Storage
An anonymous reader writes "Remember Fabrice bellard's [Linux-booting PC emulator in JavaScript] ? This modified version [Note: click on "emulator.html" in that directory to see it in action] allows the same emulator to boot the most recent linux kernel, 3.0.4, as well as providing the user with persistent storage. It is achieved by building a virtual block device, which stores data in HTML5 local storage. The block device can be partitioned and formatted as ext2, so it can be easily used."
why?
So when the web browser becomes the OS we will still be able to issue cryptic command-line incantations to do things that everyone else has to point-and-click to do!
That's neat and it's clear that this guy has MAD skills. But, why the HELL would anybody spend so much time doing something so very technical and difficult with no value whatsoever? It isn't art, it isn't a literary piece it isn't useful. It is just a monumental waste of very valuable time.
WTF?
I really hope that this JavaScript fad blows over soon. While it was just mildly annoying back in 2008 when it started picking up steam, now it's just getting stupid.
Look, JavaScript was a mistake. It was poorly designed from the beginning, and it took 15 years before implementations of it weren't complete shit. Hell, it's basically a mistake of history and circumstance that it's so widely available.
As a language, there's nothing special about it. It's not "Scheme-with-a-C-like-syntax" like some foolish people claim. It's doesn't even do prototyped-based OO sensibly (refer to Self to see it done correctly). It's just a half-assed scripting language.
And don't go blaming the DOM for JavaScript's bad reputation. It's a poor language in any context. Lua is a better scripting language, and Python is a better prototyping language, and Java, C++ and C# are better languages for building large networked applications.
Get over it, guys. There's nothing special about JavaScript. It's merely a limited version of essentially every other programming language ever implemented. Just because you can use it to do stuff that other languages can easily do it does not mean that JavaScript is "unique" in any way.
The Ruby fad has already ended. I hope the JavaScript one ends just as swiftly.
This could be a great thing to embed into online how-tos and the like for teaching basic or even advanced linux. ... heh, embedded linux on the rise again :P
Oracle is making announcements about Java 7 and 8 this week. Supposedly the new stuff is better integration between Java and HTML5, and between Javascript and the JVM.
Will that revised tech be good support for an interactive user shell with a Javascript commandline calling Java objects, reporting back HTML5 in a DOM? Interactive HTML5 GUI objects that can take GUI events back into Javascript logic or just Javascript glue to Java objects in the JVM?
Will Android's Dalvik JVM follow that route, or take its own route to that architecture?
--
make install -not war
Pentium MMX. Is that what everyone gets as well?
"Windows 8 is going to use less memory"
"Oh yeah? Well Linux can run in javascript, ha!"
XML is like violence. If it doesn't solve the problem, use more.
Except that the author of original emulator is an asshole.
This is because he didn't release the source of it (its obscured javascript) and he nether licensed it under a free licence.
And author of this mod, who say that he obtained a permission to _host_ these obscured files just supports that bad guy.
Both should be ashamed of this. They didn't do a rocket science, nobody would want to buy this stuff.
Rather than using javascript to load infected files that use *.pdf and other infectible formats, they can now run a botnet just using an infected ad straight inside your web browser.
Look at everyone going meta. :D
Now I want to run X on this virtual machine and fire up a browser. (Maybe just install Lynx on it if I can't install X on it.)
That'd be a browser in an OS in a browser in an OS.
Some apps are WYSIWYG. Some others are WYSIWTF.
What's the login? If I download it, will my js Linux remember things from session to session? Could I install a webserver on it?
Democracy Now! - your daily, uncensored, corporate-free
Emm, what's d login name and password?
5ryn
While jsLinux is cool, and this is a cool addition, it just makes me wish JavaScript wasn't the only languageVM embedded in the browser. The thought of what could be done if one could take advantage of what the various scripting languages do best instead of trying to fit JavaScript to everything makes me sad.
Having to work for a living is the root of all evil.
This isn't linux in javascript. This is more of an output to screen from a linux server.
1. All the important code has been "compiled" with some javascript "compiler" that basically takes javascript code and fucks with it to where you can't read it
2. Does not follow the GNU license.
3. There isn't enough code to make it a full linux in javascript.
4. You won't be able to copy this and run it off your own computer
nothing to see here people
I suppose at some point someone might get a JVM running in Javascript...
Some post-PC pessimists are under the impression that this educational sandbox will soon end up being all you have because the operating system publisher or hardware maker won't give you the cryptographic keys to boot anything else unless you represent a major corporation.
Google Chrome has "Native Client", a verifiably type-safe subset of native code. One might, for example, port DOSBox to Native Client.
There should a "Post as Anonymous Troll" option.
mod me out without posting or proving this isn't real
nice job
never again
enjoy your bots and bullshitting people
All hail the year of linux in the browser!
rewriting history since 2109
Yes. And the nice thing about this is that you can make things as slow as you need to. For a while, there was a threat that hardware would outpace the demands of software, but now that we're building everything in bloated virtual languages running in virtual machines running on virtual hardware, we can NEST that shit and continue to drive the demand for ever faster hardware.
Because otherwise, you know, my 2002 desktop runs KDE 4.7, Win7, the latest firefox and thunderbird, and everything else I throw at it with no problems. There's serious danger in that I haven't needed to upgrade it for a decade. We can't have that now, can we?
Doesn't run in my Android browser.
That'd be a browser in an OS in a browser in an OS. :D
... and that could be extended to an arbitrary depth!
It's easier to be a result of the past, but more fun to be a cause of the future! http://www.spacefinancegroup.com/
blah blah blah SCO.... blah blah... now Linux is more relevant than EVER! blah blah blah.... built on JavaScript just because we CAN! blah blah
Christ, people, get a grip.
You have no clue what you're talking about.
which is totally what she said
Have gnu, will travel.
With Linux, the browser runs you!
Where are instructions about how to create the advertised 'persistent block device'? Perhaps I missed it but the readme says that "This project allows the virtual machine to access a persistent block device. This means a user can format and partition this device inside it's virtual machine." BUT I do not see the instructions anywhere obvious. Even booting up this virtual machine ... I had to guess to login ... I eventually found user 'root' and an empty password would work to login. A quick 'df -h' does not reveal any persistent block device present. So I ask myself ... after going to all this trouble to host this demonstration ... why aren't there a few more instructions other than "For more details, see the source code." offered?
Signed perplexed.
Start it up in VMWare instance. Start up VMWare. Hot move the instance running the web browser to itself. It would so rock.
We heard you like Linux... so we put some Linux in your Linux so you can Linux while you Linux.
This'll be handy for those who've bought into the Google Chromebook and discovered that all they get is a browser... no, seriously, don't you guys think you were even the slightest bit done over, when you can get a webbook for £60 with free lifetime data allowance?
Operation Guillotine is in effect.
Only the bootloader needsto be signed for secure boot, so as long as grub is signed, you can boot whatever yoou want.
The license of GRUB requires that it be distributed with "Installation Information", which includes private keys for signing. Operating systems would need to be shipped with a non-GPL bootloader, and makers of home PCs would have no incentive to include keys for this bootloader because boot-time malware could work by installing it and setting it as default.
you can boot linux from the NTloader just fine if you have a system tah only has MS signing keys and no way to disable secure boot.
The NT loader of Windows 8 will check the signature on any kernel it loads, and (I'm guessing) so will the NT loader of Windows 7 and Windows Vista after a service pack to allow their use on machines that require UEFI secure boot.
and still no one sees the security problems and thinks maybe just maybe html5 encompasses far too much for web a browser.
increase features to hell with the consequences!
Umm, you don't have to be an administrator to install a C++ or C# program on a PC. I compile and install C, C++ and Java software to my unprivileged user's home directory all the time on Linux, Solaris and Mac OS X systems.
It appears you've never used a thoroughly locked down machine with /home mounted noexec.
I run Windows programs written in C++ and C# from my unprivileged account's desktop just slightly less often. I've never run into problems.
It appears you've never used a thoroughly locked down machine with Software Restriction Policies.
Why do you JavaScript morons and Web 2.0 weenies always make the false claim that "you have to be an administrator to install a program on a PC"?
For one thing, PCs have the measures I described above. For another, please address video game consoles and other set-top boxes, which won't run anything unsigned or self-signed.
cat README This will solve your problem.
I think, therefore you are.
cat README
Liar.
--
make install -not war
Did anyone manage to run stuff like gcc in this? It would make a _GREAT_ education tool.
(network access would be great too, but I guess that would be pretty hard with javascript...)
Ok, that was, by far, the easiest way to get Linux running on my iPad.
Can I get a JavaScript engine that copies the best features of MS PowerShell script (as PS has copied the best features of JS, Perl, csh, and Java/C++)?
Mainly I'm looking for a typed object pipeline with reflection the shell can access. Reflection that exposes APIs of all the classes (bundled in apps and in the OS) installed in the system. Which, as Javascript, should mean "installed in the Internet". Javascript that wraps reflection via CORBA or some other webservices registry/server would be extraordinary - a transformative technology. But just an object pipeline with language iterators and collections operators against localhost resources would be awesome.
--
make install -not war
This web app would be even cooler if the local Linux state could be synced with a server's state. If I could run commands locally, generating a history file that I could send to a server to execute over again there. Or vice versa, where I create state in the local Linux by rerunning history commands downloaded from the server. Or sync either direction, line by line. A kind of "VMWeb".
As it is I don't see any way to install any app in it, either by downloading a binary or by compiling typed-in source locally. In fact I don't see any network operations exposed to that shell. Which is too bad, since it's running in a complete network browser - to say nothing of reaching the network OS the browser is running in. The busybox installed in this instance doesn't seem to have any network commands enabled.
--
make install -not war
This cool Web app is not "Linux in Javascript". It is in fact a "Javascript PC Emulator", just as the app says in the app's page title. It's a bootloader and a virtual PC implemented in Javascript running in the browser JS engine. Which loads a stripped-down Linux binary into itself and runs it, as if it were running on the PC. The Linux was written in C, compiled into PC (x86) machine instructions like any PC Linux, and then runs on the Javascript PC emulator.
I suppose it might be possible to run a Windows binary on it, if that bloatware would fit in the browser. Maybe DOS, or even Novell Netware (though this Linux demo has its networking stripped, and in any case the browser enforces the originating-server-only network access).
Very admirable project. Truly journalistic bad headline and summary.
--
make install -not war
No lspci
which dynamically compiles x86 code into Excel macros.
*duck*
Like it claiming to have the f00f bug - has anyone verified that this virtual cpu has it and that Linux fix for it works properly?
...is actually 3.0.6. kernel.org is back up but it's not updating properly.
.. the (html5) local storage capacity limit in most browsers is 5MiB (to 10MiB).