Linux Today: Linux News On Internet Time.

More on LinuxToday

Linux Magazine: It's (Not) Magic

Mar 09, 2005, 13:00 (0 Talkback[s])
(Other stories by Jerry Peek)

WEBINAR: On-demand webcast

How to Boost Database Development Productivity on Linux, Docker, and Kubernetes with Microsoft SQL Server 2017 REGISTER >

"While some operating systems use file extensions like .doc,.pdf, and .txt to associate files with applications, Linux systems generally eschews extensions.( Some applications use extensions by convention — C compilers, for instance, expect source filenames to end with .c — but the kernel doesn't enforce this.) Instead, Linux uses a system of magic numbers, where the first few bytes of each executable file tell the kernel how to run it.

"For example, there's no need to name a shell script Plain foo is fine, because Linux figures out the rest( as you'll see in a moment). Magic numbers are widely used on Linux, and not just for executables. Magic numbers are used to identify many other types of files, too..."

Complete Story

Related Stories: