Sign up ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free.

I keep reading this sentence:

Linux is a Unix-like system, but it is not Unix.

I don't know what's the real difference between the two. I know Linux got a lot of ideas from Unix and the licenses of the two are different. Apart from that, as I am not an expert in either one of them, I want to know whether there are basic differences between them in design or other significant aspects.

share|improve this question

closed as off topic by Walter, gnat, maple_shaft Apr 11 '12 at 14:41

Questions on Programmers Stack Exchange are expected to relate to software development within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

would you mind clarifying where did you read that? web search shows me Linux Kernel Development (3rd Edition) by Robert Love, is that it? – gnat Apr 9 '12 at 7:35

8 Answers 8

up vote 27 down vote accepted

A "Unix like" system may be fully compliant with the Single UNIX Specification, the collective name of standards for what qualifies as a Unix system, but at the same time Unix is a registered trademark of The Open Group and vendors of Unix like systems need to get their systems registered to officially qualify as Unix. Currently the registered UNIX 03 systems are:

  • Apple Inc.: Mac OS X Version 10.5 Leopard on Intel-based Macintosh computers
  • Apple Inc.: Mac OS X Version 10.6 Snow Leopard on Intel-based Macintosh computers
  • Fujitsu Limited: Solaris™10 Operating System on Fujitsu PRIMEPOWER® 64-bit SPARC® Based Platforms
  • Hewlett-Packard Company: HP-UX 11i V3 Release B.11.31 or later on HP Integrity Servers
  • IBM Corporation: AIX 5L for POWER V5.2 dated 8-2004 or later with APARs: IY59610, IY60869, IY61405 with VAC or later on pSeries CHRP systems
  • IBM Corporation: AIX 5L for POWER V5.3 dated 7-2006 or later on Systems using CHRP system architecture with POWER™processors
  • IBM Corporation: AIX 6 Operating System V6.1.2 with SP1 or later on Systems using CHRP system architecture with POWER™ processors and 2, 8 or 128 port async cards
  • Oracle Corporation: Oracle Solaris 11 FCS and later on SPARC-based platforms, 32-bit and 64-bit and on X86-based platforms, 32-bit and 64-bit
  • Oracle Corporation: Solaris 10 Operating System plus patch 118844-06 for X86 and on, on 64-bit X86 based systems
  • Oracle Corporation: Solaris 10 Operating System and on, on 32-bit and 64-bit SPARC based systems
  • Oracle Corporation: Solaris 10 Operating System and on, on 32-bit X86 based systems

Vendors of open source Unix like systems (mostly Linux and FreeBSD) typically don't register with The Open Group, either to avoid the costs of certification or, well, because they don't find much value in doing so. In theory, it's entirely possible that a Unix like system is technically Unix, and all it's missing is certification.

The Linux Foundation on the other hand, created the Linux Standard Base, an ISO standard, in an effort to standardize Linux. Compliance with POSIX is at the heart of both the SUS and the LSB, maintaining in a way the link between Unix and Linux.

Unix and Unix like systems tend to be more similar than different, in theory all popular Unix flavours, registered or not, are POSIX compliant (full or mostly), so they share a core programming interface, shells and utilities (and a lot of other stuff). IEEE and The Open Group maintain a freely available copy of the latest version, POSIX.1-2008, where you can find more information on what POSIX compliance actually means.

Now, apart from the legal and technical reasons, Linux inherited the "not Unix" mantra from it's association with GNU, a Unix like operating system initiated by Richard Stallman. GNU stands for "GNU's not Unix", as Stallman's intentions were to build a Unix compatible system that would be free, and in order to do that it should contain no Unix code, as Unix is proprietary.

Early Linux developers started porting GNU tools to Linux, and the resulting system was referred as GNU/Linux as early as 1992. There is a long lasting controversy on whether Linux should be referred to as Linux or GNU/Linux (as it incorporates several parts of GNU), but that's irrelevant to your question, what's relevant is that "not Unix" may just refer to the association with GNU and have little to do with it's design, depending on context.

The "History of Linux" article on Wikipedia explains the origins of Linux and it's relationship with Unix (via Minix and GNU) in some detail, and you should also take some time to read through the references of the article, if you are interested in learning more.

share|improve this answer
good answer,I will wait and see if choose yours as my answer:) – Gnijuohz Apr 9 '12 at 4:27
@Gnijuohz Don't rush in accepting answers, always let your question mature for a day or two (or more, if you want), you may get great answers from people who wouldn't bother answering if they saw that you already accepted an answer. Accepting an answer is completely up to you, you don't even have to accept if none of the answers were helpful to you, regardless of how the community responded to them. – Yannis Apr 9 '12 at 4:35
Interesting, apparently the latest version of OS X is not "officially" UNIX. – Kris Harper Apr 9 '12 at 10:57
@root45 That's to be expected, as some time is required to check a version for compliance. – Yannis Apr 9 '12 at 11:28
@YannisRizos Ah okay. That makes sense. Thanks for the information. – Kris Harper Apr 9 '12 at 12:23

UNIX is a family of operating systems and nowadays UNIX is more of a brand owned by The Open Group. For an operating system to be branded UNIX, it must undergo a conformance testing, and for Linux this would mean that every distribution out there (Ubuntu, Debian, Fedora, Red Hat, etc) would have to separately undergo this conformance testing for every release. So this is one of the main reasons why Linux is a unix-like system and not a UNIX.

This testing that I mentioned is to ensure the OS compliance with the Single Unix Specification, which is currently at version 4 SUSv4 (Single Unix Specification version 4). This specification defines a set of APIs that must be available to applications for a system to be qualified for the name UNIX.

share|improve this answer
Is it a good standard to follow? Do Linux authors try to? – Job Apr 9 '12 at 3:41
It's a good however incomplete standard. The contributors of the Linux Kernel do try to follow this standard and Linux can be unofficially considered a UNIX system. If you are developing an applications against the Unix standards it will likely compile and run on a Linux system. Unfortunately, as I said before, the UNIX is rather incomplete is some aspects, so the OSes provide additional APIs for some tasks and this is what makes certain applications platform dependent as these additional API tend to vary. – Raphael Apr 9 '12 at 3:49
There was a distribution called Linux-FT that started the POSIX certification process, but unsurprisingly the sponsors ran out of money. – user4051 Apr 9 '12 at 10:13
Thanks for this info! I aways wondered if someone out there had ever tried to certify a distro. – Raphael Apr 9 '12 at 16:11

The existing answers already mention some of the differences that you are looking for. Without being the Linux kernel expert, I'd also add that many of the design/implementation differences between GNU/Linux and the various Unices are covered in the Linux kernel design patterns series.

share|improve this answer

"UNIX" is a complicated thing to pin down. In terms of standards conformance, both Solaris and Mac OS X are "officially" UNIX but you don't have to spend much time before you find rather large differences between the two. There's a great diagram that documents the release of various flavours of UNIX or UNIX-like operating systems and how they influenced and diverged from each other.

In the grand scheme of things that look, walk and quack like UNIX, a Linux system [*] is one of the more conventional releases. It's quite common for people to refer to Unices or *nix and mean "anything UNIX-like", which probably includes Linux. However UNIX is a registered trademark with limitations on how it may be applied commercially; no Linux distribution conforms to those limitations.

[*]Because this question invites a level of semantic hair-splitting I think it's on-topic in this case to point out that Linux itself is just a kernel on which an operating system can be built. It's common to build a UNIX-like system on top of Linux, which is what it was designed for, and that system is usually built out of GNU project components. In the answer above "Linux" could be read as shorthand for "an operating system that incorporates the Linux kernel".

share|improve this answer
@YannisRizos I'll add a reference to the answer, it definitely is certified. – user4051 Apr 9 '12 at 9:57
Yes, you're absolutely right, from Leopard and onwards Mac OS is UNIX 03 certified, and here's another reference. – Yannis Apr 9 '12 at 10:04

I once read that Linux is what you get when you take a PC developer and ask him to write a Unix OS, whereas FreeBSD is what you get when you take a Unix developer and ask him to make a PC OS.... don't forget the BSDs in your comparison!

The differences is mainly in the Kernel as the userspace applications (including things like ls) are all part of the GNU project. This means that Unix, FreeBSD, and Linux all appear to be pretty much the same thing.

However there are differences once you look closely. The directory layout will be different (but many Linux distros use their own mostly compatible but still different layouts anyway), the filesystems are different (Unix uses UFS, FreeBSD uses FFS, Linux uses Ext3 to be simplistic - all of them can use ports of common FSs, eg ZFS)

Then there are differences in core APIs, Linux will give you the inotify API to tell you when files changes, Mac OSX gives you FSEvents, and FreeBSD gives you kqueue.

So they can be considered the same family - compare a Windows system with GNU tools ported to it with a Linux system with the same tools. They will only superficially appear the same, but a Unix or FreeBSD system will still appear comparable. At a closer look, you'll find porting apps between FreeBSD, Unix and Linux relatively easy compared to porting to alternative OSs such as Windows.

share|improve this answer

Unix is not any more a single Operating System. It used to be an implementation by Bell Labs/ AT&T but now it is a standard.

Technically, Linux is only a kernel. This kernel can be found in non Unix like OSes, the most popular being Android. On the other hand, there are many Linux based OSes that are Unix like. Most (if not all) of them are using the Gnu libraries and utilities. This combination is providing Linux distributions the Unix API and compliance (or non compliance) to the standards.

The Unix standard doesn't require a compliant system to be proprietary or to have any particular license. BSDs, OpenSolaris/Illumos, darwin are examples of non Linux still free Unix implementations.

Compliant systems are usually but not always a mix of proprietary and open source components while Gnu/Linux can be either fully Open Source or also include proprietary stuff.

As far a Unix compliance is concerned, there are no much differences. Most Linux distributions and Unix implementations share the same set of commands using the same set of options. However, you will find a lot of extensions of the standard commands, especially on the Gnu side where they are called Gnuisms, and numerous commands that aren't defined by the standards in the first place (compilers, administrative commands, installation, packaging, graphic environment). This is an area where you can find a lot of divergence, incompatibilities and sometimes holy wars.

Gnu/Linux development model is usually considered to be more "organic" and "bazaar" like, while other Unix like systems are more "designed" and "cathedral" like. Depending on the subsystems, the difference is not that much clear-cut and depends the individuals and/or companies behind them.

share|improve this answer

Linux comes with many tools such as:

  • GUI system
  • GNU utilities (such as cp, mv, ls, date, bash etc)
  • installation & management tools
  • GNU C/C++ Compilers
  • Editors (vi)
  • and various applications (such as OpenOffice, Firefox).

However, most UNIX operating systems are considered as a complete operating system as everything come from a single source or vendor.

Some things they share:

  • GUI, file, and windows managers (KDE, Gnome)
  • Shells (ksh, csh, bash)
  • Various office applications such as
  • Development tools (perl, php, python, GNU C/C++ compilers)
  • POSIX interface
share|improve this answer
Why downvoted?? – Billjk Apr 9 '12 at 3:28
Linux also expands on Unix philosophy ... – Job Apr 9 '12 at 3:40
Linux is not just a kernel, the Linux kernel is, well, the kernel. Linux usually refers to a full system that's build around the Linux kernel. – Yannis Apr 9 '12 at 3:50
@Anonymous - Sometimes, if you edit and correct your answer, downvoters may remove the downvote. It's not guaranteed, but sometimes it does help. (I didn't downvote, just trying to be helpful) :) The rest of your answer is correct, IMHO, so getting rid of the discrepancy may help get you some upvotes/avoid more downvotes. – jmort253 Apr 9 '12 at 4:24
Thanks! Took your advice – Billjk Apr 9 '12 at 4:26

Not really, Linux was a cobbled together reverse engineering of Unix after all, so the kernel design followed Ken Thompson's philosophy. The Linux way seems to be to imitate Unix philosophy as closely as possible without ever burdening ones self with original thought.

share|improve this answer
@YannisRizos What do you mean by "but it wasn't really usable". AFAIK it was fully usable, but because it was written in PDP assembly it was hard to port it in other architectures. – ierax Apr 9 '12 at 10:56
@samual-johnson -1 Because you don't back up your statements with references. It's the first time that I'm hearing about the "Ken Thompson philosophy" (and it's Thompson, not Thomson). – ierax Apr 9 '12 at 11:00
@faif Checking my references, the rudimentary kernel I was referring to was written for the GE-645 and not the PDP, so it was a stretch to call it a Unix kernel. I've deleted the comment, since the main point was about the lack of references anyways and your comment is enough to convey that message. - samual please take some time to either back up your claims with solid references or revise it to something less opinion based. – Yannis Apr 9 '12 at 11:25
@YannisRizos Interesting. I haven't heard about GE-645, which according to Wikipedia was an improved version of Multics. Thanks for the info. – ierax Apr 9 '12 at 16:36

Not the answer you're looking for? Browse other questions tagged or ask your own question.