Why n*x


91 posts   Page 1 of 4   1, 2, 3, 4
by DavidS » Mon Jun 04, 2012 3:48 pm
There was a time that the n*x based Operating Systems were truly simple well designed products. Now it would take years of study to completely understand the kernel of any one of these in detail, not to mention every thing that is piled on top of the kernel. This is the antithesis of good OS design. When a system gets that complex maintaining the system becomes increasingly difficult, bugs become acceptable, and there is no teaching the system in detail.

I say it is time to reevaluate the choice of Operating Systems (again). Modern *n*x systems have become complex beyond the point of easy maintainability, modern proprietary Operating Systems have become even more complex than this, any bug that does not immediately crash the system is allowed to remain unchecked for long periods due to this complexity. In the 1970s the effort was put forth to create operating systems that are simple enough to easily maintain, one of these was Unix. this was a response to the bloated unmaintainable systems of that time. This has happened again, DO WE NOT LEARN FROM OUR PAST MISTAKES. And now many of the user level applications have developed the same problems, memory leaks are deemed acceptable, redundant routines are the norm (because the projects have become so big it is easier to re-implement a routine than to find the already existing one).

IT IS TIME TO REMEMBER THE GOOD SYSTEMS
A few examples of simple to maintain systems that include a GUI are:
    RISC OS
    QL QDOS
    TOS/GEM
    AMIGA OS (pre 3.5)
    GEOS
    Original Unix v5
    Original BSD 4.4

We are the hackers of today. Let us create a new generation of good well implemented easy to maintain Operating Systems, and applications that mirror this philosophy. We do not have to put up with this BLOAT, we do not have to put up with this poor coding paradigm. It is the simple hackers taking the power into there own hands and creating the first generation of simpler systems in the 1970s that gave us the personal computer, let us be the hackers of today that take the power away from the computer lords of today and show the world what can be done with the hardware that we now have. It is time to say; NO to wasted processor clocks, NO to wasted code space, NO to unmaintainable bloat, NO to accepting bugs (because they don't get in the way), NO to wasting memory (just because its cheap). It is time to say YES to well thought Operating Systems, YES to efficient and maintainable applications. YES to leaving resources for other processes to use, and YES to complete debugging.

The term Hacker as used herein refers to Software Engineers and Electronics Engineers.

WE ARE THE HACKERS OF TODAY; LET US REMIND THE WORLD HOW FUN AND FAST COMPUTING CAN BE.

I am doing my part to create a modern operating system that lives up to these goals, will you each please do your part? Lets provide enough options that people can choose a GOOD system based on its own merit (because the choice does exist). Now there is little choice we must change this, and only we can.
ARM Assembly Language: For those that want: Simple, Powerful, Easy to learn, and Easy to debug.
User avatar
Posts: 1251
Joined: Thu Dec 15, 2011 6:39 am
Location: USA
by cheery » Mon Jun 04, 2012 3:54 pm
Good thinking but cut out the nationalistic propaganda. That bites to nobody these days.

Fundamental things in computing should be simple enough you can program them yourself. This is where you should start from. ;)
User avatar
Posts: 219
Joined: Wed Jan 25, 2012 9:39 pm
by DavidS » Mon Jun 04, 2012 4:13 pm
Thank you; That is the message that I am attempting to give. Any software should be easily maintainable.
ARM Assembly Language: For those that want: Simple, Powerful, Easy to learn, and Easy to debug.
User avatar
Posts: 1251
Joined: Thu Dec 15, 2011 6:39 am
Location: USA
by rurwin » Mon Jun 04, 2012 4:29 pm
Yes, I agree. Let's do that.

Except it doesn't answer the mission of the Raspberry Pi: cheap programming education.

Linux has thousands of available programs; your new OS has none plus whatever you write. Linux has thousands of programmers; your new OS has none plus you and whoever you recruit.

Go ahead and write your new OS. It would be a useful thing to have around, and it might be useful in teaching OS theory at degree level or advanced A level. When you have Scratch and Python, or maybe some new language that is built on new ideas, then it might be the right thing for the Raspberry Pi.
User avatar
Forum Moderator
Forum Moderator
Posts: 2904
Joined: Mon Jan 09, 2012 3:16 pm
by DavidS » Mon Jun 04, 2012 4:49 pm
rurwin wrote:Yes, I agree. Let's do that.

Yes the only way that alternatives can come into being is if we do it. Though just one alternative is not enough.

rurwin wrote:Except it doesn't answer the mission of the Raspberry Pi: cheap programming education.

