Busybox replacement

From eLinux.org
Revision as of 20:08, 11 January 2012 by Tim Bird (Talk | contribs)

Jump to: navigation, search

This page has information about the commands and features desired for a busybox replacement program.

See Busybox replacement project for the project proposal for this work.

Command List

[Rob - can you massage this list?]

The first release of a busybox replacement should include the following commands: [insert candidate list here]

Toybox currently implements

The triaged toybox is currently implementing usable versions of:

 bzcat cat catv chroot chvt cksum count cp df dmesg echo false help
 mdev mkswap nc netcat nice oneit patch pwd rmdir seq setsid sh
 sha1sum sleep sort sync tee toysh true uname which yes

See http://landley.net/code/toybox/todo.txt

Toolbox commands

Toolbox in Android (what version?) implements the following commands:

date id uptime schedtop ifconfig start newfs_msdos
ls route netstat ioctl reboot getprop cmp insmod chmod
r cat lsmod chown log df top printenv ionice setprop rmmod setconsole
sleep watchprops notify wipe smd iftop rmdir dd vmstat hd rm mount
ln lsof getevent ps dmesg renice kill mkdir sendevent nandread mv
sync stop umount

The following are unique to Android:

  • schedtop
  • newfs_msdos
  • getprop
  • log
  • setprop
  • watchprops
  • notify
  • wipe
  • iftop
  • getevent
  • sendevent
  • nandread
  • stop
  • smd
  • setconsole

Ones I;m not sure about:

  • r?
  • ioctl?

Busybox commands

A default build of Busybox 1.10 has the following commands:

	[, [[, addgroup, adduser, adjtimex, ar, arp, arping, ash,
	awk, basename, bunzip2, bzcat, bzip2, cal, cat, catv,
	chattr, chgrp, chmod, chown, chpasswd, chpst, chroot,
	chrt, chvt, cksum, clear, cmp, comm, cp, cpio, crond,
	crontab, cryptpw, cut, date, dc, dd, deallocvt, delgroup,
	deluser, df, dhcprelay, diff, dirname, dmesg, dos2unix,
	du, dumpkmap, dumpleases, echo, ed, egrep, eject, env,
	envdir, envuidgid, expand, expr, false, fbset, fdflush,
	fdformat, fdisk, fgrep, find, fold, free, freeramdisk,
	fsck, fsck.minix, fuser, getopt, getty, grep, gunzip,
	gzip, halt, hdparm, head, hexdump, hostid, hostname, hwclock,
	id, ifconfig, ifdown, ifup, inetd, init, insmod, install,
	ip, ipaddr, ipcalc, ipcrm, ipcs, iplink, iproute, iprule,
	iptunnel, kbd_mode, kill, killall, killall5, klogd, last,
	length, less, linux32, linux64, linuxrc, ln, loadfont,
	loadkmap, logger, login, logname, logread, losetup, lpd,
	lpq, lpr, ls, lsattr, lsmod, lzmacat, makedevs, md5sum,
	mdev, mesg, microcom, mkdir, mkfifo, mkfs.minix, mknod,
	mkswap, mktemp, modprobe, more, mount, mountpoint, mt,
	mv, nameif, netstat, nice, nmeter, nohup, nslookup, od,
	openvt, passwd, patch, pgrep, pidof, ping, pipe_progress,
	pivot_root, pkill, poweroff, printenv, printf, ps, pscan,
	pwd, raidautorun, rdate, readlink, readprofile, realpath,
	reboot, renice, reset, resize, rm, rmdir, rmmod, route,
	rpm, rpm2cpio, run-parts, runlevel, runsv, runsvdir, rx,
	script, sed, sendmail, seq, setarch, setconsole, setkeycodes,
	setlogcons, setsid, setuidgid, sh, sha1sum, sleep, softlimit,
	sort, split, start-stop-daemon, stat, strings, stty, su,
	sulogin, sum, sv, svlogd, swapoff, swapon, switch_root,
	sync, sysctl, syslogd, tac, tail, tar, taskset, tee, telnetd,
	test, time, top, touch, tr, true, tty, ttysize, udhcpc,
	udhcpd, umount, uname, uncompress, unexpand, uniq, unix2dos,
	unlzma, unzip, uptime, usleep, uudecode, uuencode, vi,
	vlock, watch, watchdog, wc, wget, which, who, whoami,
	xargs, yes, zcat

Random Notes

Can implement incrementally

Rob wrote:

One nice thing about busybox/toybox/toolbox is you can install multiple implementations side by side, and have what symlinks you create (or what comes first in the $PATH) determine who is implementing what.

This allows gradual transitions. Each release, we replace a couple more commands from the old one, until the old one finally isn't being used for anything anymore and we can uninstall it...