flat assembler
Message board for the users of flat assembler.

Index > OS Construction > HD disk system

Goto page 1, 2  Next
Author
Thread Post new topic Reply to topic
dosin



Joined: 24 Aug 2007
Posts: 337
dosin
I was looking into hd disk systems.. and I am considering Hierarchical File System devel by Apple..

I have read that when the os has mulitasking it can cause problems with this file system: slows the system waiting for access ect....


I found full source for this system thats a plus.. format util and other utils
for the file system all writen in C code...

if anyone has any sugestions or opinions on it please let me know...

I want something that people wont be afraid to try - an existing file sys..
That is well documented...

I have a new hd drive and ready to format it and start writing.. lol
just want some comments on what would work well other than windows fat!
Post 22 Feb 2009, 19:58
View user's profile Send private message Reply with quote
tom tobias



Joined: 09 Sep 2003
Posts: 1320
Location: usa
tom tobias
Hi dosin,
There exist many different ideas on the internet, for file system design...advfs, for example.
Question number one, I suppose, does your new file system require compatiblity with some existing file system?
Then, I guess the question arises, WHICH features must your new file system elaborate:
For example, do you have a requirement to recover deleted files? How about the ability to reconfigure directories or drives? Do you need a log for transactions?
Here's an example of a rather complex file system. I am not too fond of it, too much complexity for my taste.
On the other hand, if the file system is too simple, perhaps it will not be compatible with saving files downloaded from the internet, once your new browser is operational... I guess storage and retrieval of files up to 8gb is reasonable, since that is the maximum capacity of many DVD blanks.
dosin wrote:
I want something that people wont be afraid to try - an existing file sys.. That is well documented...
As far as my being fearful of trying a novel file system, rest assured, friend, I have no such disinclination. Whatever you post, I will try. I don't mean to suggest that existing file systems are inappropriate, just, I think they are designed for different requirements, and probably came into existence in an era where the computing environment was quite dissimilar from the present one. In my opinion, you need not fear design of a novel file system, based upon simplicity, i.e. one which is NOT full featured, but rather, a file system designed for your new browser to function effectively, a file system demanding the least effort to implement.
Post 23 Feb 2009, 04:00
View user's profile Send private message Reply with quote
dosin



Joined: 24 Aug 2007
Posts: 337
dosin
Quote:
one which is NOT full featured, but rather, a file system designed for your new browser to function effectively, a file system demanding the least effort to implement


yes - that about sums it up.... Very Happy

A while ago I created a database in c++ .. that stored and retrived data in one file that started at 0 bytes and then would grow as each new record was entered with no limit on how big it got.. would fill the disk drive bfore stopping... not a good idea.. but a limit could be added..

how this was done is simular to how you could store files on a disk...

using an existing system or creating one - there both going to require a lot of work...

if this would spark some interest in anyone here... we could create a open source disk system with fasm.. to use if wanted with any os created with fasm..

for use on floppies,hd,usb drives .. create a format util ... and an os installer..
ect...

who would own it - the Fasm community!

Either way I have the same problem .. I dont want to over complicate things thats why I am staying away from linux file systems..

just a thought if anyone is interested!
Post 23 Feb 2009, 05:39
View user's profile Send private message Reply with quote
bitRAKE



Joined: 21 Jul 2003
Posts: 2804
Location: dank orb
bitRAKE
Currently, I'm just using a flat array on my USB stick,
something similar to:
Code:
struc entry {
   .start          rq 1
        .sectors        rq 1
        .date           rd 1
        .flags          rd 1
        .name   rb 40
}    
...this is at the extreme least effort end of the spectrum. Initially, I was going to make all files the same size, lol.
Post 23 Feb 2009, 08:15
View user's profile Send private message Visit poster's website Reply with quote
tom tobias



Joined: 09 Sep 2003
Posts: 1320
Location: usa
tom tobias
bitRAKE wrote:

Currently, I'm just using a flat array on my USB stick
I like it, but, does the date field reflect revision history? What happens if one wishes to append data to a file? Is the original date overwritten? Why not use rq for all parameters? Wastefulness, versus efficiency and simplicity of design!!!! How is sector size defined, i.e. is this parameter related to the geometry of a particular device? What information is stored in and retrieved from flags? How is that information useful? Does one need a parameter to adjust for different media type?
Thanks very much for sharing your design bitRAKE, an excellent first step.
Smile
Post 23 Feb 2009, 11:41
View user's profile Send private message Reply with quote
dosin