It answers the call better than Linux. A system that people can actually fully understand and can be debugged and maintained. You can not teach Linux in full in a reasonable period of time, and the libraries upon libraries in Linux distros?
rurwin wrote:Linux has thousands of available programs; your new OS has none plus whatever you write. Linux has thousands of programmers; your new OS has none plus you and whoever you recruit.

Some what true. This is true for all systems begin. There are a good number of good well written applications out there that will be worth porting. And I know that the applications that every one knows are the ones that I will not port because they are rife with bugs/leaks. There are already a few applications ported to my Operating System (that is as yet without a name), including a few compilers.
rurwin wrote:Go ahead and write your new OS. It would be a useful thing to have around, and it might be useful in teaching OS theory at degree level or advanced A level. When you have Scratch and Python, or maybe some new language that is built on new ideas, then it might be the right thing for the Raspberry Pi.

Yes I will be writing mine. I would ask that you and any one else that has the skill create another Operating System each. If we provide enough different systems, each with a good number of applications, and development tools, we can create an environment that encourages the development of good software. each system having its group of users, plus those that choose to use more than one of the available Operating Systems. And even if history forgets about my attempt, I hope that there will be enough others to provide the diversity that we NEED.

This multiplicity is needed to encourage people to develop good software, rather than just cobbling stuff together that 'gets the job done'.
ARM Assembly Language: For those that want: Simple, Powerful, Easy to learn, and Easy to debug.
User avatar
Posts: 1251
Joined: Thu Dec 15, 2011 6:39 am
Location: USA
by tufty » Mon Jun 04, 2012 5:46 pm
Linux is a monster because it's a bloody great monolithic kernel that's been patched together to support pretty much every piece of hardware under the sun with no particular design process. As a kernel it's become bloated, ugly and all-too-frequently insecure. This does not mean that this holds for all *n*x kernels, however - OpenBSD is a particularly good example of a solidly engineered, cleanly designed kernel.

The *n*x / Posix approach is very good for what it's good for. That doesn't mean it's the be-all and end-all of systems, but it can be exceptionally flexible and fast. I don't overly like it, but it can be very good.

I suspect that much of what you're (rightfully) complaining about is actually userland, and nothing to do with the OS proper. X needs to die. User filesystem structure visibility needs to die. Losing state between reboots needs to be a thing of the past. So do 'applications'.

Very little of what needs to change needs to change at a kernel level. A decent realtime (or, at the least, low-latency), processor-scalable microkernel is all that's needed, and they already exist.

Simon

Smon
Posts: 1367
Joined: Sun Sep 11, 2011 2:32 pm
by cheery » Mon Jun 04, 2012 6:25 pm
rurwin wrote:Linux has thousands of available programs; your new OS has none plus whatever you write. Linux has thousands of programmers; your new OS has none plus you and whoever you recruit.


Correct, although distubingly biased view on subject. Linux has the merits and properties that made it widely accepted in hacker circles. It has it's problems and annoyances as well though. It has made kernels commodity items and that's great thing, but I'm not convinced that it'd be end of the road for OS development. I'd like to see weighting and appraising of linux internals. With ideas and assertions on how to improve.

I do think one worthy goal to attribute for raspberry pi would be popularization of the kernel development for new masses. It is exactly what you state it wouldn't be - cheap programming education. Well systems programming education but you don't really think that nobody should pursue those topics, do you?

tufty: I don't think the monolithic structure of linux kernel is to blame. The module system isn't that bad to use, and if wrong drivers crash then micro kernel|modular kernel difference doesn't really make difference for the kernel panic screen.
User avatar
Posts: 219
Joined: Wed Jan 25, 2012 9:39 pm
by rurwin » Mon Jun 04, 2012 7:46 pm
cheery wrote:I do think one worthy goal to attribute for raspberry pi would be popularization of the kernel development for new masses. It is exactly what you state it wouldn't be - cheap programming education. Well systems programming education but you don't really think that nobody should pursue those topics, do you?

Not below A-level, no. The RaspPi is designed for children. It very well may have a place at 18+, but that is not the market that the foundation is aiming it at.

I can't see 10 year-olds developing OS code, and while the odd precocious 14 year-old may be mature enough to handle it, I don't see it in the syllabus there either.

