5 busybox - I am BusyBox of Borg. Unix will be assimilated.
9 busybox <function> [arguments...] # or
11 <function> [arguments...] # if symlinked
15 BusyBox is a multi-call binary that combines many common Unix utilities into a
16 single executable. Most people will create a link to busybox for each function
17 they wish to use, and BusyBox will act like whatever it was invoked as. For
23 will cause BusyBox to behave as 'ls' (if the 'ls' command has been compiled
24 into busybox). You can also invoke BusyBox by providing it the command to run
25 on the command line. For example,
29 will also cause BusyBox to behave as 'ls'.
31 BusyBox has been written with size-optimization in mind. It is very easy to
32 include or exclude the commands (or features) you want installed. BusyBox
33 tries to make itself useful to small systems with limited resources.
37 Currently defined functions include:
39 basename, cat, chgrp, chmod, chown, chroot, clear, chvt, cp, date, dd, df,
40 dirname, dmesg, du, dutmp, echo, false, fbset, fdflush, find, free,
41 freeramdisk, deallocvt, fsck.minix, grep, gunzip, gzip, halt, head, hostid,
42 hostname, init, kill, killall, length, ln, loadacm, loadfont, loadkmap, logger,
43 logname, ls, lsmod, makedevs, math, mkdir, mkfifo, mkfs.minix, mknod, mkswap,
44 mnc, more, mount, mt, mv, nslookup, ping, poweroff, printf, ps, pwd, reboot,
45 rm, rmdir, rmmod, sed, sh, sfdisk, sleep, sort, sync, syslogd, swapon, swapoff,
46 tail, tar, test, tee, touch, tr, true, tty, umount, uname, uniq, update,
47 uptime, usleep, wc, whoami, yes, zcat, [
51 Most BusyBox commands support the B<--help> option to provide a
52 terse runtime description of their behavior.
58 Usage: basename [file ...]
60 Strips directory and suffix from filenames.
64 $ basename /usr/local/bin/foo
66 $ basename /usr/local/bin/
69 -------------------------------
75 Concatenates files and prints them to the standard output.
82 -------------------------------
86 Usage: chgrp [OPTION]... GROUP FILE...
88 Change the group membership of each FILE to GROUP.
92 -R change files and directories recursively
97 -r--r--r-- 1 andersen andersen 0 Apr 12 18:25 /tmp/foo
100 -r--r--r-- 1 andersen root 0 Apr 12 18:25 /tmp/foo
102 -------------------------------
106 Usage: chmod [B<-R>] MODE[,MODE]... FILE...
108 Changes file access permissions for the specified file(s) or directory(s).
109 Each MODE is defined by combining the letters for WHO has access to the file,
110 an OPERATOR for selecting how the permissions should be changed, and a
111 PERISSION for the file(s) or directory(s).
113 WHO may be chosen from:
115 u the User who owns the file
116 g users in the file's Group
117 o Other users not in the file's group
120 OPERATOR may be chosen from:
123 - remove a permission
124 = assign a permission
126 PERMISSION may be chosen from:
130 x eXecute (or access for directories)
131 s Set user (or group) ID bit
132 t sTickey bit (for directories prevents removing files by non-owners)
134 Alternately, permissions may be set numerically where the first three
135 numbers are calculated by adding the octal values:
141 An optional fourth digit may also be used to specify
149 -R change files and directories recursively.
154 -rw-rw-r-- 1 root root 0 Apr 12 18:25 /tmp/foo
157 -rwxrw-r-- 1 root root 0 Apr 12 18:25 /tmp/foo*
160 -r--r--r-- 1 root root 0 Apr 12 18:25 /tmp/foo
162 -------------------------------
166 Usage: chown [OPTION]... OWNER[.[GROUP] FILE...
168 Changes the owner and/or group of each FILE to OWNER and/or GROUP.
172 -R change files and directories recursively
177 -r--r--r-- 1 andersen andersen 0 Apr 12 18:25 /tmp/foo
178 $ chown root /tmp/foo
180 -r--r--r-- 1 root andersen 0 Apr 12 18:25 /tmp/foo
181 $ chown root.root /tmp/foo
183 -r--r--r-- 1 root root 0 Apr 12 18:25 /tmp/foo
185 -------------------------------
189 Usage: chroot NEWROOT [COMMAND...]
191 Run COMMAND with root directory set to NEWROOT.
196 lrwxrwxrwx 1 root root 12 Apr 13 00:46 /bin/ls -> /busybox
197 $ mount /dev/hdc1 /mnt -t minix
200 -rwxr-xr-x 1 root root 40816 Feb 5 07:45 /bin/ls*
202 -------------------------------
208 -------------------------------
214 Change foreground virtual terminal to /dev/ttyN
216 -------------------------------
220 Usage: cp [OPTION]... SOURCE DEST
222 or: cp [OPTION]... SOURCE... DIRECTORY
224 Copy SOURCE to DEST, or multiple SOURCE(s) to DIRECTORY.
228 -p preserve file attributes if possable
229 -R copy directories recursively
231 -------------------------------
235 Usage: date [OPTION]... [+FORMAT]
237 or: date [OPTION] [MMDDhhmm[[CC]YY][.ss]]
239 Display the current time in the given FORMAT, or set the system date.
243 -R output RFC-822 compliant date string
244 -s set time described by STRING
245 -u print or set Coordinated Universal Time
250 Wed Apr 12 18:52:41 MDT 2000
252 -------------------------------
256 Usage: dd [if=name] [of=name] [bs=n] [count=n] [skip=n] [seek=n]
258 Copy a file, converting and formatting according to options
260 if=FILE read from FILE instead of stdin
261 of=FILE write to FILE instead of stdout
262 bs=n read and write n bytes at a time
263 count=n copy only n input blocks
264 skip=n skip n input blocks
265 seek=n skip n output blocks
267 Numbers may be suffixed by w (x2), k (x1024), b (x512), or M (x1024^2)
271 $ dd if=/dev/zero of=/dev/ram1 bs=1M count=4
275 -------------------------------
279 Usage: df [filesystem ...]
281 Prints the filesystem space used and space available.
286 Filesystem 1k-blocks Used Available Use% Mounted on
287 /dev/sda3 8690864 8553540 137324 98% /
288 /dev/sda1 64216 36364 27852 57% /boot
290 Filesystem 1k-blocks Used Available Use% Mounted on
291 /dev/sda3 8690864 8553540 137324 98% /
293 -------------------------------
299 Strip non-directory suffix from file name
308 -------------------------------
312 Usage: dmesg [B<-c>] [B<-n> level] [B<-s> bufsize]
314 Print or controls the kernel ring buffer.
316 -------------------------------
320 Usage: du [OPTION]... [FILE]...
322 Summarize disk space used for each FILE and/or directory.
323 Disk space is printed in units of 1k (i.e. 1024 bytes).
327 -l count sizes many times if hard linked
328 -s display only a total for each argument
334 12 ./kernel-patches/CVS
344 -------------------------------
350 Dump utmp file format (pipe delimited) from FILE
355 $ dutmp /var/run/utmp
356 8|7||si|||0|0|0|955637625|760097|0
357 2|0|~|~~|reboot||0|0|0|955637625|782235|0
358 1|20020|~|~~|runlevel||0|0|0|955637625|800089|0
359 8|125||l4|||0|0|0|955637629|998367|0
360 6|245|tty1|1|LOGIN||0|0|0|955637630|998974|0
361 6|246|tty2|2|LOGIN||0|0|0|955637630|999498|0
362 7|336|pts/0|vt00andersen|andersen|:0.0|0|0|0|955637763|0|0
364 -------------------------------
368 Usage: echo [-neE] [ARG ...]
370 Prints the specified ARGs to stdout
374 -n suppress trailing newline
375 -e interpret backslash-escaped characters (i.e. \t=tab etc)
376 -E disable interpretation of backslash-escaped characters
380 $ echo "Erik is cool"
382 $ echo -e "Erik\nis\ncool"
386 $ echo "Erik\nis\ncool"
389 -------------------------------
393 Returns an exit code of FALSE (1)
401 -------------------------------
405 Usage: fbset [options] [mode]
407 Show and modify frame buffer device settings
428 # D: 78.653 MHz, H: 59.949 kHz, V: 75.694 Hz
429 geometry 1024 768 1024 768 16
430 timings 12714 128 32 16 4 128 4
432 rgba 5/11,6/5,5/0,0/0
435 -------------------------------
439 Usage: fdflush device
441 Force floppy disk drive to detect disk change
443 -------------------------------
447 Usage: find [PATH...] [EXPRESSION]
449 Search for files in a directory hierarchy. The default PATH is
450 the current directory; default EXPRESSION is '-print'
453 EXPRESSION may consist of:
455 -follow Dereference symbolic links.
456 -name PATTERN File name (leading directories removed) matches PATTERN.
457 -print print the full file name followed by a newline to stdout.
461 $ find / -name /etc/passwd
464 -------------------------------
470 Displays the amount of free and used memory in the system.
475 total used free shared buffers
476 Mem: 257628 248724 8904 59644 93124
477 Swap: 128516 8404 120112
478 Total: 386144 257128 129016
480 -------------------------------
484 Usage: freeramdisk DEVICE
486 Free all memory used by the specified ramdisk.
490 $ freeramdisk /dev/ram2
492 -------------------------------
498 Deallocates unused virtual terminal /dev/ttyN
500 -------------------------------
504 Usage: fsck.minix [B<-larvsmf>] /dev/name
506 Performs a consistency check for MINIX filesystems.
510 -l Lists all filenames
511 -r Perform interactive repairs
512 -a Perform automatic repairs
514 -s Outputs super-block information
515 -m Activates MINIX-like "mode not cleared" warnings
516 -f Force file system check.
518 -------------------------------
522 Usage: grep [OPTIONS]... PATTERN [FILE]...
524 Search for PATTERN in each FILE or standard input.
528 -h suppress the prefixing filename on output
529 -i ignore case distinctions
530 -n print line number with output lines
531 -q be quiet. Returns 0 if result was found, 1 otherwise
533 This version of grep matches full regular expresions.
537 $ grep root /etc/passwd
538 root:x:0:0:root:/root:/bin/bash
539 $ grep ^[rR]oo. /etc/passwd
540 root:x:0:0:root:/root:/bin/bash
542 -------------------------------
546 Usage: gunzip [OPTION]... FILE
548 Uncompress FILE (or standard input if FILE is '-').
552 -c Write output to standard output
553 -t Test compressed file integrity
557 $ ls -la /tmp/busybox*
558 -rw-rw-r-- 1 andersen andersen 557009 Apr 11 10:55 /tmp/busybox-0.43.tar.gz
559 $ gunzip /tmp/busybox-0.43.tar.gz
560 $ ls -la /tmp/busybox*
561 -rw-rw-r-- 1 andersen andersen 1761280 Apr 14 17:47 /tmp/busybox-0.43.tar
563 -------------------------------
567 Usage: gzip [OPTION]... FILE
569 Compress FILE with maximum compression.
570 When FILE is '-', reads standard input. Implies B<-c>.
574 -c Write output to standard output instead of FILE.gz
578 $ ls -la /tmp/busybox*
579 -rw-rw-r-- 1 andersen andersen 1761280 Apr 14 17:47 /tmp/busybox-0.43.tar
580 $ gzip /tmp/busybox-0.43.tar
581 $ ls -la /tmp/busybox*
582 -rw-rw-r-- 1 andersen andersen 554058 Apr 14 17:49 /tmp/busybox-0.43.tar.gz
585 -------------------------------
591 This comand halts the system.
593 -------------------------------
597 Usage: head [OPTION] [FILE]...
599 Print first 10 lines of each FILE to standard output.
600 With more than one FILE, precede each with a header giving the
601 file name. With no FILE, or when FILE is -, read standard input.
605 -n NUM Print first NUM lines instead of first 10
609 $ head -n 2 /etc/passwd
610 root:x:0:0:root:/root:/bin/bash
611 daemon:x:1:1:daemon:/usr/sbin:/bin/sh
613 -------------------------------
619 Prints out a unique 32-bit identifier for the current
620 machine. The 32-bit identifier is intended to be unique
621 among all UNIX systems in existence.
623 -------------------------------
627 Usage: hostname [OPTION] {hostname | B<-F> file}
629 Get or set the hostname or DNS domain name. If a hostname is given
630 (or a file with the B<-F> parameter), the host name will be set.
635 -i Addresses for the hostname
637 -F FILE Use the contents of FILE to specify the hostname
644 -------------------------------
650 Init is the parent of all processes.
652 This version of init is designed to be run only by the kernel.
654 BusyBox init doesn't support multiple runlevels. The runlevels field of
655 the /etc/inittab file is completely ignored by BusyBox init. If you want
656 runlevels, use sysvinit.
658 BusyBox init works just fine without an inittab. If no inittab is found,
659 it has the following default behavior:
661 ::sysinit:/etc/init.d/rcS
664 if it detects that /dev/console is _not_ a serial console, it will also run:
666 tty2::askfirst:/bin/sh
668 If you choose to use an /etc/inittab file, the inittab entry format is as follows:
670 <id>:<runlevels>:<action>:<process>
674 WARNING: This field has a non-traditional meaning for BusyBox init!
675 The id field is used by BusyBox init to specify the controlling tty for
676 the specified process to run on. The contents of this field are
677 appended to "/dev/" and used as-is. There is no need for this field to
678 be unique, although if it isn't you may have strange results. If this
679 field is left blank, it is completely ignored. Also note that if
680 BusyBox detects that a serial console is in use, then all entries
681 containing non-empty id fields will _not_ be run. BusyBox init does
682 nothing with utmp. We don't need no stinkin' utmp.
686 The runlevels field is completely ignored.
690 Valid actions include: sysinit, respawn, askfirst, wait,
691 once, and ctrlaltdel.
693 askfirst acts just like respawn, but before running the specified
694 process it displays the line "Please press Enter to activate this
695 console." and then waits for the user to press enter before starting
696 the specified process.
698 Unrecognised actions (like initdefault) will cause init to emit
699 an error message, and then go along with its business.
703 Specifies the process to be executed and it's command line.
706 Example /etc/inittab file:
708 # This is run first except when booting in single-user mode.
710 ::sysinit:/etc/init.d/rcS
712 # /bin/sh invocations on selected ttys
714 # Start an "askfirst" shell on the console (whatever that may be)
716 # Start an "askfirst" shell on /dev/tty2
717 tty2::askfirst:/bin/sh
719 # /sbin/getty invocations for selected ttys
721 tty4::respawn:/sbin/getty 38400 tty4
722 tty5::respawn:/sbin/getty 38400 tty5
725 # Example of how to put a getty on a serial line (for a terminal)
727 #ttyS0::respawn:/sbin/getty -L ttyS0 9600 vt100
728 #ttyS1::respawn:/sbin/getty -L ttyS1 9600 vt100
730 # Example how to put a getty on a modem line.
731 #ttyS2::respawn:/sbin/getty -x0 -s 57600 ttyS2
733 # Stuff to do before rebooting
734 ::ctrlaltdel:/bin/umount -a -r > /dev/null 2>&1
735 ::ctrlaltdel:/sbin/swapoff -a > /dev/null 2>&1
737 -------------------------------
741 Usage: kill [B<-signal>] process-id [process-id ...]
743 Send a signal (default is SIGTERM) to the specified process(es).
747 -l List all signal names and numbers.
752 252 root root S [apache]
753 263 www-data www-data S [apache]
754 264 www-data www-data S [apache]
755 265 www-data www-data S [apache]
756 266 www-data www-data S [apache]
757 267 www-data www-data S [apache]
760 -------------------------------
764 Usage: killall [B<-signal>] process-name [process-name ...]
766 Send a signal (default is SIGTERM) to the specified process(es).
770 -l List all signal names and numbers.
776 -------------------------------
782 Prints out the length of the specified string.
788 -------------------------------
792 Usage: ln [OPTION] TARGET... LINK_NAME|DIRECTORY
793 Create a link named LINK_NAME or DIRECTORY to the specified TARGET
797 -s make symbolic links instead of hard links
798 -f remove existing destination files
802 $ ln -s busybox /tmp/ls
803 [andersen@debian busybox]$ ls -l /tmp/ls
804 lrwxrwxrwx 1 root root 7 Apr 12 18:39 ls -> busybox*
806 -------------------------------
810 FIXME -- this command does not yet have proper documentation
812 -------------------------------
818 Loads a console font from standard input.
821 -------------------------------
825 FIXME -- this command does not yet have proper documentation
827 -------------------------------
831 Usage: logger [OPTION]... [MESSAGE]
833 Write MESSAGE to the system log. If MESSAGE is '-', log stdin.
837 -s Log to stderr as well as the system log.
838 -t Log using the specified tag (defaults to user name).
839 -p Enter the message with the specified priority.
840 This may be numerical or a ``facility.level'' pair.
846 -------------------------------
852 Print the name of the current user.
859 -------------------------------
863 Usage: ls [B<-1acdelnpuxACF>] [filenames...]
867 -a do not hide entries starting with .
868 -c with -l: show ctime (the time of last
869 modification of file status information)
870 -d list directory entries instead of contents
871 -e list both full date and full time
872 -l use a long listing format
873 -n list numeric UIDs and GIDs instead of names
874 -p append indicator (one of /=@|) to entries
875 -u with -l: show access time (the time of last
877 -x list entries by lines instead of by columns
878 -A do not list implied . and ..
879 -C list entries by columns
880 -F append indicator (one of */=@|) to entries
882 -------------------------------
888 Shows a list of all currently loaded kernel modules.
890 -------------------------------
894 Usage: makedevs NAME TYPE MAJOR MINOR FIRST LAST [s]
896 Creates a range of block or character special files
900 b: Make a block (buffered) device.
901 c or u: Make a character (un-buffered) device.
902 p: Make a named pipe. MAJOR and MINOR are ignored for named pipes.
904 FIRST specifies the number appended to NAME to create the first device.
905 LAST specifies the number of the last item that should be created.
906 If 's' is the last argument, the base device is created as well.
910 $ makedevs /dev/ttyS c 4 66 2 63
911 [creates ttyS2-ttyS63]
912 $ makedevs /dev/hda b 3 0 0 8 s
913 [creates hda,hda1-hda8]
915 -------------------------------
919 Usage: math expression ...
921 This is a Tiny RPN calculator that understands the
922 following operations: +, -, /, *, and, or, not, eor.
928 $ math 8 8 \* 2 2 + /
935 -------------------------------
939 Usage: mkdir [OPTION] DIRECTORY...
941 Create the DIRECTORY(ies), if they do not already exist
945 -m set permission mode (as in chmod), not rwxrwxrwx - umask
946 -p no error if dir exists, make parent directories as needed
952 /tmp/foo: File exists
953 $ mkdir /tmp/foo/bar/baz
954 /tmp/foo/bar/baz: No such file or directory
955 $ mkdir -p /tmp/foo/bar/baz
957 -------------------------------
961 Usage: mkfifo [OPTIONS] name
963 Creates a named pipe (identical to 'mknod name p')
967 -m create the pipe using the specified mode (default a=rw)
969 -------------------------------
973 Usage: mkfs.minix [B<-c> | B<-l> filename] [B<-nXX>] [B<-iXX>] /dev/name [blocks]
975 Make a MINIX filesystem.
979 -c Check the device for bad blocks
980 -n [14|30] Specify the maximum length of filenames
981 -i Specify the number of inodes for the filesystem
982 -l FILENAME Read the bad blocks list from FILENAME
983 -v Make a Minix version 2 filesystem
985 -------------------------------
989 Usage: mknod [OPTIONS] NAME TYPE MAJOR MINOR
991 Create a special file (block, character, or pipe).
995 -m create the special file using the specified mode (default a=rw)
998 b: Make a block (buffered) device.
999 c or u: Make a character (un-buffered) device.
1000 p: Make a named pipe. MAJOR and MINOR are ignored for named pipes.
1004 $ mknod /dev/fd0 b 2 0
1005 $ mknod -m 644 /tmp/pipe p
1007 -------------------------------
1011 Usage: mkswap [B<-c>] [B<-v0>|B<-v1>] device [block-count]
1013 Prepare a disk partition to be used as a swap partition.
1017 -c Check for read-ability.
1018 -v0 Make version 0 swap [max 128 Megs].
1019 -v1 Make version 1 swap [big!] (default for kernels > 2.1.117).
1020 block-count Number of block to use (default is entire partition).
1022 -------------------------------
1026 Usage: mnc [IP] [port]
1028 mini-netcat opens a pipe to IP:port
1032 $ mnc foobar.somedomain.com 25
1033 220 foobar ESMTP Exim 3.12 #1 Sat, 15 Apr 2000 00:03:02 -0600
1035 214-Commands supported:
1036 214- HELO EHLO MAIL RCPT DATA AUTH
1037 214 NOOP QUIT RSET HELP
1039 221 foobar closing connection
1041 -------------------------------
1045 Usage: more [file ...]
1047 More is a filter for paging through text one screenful at a time.
1053 -------------------------------
1057 Usage: mount [flags]
1058 mount [flags] device directory [B<-o> options,more-options]
1062 -a: Mount all file systems in fstab.
1063 -o option: One of many filesystem options, listed below.
1064 -r: Mount the filesystem read-only.
1065 -t filesystem-type: Specify the filesystem type.
1066 -w: Mount for reading and writing (default).
1068 Options for use with the "B<-o>" flag:
1070 async / sync: Writes are asynchronous / synchronous.
1071 dev / nodev: Allow use of special device files / disallow them.
1072 exec / noexec: Allow use of executable files / disallow them.
1073 loop: Mounts a file via loop device.
1074 suid / nosuid: Allow set-user-id-root programs / disallow them.
1075 remount: Re-mount a currently-mounted filesystem, changing its flags.
1076 ro / rw: Mount for read-only / read-write.
1077 There are EVEN MORE flags that are specific to each filesystem.
1078 You'll have to see the written documentation for those.
1083 /dev/hda3 on / type minix (rw)
1084 proc on /proc type proc (rw)
1085 devpts on /dev/pts type devpts (rw)
1086 $ mount /dev/fd0 /mnt -t msdos -o ro
1087 $ mount /tmp/diskimage /opt -t ext2 -o loop
1089 -------------------------------
1093 Usage: mt [B<-f> device] opcode value
1095 Control magnetic tape drive operation
1097 -------------------------------
1101 Usage: mv SOURCE DEST
1103 or: mv SOURCE... DIRECTORY
1105 Rename SOURCE to DEST, or move SOURCE(s) to DIRECTORY.
1109 $ mv /tmp/foo /bin/bar
1111 -------------------------------
1115 Usage: nslookup [HOST]
1117 Queries the nameserver for the IP address of the given HOST
1121 $ nslookup localhost
1128 -------------------------------
1132 Usage: ping [OPTION]... host
1134 Send ICMP ECHO_REQUEST packets to network hosts.
1138 -c COUNT Send only COUNT pings.
1139 -q Quiet mode, only displays output at start
1144 PING slag (127.0.0.1): 56 data bytes
1145 64 bytes from 127.0.0.1: icmp_seq=0 ttl=255 time=20.1 ms
1147 --- debian ping statistics ---
1148 1 packets transmitted, 1 packets received, 0% packet loss
1149 round-trip min/avg/max = 20.1/20.1/20.1 ms
1151 -------------------------------
1155 Shuts down the system, and requests that the kernel turn off power upon halting.
1157 -------------------------------
1161 Usage: printf format [argument...]
1163 Formats and prints the given data in a manner similar to the C printf command.
1167 $ printf "Val=%d\n" 5
1170 -------------------------------
1176 Report process status
1178 This version of ps accepts no options.
1183 PID Uid Gid State Command
1185 2 root root S [kflushd]
1186 3 root root S [kupdate]
1187 4 root root S [kpiod]
1188 5 root root S [kswapd]
1189 742 andersen andersen S [bash]
1190 743 andersen andersen S -bash
1191 745 root root S [getty]
1192 2990 andersen andersen R ps
1194 -------------------------------
1198 Prints the full filename of the current working directory.
1205 -------------------------------
1209 Instructs the kernel to reboot the system.
1211 -------------------------------
1215 Usage: rm [OPTION]... FILE...
1217 Remove (unlink) the FILE(s).
1221 -f remove existing destinations, never prompt
1222 -r or -R remove the contents of directories recursively
1228 -------------------------------
1232 Usage: rmdir [OPTION]... DIRECTORY...
1234 Remove the DIRECTORY(ies), if they are empty.
1240 -------------------------------
1244 Usage: rmmod [OPTION]... [MODULE]...
1246 Unloads the specified kernel modules from the kernel.
1250 -a Try to remove all unused kernel modules.
1256 -------------------------------
1260 Usage: sed [B<-n>] B<-e> script [file...]
1262 Allowed sed scripts come in the following form:
1266 where address ADDR can be:
1267 NUMBER Match specified line number
1269 /REGEXP/ Match specified regexp
1270 (! inverts the meaning of the match)
1273 s/regexp/replacement/[igp]
1274 which attempt to match regexp against the pattern space
1275 and if successful replaces the matched portion with replacement.
1278 which appends TEXT after the pattern space
1282 -e add the script to the commands to be executed
1283 -n suppress automatic printing of pattern space
1285 This version of sed matches full regular expresions.
1289 $ echo "foo" | sed -e 's/f[a-zA-Z]o/bar/g'
1292 -------------------------------
1298 lash -- the BusyBox LAme SHell (command interpreter)
1300 FIXME -- this command does not yet have proper documentation
1302 -------------------------------
1306 Usage: sfdisk [options] device ...
1308 device: something like /dev/hda or /dev/sda
1312 -s [or --show-size]: list size of a partition
1313 -c [or --id]: print or change partition Id
1314 -l [or --list]: list partitions of each device
1315 -d [or --dump]: idem, but in a format suitable for later input
1316 -i [or --increment]: number cylinders etc. from 1 instead of from 0
1317 -uS, -uB, -uC, -uM: accept/report in units of sectors/blocks/cylinders/MB
1318 -T [or --list-types]:list the known partition types
1319 -D [or --DOS]: for DOS-compatibility: waste a little space
1320 -R [or --re-read]: make kernel reread partition table
1321 -N# : change only the partition with number #
1322 -n : do not actually write to disk
1323 -O file : save the sectors that will be overwritten to file
1324 -I file : restore these sectors again
1325 -v [or --version]: print version
1326 -? [or --help]: print this message
1330 -g [or --show-geometry]: print the kernel's idea of the geometry
1331 -x [or --show-extended]: also list extended partitions on output
1333 or expect descriptors for them on input
1334 -L [or --Linux]: do not complain about things irrelevant for Linux
1335 -q [or --quiet]: suppress warning messages
1336 You can override the detected geometry using:
1337 -C# [or --cylinders #]:set the number of cylinders to use
1338 -H# [or --heads #]: set the number of heads to use
1339 -S# [or --sectors #]: set the number of sectors to use
1341 You can disable all consistency checking with:
1343 -f [or --force]: do what I say, even if it is stupid
1345 -------------------------------
1351 Pause for N seconds.
1356 [2 second delay results]
1358 -------------------------------
1362 Usage: sort [B<-n>] [B<-r>] [FILE]...
1364 Sorts lines of text in the specified files
1368 $ echo -e "e\nf\nb\nd\nc\na" | sort
1376 -------------------------------
1382 Write all buffered filesystem blocks to disk.
1384 -------------------------------
1388 Usage: syslogd [OPTION]...
1390 Linux system and kernel (provides klogd) logging utility.
1391 Note that this version of syslogd/klogd ignores /etc/syslog.conf.
1395 -m Change the mark timestamp interval. default=20min. 0=off
1396 -n Do not fork into the background (for when run by init)
1397 -K Do not start up the klogd process (by default syslogd spawns klogd).
1398 -O Specify an alternate log file. default=/var/log/messages
1400 -------------------------------
1404 Usage: swapon [OPTION] [device]
1406 Start swapping virtual memory pages on the given device.
1410 -a Start swapping on all swap devices
1412 -------------------------------
1416 Usage: swapoff [OPTION] [device]
1418 Stop swapping virtual memory pages on the given device.
1422 -a Stop swapping on all swap devices
1424 -------------------------------
1428 Usage: tail [OPTION] [FILE]...
1430 Print last 10 lines of each FILE to standard output.
1431 With more than one FILE, precede each with a header giving the
1432 file name. With no FILE, or when FILE is -, read standard input.
1436 -n NUM Print last NUM lines instead of first 10
1437 -f Output data as the file grows. This version
1438 of 'tail -f' supports only one file at a time.
1442 $ tail -n 1 /etc/resolv.conf
1445 -------------------------------
1449 Usage: tar -[cxtvO] [B<--exclude> File] [B<-f> tarFile] [FILE] ...
1451 Create, extract, or list files from a tar file. Note that
1452 this version of tar treats hard links as separate files.
1454 Main operation mode:
1462 f name of tarfile or "-" for stdin
1464 --exclude file to exclude
1468 v verbosely list files processed
1472 $ zcat /tmp/tarball.tar.gz | tar -xf -
1473 $ tar -cf /tmp/tarball.tar /usr/local
1475 -------------------------------
1479 Usage: test EXPRESSION
1482 Checks file types and compares values returning an exit
1483 code determined by the value of EXPRESSION.
1500 -------------------------------
1504 Usage: tee [OPTION]... [FILE]...
1506 Copy standard input to each FILE, and also to standard output.
1510 -a append to the given FILEs, do not overwrite
1514 $ echo "Hello" | tee /tmp/foo
1518 -------------------------------
1522 Usage: touch [B<-c>] file [file ...]
1524 Update the last-modified date on (or create) the selected file[s].
1529 /bin/ls: /tmp/foo: No such file or directory
1532 -rw-rw-r-- 1 andersen andersen 0 Apr 15 01:11 /tmp/foo
1534 -------------------------------
1538 Usage: tr [B<-cdsu>] string1 [string2]
1540 Translate, squeeze, and/or delete characters from standard
1541 input, writing to standard output.
1545 $ echo "gdkkn vnqkc" | tr [a-y] [b-z]
1548 -------------------------------
1552 Returns an exit code of TRUE (0)
1560 -------------------------------
1566 Print the file name of the terminal connected to standard input.
1570 -s print nothing, only return an exit status
1577 -------------------------------
1581 Usage: umount [flags] filesystem|directory
1585 -a: Unmount all file systems
1586 -r: Try to remount devices as read-only if mount is busy
1587 -f: Do not free loop device (if a loop device has been used)
1593 -------------------------------
1597 Usage: uname [OPTION]...
1599 Print certain system information. With no OPTION, same as B<-s>.
1603 -a print all information
1604 -m the machine (hardware) type
1605 -n print the machine's network node hostname
1606 -r print the operating system release
1607 -s print the operating system name
1608 -p print the host processor type
1609 -v print the operating system version
1614 Linux debian 2.2.15pre13 #5 Tue Mar 14 16:03:50 MST 2000 i686 unknown
1616 -------------------------------
1620 Usage: uniq [OPTION]... [INPUT [OUTPUT]]
1622 Discard all but one of successive identical lines from INPUT
1623 (or standard input), writing to OUTPUT (or standard output).
1627 $ echo -e "a\na\nb\nc\nc\na" | sort | uniq
1632 -------------------------------
1636 Usage: update [options]
1638 Periodically flushes filesystem buffers.
1642 -S force use of sync(2) instead of flushing
1643 -s SECS call sync this often (default 30)
1644 -f SECS flush some buffers this often (default 5)
1646 -------------------------------
1652 Tells how long the system has been running since boot.
1657 1:55pm up 2:30, load average: 0.09, 0.04, 0.00
1659 -------------------------------
1665 Pauses for N microseconds.
1670 [pauses for 1 second]
1672 -------------------------------
1676 Usage: wc [OPTION]... [FILE]...
1678 Print line, word, and byte counts for each FILE, and a total line if
1679 more than one FILE is specified. With no FILE, read standard input.
1683 -c print the byte counts
1684 -l print the newline counts
1685 -L print the length of the longest line
1686 -w print the word counts
1691 31 46 1365 /etc/passwd
1693 -------------------------------
1699 Prints the user name associated with the current effective user id.
1706 -------------------------------
1710 Usage: yes [OPTION]... [STRING]...
1712 Repeatedly outputs a line with all specified STRING(s), or `y'.
1714 -------------------------------
1718 This is essentially an alias for invoking "gunzip B<-c>", where
1719 it decompresses the file inquestion and send the output to stdout.
1721 -------------------------------
1727 textutils(1), shellutils(1), etc...
1731 Erik Andersen <erik@lineo.com>
1735 The following people have contributed code to BusyBox whether
1736 they know it or not.
1738 Erik Andersen <erik@lineo.com>
1742 John Beppu <beppu@lineo.com>
1746 Brian Candler <B.Candler@pobox.com>
1750 Randolph Chung <tausq@debian.org>
1754 Dave Cinege <dcinege@psychosis.com>
1758 Karl M. Hegbloom <karlheg@debian.org>
1762 John Lombardo <john@deltanet.com>
1766 Bruce Perens <bruce@perens.com>
1770 Linus Torvalds <torvalds@transmeta.com>
1774 Charles P. Wright <cpwright@villagenet.com>
1778 Enrique Zanardi <ezanardi@ull.es>
1784 # $Id: busybox.pod,v 1.16 2000/04/18 00:00:52 erik Exp $