OS to experiment - Focus on Distributed Operating Systems

All off topic discussions go here. Everything from the funny thing your cat did to your favorite tv shows. Non-programming computer questions are ok too.
Post Reply
Tapti
Posts: 7
Joined: Mon May 23, 2011 9:13 am
Location: India

OS to experiment - Focus on Distributed Operating Systems

Post by Tapti »

OK. Here's the deal.

I'm a Java software developer (please don't cringe :P) and I'm very curious about OS internals. Which operating system would be a gentler introduction to kernel hacking? My main interest is in the direction of Distributed Operating Systems.

Btw, I had studied OS at an under-graduate level and know the basics about process scheduling, file systems, etc. but it has been a while since I've done any coding in C or Assembly. [Edit - I've also been delving into the linux source code and reading up on OS stuff, on and off, over the past two years.]

I do use Linux as my primary OS at home and run FreeBSD on a virtual machine. And I also intend to go back to school and get my Masters degree in Comp Sci. next fall - if this has any bearing on the issue at hand.

So - Linux or FreeBSD or ... maybe ... something else altogether?

Thanks,
Tapti.

[Edit - Changed the post heading.]
Last edited by Tapti on Thu Aug 23, 2012 3:45 am, edited 1 time in total.
User avatar
iansjack
Member
Member
Posts: 4683
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: Linux or FreeBSD

Post by iansjack »

I'd go for Minix as a good, reasonably complete, OS which is simple enough to study. In conjunction with the book ( http://www.amazon.com/dp/0131429388 - seems to have got a bit pricey recently, but you may be able to find a second-hand copy) it should give you a good grounding. If you want to study a more complete OS, Linux would be your best choice, in conjunction with one of the many books about the kernel (e.g. http://www.amazon.com/Professional-Linu ... 0470343435 - just one of many). Books about FreeBSD internals tend to be rarer and more out of date.
User avatar
bluemoon
Member
Member
Posts: 1761
Joined: Wed Dec 01, 2010 3:41 am
Location: Hong Kong

Re: Linux or FreeBSD

Post by bluemoon »

If you aim for kernel hacking but not kernel development, go for linux as it has much more resources and tutorial on the internet. If you want to learn something on kernel, or OS development as a whole, there are other choices.
Tapti
Posts: 7
Joined: Mon May 23, 2011 9:13 am
Location: India

Re: Linux or FreeBSD

Post by Tapti »

Well, truth be spoken, I want to build a distributed operating system. I think (thought?) an existing OS would be a good platform to begin with, but after reading a little online I guess it wouldn't be wise to start with an operating system that didn't support "distributedness" to begin with, and try to "hack in" the support.

iansjack, I did consider Minix and would be using it right now, if I could only get it running on my system. I tried it on VMWare too, but it used to freeze randomly. I'll look it up again if you recommend Minix as a platform to do some fooling around in the "distributed world". Since it is microkernel based ... and everything is a service, I think it would be more suited for the purpose, no?

bluemoon, what are the other choices?

Thanks,
Tapti.
User avatar
bluemoon
Member
Member
Posts: 1761
Joined: Wed Dec 01, 2010 3:41 am
Location: Hong Kong

Re: OS to experiment - Focus on Distributed Operating System

Post by bluemoon »

To learn OS development, and I assume you got the necessary skill set, you can take the tutorials on the wiki and start your own :) and incrementally add designs and algorithm into it.

IMO it's not efficient to learn OS development by staring at an existing OS, you can get ideas and insight, but that is.
User avatar
Love4Boobies
Member
Member
Posts: 2111
Joined: Fri Mar 07, 2008 5:36 pm
Location: Bucharest, Romania

Re: OS to experiment - Focus on Distributed Operating System

Post by Love4Boobies »

It sounds like this is the book for you. It's also in our Books article, except I only added the C version---oops, I'll fix that soon.
"Computers in the future may weigh no more than 1.5 tons.", Popular Mechanics (1949)
[ Project UDI ]
User avatar
iansjack
Member
Member
Posts: 4683
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: OS to experiment - Focus on Distributed Operating System

Post by iansjack »

Because of the way that it is written I think that Minix would be a good starting point for a distributed OS. Far easier to get an overall grasp of than Linux or FreeBSD and so probably easier to extend for your needs. I've never had any problems running it in a VM or on physical hardware. (In fact my first foray into OS internals was typing the code in from the first edition of the Minix book, compiling it with Turbo C, and getting it running on an IBM portable - the original sewing-machine portable. A lengthy, but educational, project.)

