TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Ask HN: Has anyone ever tried building an OS that doesn't use files?

33 点作者 freework超过 10 年前
Since the beginning of computer time, all computer systems have been based on the idea of a &quot;computer file&quot;. OSX, Linux, Windows, and every other OS has been based on the system of files and folders and filenames and crap like that. I&#x27;m not too versed in computer history. Has anyone ever tried making a computer system that does not use files?<p>In my opinion, referring to the data that computers deal with as &quot;files&quot; made sense in 1954 when every large company had a &quot;paper file system&quot;, but in 2014, I think its time to come up with a new system that better mirrors how we use computers.<p>I&#x27;m working on a project I&#x27;m calling &quot;Library Transfer Protocol&quot;, which is aiming to replace the concept of &quot;file&quot; and replacing it with &#x27;Library item&#x27;. Basically, in 2014 computer usage more closely mirrors the workflow of an author (revisions, publishing, etc), rather than an employee filling up a file cabinet for internal use (thank to the facebook and the like)<p>Before I get too into this project, I&#x27;d like to know if anyone has ever tried doing something like this before.

26 条评论

jonjacky超过 10 年前
Several experimental systems have proposed replacing the traditional file system with what they call a &quot;single level store&quot;: you have data structures in memory, then the OS saves them and restores them as needed from disk storage - but there are no traditional files on the disk, and the users don&#x27;t interact with the disk storage at all - they just interact with the data while it is in memory. In this scheme, the disk storage is something like the pagefile in a conventional OS, but that&#x27;s all there is - there are no conventional files.<p>An interesting single-level store was discussed by Robert Strandh in his 2004 proposal for a Lisp operating system, Gracle. I can&#x27;t find the original paper on the web anymore but some pertinent excerpts are in <a href="https://github.com/jon-jacky/Piety/blob/master/doc/gracle_excerpts.txt" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;jon-jacky&#x2F;Piety&#x2F;blob&#x2F;master&#x2F;doc&#x2F;gracle_ex...</a>. Strandh referenced another experimental OS with a single-level store called EROS. I see he has a more recent LispOS at <a href="https://github.com/robert-strandh/LispOS" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;robert-strandh&#x2F;LispOS</a>.
评论 #8310251 未加载
评论 #8310069 未加载
captainmuon超过 10 年前
BeOS had a nice idea, although it still used files. It&#x27;s file system doubled as a database, and you could add arbitrary columns to files. For example, contacts were empty files in a special directory, and had attributes like &quot;address&quot;, &quot;name&quot; and so on. Mails were also stored in plain files, but unlike mbox&#x2F;Maildir all the metadata was stored as attributes, not in the files, making it easy to process them with scripts, or to sort them in the file browser.<p>Its a lot like the never-finished WinFS from Microsoft.<p>Funnily, modern file systems (extfs3&#x2F;4, NFTS, HPFS+?) all support extended attributes in some form or another. However, they are currently only rarely used: Mostly for the &quot;this file was downloaded from the internet, do you really want to open it&quot; flag. I wish more programs would use them to store interesting metadata, but it&#x27;s basically a chicken and egg thing now.<p>Windows and GNOME also have concepts where you can have calculatable attributes - you have a little library that looks up metadata in a database or parses it from the file, and then serves it as an additional attribute on the file (visible in the file properties tab). You can see it e.g. on mp3s or word documents in windows. However, it doesn&#x27;t seem to be widely used either, and I wouldn&#x27;t be surprised if that function has been gutted out of GNOME lately.
评论 #8309985 未加载
评论 #8310073 未加载
jasode超过 10 年前
&gt;Basically, in 2014 computer usage more closely mirrors the workflow of an author (revisions, publishing, etc), rather than an employee filling up a file cabinet for internal use (thank to the facebook and the like)<p>How did you come to this conclusion about patterns of usage? I&#x27;d think the typical user&#x2F;consumer would more likely have 1000 mp3 files rather than 1000 personally authored Microsoft Word documents (or Photoshop PSD files, etc.)<p>What about another common usage such as digital camera photos? The digital camera (or iPhone) has jpg &quot;files&quot;. How would the user mentally translate the &quot;files&quot; living on a FAT32 flash card and copy them to your &quot;Library Items&quot; storage system? Do they keep 2 mental models of storage paradigms in their head? If your proposal includes a driver&#x2F;wrapper for hiding the FAT32 file inside the concept of &quot;library item&quot;, it seems like you&#x27;re just renaming &quot;files&quot; to &quot;library items&quot;. It&#x27;s more a shift in terminology rather than shift in paradigm as a sibling comment already noted.<p>The filesystems in an operating system (NTFS, ext3, etc) are already implemented as <i>special purpose databases</i>. The &quot;rows&quot; are file id entries and they each point to the &quot;blobs&quot; which are the file contents. Whatever you propose to build has to reimplement this underlying &quot;database&quot; as well. Whether you call the rows of that database &quot;files&quot; or &quot;library items&quot; or &quot;objects&quot; or &quot;documents&quot;, it isn&#x27;t going to revolutionize the approach.
评论 #8309913 未加载
cstross超过 10 年前
Apple&#x27;s Newton OS used object-oriented data stores called &quot;soups&quot; rather than a file-oriented storage paradigm:<p><a href="http://en.wikipedia.org/wiki/Newton_%28platform%29#Operating_system_and_programming_environment" rel="nofollow">http:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Newton_%28platform%29#Operating...</a>
valarauca1超过 10 年前
MTS, z&#x2F;OS (its a long story), OS&#x2F;360 and basically everything written before Multinixs (the pre-cursor to Unix). Didn&#x27;t use files. Stone age computers.<p>The hierarchical file system as you listed it really only started to come into its own in the mid 60&#x27;s. With LISP machines at MIT and Multinix at AT&amp;T.<p>Storing data in <i>files</i> as you call it is old, and well known solution to this problem. Because finding a node on a tree is simple, and this is how file systems tend to work. Because thinking of objects, as subsets of various super classes of objects is easy for people to understand, when you don&#x27;t explain it in those words.<p>The reason very old OS&#x27;s didn&#x27;t store things like this, is because there weren&#x27;t much permanent storage. Actually MTS uses what are roughly <i>files</i> but uses a dot notation to seperation files. Which will look similar to usenet<p><pre><code> misc.data.logs.9-12-2014.dat </code></pre> Where data is your current record.<p>:.:.:<p>I support moving to a more revision, publish, etc. structure. But moving away from the tried and true hierarchical model will be difficult. Even an object based file system will develop a hierarchy of inheritance.
评论 #8309937 未加载
dkarl超过 10 年前
There&#x27;s a long history of mocking and decrying the file as a user-level concept, and many applications hide the concept from the user, even though they store user data in the filesystem. Music players (such as iTunes) are an example: there are songs, albums, and artists, but files do not show up in the UI in any way. This is standard practice at the application layer. However, implementing something at the OS layer with the expectation of exposing it directly to the user goes against the current thinking that it&#x27;s the application layer&#x27;s job to provide user-friendly concepts, and that the job of the OS is merely to support the application layer in doing that.<p>If providing support for application-level user-friendly abstractions is what you want to do, then I would suggest studying applications with UI abstractions that you admire and judging your OS storage layer by how well it supports application development.
angersock超过 10 年前
Files are a shorthand for &quot;documents&quot;. Don&#x27;t be so hung up on terminology.<p>First, look into history more--there are several non-hierarchical (read: flat) file systems out there.<p>Second, while the workflow might mirror authoring more closely (which I think is horsehit, but that&#x27;s neither here nor there) the <i>artifacts</i> of that process are what matter. Existing notions of a &quot;file&quot; map very cleanly onto the storage and organization of such artifacts.<p>There is an argument to be made for having better querying capabilities or permissions or whatever, but what is to be gained from throwing a commonly-accepted idiom away?
评论 #8309837 未加载
andrewtbham超过 10 年前
On the AS&#x2F;400 there was no traditional file system, the only storage was in a database.<p><a href="http://en.wikipedia.org/wiki/IBM_System_i" rel="nofollow">http:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;IBM_System_i</a><p>Unlike the &quot;everything is a file&quot; feature of Unix and its derivatives, on OS&#x2F;400 everything is an object (with built-in persistence and garbage collection).
评论 #8309822 未加载
SchizoDuckie超过 10 年前
WinFS was supposed to be in Windows 7, unfortunately they decided to drop it, I was really looking forward to that.<p><a href="http://en.wikipedia.org/wiki/WinFS" rel="nofollow">http:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;WinFS</a>
评论 #8313263 未加载
perlgeek超过 10 年前
Browsers. Browsers are de facto operating systems (though typically running on another OS, not on bare metal), and they don&#x27;t think in files. They handle windows, tabs, documents, document elements (DOM nodes) etc.
评论 #8309982 未加载
评论 #8310032 未加载
cjbprime超过 10 年前
The One Laptop Per Child laptop uses a Journal instead of folders -- <a href="http://wiki.sugarlabs.org/go/Design_Team/Designs/Journal" rel="nofollow">http:&#x2F;&#x2F;wiki.sugarlabs.org&#x2F;go&#x2F;Design_Team&#x2F;Designs&#x2F;Journal</a> -- and GNOME&#x27;s &quot;Activity Journal&quot; project is similar. (Smartphones are starting to use some of the same ideas, too.)
tzs超过 10 年前
I&#x27;ve toyed with the idea of replacing files with processes. If you have some data that you want to keep, you have a process that holds it in its process memory, and can give it other process via an IPC mechanism (if the other process is local) or over the network (if remote, although you could of course also use the network locally).<p>I never got around to trying it out. I think I may have tried to start some discussion on usenet along these lines maybe 10-15 years ago, but no one seemed interested.<p>A &quot;directory&quot; would simply by a process that provides some kind of lookup service to let other processes find the data storage processes that contain the data they are looking for.<p>You&#x27;d still have disks on your computer, but they would be mostly used as swap space.<p>The system would include some standard simple data holding and directory processes that implement a Unix-like namespace and permission system, but it would be easy to override this for data that needs special treatment. Just write a new data holding program that implements the special treatment you want and knows how to register with the standard directory processes.
ars超过 10 年前
For your project make sure you plan what to do if one application created the item, but another program wants to open it.<p>Don&#x27;t try to do it by applications registering types they can open - this never succeeds, there are simply too many file types in the world.<p>Also think about how to send data to someone else.<p>And finally think about how to integrate with existing devices that still use files.
walterbell超过 10 年前
Worth a look:<p>irmin, <a href="http://openmirage.org/blog/introducing-irmin" rel="nofollow">http:&#x2F;&#x2F;openmirage.org&#x2F;blog&#x2F;introducing-irmin</a><p>plan9, <a href="https://www.cs.unm.edu/~fastos/05meeting/PLAN9NOTDEADYET.pdf" rel="nofollow">https:&#x2F;&#x2F;www.cs.unm.edu&#x2F;~fastos&#x2F;05meeting&#x2F;PLAN9NOTDEADYET.pdf</a>
评论 #8309694 未加载
kazinator超过 10 年前
<i>&gt; I&#x27;m working on a project I&#x27;m calling &quot;Library Transfer Protocol&quot;, which is aiming to replace the concept of &quot;file&quot; and replacing it with &#x27;Library item&#x27;. Basically, in 2014 computer usage more closely mirrors the workflow of an author (revisions, publishing, etc), rather than an employee filling up a file cabinet for internal use (thank to the facebook and the like)</i><p>Please define how a &quot;library item&quot; is different from a &quot;file&quot;.<p>Is it made of bytes that can be read into a buffer and accessed?<p>(If not, how can an H.264 video or MP3 object exist as a library item and be processed?)<p>Do you not have spaces which assign names to library items?<p>The Hyper-Text Transfer Protocol has already replaced the concept of &quot;file&quot; with &quot;resource&quot;. A URI doesn&#x27;t necessarily name a file.
评论 #8310534 未加载
vezzy-fnord超过 10 年前
Your proposal doesn&#x27;t really sound like it deprecates files, but rather that it enhances them with attributes. Most operating systems other than Unix have already expanded on the file as a bag of bytes to one that supports features such as extended attributes and forks. Even most contemporary Unix file systems have xattrs (most notably XFS), but overall they seem to have had limited impact, and in the case of NTFS-style alternate data streams, even introduced some nasty security risks.<p>Really, what you seem to want is a file system with built-in version control and network sharing? Git and Mercurial are already virtual file systems of sorts, I guess.
coryrc超过 10 年前
Look up Common Lisp&#x27;s file handling functions. The number of options to open a file seems ridiculous in our world, but in that one function you can see a history of how many different ways &quot;files&quot; used to be accessed.
alanctgardner3超过 10 年前
Did you just describe git? Git has revisions of files, and they can be tagged, merged, etc. It still works on top of a conventional file system though, because why reinvent the wheel?
评论 #8309925 未加载
rch超过 10 年前
While not exactly an answer to your question, you might find it worthwhile to take a look at the 1060 NetKernel platform - <a href="http://1060.org" rel="nofollow">http:&#x2F;&#x2F;1060.org</a><p>&quot;NetKernel can be considered a unification of the Web and Unix implemented as a software operating system running on a microkernel within a single computer.&quot;<p><a href="https://en.wikipedia.org/wiki/NetKernel" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;NetKernel</a>
dchest超过 10 年前
Palm OS?
评论 #8309868 未加载
lawtguy超过 10 年前
What your building sounds like a document management system: <a href="http://en.wikipedia.org/wiki/Document_management_system" rel="nofollow">http:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Document_management_system</a>. Might be worth looking at some to see how they&#x27;d fit with what you&#x27;re envisioning. Even if you write it yourself, it can be helpful to see how others have solved the same problems.
rakoo超过 10 年前
Yep, check out camlistore (<a href="http://camlistore.org/" rel="nofollow">http:&#x2F;&#x2F;camlistore.org&#x2F;</a>). It can be quickly described as a big database at which you throw all your content, along with a JSON containing any attributes you want. These attributes are indexed and then searchable.
crazychrome超过 10 年前
I think the file metaphor is a must for the separation of OS and applications. Unless you have a better conceptual framework to deal with this problem, you&#x27;d probably live with &quot;files&quot;.
nobodysfool超过 10 年前
MUMPS... it&#x27;s sort of a database&#x2F;os&#x2F;programming language hybrid that uses a key value store.
yohanatan超过 10 年前
Yes, iOS.
sumitviii超过 10 年前
Is it on github?
评论 #8310539 未加载