OSDev.org

The Place to Start for Operating System Developers
It is currently Fri Mar 29, 2024 2:09 am

All times are UTC - 6 hours




Post new topic Reply to topic  [ 28 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: Editing barebones tutorial page to boot from cdrom instead
PostPosted: Sat Mar 24, 2012 5:48 pm 
Offline
Member
Member
User avatar

Joined: Thu Nov 05, 2009 5:04 pm
Posts: 234
Location: UK
Hi all,

Imho the barebones tutorial page is a bit outdated and guides the user through creating a floppy image and booting it by hand-typing a set of raw sector addresses. Creating a small iso and booting from grub with a boot menu and proper filesystem is imho much nicer, easier to follow and immediately yields a much nicer starting-off point.

I am willing to change the tutorial to this however I may need some help on advising how to make iso images from commandline under windows (I have never used windows for osdev).

Can anyone see any problems with this or has any objections?

Thanks all!

_________________
My homepage. | Discord RPG Bot | D++ - The C++ Discord API Library for Bots


Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sat Mar 24, 2012 6:02 pm 
Offline
Member
Member
User avatar

Joined: Thu Dec 21, 2006 3:03 am
Posts: 1029
Location: Hobart, Australia
brain wrote:
how to make iso images from commandline under windows


Install the "genisoimage" package for Cygwin. You should be using Cygwin already for a cross-compiler, so it's not too strenuous a requirement.

_________________
My Personal Blog | My Software Company - Loop Foundry | My Github Page


Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sat Mar 24, 2012 7:27 pm 
Offline
Member
Member
User avatar

Joined: Sat Oct 23, 2004 11:00 pm
Posts: 1223
Location: Sweden
A floppy image can easily be used in emulators or on USB's, so unless it's way easier to work with CD images I don't see the need to change. Can CD images be used on USB?

For the record, all nerds should have at least 1 floppy drive laying around somewhere. ;)

_________________
"Simplicity is the ultimate sophistication."
http://bos.asmhackers.net/ - GitHub


Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sat Mar 24, 2012 8:13 pm 
Offline
Member
Member
User avatar

Joined: Thu Nov 05, 2009 5:04 pm
Posts: 234
Location: UK
I haven't seen a floppy disk for years never mind the drive ;-) I guess what I'm getting at is the tutorial should at least use a proper filesystem, not "kernel 18+200" or whatever, imho raw loading of sectors like that is an awful mess, it means for example that if you do use a usb stick, you can store nothing else on it but the kernel and grub, a pain in the arse and waste of tons of space. Admittedly I am outside the norm of os developers by not owning some old 386 with a floppy drive but shouldn't an os be usable by normal users, and normal users no longer own floppy drives. in fact places that sell floppy disks are increasingly rare :-)

_________________
My homepage. | Discord RPG Bot | D++ - The C++ Discord API Library for Bots


Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sun Mar 25, 2012 1:49 am 
Offline
Member
Member
User avatar

Joined: Wed Oct 18, 2006 3:45 am
Posts: 9301
Location: On the balcony, where I can actually keep 1½m distance
The source of the problem is GRUB - it doesn't come installed by default and you need a live version of it to get it onto a device with an existing filesystem. If you want a filesystem-friendly version from a windows machine, you are best off grabbing someone else's image and replacing the kernel binaries with your own.

Besides that, the technical layout would also be the way to boot of harddisks and USB sticks. I'm not sure the default settings of GRUB like it if you try though.

That said, there are two tutorials out on the wiki on booting CDs.

Quote:
I haven't seen a floppy disk for years never mind the drive
I spotted two of each within an 1m radius.

_________________
"Certainly avoid yourself. He is a newbie and might not realize it. You'll hate his code deeply a few years down the road." - Sortie
[ My OS ] [ VDisk/SFS ]


Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sun Mar 25, 2012 3:24 am 
Offline
Member
Member
User avatar

Joined: Tue Feb 08, 2011 1:58 pm
Posts: 496
Combuster wrote:
I spotted two of each within an 1m radius.

Floppy disks are EOL about a year now. http://www.pcworld.com/businesscenter/article/194959/sony_to_end_floppy_disk_production.html


Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sun Mar 25, 2012 3:55 am 
Offline
Member
Member
User avatar

Joined: Thu Nov 05, 2009 5:04 pm
Posts: 234
Location: UK
Heh, that is rather funny when put in perspective, Sony sold 12 million floppies and in total the whole lot only holds 17gb... Really does make them sound as old and crappy as they are ;-)

_________________
My homepage. | Discord RPG Bot | D++ - The C++ Discord API Library for Bots


Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sun Mar 25, 2012 4:29 am 
Offline
Member
Member
User avatar

Joined: Thu Nov 16, 2006 12:01 pm
Posts: 7612
Location: Germany
brain wrote:
Imho the barebones tutorial page is a bit outdated and guides the user through creating a floppy image and booting it by hand-typing a set of raw sector addresses.


I'm absolutely with you on the "hand-typing sector addresses". But since I don't expect anyone to use an actual floppy disk, much less burning actual CDs, which image format one uses is a mere technicality IMHO.

