Yandex Big Data Essentials Week1 Unix Command Line Interface Processes managing

本文汇总了常用的Linux命令及其用法,包括文件操作、进程管理、内存查看等关键功能,适用于初学者及日常工作中需要频繁使用Linux系统的用户。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

free

displays the total amount of free and used memory
free [options]

top

provides a dynamic real-time view of a running system
top [options]

ps

provides snapshot of the status of currently running processes
ps [options]

kill

sends a signal to a process
kill [-s][-l] %pid

nice

runs a command with a modified scheduling priority
nice [OPTION] [COMMAND [ARG] …]

课程总结:

CommandDescription
awkinterpreted programming language text processing
awk -Fset the separator
catDisplay the contents of a file at the command line,is also used to copy and or append text files into a document. Named after it’s function to con-cate-nate files.
cdChange the current working directory.Also known as chdir
cd /Change the current directory to root directory
cd ..Change the current directory to parent directory
cd ~Change the current directory to your home directory
cpMake copies of files and directories
cp -rCopy directories recursively
cutDrop sections of each line fo iniput by bytes,characters, or fields,separated by a delimiter (the tab character by default)
cut -d -f-d is for delimiter instead of tab character,-f select only those fields(ex.: ” cut -d “,” -f1 multilined_file.txt” -will mean that we select only the first field from each comma-separated line in the file
duEstimate (and display) the file space usage -space used under a particular directory or file on a file system
dfDisplay the amount of available disk space being used by file systems.
df -huse human readable format
freeDisplay the total amount of free and used memory(use vm_stat instead on MacOS).
free -mDisplay the amount of memory in megabytes
feee -gDisplay the amount of memory in gigabytes
grepProcess text and print any lines which match a regular expression(“global regular expression print”)
headPrint the beginning of a text file or piped data.By default,outputs the first 10 lines of its input to the commannd line
head -nOutput the first n lines of input data(ex: “head -5 multilined_file.txt”)
killSend a signal to kill a process. The default signal for kill is TERM(which will terminate the process)
lessis similar to more,but has extended capability of allowing both forward and backward navigation through the file
lsList the content of a directory
ls -lList the contents of a directory + use a long format,displaying Unix file types,permissions,number of hard links, owner,group,size,last-modified data and filename.
ls -lhList the contents of a directory + print sizes in human readable format.(eg. 1k,234M,2G,etc)
ls -lSSort by file size
manDisplay the man pages with provide documentation about commands,system calls,library routines and the kernel
mkdirCreate a directory on a file system.
moreDisplay the contents of a text file one screen at a time
mvRename files or directories or move them to a different directory
niceRun a command with a modified scheduling priority.
psProvide information about the currently running process,including their process identification numbers (PIDS)(“process status”)
ps aselect all processes except both session leader and processes not associated with terminal.
pwdAbbreviated from “print working directory”,pwd writes the full pathname of the current working directory.
rmRemove files or directory
rm -rRemove directories and their contents recursively.
sortSort the contents of a text file.
sort -rSort the output in the reverse order. Reverse means - to reverse the result of comparsions
sort -k-k or –key=POS1[,POS2] Start a key at POS1 (origin 1), end it at POS2 (default end of the line) (ex.: “sort -k2,2 multilined_file.txt”).
sort -nCompare according to string numerical value.
tailPrint the tail end of a text file or piped data. Be default, outputs the last 10 lines of its input to the command line.
tail -nOutput the last n lines of input data (ex.: “tail -2 multilined_file.txt”).
topProduce an ordered list of running processes selected by user-specified criteria, and updates it periodically.
touchUpdate the access date and or modification date of a file or directory or create an empty file.
trReplace or remove specific characters in its input data set (“translate”).
tr -dDelete characters, do not translate.
vimIs a text editor (“vi improved”). It can be used for editing any kind of text and is especially suited for editing computer programs.
wcPrint a count of lines, words and bytes for each input file (“word count”)
wc -cPrint only the number of characters.
wc -lPrint only the number of lines.
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值