Joined: 24 Aug 2007
Posts: 337
dosin
Yes - Thanks bitrake...

I am going to put a lot of thought into what we would need for a standard and in a couple of days I will post... suport for directories and header info.. and file info needed to store to disks.... appending is going to be a little tricky..
but I think we can manage... and try to keep it simple to it can support all media types..


if done we could make a disk util for windows and linux to be able to read and write for it...


Last edited by dosin on 23 Feb 2009, 18:24; edited 1 time in total
Post 23 Feb 2009, 16:55
View user's profile Send private message Reply with quote
edfed



Joined: 20 Feb 2006
Posts: 4225
Location: 2018
edfed
maybe a pure fool design can help in file system construction.
i have still tried a similar stuff.
it is a list of pointers.
and as it is a fool thing, the first dword is the type of function needed to execute the object.

for a folder, it would be f.folder
for a file, f.file.
and for anything else, it should be a user defined type, like
audio: a.mp3, a.wav, a.ogg...
video: v.avi, v.gif...
text: t.txt, t.pdf ,t.doc, t.asm...
etc etc.
for the file itself, it would be a list of disk areas in chs or lba form.
a disk zone would be a simple:
Code:
diskzone:
.location=0
.size=4
    


a file header is:

Code:
fileheader:
.type=0
.name=4  ; a pointer to an offset inside the current folder.
.size in bytes=8
.size in sectors (512bytes)=12
;the size of the file can be up to 512*4G+4G
; if size in sectors is more than 4G, it will use size in bytes as the modulo.
.zonelist=16 ; a pointer to a list inside the folder
.misc=20 ; a pointer to a structure used ot do what you want, like dating.
...
    

a folder is a list of file header pointers.
Code:
folder:
dd f.folder,dd @f-$-4
dd file1,file2,file3
@@:
file1 dd f.ext,fil1,128,1,.zone,.misc
.zone dd @f-$-4,00001010h,1
@@:
.misc dd f.node,@f-$-4
@@:
file2 dd f.ext,fil2,1028,3,.zone,.misc
.zone dd @f-$-4,00001012h,3
@@:
.misc dd f.node,@f-$-4
@@:
file3 dd f.ext,fil3,65536,128,.zone,.misc
.zone dd @f-$-4
dd 00001020h,28
dd 00101111h,100
@@:
.misc dd s.status,@f-$-4
db '01/01/2009',10,13,'00:00',10,13,'edfed',0   
@@:
fil1 db' file1.ext',0
fil2 db 'file2.ext',0
fil3 db 'file3.ext',0
    


in this kind of structure, everything can be anywhere within the current file.

the root is simple:

it is a folder in the fool tree.
Code:

main dd f.gnode,0,0,1600,1200,@f-$-4
dd refresh,mouse,explorer
@@:
explorer dd f.gnode,100,100,1000,1000,@f-$-4
dd display,explore,command
@@:
display dd f.???,explore  ;because it will display what is the parameter of root
command dd f.???,explore ; because it will modify parameters in root

root dd f.root
     dd path 
path db 'fda/fasmx/',0
    

btw, it is very hard to do for me because i am too much lazy to do it now.
but it works, i tried it a long time ago.
it is my old explore.zip package that needs a lot of updates.

about the occupation of the disk, each sector is assigned a bit in sector field that is at the root of the drive.
for example:
Code:
fda/field
hda/field
usba/field
internet/field <-- joke
    

a 1 represent a dead or occupied sector
a 0 means a free sector.

now, lets try it!


Last edited by edfed on 24 Feb 2009, 00:39; edited 2 times in total
Post 23 Feb 2009, 18:20
View user's profile Send private message Visit poster's website Reply with quote
bitRAKE