Micro-kernels have their own issues, but if you want one, what is wrong with the GNU Herd?
User avatar
Forum Moderator
Forum Moderator
Posts: 2904
Joined: Mon Jan 09, 2012 3:16 pm
by AndrewS » Tue Jun 05, 2012 1:59 am
Any demos available of your revolutionary OS David?
You might also be interested in looking at http://www.debian.org/ports/hurd/ and http://www.minix3.org/
(although AFAIK neither have been ported to the RPi yet)
User avatar
Posts: 3608
Joined: Sun Apr 22, 2012 4:50 pm
Location: Cambridge, UK
by DavidS » Tue Jun 05, 2012 3:41 am
Not below A-level, no. The RaspPi is designed for children. It very well may have a place at 18+, but that is not the market that the foundation is aiming it at.

I can't see 10 year-olds developing OS code, and while the odd precocious 14 year-old may be mature enough to handle it, I don't see it in the syllabus there either.

May not be in the syllabus. Though I began hacking together my first crude (very crude) OS when I was about 12. And from the projects that I frequently read about it seems that kids in this age range are doing such things more and more.
ARM Assembly Language: For those that want: Simple, Powerful, Easy to learn, and Easy to debug.
User avatar
Posts: 1251
Joined: Thu Dec 15, 2011 6:39 am
Location: USA
by DavidS » Tue Jun 05, 2012 3:58 am
AndrewS wrote:Any demos available of your revolutionary OS David?
You might also be interested in looking at http://www.debian.org/ports/hurd/ and http://www.minix3.org/
(although AFAIK neither have been ported to the RPi yet)

Nothing revolutionary: Just a simple Kernel with all modules residing in userland, not a 'Micro Kernel' as the kernel does not know anything about message passing (Kernel calls from the modules are made by a simple SWI with the parameters in registers). Though it is possible to implement traditional message passing in a user level module. For the first version there is not be any use of memory page protection, though the structure is such that implementing this in a future release will be a simple matter.

The goal is simple to be simple, small, easy to maintain, and usable for day to day stuff.

Currently the binaries for the OS (in a loadable RAM image) come to 4192 Bytes (aprox. 4.1KB) and this is just basic File IO, Memory Management, Task scheduling/management, crude drivers for the most basic of devices, a font manager, and a simple WIMP. By the time that I get it to a usable state I think it will be around 16384 Bytes (16KB) for the OS. The current font takes another 1024 bytes, and the ported applications take 7MB (5MB of that is for a port of Netsurf [still kind of useless, the TCP/IP stack is incomplete, and there is no NIC driver]).

As to a demo: Not until I get things to a level that the system is usable for day to day use. If I released a half working crash prone system, that has not run on the real target hardware (I do not yet have my Raspberry Pi) then I would be going against myself on this.
ARM Assembly Language: For those that want: Simple, Powerful, Easy to learn, and Easy to debug.
User avatar
Posts: 1251
Joined: Thu Dec 15, 2011 6:39 am
Location: USA
by DavidS » Tue Jun 05, 2012 4:32 am
As to a Demo: I may do a port to the 68k Atari systems while I wait for my Pi. Though this would just be to show that porting something that is written in Assembly is NOT as difficult as so many 'scholars' claim. And maybe even a port to Sinclair QL, and the Apple IIGS (from flat mem to segmented).

Also I am aware of Minix and Hurd. These are good systems, a good clean kernel, they are still layering a ton of libraries, and X in user space though (this is a negative).
ARM Assembly Language: For those that want: Simple, Powerful, Easy to learn, and Easy to debug.
User avatar
Posts: 1251
Joined: Thu Dec 15, 2011 6:39 am
Location: USA
by yoodoo2 » Tue Jun 05, 2012 10:47 am
DavidS wrote:IT IS TIME TO REMEMBER THE GOOD SYSTEMS
A few examples of simple to maintain systems that include a GUI are:
    RISC OS
    QL QDOS
    TOS/GEM
    AMIGA OS (pre 3.5)
    GEOS
    Original Unix v5
    Original BSD 4.4


AmigaOS is now up to version 4.1 update 4 (see http://www.amigaos.net/ and http://hyperion-entertainment.biz/). It continues to follow the "simplicity" model and the code is traceable back to 3.1 (the version that came with the A1200). Unfortunately, it runs on proprietary (and expensive) PowerPC machines only.

However, there is an open-source re-implementation of AmigaOS 3.1, called AROS: http://aros.sourceforge.net/ . There is a version of AROS called Broadway X which now runs on the Pi, although there is a long way to go in porting/re-compiling any apps for ARM. See http://www.aros-broadway.de/downloads/index.html for a little more info and an image.

There are many threads on this site about the ongoing RISCOS port to Pi.

One of my reasons for getting excited about the Pi is the possibility of running several different OSs on a low-cost, low footprint device.
Posts: 7
Joined: Sat Jun 02, 2012 9:57 am
by phrasz » Mon Jun 11, 2012 2:50 am
DavidS wrote:WE ARE THE HACKERS OF TODAY; LET US REMIND THE WORLD HOW FUN AND FAST COMPUTING CAN BE.


1) Computer/ Electrical Engineers/Scientists/etc are not hackers... You can have all sorts of hackers that are not "educated" ... i.e. that 14 old kid that's owning us all right now b/c he doesn't have a job and will out code us in our sleep.

