-
Glossary of Unix programming
background
Processes usually running at a lower priority and with their input disconnected from the interactive session. Any input and output are usually directed to a file or other process.
background process
An autonomous process that runs under UNIX without requiring user interaction.
bash
Stands for GNU Bourne Again shell and is based on the Bourne shell, sh, the original command interpreter.
block special file
Provides a mechanism for communicating with device drivers via the file system. These files are called block devices because they transfer large blocks of data at a time. This type of file typically represents hard drives and removable media.
body
The set of commands executed by a loop is called the body of the loop.
Bourne shell
The original standard user interface to UNIX that supported limited programming capability.
BSD
Berkeley Software Distribution.
-
Glossary of Unix programming
BSD UNIX
Version of UNIX developed by Berkeley Software Distribution and written at the University of California, Berkeley.
built in
A command whose code is part of the shell as opposed to a utility that exists in a separate disk file, which must be read into memory before executing the command.
C shell
A user interface for UNIX written by Bill Joy at Berkeley. It features C-programming-like syntax.
cat
The command used to view the contents of a file.
cd
The command used to change directories.
character special file
Character special files provide a mechanism for communicating with a device one character at a time.
chown
The command used to change the owner of a file or directory.
command
The name of a program and any arguments you specify to that program to cause its behavior to change. You might see the term command used instead of the term utility for simple commands, where only the program name to execute is given.
-
Glossary of Unix programming
command separator
Indicates where one command ends and another begins. The most common command separator is the semicolon character, ;.
command substitution
The process by which the shell executes a command and substitutes in the output of the command.
comment
A statement that is embedded in a shell script but should not be executed by the shell.
complex command
A command that consists of a command name and a list of arguments.
compound command
A list of simple and complex commands separated by the semicolon character, ;.
compound expression
Consists of one or more expressions.
conditional execution
Alters the execution of a script, based on the system type. A script that uses conditional execution usually consists of an if statement at the beginning that sets variables to indicate the commands that should be used on a particular platform.
-
Glossary of Unix programming
cp
The command used to copy files.
daemon
A system-related background process that often runs with the permissions of root and services requests from other processes.
debugging hook
A function or set of commands that executes only when a shell script executes with a special argument. Debugging hooks provide a convenient method for tracing the execution of a script in order to fix problems.
default behavior
The output that is generated when a command runs as a simple command is called the default behavior of that command.
directory
A type of file used to store other files. For users familiar with Windows or Mac OS, UNIX directories are equivalent to folders.
directory tree
UNIX uses a hierarchical structure for organizing files and directories. This structure is often referred to as a directory tree. The tree has a single root node, the slash character (/), and all other directories are contained below it.
environment variable
A variable that is available to any program that is started by the shell.
escape sequence
A special sequence of characters that represents another character.
-
Glossary of Unix programming
escaping
Escaping a character means to put a backslash (\) just before that character. Escaping can either remove the special meaning of a character in a shell command or it can add special meaning as we saw with \n in the echo command. The character following the backslash is called an escaped character.
execute permission
In UNIX, only those files that have execute permission enabled can run.
exporting
A variable is placed in the environment by exporting it using the export command.
expression
A piece of code that are evaluated to produce a numeric result, such as 0 or 1. Some expressions that involve mathematical operations can produce other results.
field
A set of characters that are separated by one or more field separator characters. The default field separator characters are Tab and Space.
field separator
Controls the manner in which an input line is broken into fields. In the shell, the field separator is stored in the variable IFS. In awk the field separator is stored in the awk variable FS. Both the shell and awk use the default value of Space and Tab for the field separator.
file descriptor
An integer that is associated with a file. Allows you to read and write from a file using the integer instead of the filename.
filesystem
A directory structure contained within a disk drive or disk area. The total available disk space can be composed of one or more filesystems. A filesystem must be mounted before it can be accessed. To mount a filesystem, you must specify a directory to act as the mount point. Once mounted, any access to the mount point directory or its subdirectories will access the separate filesystem.
-
Glossary of Unix programming
Glossary of Unix programming
hard link
A directory entry which maps a filename to an inode number. A file may have multiple names or hard links. The link count gives the number of names by which a file is accessible. Hard links do not allow multiple names for directories and do not allow multiple names in different filesystems.
home directory
Your home directory is the directory that you start out in after you log in.
infinite loop
A loop that executes forever without terminating.
inode
A table entry within a filesystem that contains file information such as the owner, group, permissions, last modification date/time, last access date/time, and the block list of the actual file data. There is one inode for each file. The inodes are numbered sequentially. The inode does not contain the filename. A directory is a table that maps filenames to inode numbers.
input redirection
In UNIX, the process of sending input to a command from a file.
-
Glossary of Unix programming
Glossary of Unix programming
interactive mode
In interactive mode, the shell reads input from you and executes the commands that you specify. This mode is called interactive because the shell is interacting with a user.
invisible or hidden file
A file whose name starts with the . character. By default the ls command does not list these files. You can list them by specifying the -a option to ls.
iteration
A single execution of the body of a loop.
kernel
The heart of the UNIX system. It provides utilities with a means of accessing a machine’s hardware. It also handles the scheduling and execution of commands.
Korn shell
A user interface for UNIX with extensive scripting (programming) support. Written by David G. Korn. The shell features command-line editing and will also accept scripts written for the Bourne shell.
library
A file that contains only functions. Usually libraries contain no main code.
literal character
A character with no special meaning and which causes no extra action to be taken. Quoting causes the shell to treat a wildcard as a literal character.
-
Glossary of Unix programming
local variable
A variable that is present within the current instance of the shell. It is not available to programs that are started by the shell.
loop
Enables you to execute a series of commands multiple times. Two main types of loops are the while and for loops.
ls
The command used to list the files in a directory.
main code
Consists of all the commands in a shell script that are not contained within functions.
major number
UNIX uses this to associate a block special file or a character special file with a device driver.
man page
Every version of UNIX comes with an extensive collection of online help pages called man pages (short for manual pages). The man pages are the authoritative source about your UNIX system. They contain complete information about both the kernel and all the utilities.
metacharacter
In a regular expressions, a metacharacter is a special character that is expanded to match patterns.
-
Glossary of Unix programming
minor number
UNIX uses this to associate a block special file or a character special file with a device driver.
mv
The command used to rename files.
nested loop
When a loop is located inside the body of another loop it is said to be nested within another loop.
newline character
Literally the linefeed character whose ASCII value is 10. In general, the newline character is a special shell character that indicates a complete command line has been entered and it may now be executed.
no-op
A command that does nothing and thus can be used as a dummy command or placeholder where syntax requires a command.
noninteractive mode
In noninteractive mode, the shell does not interact with you, rather it reads commands stored in a file and executes them. When it reaches the end of the file, the shell exits.
numeric expression
A command used to add, subtract, multiply, and divide two numbers. Numeric expressions are constructed using the numeric operators—+ (add), – (subtract), * (multiply), and / (divide).
-
Glossary of Unix terms
ordinary file
A file on the system that contains data, text, or program instructions.
output redirection
In UNIX the process of capturing the output of a command and storing it in a file is called output redirection, because it redirects the output of a command into a file instead of the screen.
parent process
Process that controls another often referred to as the child process or subprocess. See process.
parent process identifier
Shown in the heading of the ps command as PPID. The process identifier of the parent process. See also parent process.
parent shell
Shell (typically the login shell) that controls another, often referred to as the child shell or subshell. See shell.
piping
The process used to redirect the output of one command into the input of another command. Piping is accomplished with the pipe character, |.
process
A discrete running program under UNIX. The user’s interactive session is a process. A process can invoke (run) and control another program that is then referred to as a subprocess. Ultimately, everything a user does is a subprocess of the operating system.
process identifier
Shown in the heading of the ps command as pid. The unique number assigned to every process running in the system.
prompt
When you see a prompt, you can type the name of a command and press Enter. In this book, we will use the $ character to indicate the prompt.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
Bookmarks