Joined: 21 Jul 2003
Posts: 2804
Location: dank orb
bitRAKE
On the PC everything is 512 bytes except CD/DVD, but they can be 512 bytes, too.[1] More detail is really specific to my implementation, and possibly not helpful. (Entries are either programs or text; date field is actually the load address for programs; flags setup the environment prior to loading the sectors. With multi-GB sticks I haven't the need to delete anything, yet.)
Post 23 Feb 2009, 18:20
View user's profile Send private message Visit poster's website Reply with quote
dosin



Joined: 24 Aug 2007
Posts: 337
dosin
making a structure easy to use... that is straight forward! is a must...
I will be posting some ideas possible tonight.. then work on a disk util for formatting it - if feedback is good - if not try will again...

all code and utils will be posted for feedback/and testing! Very Happy

edfed... nice work! have you only tried it on floppies?
Post 23 Feb 2009, 19:02
View user's profile Send private message Reply with quote
edfed



Joined: 20 Feb 2006
Posts: 4225
Location: 2018
edfed
i've not tried it on floppies because it is limited to it's advancment in date of the 5th april 2006.
as it is in this file it can work on floppies but need a little updates to fool style.

to make it work on floppies, i think it just needs some updates from fool functions.
and a new interface to be more modular.
don't forget it, when you will access my file system, only a string representing the path will be needed, then, to make a comm&and line, just input text and call interpret when you hit enter.
of course, this interpret should be able to execute a lot of commands, located inside the command list of the shell, or inside the root/cmd/ folder.

and maybe the interprete will be based on my xhtml parse mechanism.

define the file system is not the harder to do, but the services around are.


new
open
close
delete
copy
paste
cut
status
properties
etc etc...

and the use of theses services is not a simple task too, in my point of view.

_________________
Smile fool iem.design
Post 24 Feb 2009, 00:25
View user's profile Send private message Visit poster's website Reply with quote
dosin



Joined: 24 Aug 2007
Posts: 337
dosin
moved topic down


Last edited by dosin on 24 Feb 2009, 00:51; edited 2 times in total
Post 24 Feb 2009, 00:35
View user's profile Send private message Reply with quote
edfed



Joined: 20 Feb 2006
Posts: 4225
Location: 2018
edfed
tried on a usb drive saw as a bios drive by win98 console.
tried on hard drives too.
the basic strusture is very simple.
interpret/explore.asm
Code:
rootdir:
.size dd .end-.size-4
.fil00:
db 'asmx86',0,0,0,0,0,0,0,0,0,0
dd asmdir.end-asmdir
dd 00000003h
.fil01:
db 'typematic',0,0,0,0,0,0,0
dd 0
dd 00000004h
.fil02:
db '3d prossessing',0,0
dd 0
dd 00000005h
.fil03:
db '3dengine.com',0,0,0,0
dd 0
dd 00000006h
.fil04:
db 'drag n move',0,0,0,0,0
dd 0
dd 00000007h
.fil05:
db 'explorer.asm',0,0,0,0
dd 0
dd 00000008h
.fil06:
db 'mouse.inc',0,0,0,0,0,0,0
dd 0
dd 00000009h
.fil07:
db 'mode13h.inc',0,0,0,0,0
dd 0
dd 0000000ah
.fil08:
db 'scancode.inc',0,0,0,0
dd 0
dd 0000000bh
.fil09:
db 'refresh.inc',0,0,0,0,0
dd 0
dd 0000000ch
.end:

asmdir:
.size dd .end-.size-4
.fil00:
db '3dpross',0,0,0,0,0,0,0,0,0
dd 0
dd 00000002h
db 'asm',0,0,0,0,0,0,0,0,0,0,0,0,0
dd 0
dd 00000003h
.end:
    


i was able to create files inside this structure with the "NEW xxx" command, where xxx is the name to give to the new file.
and i was able to explore the new created file and create new files inside this new folder.
etc etc.
but it is very limited and full of bugs, but is a good start.
Post 24 Feb 2009, 00:47
View user's profile Send private message Visit poster's website Reply with quote
dosin



Joined: 24 Aug 2007
Posts: 337
dosin
what kind of media have you tried it on: type and sizes? ect...


I have been reading up on creating a file sys,,, from what I unterstand they come with low level format .. just need a file system writen for the OS for follow for placement of files.. so there is no need for fdisk util except on older drives... unless you want to create more than one portion.. and from what I read low level formats will not work on todays disk drives.. am I understanding this correctly...

for floppies I am going to leave it as a Fat.. since it comes pre formated this way.. just HD and usb will be the focus..

what kind of bugs you been running into edfed?
Post 24 Feb 2009, 00:52
View user's profile Send private message Reply with quote
edfed



Joined: 20 Feb 2006
Posts: 4225
Location: 2018
edfed
the bugs are the impossibility to use a sector field because not well handcoded.
i want to do the field that way:
one sector ==> (512-8 )*8 bytes to represent the occupation of drive.
the following sector is pointed to by the dword at the end, and the previous is pointed to by the first dword.
Code:
sector field:
dd previous (0 = nothing)
rb 512-8
dd next (0=nothing)
    


or coding the sector field as any other file.
with zones and location.
just don't forget to set the bits corresponding to the sector filed itself.

another bug was induced by the lack of functionality of sector field:
it was impossible to determine a place where to put the new file.

indead, it would be very easy to fix these bugs because they last since 3 years, when i was a pure beginner.


Last edited by edfed on 24 Feb 2009, 17:20; edited 1 time in total
Post 24 Feb 2009, 06:38
View user's profile Send private message Visit poster's website Reply with quote
tom tobias



Joined: 09 Sep 2003
Posts: 1320
Location: usa
tom tobias
edfed wrote:
...indead, {sic, indeed} it would be very easy to fix these bugs because they last since 3 years, when i was a pure beginner.
Despite, or perhaps due to the presence of so many impure thoughts, I remain a complete novice, even after four decades of turmoil, if not travail....
Thanks for these helpful ideas, edfed, well done.
dosin wrote:

what I read low level formats will not work on todays disk drives.. am I understanding this correctly...
Well, I have not tested all of today's drives, but on my SATA and PATA (IDE) drives, this low level format tool works fine:
http://www.killdisk.com/
To create partitions, I recommend, as Bogdan taught me, Ranish partition manager:
http://www.ranish.com/part/
I also employ, with good success, XOSL, to select which operating system to use.
I will be testing dosin's and edfed's new file system designs using the "C" partition, i.e. first bootable partition, on a conventional IDE drive. I will use Ranish/XOSL to select that test partition, rather than win98 or xp, or linux, or sol. Normally, one keeps that first partition active for DOS, or freedos, or DEX, or Menuet.
Post 24 Feb 2009, 13:45
View user's profile Send private message Reply with quote
edfed



Joined: 20 Feb 2006
Posts: 4225
Location: 2018
edfed
hem, problem with partitions:
i don't want to support partition tables because i never use it, and i don't see the utility of this.
i'd prefer the reverse stuff, make many drives looks like only one volume.
for example, the folders in a floppy drive, and the rest in a disk.
and maybe a ram file system extension.
Post 24 Feb 2009, 16:49
View user's profile Send private message Visit poster's website Reply with quote
dosin



Joined: 24 Aug 2007
Posts: 337
dosin
Thanks Tom - for the utils.. I will check them out!!! Very Happy
Post 24 Feb 2009, 16:57
View user's profile Send private message Reply with quote
dosin



Joined: 24 Aug 2007
Posts: 337
dosin
I have been thinking about it - and will have a back up - just incase of system failure/power outage.... Will also be able to handle reading and writing.. deleting and appended files... its really quite simple.. well not real simple.. but I think I can make it work.. I will be starting later this week once I can figure out a few things on portions\getting numb of drives .. geom of the drives.. ect.. not much.. Laughing
Post 25 Feb 2009, 03:25
View user's profile Send private message Reply with quote
tom tobias



Joined: 09 Sep 2003
Posts: 1320
Location: usa
tom tobias
dosin wrote:
I will be starting later this week once I can figure out a few things on portions\getting numb of drives .. geom of the drives.. ect.. not much..
Nonsense. This is a terrific task you have taken on, and it is a HUGE effort. The newest SATA specs call for a 6 gigabits/sec data transfer--version 3.0 of the specification, which should appear any day now. It is not easy, simply trying to get the information on the many different kinds of IDE (PATA), SCSI and SATA drives. Then we have flash drives, with USB interface. Big effort. certainly NOT, "not much".
Keep up the good work.
Smile
Post 25 Feb 2009, 11:36
View user's profile Send private message Reply with quote
dosin



Joined: 24 Aug 2007
Posts: 337
dosin
Quote:
This is a terrific task you have taken on


Its allways best to look at the lighter side of things.. not to get overwhelm by the amount of information needed to do this project... take it step by step until complete... Wink
Post 25 Feb 2009, 13:40
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  
Goto page 1, 2  Next

< Last Thread | Next Thread >
Forum Rules:
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 vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar.

Powered by rwasa.