2) I'd like to amend your statement to read: FUN OR FAST. Fast == microprocessors and flashing of ram, Fun == OS'es (media/games/interactivity). Sure you can always use links and play zork, but OS's with a GUI is what made computing what it is today.


I personally think some of the previous comments are unrepresentative of the true issue at hand: Why n*x? Because it's free, runs on near everything, and HAS AN OS with A GUI.

I'm a mentor to ~8 local high school kids, and command line/terminal activities is like pulling teeth b/c they've (my self included with Windows 3.1 ) have never NOT had a GUI.

Show me an awesome, OOB, OS, that can support a GUI, that's FREE, and has the generic activities like "the internet" and "a music/video player" and I'll point back to n*x. Oh, I forgot it also needs free licensing, a huge support base, and can run on ARM.

So having the previous target market, with the current platform, the absolute requirement of FREE, and you have n*x. I encourage your efforts, but it's kinda like stating you want to reinvent the internet to work on the IPX protocol...

A note on security:
It's NOT the kernel's fault. Security is a constant battle between itself, speed, and accessibility (ease of use). Thus, with this tripod security will ALWAYS lose out. Another part is security is ALWAYS an afterthought: "we'll patch/fix/plug a finger in the dam later". Ease of use demands the lack of security to be universal, because if you release to everyone what your super-secret-password-code-thing is anyone will be able to bypass it and the security has now failed.

Security needs to be a part of the design, yes, BUT if the other two parts win out security will be dropped in a moments notice (see RasPi's debian image with no netfilter/iptables). However, that doesn't mean the sky is falling, rather you now need to determine how to security that black box.
Posts: 46
Joined: Fri Jun 01, 2012 4:13 am
by jamesh » Mon Jun 11, 2012 8:54 am
Anyone who wants to write their own OS to replace Linux on the Raspi is more than welcome.

I'll pop back in two years to see how you got on.

Meanwhile, I have some wheels that need reinventing.
Unemployed software engineer currently specialising in camera drivers and frameworks, but can put mind to most embedded tasks. Got a job in N.Cambridge or surroundings? I'm interested!
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 11686
Joined: Sat Jul 30, 2011 7:41 pm
by piglet » Mon Jun 11, 2012 9:58 am
What shape are you considering?
User avatar
Posts: 568
Joined: Sat Aug 27, 2011 1:16 pm
by jamesh » Mon Jun 11, 2012 10:08 am
Still under development - once I have the final shape designed, I'm going to patent it. I'm thinking rounded corners....
Unemployed software engineer currently specialising in camera drivers and frameworks, but can put mind to most embedded tasks. Got a job in N.Cambridge or surroundings? I'm interested!
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 11686
Joined: Sat Jul 30, 2011 7:41 pm
by cheery » Mon Jun 11, 2012 10:48 am
You're going to drive interesting surfaces with your wheels.

But you do realise wheels have been reinvented couple times over the history? And I don't think the current iteration would be the last one.

You do realise that do you?
User avatar
Posts: 219
Joined: Wed Jan 25, 2012 9:39 pm
by jamesh » Mon Jun 11, 2012 10:51 am
Yes, but I'm going to make mine out of rubber, make them hollow and put air in them, for a smoother ride.
Unemployed software engineer currently specialising in camera drivers and frameworks, but can put mind to most embedded tasks. Got a job in N.Cambridge or surroundings? I'm interested!
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 11686
Joined: Sat Jul 30, 2011 7:41 pm
by cheery » Mon Jun 11, 2012 10:58 am
That's not the point. You might still learn something from the failure.
User avatar
Posts: 219
Joined: Wed Jan 25, 2012 9:39 pm
by jamesh » Mon Jun 11, 2012 11:25 am
Pretty sure my rubber air filled wheels are going to be very successful.

Back on topic, yes, you probably will learn a lot whether you succeed or fail. You could also learn a lot on a project which will be of more use, where there is no reinventing required. There are many OS's out there that could be ported to the Raspi. There is absolutely no need to write a new one, unless you are doing is JUST for the fun/learning of it. Because no matter how good you are, you won't get to a point where it can be a replacement for either Linux or any of the other OS's that could be ported, in a sensible timescale. It's simply too much work. Someone who could write a OS from scratch would be much better used helping in other areas.

Note, I am talking a OS that could be a replacement for either Linux or RISCOS on the Raspi, or perhaps a small RTOS (many of which are possible candidates for porting already). I'm not talking of a very very simple OS with very limited features (ie. Run and flash a few LED's). An OS to my mind should support multithreading, and perhaps multi processes and all the devices on the board (USB, SD card, networking etc). Only with that feature set does it become useful for the Raspi's primary purpose. That's just my opinion. YMMV.
Unemployed software engineer currently specialising in camera drivers and frameworks, but can put mind to most embedded tasks. Got a job in N.Cambridge or surroundings? I'm interested!
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 11686
Joined: Sat Jul 30, 2011 7:41 pm
by cheery » Mon Jun 11, 2012 12:23 pm
An OS to my mind should support multithreading, and perhaps multi processes and all the devices on the board (USB, SD card, networking etc). Only with that feature set does it become useful for the Raspi's primary purpose. That's just my opinion. YMMV.


