An ordinary user executes a command under the shell, what happens behind this, is a summary of the individual, if there is a wrong place welcome to build, thank you!
Touch/tmp/test.txt
#######################################################################################
Tom executes this command in the shell, the shell sends the command to the kernel and determines whether the command exists, determines whether Tom has permission to execute through the metadata on the file system, the kernel loads the mkdir instruction and data from memory, and starts mkdir as Tom. The kernel determines whether the mkdir process initiated by Tom has permission to/ TMP directory to establish a called Text.txt file, if the permissions through the system call to the kernel request to establish a file, the kernel will be used to go to the CPU to execute, and then the CPU will store the results in memory, and then the kernel from memory to extract the results, the kernel will be the result of the file system in the corresponding storage space on a block, and To the process, the process through the shell performance to the user.
This article is from the "Hanging Sword" blog, please be sure to keep this source http://sublime.blog.51cto.com/8856101/1434025