So, there are lots of different versions of Unix out there: HP-UX, AIX, BSD, etc. Linux is considered a Unix clone rather than an implementation of Unix. Are all the "real" Unices actual descendants of the original? If not, what separates Linux from Unix?
Linux vs Unix – Is Linux a Unix?
historylinuxunix
Related Solutions
We can distinguish UNIX the trademark from Unix the code-base.
AT&T
Unix was initially developed at Bell Labs, owned by AT&T. This Unix team became AT&T's Unix System Laboratories (USL) and produced Unix System V (Roman numeral for five) or SysV for short. The University of California at Berkeley (UCB) also licenced Unix for academic use, their Computer Systems Research Group (CSRG) later made many important changes and additions (notably TCP/IP) in their Berkeley Software Distribution (BSD) which were later incorporated into many descendants of Unix leading to the BSD vs SysV split. Ultimately a lot of the BSD changes were back-ported into SysV (which we can consider the main "ancestral Unix" code base).
Along the way, many different businesses have licenced this code-base (at various stages in it's development) and used it as the basis of their proprietary Unix operating systems - AIX, HPUX, IRIX, Solaris, Ultrix and dozens of others.
Novell (Attachmate)
USL was purchased by Novell. At this time, the ancestral Unix code was known as Unix system V release 4 - or SVR4 for short. Novell named their product Unixware to complement the name of their legacy network OS Netware. Novell have been Acquired by Attachmate.
The Santa Cruz Operation
Novell eventually sold their Unix business to an old SVR3.2 licensee The Santa Cruz Operation (SCO) whose main business up to that point was selling a product named OpenServer that was based on Unix SVR3.2. Novell (since bought by Attachmate) still own some rights‡ to Unix but do not do any work on the source code.
Caldera / The Sco Group / TSG Group Inc
The Santa Cruz Operation later sold their Unix business to a Linux company Caldera who later renamed themselves to The SCO Group (sometimes referred to as new SCO or SCOG) and who had a disastrous failure of leadership leading to chapter-11 bankruptcy and sale of the Unix business to UnXis, a business formed for this purpose. Subsequently The SCO Group were reorganised into TSG Group Inc and TSG Operations Inc. They have no role regarding maintenance of the ancestral Unix code base. In August 2012 TSG Group Inc converted to chapter 7 bankruptcy.
UnXis / Xinuos
So now UnXis are responsible for marketing and developing/maintaining Unixware - the ancestral AT&T Unix code base. Because the Santa Cruz Operation (old SCO) originally ported† Unix to the x86 platform, I believe x86 and x86_64 are the only target platforms that UnXis directly support.
On June 12 2013, UnXis announced it had been renamed Xinuos.
Xinuos no longer seriously support installation of their ancestral Unix products on bare metal. Their SVR3.2 and SVR5 based products are offered as virtual machines (VM) to be run under their "OpenServer 10" product which is a derivative of FreeBSD.
So the body of code with the greatest claim to be the prime descendant of the ancestral Unix code is now, in practical terms, not much more than a compatibility layer between other operating systems and legacy applications.
† Microsoft licensed Unix and ported it to 16-bit Zilog Z8000 - old SCO purchased Xenix from them and ported it to the 16-bit 8086 architecture (used by IBM for their original IBM PC). Old SCO later ported SVR3.2 to x86 as 32-bit SCO-Unix later renamed OpenServer
‡ Novell's rights were contested, somewhat futilely, by The SCO Group (now named TSG Group Inc), the bankrupt remnants of the old Linux company Caldera. It is not yet clear whether TSG Group Inc have finally discontinued this and related litigation, the last activity in a related case against IBM was January 2018 and TSG Group Inc are not commercially active
If what you have in mind is the usage of time
shell builtin, then 3 digit precision is the design limitation - as per man bash
:
TIMEFORMAT
The value of this parameter is used as a format string specify‐
ing how the timing information for pipelines prefixed with the
time reserved word should be displayed. The % character intro‐
duces an escape sequence that is expanded to a time value or
other information. The escape sequences and their meanings are
as follows; the braces denote optional portions.
%% A literal %.
%[p][l]R The elapsed time in seconds.
%[p][l]U The number of CPU seconds spent in user mode.
%[p][l]S The number of CPU seconds spent in system mode.
%P The CPU percentage, computed as (%U + %S) / %R.
The optional p is a digit specifying the precision, the number
of fractional digits after a decimal point. A value of 0 causes
no decimal point or fraction to be output. At most three places
after the decimal point may be specified; values of p greater
than 3 are changed to 3. If p is not specified, the value 3 is
used.
For seemingly more precise measurements, you can try using date
with customized output formatting to show nanoseconds:
Tstart=$(date "+%s.%N")
some_command(s)
Tend=$(date "+%s.%N")
echo "Elapsed: $( Tend-Tstart |bc -l) nanoseconds"
However, notice that in both cases (time
and date
), you have some overhead, as the system takes some time to run the starting/stopping commands. The overhead is smaller for time
, thanks to it being a builtin. So the three-digit limit is there for a reason: the rest is just random garbage.
See also this similar question, though the accepted answer contains a little bug currently.
Best Answer
That depends on what you mean by “Unix”, and by “Linux”.
UNIX is a registered trade mark of The Open Group. The trade mark has had an eventful history, and it's not completely clear that it's not genericized due to the widespread usage of “Unix” refering to Unix-like systems (see below). Currently the Open Group grants use of the trade mark to any system that passes a Single UNIX certification. See also Why is there a * When There is Mention of Unix Throughout the Internet?.
Unix is an operating system that was born in 1969 at Bell Labs. Various companies sold, and still sell, code derived from this original system, for example AIX, HP-UX, Solaris. See also Evolution of Operating systems from Unix.
There are many systems that are Unix-like, in that they offer similar interfaces to programmers, users and administrators. The oldest production system is the Berkeley Software Distribution, which gradually evolved from Unix-based (i.e. containing code derived from the original implementation) to Unix-like (i.e. having a similar interface). There are many BSD-based or BSD-derived operating systems: FreeBSD, NetBSD, OpenBSD, Mac OS X, etc. Other examples include OSF/1 (now discontinued, it was a commercial Unix-like non-Unix-based system), Minix (originally a toy Unix-like operating system used as a teaching tool, now a production embedded Unix-like system), and most famously Linux.
Strictly speaking, Linux is an operating system kernel that is designed like Unix's kernel.
Linux is most commonly used as a name of Unix-like operating systems that use Linux as their kernel. As many of the tools outside the kernel are part of the GNU project, such systems are often known as GNU/Linux. All major Linux distributions consist of GNU/Linux and other software.
There are Linux-based Unix-like systems that don't use many GNU tools, especially in the embedded world, but I don't think any of them does away with GNU development tools, in particular GCC.
There are operating systems that have Linux as their kernel but are not Unix-like. The most well-known is Android, which doesn't have a Unix-like user experience (though you can install a Unix-like command line) or administrator experience or (mostly) programmer experience (“native” Android programs use an API that is completely different from Unix).