My main reason for recommending Minix was because of Tanenbaum's book which, to my mind, provides an accessible but comprehensive view of a Unix-style OS. The books that I have read about the BSD, Linux, and OS X kernels are more comprehensive but far harder to follow, IMO, as starter texts.
Tapti
Posts: 7
Joined: Mon May 23, 2011 9:13 am
Location: India

Re: OS to experiment - Focus on Distributed Operating System

Post by Tapti »

Because of the way that it is written I think that Minix would be a good starting point for a distributed OS. Far easier to get an overall grasp of than Linux or FreeBSD and so probably easier to extend for your needs. I've never had any problems running it in a VM or on physical hardware.
OK. I'll give Minix another try then. Can you please tell me which version of Minix you used with which version of VMWare (or any other emulator / virtualizer you had used)? That will be extremely helpful.
To learn OS development, and I assume you got the necessary skill set, you can take the tutorials on the wiki and start your own :) and incrementally add designs and algorithm into it.
Ahh... the temptation! :P My C skills are a year old and ASM skills a couple of years old. I have (or think I have) reasonable understandings of the OS "concepts". And since, I'm stuck in a desert land for the next two weeks, with not much on my hands, I think I'll be able to get this thing bootstrapped!
It sounds like this is the book for you.
OS concepts in Java!! :shock: :shock:
On a serious note, I'll definitely try to get my hands on it. Sounds an interesting approach. Thanks :)
User avatar
iansjack
Member
Member
Posts: 4683
Joined: Sat Mar 31, 2012 3:07 am
Location: Chichester, UK

Re: OS to experiment - Focus on Distributed Operating System

Post by iansjack »

Try Minix 3, whatever the latest version is, on VirtualBox. It may just be me, but I find VirtualBox a bit more versatile than VMWare. There's a guide to installing Minix 3 on VirtualBox here: http://wiki.minix3.org/en/UsersGuide/Ru ... VirtualBox
User avatar
Brendan
Member
Member
Posts: 8561
Joined: Sat Jan 15, 2005 12:00 am
Location: At his keyboard!
Contact:

Re: Linux or FreeBSD

Post by Brendan »

Hi,
Tapti wrote:Well, truth be spoken, I want to build a distributed operating system. I think (thought?) an existing OS would be a good platform to begin with, but after reading a little online I guess it wouldn't be wise to start with an operating system that didn't support "distributedness" to begin with, and try to "hack in" the support.
Using an existing OS as the basis for a distributed operating system probably isn't a good idea; however, using an existing kernel as the basis for a distributed operating system may be a wise idea.

Mostly you'd have to figure out exactly what "distributed operating system" actually means to you (for some people, just using NFS and X on a LAN is "close enough" to distributed(!) ), then weigh the advantages/disadvantages. The advantages of using an existing kernel are relatively obvious (you'd save yourself many years of work on things like scheduling, device drivers, etc). The disadvantages depend on how close an existing kernel is to what you actually want, and losing the flexibility you'd get if you were doing it yourself.


Cheers,

Brendan
For all things; perfection is, and will always remain, impossible to achieve in practice. However; by striving for perfection we create things that are as perfect as practically possible. Let the pursuit of perfection be our guide.
Tapti
Posts: 7
Joined: Mon May 23, 2011 9:13 am
Location: India

Re: OS to experiment - Focus on Distributed Operating System

Post by Tapti »

Thanks for the wonderful responses. I'm thinking things out in my head and reading up on resources online to understand things better.
Mostly you'd have to figure out exactly what "distributed operating system" actually means to you (for some people, just using NFS and X on a LAN is "close enough" to distributed(!) ), then weigh the advantages/disadvantages.
That's put very succinctly. What I have on my mind isn't really that - I'm not even thinking about an operating system targeted at the every-day users. I'll see if I can get something remotely resembling a prototype up and running, in the next ... weeks (months? years?) and then will elaborate. Don't want to sound like an idiot with fancy ideas and nothing real to show! :D

Thanks for the wonderful help. Really appreciated ... muchas gracias :)
TylerH
Member
Member
Posts: 285
Joined: Tue Apr 13, 2010 8:00 pm
Contact:

Re: OS to experiment - Focus on Distributed Operating System

Post by TylerH »

MIT's Xv6 might be a suitable alternative to Minix. It's an educational kernel also, and they freely distribute the accompanying textbook/commentary. I've never tried running it, so I don't know how reliable it really is, although I would think MIT is capable of building a working kernel.

You can get it here: http://pdos.csail.mit.edu/6.828/2011/xv6.html.
Post Reply