📄 busybox.1
字号:
.\" Automatically generated by Pod::Man v1.3, Pod::Parser v1.13.\".\" Standard preamble:.\" ========================================================================.de Sh \" Subsection heading.br.if t .Sp.ne 5.PP\fB\\$1\fR.PP...de Sp \" Vertical space (when we can't use .PP).if t .sp .5v.if n .sp...de Vb \" Begin verbatim text.ft CW.nf.ne \\$1...de Ve \" End verbatim text.ft R.fi...\" Set up some character translations and predefined strings. \*(-- will.\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left.\" double quote, and \*(R" will give a right double quote. | will give a.\" real vertical bar. \*(C+ will give a nicer C++. Capital omega is used to.\" do unbreakable dashes and therefore won't be available. \*(C` and \*(C'.\" expand to `' in nroff, nothing in troff, for use with C<>..tr \(*W-|\(bv\*(Tr.ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'.ie n \{\. ds -- \(*W-. ds PI pi. if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch. if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch. ds L" "". ds R" "". ds C` "". ds C' ""'br\}.el\{\. ds -- \|\(em\|. ds PI \(*p. ds L" ``. ds R" '''br\}.\".\" If the F register is turned on, we'll generate index entries on stderr for.\" titles (.TH), headers (.SH), subsections (.Sh), items (.Ip), and index.\" entries marked with X<> in POD. Of course, you'll have to process the.\" output yourself in some meaningful fashion..if \nF \{\. de IX. tm Index:\\$1\t\\n%\t"\\$2"... nr % 0. rr F.\}.\".\" For nroff, turn off justification. Always turn off hyphenation; it makes.\" way too many mistakes in technical documents..hy 0.if n .na.\".\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2)..\" Fear. Run. Save yourself. No user-serviceable parts.. \" fudge factors for nroff and troff.if n \{\. ds #H 0. ds #V .8m. ds #F .3m. ds #[ \f1. ds #] \fP.\}.if t \{\. ds #H ((1u-(\\\\n(.fu%2u))*.13m). ds #V .6m. ds #F 0. ds #[ \&. ds #] \&.\}. \" simple accents for nroff and troff.if n \{\. ds ' \&. ds ` \&. ds ^ \&. ds , \&. ds ~ ~. ds /.\}.if t \{\. ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u". ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'. ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'. ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'. ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'. ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'.\}. \" troff and (daisy-wheel) nroff accents.ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'.ds 8 \h'\*(#H'\(*b\h'-\*(#H'.ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#].ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'.ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'.ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#].ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#].ds ae a\h'-(\w'a'u*4/10)'e.ds Ae A\h'-(\w'A'u*4/10)'E. \" corrections for vroff.if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'.if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'. \" for low resolution devices (crt and lpr).if \n(.H>23 .if \n(.V>19 \\{\. ds : e. ds 8 ss. ds o a. ds d- d\h'-1'\(ga. ds D- D\h'-1'\(hy. ds th \o'bp'. ds Th \o'LP'. ds ae ae. ds Ae AE.\}.rm #[ #] #H #V #F C.\" ========================================================================.\".IX Title "BUSYBOX 1".TH BUSYBOX 1 "2002-10-26" "version 0.60.5" "BusyBox".UC.SH "NAME"BusyBox \- The Swiss Army Knife of Embedded Linux.SH "SYNTAX".IX Header "SYNTAX".Vb 1\& BusyBox <function> [arguments...] # or.Ve.Vb 1\& <function> [arguments...] # if symlinked.Ve.SH "DESCRIPTION".IX Header "DESCRIPTION"BusyBox combines tiny versions of many common \s-1UNIX\s0 utilities into a singlesmall executable. It provides minimalist replacements for most of the utilitiesyou usually find in fileutils, shellutils, findutils, textutils, grep, gzip,tar, etc. BusyBox provides a fairly complete \s-1POSIX\s0 environment for any smallor embedded system. The utilities in BusyBox generally have fewer options thantheir full-featured \s-1GNU\s0 cousins; however, the options that are included providethe expected functionality and behave very much like their \s-1GNU\s0 counterparts. .PPBusyBox has been written with size-optimization and limited resources in mind.It is also extremely modular so you can easily include or exclude commands (orfeatures) at compile time. This makes it easy to customize your embeddedsystems. To create a working system, just add a kernel, a shell (such as ash),and an editor (such as elvis-tiny or ae)..SH "USAGE".IX Header "USAGE"When you create a link to BusyBox for the function you wish to use, when BusyBoxis called using that link it will behave as if the command itself has been invoked..PPFor example, entering.PP.Vb 2\& ln -s ./BusyBox ls\& ./ls.Vewill cause BusyBox to behave as 'ls' (if the 'ls' command has been compiledinto BusyBox). .PPYou can also invoke BusyBox by issuing the command as an argument on thecommand line. For example, entering.PP.Vb 1\& ./BusyBox ls.Vewill also cause BusyBox to behave as 'ls'. .SH "COMMON OPTIONS".IX Header "COMMON OPTIONS"Most BusyBox commands support the \fB\-h\fR option to provide aterse runtime description of their behavior. .SH "COMMANDS".IX Header "COMMANDS"Currently defined functions include:.PPadjtimex, ar, basename, busybox, cat, chgrp, chmod, chown, chroot, chvt, clear,cmp, cp, cpio, cut, date, dc, dd, deallocvt, df, dirname, dmesg, dos2unix, dpkg,dpkg\-deb, du, dumpkmap, dutmp, echo, expr, false, fbset, fdflush, find, free,freeramdisk, fsck.minix, getopt, grep, gunzip, gzip, halt, head, hostid,hostname, id, ifconfig, init, insmod, kill, killall, klogd, length, ln,loadacm, loadfont, loadkmap, logger, logname, ls, lsmod, makedevs, md5sum,mkdir, mkfifo, mkfs.minix, mknod, mkswap, mktemp, more, mount, mt, mv, nc,nslookup, ping, pivot_root, poweroff, printf, ps, pwd, rdate, readlink, reboot,renice, reset, rm, rmdir, rmmod, route, rpm2cpio, sed, setkeycodes,sh, sleep, sort, stty, swapoff, swapon, sync, syslogd, tail, tar, tee, telnet,test, tftp, touch, tr, true, tty, umount, uname, uniq, unix2dos, update, uptime,usleep, uudecode, uuencode, watchdog, wc, wget, which, whoami, xargs, yes, zcat,[.IP "\fBadjtimex\fR" 4.IX Item "adjtimex"adjtimex [\fB\-q\fR] [\fB\-o\fR offset] [\fB\-f\fR frequency] [\fB\-p\fR timeconstant] [\fB\-t\fR tick].SpReads and optionally sets system timebase parameters.See \fIadjtimex\fR\|(2)..SpOptions:.Sp.Vb 6\& -q quiet mode - do not print\& -o offset time offset, microseconds\& -f frequency frequency adjust, integer kernel units (65536 is 1ppm)\& (positive values make the system clock run fast)\& -t tick microseconds per tick, usually 10000\& -p timeconstant.Ve\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-.IP "\fBar\fR" 4.IX Item "ar"ar \-[ov][ptx] \s-1ARCHIVE\s0 \s-1FILES\s0.SpExtract or list \s-1FILES\s0 from an ar archive..SpOptions:.Sp.Vb 5\& -o preserve original dates\& -p extract to stdout\& -t list\& -x extract\& -v verbosely list files processed.Ve\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-.IP "\fBbasename\fR" 4.IX Item "basename"basename \s-1FILE\s0 [\s-1SUFFIX\s0].SpStrips directory path and suffixes from \s-1FILE\s0.If specified, also removes any trailing \s-1SUFFIX\s0..SpExample:.Sp.Vb 6\& $ basename /usr/local/bin/foo\& foo\& $ basename /usr/local/bin/\& bin\& $ basename /foo/bar.txt .txt\& bar.Ve\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-.IP "\fBcat\fR" 4.IX Item "cat"cat [\s-1FILE\s0]....SpConcatenates \s-1FILE\s0(s) and prints them to stdout..SpExample:.Sp.Vb 2\& $ cat /proc/uptime\& 110716.72 17.67.Ve\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-.IP "\fBchgrp\fR" 4.IX Item "chgrp"chgrp [\s-1OPTION\s0]... \s-1GROUP\s0 \s-1FILE\s0....SpChange the group membership of each \s-1FILE\s0 to \s-1GROUP\s0..SpOptions:.Sp.Vb 1\& -R Changes files and directories recursively..VeExample:.Sp.Vb 5\& $ ls -l /tmp/foo\& -r--r--r-- 1 andersen andersen 0 Apr 12 18:25 /tmp/foo\& $ chgrp root /tmp/foo\& $ ls -l /tmp/foo\& -r--r--r-- 1 andersen root 0 Apr 12 18:25 /tmp/foo.Ve\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-.IP "\fBchmod\fR" 4.IX Item "chmod"chmod [\fB\-R\fR] MODE[,MODE]... \s-1FILE\s0....SpEach \s-1MODE\s0 is one or more of the letters ugoa, one of thesymbols +\-= and one or more of the letters rwxst..SpOptions:.Sp.Vb 1\& -R Changes files and directories recursively..VeExample:.Sp.Vb 8\& $ ls -l /tmp/foo\& -rw-rw-r-- 1 root root 0 Apr 12 18:25 /tmp/foo\& $ chmod u+x /tmp/foo\& $ ls -l /tmp/foo\& -rwxrw-r-- 1 root root 0 Apr 12 18:25 /tmp/foo*\& $ chmod 444 /tmp/foo\& $ ls -l /tmp/foo\& -r--r--r-- 1 root root 0 Apr 12 18:25 /tmp/foo.Ve\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-.IP "\fBchown\fR" 4.IX Item "chown"chown [ \fB\-Rh\fR ]... OWNER[<.|:>[\s-1GROUP\s0]] \s-1FILE\s0....SpChange the owner and/or group of each \s-1FILE\s0 to \s-1OWNER\s0 and/or \s-1GROUP\s0..SpOptions:.Sp.Vb 2\& -R Changes files and directories recursively.\& -h Do not dereference symbolic links..VeExample:.Sp.Vb 8\& $ ls -l /tmp/foo\& -r--r--r-- 1 andersen andersen 0 Apr 12 18:25 /tmp/foo\& $ chown root /tmp/foo\& $ ls -l /tmp/foo\& -r--r--r-- 1 root andersen 0 Apr 12 18:25 /tmp/foo\& $ chown root.root /tmp/foo\& ls -l /tmp/foo\& -r--r--r-- 1 root root 0 Apr 12 18:25 /tmp/foo.Ve\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-.IP "\fBchroot\fR" 4.IX Item "chroot"chroot \s-1NEWROOT\s0 [\s-1COMMAND\s0...].SpRun \s-1COMMAND\s0 with root directory set to \s-1NEWROOT\s0..SpExample:.Sp.Vb 6\& $ ls -l /bin/ls\& lrwxrwxrwx 1 root root 12 Apr 13 00:46 /bin/ls -> /BusyBox\& $ mount /dev/hdc1 /mnt -t minix\& $ chroot /mnt\& $ ls -l /bin/ls\& -rwxr-xr-x 1 root root 40816 Feb 5 07:45 /bin/ls*.Ve\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-.IP "\fBchvt\fR" 4.IX Item "chvt"chvt N.SpChanges the foreground virtual terminal to /dev/ttyN.Sp\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-.IP "\fBclear\fR" 4.IX Item "clear"clear .SpClear screen..Sp\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-.IP "\fBcmp\fR" 4.IX Item "cmp"cmp \s-1FILE1\s0 [\s-1FILE2\s0].Sp.Vb 2\& -s quiet mode - do not print\&Compare files..Ve\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-.IP "\fBcp\fR" 4.IX Item "cp"cp [\s-1OPTION\s0]... \s-1SOURCE\s0 \s-1DEST\s0.SpCopies \s-1SOURCE\s0 to \s-1DEST\s0, or multiple \s-1SOURCE\s0(s) to \s-1DIRECTORY\s0..Sp.Vb 5\& -a Same as -dpR\& -d Preserves links\& -p Preserves file attributes if possible\& -f force (implied; ignored) - always set\& -R Copies directories recursively.Ve\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-.IP "\fBcpio\fR" 4.IX Item "cpio"cpio \-[dimtuv][F cpiofile].SpExtract or list files from a cpio archiveMain operation mode:.Sp.Vb 5\& d make leading directories\& i extract\& m preserve mtime\& t list\& u unconditional overwrite F input from file.Ve\&\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-.IP "\fBcut\fR" 4.IX Item "cut"cut [\s-1OPTION\s0]... [\s-1FILE\s0]....SpPrints selected fields from each input \s-1FILE\s0 to standard output..SpOptions:.Sp.Vb 6\& -b LIST Output only bytes from LIST\& -c LIST Output only characters from LIST\& -d CHAR Use CHAR instead of tab as the field delimiter\& -s Output only the lines containing delimiter\& -f N Print only these fields\& -n Ignored.VeExample:.Sp.Vb 4\& $ echo "Hello world" | cut -f 1 -d ' '\& Hello\& $ echo "Hello world" | cut -f 2 -d ' '
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -