ADV *NIX DAY 1-3 Flashcards
Utility to locate/print block device attributes.
blkid
Desktop Management Interface. A tool for dumping a computer’s DMI table contents in a human-readable format.
dmidecode
Print system information.
–a= all information
2.6.32-279
(2=kernel version, 6=Major revision, 32=Minor revision, 279= patch level & fixes)
uname
Query and change the system host name and related settings.
hostnamectl (CentOS7)
Change current run-level.
init
Determine current run-level.
who -r
Update and query run-level information for system services.
chkconfig
Run SysV init scripts. Start, stop, restart or view the status of services in /etc/init.d
service (CentOS6)
Query or send control commands to the systemd manager, to enable, disable, start, stop, or view the status of services.
systemctl (CentOS7)
Create the list of operating systems to boot in GRUB’s menu interface.
/boot/grub/grub.conf
init daemon configuration file, the initdefault line specifies what run-level starts at boot.
/etc/inittab
User mode components may include:
processes and threads windows manager libraries applications shells commands utility programs
Part of process management that shares CPU time between multiple LWPs.
scheduler
Implements file and file system related interfaces provided to user.
VFS
Elements of the Linux kernel that an architecture must use for normal operation and efficiency.
Architecture-dependent code
Ensures the proper and timely execution of processes.
process management
Provides an API to resources that send data across a network.
Network Subsystem
Converts a process running in user mode to a protected kernel mode process.
SCI
A program that provides the user CLI to the kernel.
Shell
An instance of a program in execution.
process
Contains the SCI and handles mapping between user requests and device driver actions. It also manages system resources and performs system services.
Kernel
Computer programs used to perform certain tasks, functions, or activities and originate in user mode.
Application
This mode includes processes such as shells, Linux commands, utilities, and user application programs.
User mode
An implementation of the standard C library used by many operating systems and programs on those systems.
glibc
When memory is exhausted and pages of memory are moved onto the disk.
swapping
A family of related standards specified by the IEEE that defines the API of a Unix OS.
POSIX
Run in user mode on top of a single kernel thread and shares address space and system resources.
LWP
A program that runs unobtrusively in the background rather than under the direct control of a user.
Daemon
This is a wrapper function for a Linux kernel system call.
library function
A low-level program allowing the kernel to communicate with a particular piece of hardware.
device driver
A catastrophic kernel crash that halts the entire PC.
kernel panic
Applications that make the OS work. (e.g., GUI, compilers, tools, and editors)
GNU Software
Displays file system type. (e.g., Ext, UFS, NTFS, …)
blkid
Executed from /etc/rc.d/rc*.d and spawns a login.
Run level
Executes Kernel and initrd images.
Grub
Executes bootloader (GRUB).
MBR
Executes /sbin/init deamon.
Kernel
Executes run-level programs.
Init
Executes MBR
Bios
The file where the init daemon gets its instructions from.
/etc/inittab
Initial root file system with limited directories and executables.
Initrd
Linux process that spawns a login.
getty or mingetty
Command used to verify current run level.
who -r
Directory where master copies of the startup scripts reside.
/etc/init.d
Command used to change current run level.
init (command)
Command that updates and queries run level information for system services.
chkconfig
Command retrieves information from a listing of available shells in the /etc/shells file.
chsh
Command that provides a description of the system’s hardware components.
dmidecode
More secure but less controllable system initialization manager.
systemd
Init manager where run-levels dictate the start up environment.
SysV
Modified SysV initialization manager, used by CentOS Version 6.
Upstart
Command that starts, stops, or restarts many services located in /etc/init.d.
service
Location of network-based services that fall in the xinetd category. (full path)
/etc/xinetd.d
Systemd command used to enable, start, stop, or disable services.
systemctl
Linux command used to view calls accessed during the execution of a command.
strace
Sets or prints the limits imposed on files written by the shell and its processes.
ulimit
Displays limits imposed on resources available to the current shell.
ulimit -a
Displays or sets core file size.
ulimit -c
Displays or sets max number of processes available to a single user.
ulimit -u
Similar to Windows Task Manager, this *nix tool is used to view system processes and their states.
ps
Allows a device driver or any other kernel service to be linked into and removed from the kernel while it is running.
LKM
Linux command used to display a list of active LKMs.
lsmod
Command and option to display all kernel parameter values currently available.
sysctl -a
Command and option to change a sysctl value for current session.
sysctl -w
Command and option to load sysctl values from a file.
sysctl -p
Configuration file where user limits imposed on resources are set.
/etc/security/limits.conf
Linux file where all kernel values are loaded from at system boot.
/etc/sysctl.conf
Process interruption caused by some event external of and asynchronous to the current running process.
interrupt
Error or exception condition generated within current running process. Software written to catch an exception generated by the CPU.
trap
List three ways in which a process-level interrupt request can be sent:
terminal
Administrator
Kernel
Terminal interrupt (user hits interrupt keys).
SIGINT
Surest kill (cannot be trapped)
SIGKILL
Restarts a daemon
SIGHUP
Default termination signal used by kill command.
SIGTERM
Quit from terminal, process produces a core dump file.
SIGQUIT
process state: R S Z T
process state: Running Sleeping Zombie Suspended (stopped or terminated)
Command that reveals all file systems, disk space usage, and logical mount points in block size.
df
Displays or maps logical devices to mount points on a file system.
mount
What Linux command displays the disk’s physical partitioning scheme?
fdisk
A ______ is the basic file allocation unit for EXT(X). The size is defined in the superblock.
block
The allocation status of blocks (data) is determined using the block group’s ___________.
block bitmap
The allocation status of inodes is determined using the block group’s ___________.
inode bitmap
The _______ lists the blocks on the disk where the data is stored.
Inode Table
What command can be used to view the primary superblock?
dumpe2fs
What are the three timestamps associated with the EXT(X) filesystem?
modification
access
change
What are the three timestamps associated with the EXT(X) filesystem?
hardlink
What type of link file contains the pathname to another file?
symbolic link
What command is used to view file or file system status to include the access, change, and modify timestamps?
stat
is a simple data structure containing the filename and the inode address where the file’s metadata can be found. This also contains a pointer to the next entry.
directory entry