But if you feel like you could integrate the CD image instructions into the tutorial, by all means go ahead. I don't think anyone would shed a tear if the Bare Bones gave CD instructions instead of floppy ones.

_________________
Every good solution is obvious once you've found it.


Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sun Mar 25, 2012 7:13 am 
Offline
Member
Member

Joined: Thu Aug 11, 2011 12:04 am
Posts: 125
Location: Watching You
I say no! Both CD drives and USB disks emulate a floppy in the bios. What should be done is better documentation about EFI.

_________________
Get back to work!
Github


Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sun Mar 25, 2012 10:13 am 
Offline
Member
Member

Joined: Sat Mar 21, 2009 1:29 pm
Posts: 51
Location: Ireland
brain wrote:
Heh, that is rather funny when put in perspective, Sony sold 12 million floppies and in total the whole lot only holds 17gb... Really does make them sound as old and crappy as they are ;-)


Actually there's an error in the maths there. 12,000,000 * 1.44 MB is just over 17TB.


Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sun Mar 25, 2012 10:42 am 
Offline
Member
Member
User avatar

Joined: Thu Nov 05, 2009 5:04 pm
Posts: 234
Location: UK
pinged wrote:
brain wrote:
Heh, that is rather funny when put in perspective, Sony sold 12 million floppies and in total the whole lot only holds 17gb... Really does make them sound as old and crappy as they are ;-)


Actually there's an error in the maths there. 12,000,000 * 1.44 MB is just over 17TB.


Not exactly - the fat12 filesystem's overhead will take away that little bit extra you refer to. technically you could store over 17gb raw data but in terms of files the fs overhead limits you to just a little less :-) also I think the page giving the example was rounded to be more readable anyway.

Edit: ah wait you said terabytes - yeah they ballsed up their maths then, d'oh!...

_________________
My homepage. | Discord RPG Bot | D++ - The C++ Discord API Library for Bots


Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sun Mar 25, 2012 1:36 pm 
Offline
Member
Member
User avatar

Joined: Wed Oct 27, 2010 4:53 pm
Posts: 1150
Location: Scotland
I would never want to switch from floppies to CDs - optical drives are horrible and will probably soon be just as obsolete. A much better route might be Micro-SD cards which are faster, have much higher capacity, and look as if they should give you the ability to switch cards just like floppy disks without having to worry about the drive number changing if you're accessing them through the BIOS [has anyone ever done this?]. I don't want to touch the hard drives in my machines, and I don't want to risk writing to them by mistake, so this looks as if it could be a way to keep things really safe while allowing my OS to modify itself and save itself to a different card without having to hunt via the BIOS for another drive to save to (and that's important if you want to be able to tell other people that if they use your OS it absolutely will not touch the hard drive). It would also be possible to have a fixed size partition for the OS so that the size of the card never matters, while a second partition could be FAT32 for use at a later stage. This would allow people to design their own format for the partition containing their OS and not have anyone else's file format imposed on them. Alternatively they could make the whole card a fat32 partition and work with that from the outset, but the point is that they would have more options. CD's look to me like a straitjacket, and one which will soon become obsolete - most machines won't have an optical drive in the future, and many already don't.


Attachments:
The future.JPG
The future.JPG [ 60.19 KiB | Viewed 9375 times ]

_________________
Help the people of Laos by liking - https://www.facebook.com/TheSBInitiative/?ref=py_c

MSB-OS: http://www.magicschoolbook.com/computing/os-project - direct machine code programming
Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sun Mar 25, 2012 2:29 pm 
Offline
Member
Member
User avatar

Joined: Thu Nov 05, 2009 5:04 pm
Posts: 234
Location: UK
What obscure 'many' consumer machines do you use that have neither a cd drive, dvd drive or blu-ray drive?

_________________
My homepage. | Discord RPG Bot | D++ - The C++ Discord API Library for Bots


Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sun Mar 25, 2012 2:38 pm 
Offline
Member
Member
User avatar

Joined: Thu Dec 21, 2006 3:03 am
Posts: 1029
Location: Hobart, Australia
brain wrote:
What obscure 'many' consumer machines do you use that have neither a cd drive, dvd drive or blu-ray drive?


Most notebooks under 13" don't have an optical drive. Apart from installing the operating system, most people just don't use them any more.

_________________
My Personal Blog | My Software Company - Loop Foundry | My Github Page


Top
 Profile  
 
 Post subject: Re: Editing barebones tutorial page to boot from cdrom inste
PostPosted: Sun Mar 25, 2012 3:58 pm 
Offline
Member
Member
User avatar

Joined: Mon Jan 26, 2009 2:48 am
Posts: 792
I feel that in general, in the wiki's tutorials GRUB should not replace writing your own boot loader. GRUB is a very useful tool, but IMHO the reward in OS development is doing things yourself, and do them your own way.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 28 posts ]  Go to page 1, 2  Next

All times are UTC - 6 hours


Who is online

Users browsing this forum: No registered users and 27 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group