Difference between revisions of "BusyBox"

From ArchWiki
Jump to: navigation, search
m (gnu2busybox-diffutils: use pkg template.)
(improve install link as recommended in Help:Style#Package management instructions)
 
(13 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 
[[Category:System administration]]
 
[[Category:System administration]]
 +
{{Warning|Do not expect full drop-in replacement and compatibility. Certain utilities may not exist and for those that do, there may be missing options. One purpose of this Wiki is to document missing features and the problems they cause (in order to device work-arounds). Make sure that the replacement(s) that you install fill your needs before proceeding.}}
  
The [https://wiki.archlinux.org/index.php/DeveloperWiki:Core-Repository base]2[https://www.archlinux.org/packages/community/x86_64/busybox/ busybox] project aims to offer drop-in replacements for various central parts of the Arch linux base system.
+
{{Out of date|Last proper update was from 2011, so especially the "missing" sections should be checked}}
  
'''IMPORTANT: Do not expect 100% drop-in replacement and compatibility. Certain utilities may not exist and for those that do, there may be missing options. One purpose of this Wiki is to document missing features and the problems they cause (in order to device work-arounds). Make sure that the replacement(s) that you install fill your needs before proceeding.'''
+
== Installation ==
  
Busybox commands are simply symlinks to the busybox binary and are thus extremely light weight. For a low footprint system, this could be quite valuable.
+
[[Install]] {{Pkg|busybox}} from the [[official repositories]].
  
 +
Busybox commands are symbolic links to {{ic|/usr/bin/busybox}} and thus take very little space. This is especially interesting for low-footprint systems. Several packages in the [[AUR]] replace the GNU utilities with these symbolic links.
  
----
+
== init ==
  
==gnu2busybox-coreutils==
+
[https://github.com/hut/minirc Minirc] provides an init script compatible to busybox-init. See [[init]] for details.
  
Package {{AUR|gnu2busybox-coreutils}} offers a nearly pain-free drop-in replacement of the GNU coreutils. Some commands lack options present in the corresponding coreutils binaries.
+
== coreutils ==
  
Gain from replacing coreutils with busybox: GNU {{Pkg|coreutils}}: 13.1 MB installed, symlinks to busybox: approximately 0.
+
{{AUR|busybox-coreutils}}{{Broken package link|{{aur-mirror|busybox-coreutils}}}} is the busybox equivalent to GNU {{Pkg|coreutils}}. Some commands lack options present in the corresponding coreutils binaries.
  
'''Missing utilities:'''
+
Space gain: 13.1 MB installed (coreutils)
  
/bin
+
=== Missing functionality ===
    dircolors
+
  
/usr/bin
+
dircolors chcon csplit factor fmt join nl nproc paste pinky pr ptx runcon shuf stdbuf timeout truncate tsort users
    chcon csplit factor fmt join nl nproc paste pinky pr ptx runcon shuf
+
    stdbuf timeout truncate tsort users
+
  
'''Missing utilities that are mapped to corresponding Busybox functions or ash script files'''
+
=== Missing utilities mapped to corresponding Busybox functions or ash script files ===
  
/bin
+
dir --> ls
    dir --> ls
+
shred --> rm
    shred --> rm
+
vdir --> ls
    vdir --> ls
+
  
/usr/bin
+
link --> ln
    link --> ln
+
unlink --> rm
    unlink --> rm
+
sha224sum --> script: perl-digest-sha
    sha224sum --> script: perl-digest-sha
+
sha256sum --> script: perl-digest-sha
    sha256sum --> script: perl-digest-sha
+
sha384sum --> script: perl-digest-sha
    sha384sum --> script: perl-digest-sha
+
sha512sum --> script: perl-digest-sha
    sha512sum --> script: perl-digest-sha
+
  
'''Missing features that cause problems:'''
+
=== Missing features that cause problems ===
  
      readlink: missing option [-e, -m, -q or -s] causes problems for Yaourt
+
readlink: missing option [-e, -m, -q or -s]
   
+
----
+
  
==base2busybox-util-linux==
+
== util-linux ==
  
Package {{AUR|base2busybox-util-linux}} offers an alternative to util-linux.
+
{{AUR|busybox-util-linux}}{{Broken package link|{{aur-mirror|busybox-util-linux}}}} is the busybox equivalent to GNU {{Pkg|util-linux}}.
  
Gain from replacing util-linux with busybox: {{Pkg|util-linux}}: 7.5 MB installed, symlinks to busybox: approximately 0.
+
Space gain: 7.5 MB installed (util-linux)
  
'''Missing utilities:'''
+
=== Missing utilities ===
  
/bin
+
arch findmnt lsblk agetty blkid cfdisk ctrlaltdel findfs fsck.cramfs fsfreeze fstrim mkfs mkfs.bfs mkfs.cramfs raw sfdisk swaplabel wipefs
    arch findmnt lsblk
+
  
/sbin
+
chkdupexe col colcrt colrm column cytune ddate fallocate i386 ionice ipcmk isosize line look lscpu mcookie namei pg rename scriptreplay setterm tailf taskset ul unshare uuidgen whereis write x86_64
    agetty blkid cfdisk ctrlaltdel findfs fsck.cramfs fsfreeze fstrim mkfs
+
    mkfs.bfs mkfs.cramfs raw sfdisk swaplabel wipefs
+
  
/usr/bin
+
addpart delpart ldattach partx tunelp uuidd
  chkdupexe col colcrt colrm column cytune ddate fallocate i386 ionice ipcmk
+
  isosize line look lscpu mcookie namei pg rename scriptreplay setterm tailf
+
  taskset ul unshare uuidgen whereis write x86_64
+
  
/usr/sbin
+
== findutils ==
    addpart delpart ldattach partx tunelp uuidd
+
  
'''Missing features that cause problems:'''
+
{{AUR|busybox-findutils}}{{Broken package link|{{aur-mirror|busybox-findutils}}}} is the busybox equivalent to GNU {{Pkg|findutils}}.
  
==gnu2busybox-findutils==
+
=== Missing utilities ===
  
Package {{AUR|gnu2busybox-findutils}} offers functionality corresponding to the binaries found in GNU {{Pkg|findutils}}.
+
oldfind
  
Gain from replacing findutils with busybox: GNU findutils: 1.7 MB installed, symlinks to busybox: approximately 0.
+
== diffutils ==
  
'''Missing utilities:'''
+
{{AUR|busybox-diffutils}}{{Broken package link|{{aur-mirror|busybox-diffutils}}}} from the AUR offers functionality corresponding to the binaries found in GNU {{Pkg|diffutils}}.
  
/usr/bin
+
Space gain: 1.4 MB installed (diffutils)
    oldfind
+
  
'''Missing features that cause problems:'''
+
=== Missing utilities ===
  
----
+
diff3 sdiff
  
==gnu2busybox-diffutils==
+
== mdev ==
  
Package {{AUR|gnu2busybox-diffutils}} offers functionality corresponding to the binaries found in GNU {{Pkg|diffutils}}.
+
See [https://wiki.gentoo.org/wiki/Mdev Gentoo wiki].
 
+
Gain from replacing diffutils with busybox: GNU diffutils: 1.4 MB installed, symlinks to busybox: approximately 0.
+
 
+
'''Missing utilities:'''
+
 
+
/usr/bin
+
    diff3 sdiff
+
 
+
'''Missing features that cause problems:'''
+
 
+
==FUTURE PLANS==
+
 
+
* Busybox-init: a very simple (only 1 runlevel) init system, ash init scripts
+
* Meta-package and/or group to easily convert an Arch base system to a busybox base system.
+

Latest revision as of 21:17, 13 December 2015

Warning: Do not expect full drop-in replacement and compatibility. Certain utilities may not exist and for those that do, there may be missing options. One purpose of this Wiki is to document missing features and the problems they cause (in order to device work-arounds). Make sure that the replacement(s) that you install fill your needs before proceeding.

Tango-view-refresh-red.pngThis article or section is out of date.Tango-view-refresh-red.png

Reason: Last proper update was from 2011, so especially the "missing" sections should be checked (Discuss in Talk:BusyBox#)

Installation

Install busybox from the official repositories.

Busybox commands are symbolic links to /usr/bin/busybox and thus take very little space. This is especially interesting for low-footprint systems. Several packages in the AUR replace the GNU utilities with these symbolic links.

init

Minirc provides an init script compatible to busybox-init. See init for details.

coreutils

busybox-coreutilsAUR[broken link: archived in aur-mirror] is the busybox equivalent to GNU coreutils. Some commands lack options present in the corresponding coreutils binaries.

Space gain: 13.1 MB installed (coreutils)

Missing functionality

dircolors chcon csplit factor fmt join nl nproc paste pinky pr ptx runcon shuf stdbuf timeout truncate tsort users

Missing utilities mapped to corresponding Busybox functions or ash script files

dir --> ls
shred --> rm
vdir --> ls
link --> ln
unlink --> rm
sha224sum --> script: perl-digest-sha
sha256sum --> script: perl-digest-sha
sha384sum --> script: perl-digest-sha
sha512sum --> script: perl-digest-sha

Missing features that cause problems

readlink: missing option [-e, -m, -q or -s]

util-linux

busybox-util-linuxAUR[broken link: archived in aur-mirror] is the busybox equivalent to GNU util-linux.

Space gain: 7.5 MB installed (util-linux)

Missing utilities

arch findmnt lsblk agetty blkid cfdisk ctrlaltdel findfs fsck.cramfs fsfreeze fstrim mkfs mkfs.bfs mkfs.cramfs raw sfdisk swaplabel wipefs 
chkdupexe col colcrt colrm column cytune ddate fallocate i386 ionice ipcmk isosize line look lscpu mcookie namei pg rename scriptreplay setterm tailf taskset ul unshare uuidgen whereis write x86_64
addpart delpart ldattach partx tunelp uuidd

findutils

busybox-findutilsAUR[broken link: archived in aur-mirror] is the busybox equivalent to GNU findutils.

Missing utilities

oldfind

diffutils

busybox-diffutilsAUR[broken link: archived in aur-mirror] from the AUR offers functionality corresponding to the binaries found in GNU diffutils.

Space gain: 1.4 MB installed (diffutils)

Missing utilities

diff3 sdiff

mdev

See Gentoo wiki.