/*********************************************************************
* Author : lile
* Modified : 2019年12月28日星期六 10:56:13
* Email : [email protected]
* HomePage : lile777.blog.csdn.net
* CopyRight : 该文章版权由lile所有。
* 保留原文出处链接和本声明的前提下,可在非商业目的下任意传播和复制。
* 对于商业目的下对本文的任何行为需经作者同意。
*********************************************************************/
root@android:/ # busybox-smp swapon --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: swapon [-a] [-p PRI] [DEVICE]
Start swapping on DEVICE
-a Start swapping on all swap devices
-p PRI Set swap device priority
root@android:/ # busybox-smp switch_root --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: switch_root [-c /dev/console] NEW_ROOT NEW_INIT [ARGS]
Free initramfs and switch to another root fs:
chroot to NEW_ROOT, delete all in /, move NEW_ROOT to /,
execute NEW_INIT. PID must be 1. NEW_ROOT must be a mountpoint.
-c DEV Reopen stdio to DEV after switch
root@android:/ # busybox-smp sysctl --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: sysctl [OPTIONS] [VALUE]...
Configure kernel parameters at runtime
-n Don't print key names
-e Don't warn about unknown keys
-w Change sysctl setting
-p FILE Load sysctl settings from FILE (default /etc/sysctl.conf)
-a Display all values
-A Display all values in table form
root@android:/ # busybox-smp syslogd --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: syslogd [OPTIONS]
System logging utility
-n Run in foreground
-O FILE Log to FILE (default:/var/log/messages)
-l N Log only messages more urgent than prio N (1-8)
-S Smaller output
-s SIZE Max size (KB) before rotation (default:200KB, 0=off)
-b N N rotated logs to keep (default:1, max=99, 0=purge)
-R HOST[:PORT] Log to IP or hostname on PORT (default PORT=514/UDP)
-L Log locally and via network (default is network only if -R)
-D Drop duplicates
-C[size_kb] Log to shared mem buffer (use logread to read it)
-f FILE Use FILE as config (default:/etc/syslog.conf)
root@android:/ # busybox-smp tac --help
// http://codingstandards.iteye.com/blog/830800
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: tac [FILE]...
Concatenate FILEs and print them in reverse
root@android:/ # busybox-smp tcpsvd --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: tcpsvd [-hEv] [-c N] [-C N[:MSG]] [-b N] [-u USER] [-l NAME] IP PORT PROG
Create TCP socket, bind to IP:PORT and listen
for incoming connection. Run PROG for each connection.
IP IP to listen on, 0 = all
PORT Port to listen on
PROG ARGS Program to run
-l NAME Local hostname (else looks up local hostname in DNS)
-u USER[:GRP] Change to user/group after bind
-c N Handle up to N connections simultaneously
-b N Allow a backlog of approximately N TCP SYNs
-C N[:MSG] Allow only up to N connections from the same IP
New connections from this IP address are closed
immediately. MSG is written to the peer before close
-h Look up peer's hostname
-E Don't set up environment variables
-v Verbose
root@android:/ # busybox-smp tee --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: tee [-ai] [FILE]...
Copy stdin to each FILE, and also to stdout
-a Append to the given FILEs, don't overwrite
-i Ignore interrupt signals (SIGINT)
root@android:/ # busybox-smp telnetd --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: telnetd [OPTIONS]
Handle incoming telnet connections
-l LOGIN Exec LOGIN on connect
-f ISSUE_FILE Display ISSUE_FILE instead of /etc/issue
-K Close connection as soon as login exits
(normally wait until all programs close slave pty)
-p PORT Port to listen on
-b ADDR[:PORT] Address to bind to
-F Run in foreground
-i Inetd mode
-w SEC Inetd 'wait' mode, linger time SEC
-S Log to syslog (implied by -i or without -F and -w)
root@android:/ # busybox-smp tftpd --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: tftpd [-cr] [-u USER] [DIR]
Transfer a file on tftp client's request
tftpd should be used as an inetd service.
tftpd's line for inetd.conf:
69 dgram udp nowait root tftpd tftpd -l /files/to/serve
It also can be ran from udpsvd:
udpsvd -vE 0.0.0.0 69 tftpd /files/to/serve
-r Prohibit upload
-c Allow file creation via upload
-u Access files as USER
-l Log to syslog (inetd mode requires this)
root@android:/ # busybox-smp tr --help
// http://man.linuxde.net/tr
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: tr [-cds] STRING1 [STRING2]
Translate, squeeze, or delete characters from stdin, writing to stdout
-c Take complement of STRING1
-d Delete input characters coded STRING1
-s Squeeze multiple output characters of STRING2 into one character
root@android:/ # busybox-smp traceroute --help
// http://man.linuxde.net/traceroute
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: traceroute [-46FIldnrv] [-f 1ST_TTL] [-m MAXTTL] [-p PORT] [-q PROBES]
[-s SRC_IP] [-t TOS] [-w WAIT_SEC] [-g GATEWAY] [-i IFACE]
[-z PAUSE_MSEC] HOST [BYTES]
Trace the route to HOST
-4,-6 Force IP or IPv6 name resolution
-F Set the don't fragment bit
-I Use ICMP ECHO instead of UDP datagrams
-l Display the TTL value of the returned packet
-d Set SO_DEBUG options to socket
-n Print numeric addresses
-r Bypass routing tables, send directly to HOST
-v Verbose
-m Max time-to-live (max number of hops)
-p Base UDP port number used in probes
(default 33434)
-q Number of probes per TTL (default 3)
-s IP address to use as the source address
-t Type-of-service in probe packets (default 0)
-w Time in seconds to wait for a response (default 3)
-g Loose source route gateway (8 max)
root@android:/ # busybox-smp true --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: true
Return an exit code of TRUE (0)
root@android:/ # busybox-smp tty --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: tty
Print file name of stdin's terminal
-s Print nothing, only return exit status
root@android:/ # tty
/dev/pts/1
root@android:/ # busybox-smp ttysize --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: ttysize [w] [h]
Print dimension(s) of stdin's terminal, on error return 80x25
root@android:/ # busybox-smp tunctl --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: tunctl [-f device] ([-t name] | -d name) [-u owner] [-g group] [-b]
Create or delete tun interfaces
-f name tun device (/dev/net/tun)
-t name Create iface 'name'
-d name Delete iface 'name'
-u owner Set iface owner
-g group Set iface group
-b Brief output
root@android:/ # busybox-smp udhcpc --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: udhcpc [-fbnqvoCRB] [-i IFACE] [-r IP] [-s PROG] [-p PIDFILE]
[-V VENDOR] [-x OPT:VAL]... [-O OPT]...
-i,--interface IFACE Interface to use (default eth0)
-p,--pidfile FILE Create pidfile
-s,--script PROG Run PROG at DHCP events (default /usr/share/udhcpc/default.script)
-B,--broadcast Request broadcast replies
-t,--retries N Send up to N discover packets
-T,--timeout N Pause between packets (default 3 seconds)
-A,--tryagain N Wait N seconds after failure (default 20)
-f,--foreground Run in foreground
-b,--background Background if lease is not obtained
-n,--now Exit if lease is not obtained
-q,--quit Exit after obtaining lease
-R,--release Release IP on exit
-S,--syslog Log to syslog too
-a,--arping Use arping to validate offered address
-O,--request-option OPT Request option OPT from server (cumulative)
-o,--no-default-options Don't request any options (unless -O is given)
-r,--request IP Request this IP address
-x OPT:VAL Include option OPT in sent packets (cumulative)
Examples of string, numeric, and hex byte opts:
-x hostname:bbox - option 12
-x lease:3600 - option 51 (lease time)
-x 0x3d:0100BEEFC0FFEE - option 61 (client id)
-F,--fqdn NAME Ask server to update DNS mapping for NAME
-V,--vendorclass VENDOR Vendor identifier (default 'udhcp VERSION')
-C,--clientid-none Don't send MAC as client identifier
-v Verbose
Signals:
USR1 Renew lease
USR2 Release lease
root@android:/ # busybox-smp udpsvd --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: udpsvd [-hEv] [-c N] [-u USER] [-l NAME] IP PORT PROG
Create UDP socket, bind to IP:PORT and wait
for incoming packets. Run PROG for each packet,
redirecting all further packets with same peer ip:port to it.
IP IP to listen on, 0 = all
PORT Port to listen on
PROG ARGS Program to run
-l NAME Local hostname (else looks up local hostname in DNS)
-u USER[:GRP] Change to user/group after bind
-c N Handle up to N connections simultaneously
-h Look up peer's hostname
-E Don't set up environment variables
-v Verbose
root@android:/ # busybox-smp unexpand --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: unexpand [-fa][-t N] [FILE]...
Convert spaces to tabs, writing to stdout
-a,--all Convert all blanks
-f,--first-only Convert only leading blanks
-t,--tabs=N Tabstops every N chars
// http://man.linuxde.net/uniq
root@android:/ # busybox-smp uniq --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: uniq [-cdu][-f,s,w N] [INPUT [OUTPUT]]
Discard duplicate lines
-c Prefix lines by the number of occurrences
-d Only print duplicate lines
-u Only print unique lines
-f N Skip first N fields
-s N Skip first N chars (after any skipped fields)
-w N Compare N characters in line
root@android:/ # busybox-smp unix2dos --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: unix2dos [-ud] [FILE]
Convert FILE in-place from Unix to DOS format.
When no file is given, use stdin/stdout.
-u dos2unix
-d unix2dos
root@android:/ # busybox-smp uptime --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: uptime
Display the time since the last boot
root@android:/ # busybox-smp users --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: users
Print the users currently logged on
root@android:/ # busybox-smp uudecode --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: uudecode [-o OUTFILE] [INFILE]
Uudecode a file
Finds OUTFILE in uuencoded source unless -o is given
root@android:/ # busybox-smp uuencode --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: uuencode [-m] [FILE] STORED_FILENAME
Uuencode FILE (or stdin) to stdout
-m Use base64 encoding per RFC1521
root@android:/ # busybox-smp vconfig --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: vconfig COMMAND [OPTIONS]
Create and remove virtual ethernet devices
add IFACE VLAN_ID
rem VLAN_NAME
set_flag IFACE 0|1 VLAN_QOS
set_egress_map VLAN_NAME SKB_PRIO VLAN_QOS
set_ingress_map VLAN_NAME SKB_PRIO VLAN_QOS
set_name_type NAME_TYPE
root@android:/ # busybox-smp vlock --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: vlock [-a]
Lock a virtual terminal. A password is required to unlock.
-a Lock all VTs
root@android:/ # busybox-smp volname --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: volname [DEVICE]
Show CD volume name of the DEVICE (default /dev/cdrom)
root@android:/ # busybox-smp wall --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: wall [FILE]
Write content of FILE or stdin to all logged-in users
root@android:/ # busybox-smp watch --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: watch [-n SEC] [-t] PROG ARGS
Run PROG periodically
-n Loop period in seconds (default 2)
-t Don't print header
root@android:/ # busybox-smp watchdog --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: watchdog [-t N[ms]] [-T N[ms]] [-F] DEV
Periodically write to watchdog device DEV
-T N Reboot after N seconds if not reset (default 60)
-t N Reset every N seconds (default 30)
-F Run in foreground
Use 500ms to specify period in milliseconds
root@android:/ # busybox-smp wget --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: wget [-c|--continue] [-s|--spider] [-q|--quiet] [-O|--output-document FILE]
[--header 'header: value'] [-Y|--proxy on/off] [-P DIR]
[--no-check-certificate] [-U|--user-agent AGENT] [-T SEC] URL...
Retrieve files via HTTP or FTP
-s Spider mode - only check file existence
-c Continue retrieval of aborted transfer
-q Quiet
-P DIR Save to DIR (default .)
-T SEC Network read timeout is SEC seconds
-O FILE Save to FILE ('-' for stdout)
-U STR Use STR for User-Agent header
-Y Use proxy ('on' or 'off')
root@android:/ # busybox-smp which --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: which [COMMAND]...
Locate a COMMAND
root@android:/ # busybox-smp who --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: who [-a]
Show who is logged on
-a Show all
-H Print column headers
root@android:/ # busybox-smp whois --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: whois [-h SERVER] [-p PORT] NAME…
Query WHOIS info about NAME
-h,-p Server to query
root@android:/ # busybox-smp xargs --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: xargs [OPTIONS] [PROG ARGS]
Run PROG on every item given by stdin
-p Ask user whether to run each command
-r Don't run command if input is empty
-0 Input is separated by NUL characters
-t Print the command on stderr before execution
-e[STR] STR stops input processing
-n N Pass no more than N args to PROG
-s N Pass command line of no more than N bytes
-x Exit if size is exceeded
root@android:/ # busybox-smp xz --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: xz -d [-cf] [FILE]...
Decompress FILE (or stdin)
-d Decompress
-c Write to stdout
-f Force
root@android:/ # busybox-smp xzcat --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: xzcat FILE
Decompress to stdout
root@android:/ # busybox-smp yes --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: yes [STRING]
Repeatedly output a line with STRING, or 'y'
root@android:/ # busybox-smp zcat --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: zcat FILE
Decompress to stdout
root@android:/ # busybox-smp zcip --help
BusyBox v1.20.0 (2012-08-22 21:36:24 CDT) multi-call binary.
Usage: zcip [OPTIONS] IFACE SCRIPT
Manage a ZeroConf IPv4 link-local address
-f Run in foreground
-q Quit after obtaining address
-r 169.254.x.x Request this address first
-v Verbose
With no -q, runs continuously monitoring for ARP conflicts,
exits only on I/O errors (link down etc)
root@android:/ # ls -lh /system/bin/busybox-smp
-rwxr-xr-x 1 0 2000 1.0M Sep 5 2013 /system/bin/busybox-smp
整体过一遍下来,不得不感慨busybox这把瑞士军刀的厉害,在这么小的体积内蕴含了如此丰富的功能,这应该就是开源的力量吧!