POSIX是什么?我读过维基百科上的文章,每次遇到这个词我都会去读。事实上,我从来没有真正理解它是什么。
有没有人可以通过解释“POSIX的需求”来解释给我听?
POSIX是什么?我读过维基百科上的文章,每次遇到这个词我都会去读。事实上,我从来没有真正理解它是什么。
有没有人可以通过解释“POSIX的需求”来解释给我听?
当前回答
关于POSIX的一些事实并不那么明朗。
POSIX也是系统调用接口或API,它有将近30年的历史。
它被设计用于对本地存储的串行数据访问,使用具有单个cpu的单台计算机。
在POSIX的设计中,安全性并不是一个主要的问题,这导致了多年来大量的竞争条件攻击,迫使程序员绕过这些限制。
严重的错误仍在被发现,这些错误本可以通过更安全的POSIX API设计来避免。
POSIX期望用户一次发出一个同步调用,并在发出下一个调用之前等待它的结果。今天的程序员希望一次发出许多异步请求,以提高总体吞吐量。
这种同步API对于访问远程和云对象尤其不利,因为在这些地方,高延迟很重要。
其他回答
POSIX代表可移植操作系统接口(Portable Operating System Interface),是IEEE为促进应用程序可移植性而设计的标准。POSIX是一个厂商联盟试图创建UNIX的单一标准版本。
In 1985, individuals from companies throughout the computer industry joined together to develop the POSIX (Portable Operating System Interface for Computer Environments) standard, which is based largely on the UNIX System V Interface Definition (SVID) and other earlier standardization efforts. These efforts were spurred by the U.S. government, which needed a standard computing environment to minimize its training and procurement costs. Released in 1988, POSIX is a group of IEEE standards that define the API, shell, and utility interfaces for an operating system. Although aimed at UNIX-like systems, the standards can apply to any compatible operating system. Now that these stan- dards have gained acceptance, software developers are able to develop applications that run on all conforming versions of UNIX, Linux, and other operating systems.
摘自《Linux实用指南》
POSIX是一种操作系统标准,旨在使编写跨平台软件变得更容易。这在Unix世界中是一件特别重要的事情。
Posix governs interoperability, portability, and in other areas such as the usage and mechanism of fork, permissions and filesystem standards such as /etc, /var, /usr and so on . Hence, when developers write a program under a Posix compliant system such as for example Linux, it is generally, not always, guaranteed to run on another posix compliant system such as IBM's AIX system or other commercial variants of Unix. Posix is a good thing to have as such it eases the software development for maximum portability which it strives for. Hope this answer makes sense.
感谢Jed Smith和Tinkertim指出我的错误——我的错!!:(
Posix更像是一个操作系统,它是一个“操作系统标准”。你可以把它想象成一个虚构的操作系统,它实际上并不存在,但它有一个文档。这些论文是由IEEE定义的“posix标准”,IEEE是美国的大型标准组织。 实现该规范的操作系统是“posix兼容的”。
政府法规在投资中更倾向于posix兼容的解决方案,因此posix兼容具有显著的财务优势,特别是对于美国的大型IT公司。
一个完全兼容posix的操作系统的回报是,它可以保证无缝地编译和运行所有兼容posix的应用程序。
Linux是最著名的。OSX、Solaris、NetBSD和Windows NT也可以在这里使用。Free和OpenBSD只是“几乎”兼容posix。WinNT的posix-compliance只是避免上述政府监管的伪解决方案。