Linux Basics: Difference between revisions

Line 972:
! Type !! System Call !! Description !! Call Syntax
|-
|Rowspan='1112'|Process || fork || Used to create processes. <br/> When creating child process, it creates a new process while preserving the parent process.
|-
|exec || Also used to create processes; but replaces the address space, text segment, data segment etc. of the current process with the new process.<br/> Only the new process exists after exec().<br/> The process which made the system call, wouldn't exist.
Line 981:
|-
|open || open and possibly create a file
|-
|openat || open and possibly create a file
|-
|close || close a file descriptor
Line 1,050 ⟶ 1,052:
|syslog || read and/or clear kernel message ring buffer; set console_loglevel
|-
 
|ptrace || process trace
|-
getuid get user identity
setuid set|getuid || get user identity
|-
utime change file last access and modification times
getuid get|setuid || set user identity
ustat get filesystem statistics
|-
statfs get filesystem statistics
|utime || change file last access and modification times
sysfs get filesystem type information
|-
getpriority get/set program scheduling priority
|ustat || get filesystem statistics
mlock lock and unlock memory
|-
sysctl read/write system parameters
|statfs || get filesystem statistics
prctl operations on a process
|-
chroot change root directory
|sysfs || get filesystem type information
sync commit filesystem caches to disk
|-
mount mount filesystem
|getpriority || get/set program scheduling priority
umount unmount filesystem
|-
swapon start swapping to file/device
|mlock || lock and unlock memory
swapoff stop swapping to file/device
|-
reboot reboot or enable/disable Ctrl-Alt-Del
|sysctl || read/write system parameters
sethostname set hostname
|-
gethostname get hostname
|prctl || operations on a process
ioperm set port input/output permissions
|-
init_module load a kernel module
|chroot || change root directory
delete_module unload a kernel module
|-
 
|sync || commit filesystem caches to disk
|-
|mount || mount filesystem
|-
|umount || unmount filesystem
|-
|swapon || start swapping to file/device
|-
|swapoff || stop swapping to file/device
|-
|reboot || reboot or enable/disable Ctrl-Alt-Del
|-
|sethostname || set hostname
|-
|gethostname || get hostname
|-
|ioperm || set port input/output permissions
|-
|init_module || load a kernel module
|-
|delete_module || unload a kernel module
|-
|io_setup || create an asynchronous I/O context
|-
|ppoll || wait for some event on a file descriptor
|-
|tee || duplicating pipe content
|-
|getcpu || determine CPU and NUMA node on which the calling thread is running
|}