Everyone always say I'm wasting my time, whether it was anything I were doing that doesn't bring coffee to the table.

So you're requiring:
  • Multiple processes and perhaps multiple threads - about a standard desktop userspace
  • Drivers and support for all interfaces on the board - reasonable demands

And you're saying despite the fixed hardware there is, we couldn't do this, as it's simply "too much work"? If it was, how were you able to port linux in the first place?
User avatar
Posts: 219
Joined: Wed Jan 25, 2012 9:39 pm
by jamesh » Mon Jun 11, 2012 1:06 pm
Linux already compiled for Arm, and drivers for USB already existed, just needed memory map stuff to be sorted out, a new driver for the video, and drivers for the graphics stuff (and some other stuff). But then, Broadcom did have a big team of >20 working on it - the Foundation didn't do the majority of the port - it was already in place as this chip is used in other devices that run Linux. Foundation has dnoe quite a bit of work since though.

Although porting Linux is a different job to writing a OS from scratch to run on the Raspi (which is what this thread is about? Or indeed any other device). There is a reason why there are OS products out there that companies buy rather than writing their own. Nucleus, ThreadX, VXWorks to name just a few. Btw, I not saying people should'nt try, but I would encourage them to consider there their talents may be better apllied elsewhere, in areas where there are not already a number of perfectly adequate solutions.

re: Multi process (maybe) and multi thread (yes) - not talking about the desktop. You need multi threaded whether you have a desktop or not.
Unemployed software engineer currently specialising in camera drivers and frameworks, but can put mind to most embedded tasks. Got a job in N.Cambridge or surroundings? I'm interested!
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 11686
Joined: Sat Jul 30, 2011 7:41 pm
by cheery » Mon Jun 11, 2012 2:05 pm
It's really simple really. Linux is there now and it's really useful right now. It catches improvements regularly. If we were doing something practical it'd be the kernel we would use anyway at the moment.

But if nobody dispatches on playing near with the hardware, who will improve linux tomorrow? Shouldn't there be people who get things further too eventually?

Also, you don't need to discourage people from getting on hardware programming. I'm sure the protocols and all that mess will take care of that.
User avatar
Posts: 219
Joined: Wed Jan 25, 2012 9:39 pm
by jamesh » Mon Jun 11, 2012 2:18 pm
cheery wrote:It's really simple really. Linux is there now and it's really useful right now. It catches improvements regularly. If we were doing something practical it'd be the kernel we would use anyway at the moment.

But if nobody dispatches on playing near with the hardware, who will improve linux tomorrow? Shouldn't there be people who get things further too eventually?

Also, you don't need to discourage people from getting on hardware programming. I'm sure the protocols and all that mess will take care of that.


There's nothing to stop people who want to work on OS's working on Linux right now - you don't need to wait until tomorrow! In fact,I would recommend it. Going to be decent demand for people with low level Linux experience I think. There's always new HW out there that needs drivers. You have all the source for the Raspi kernel drivers. Good place to start.
Unemployed software engineer currently specialising in camera drivers and frameworks, but can put mind to most embedded tasks. Got a job in N.Cambridge or surroundings? I'm interested!
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 11686
Joined: Sat Jul 30, 2011 7:41 pm