0

I'm using busybox in an embedded device. The built-in busybox is rather limited. So I want try to replace busybox in place with new, more complete version. I find some info about replacing Busybox on device use serial communication and command line, this also requireds to a http server on LAN. The part of commands

route add -net 192.168.15.0/24 eth0
mount -t tmpfs -o size=2M,mode=0755 tmpfs /mnt
cd /mnt
wget http://192.168.15.10/busybox-armv5l
chmod +x busybox-armv5l

Two points isn't clear here: new busybox does not replace the existing version, instead it's added into another location as an additional busybox? Second, the new busybox is placed into tmpfs in RAM: so its not saved permanently in the partition, and deleted after a reboot? Am I correct?

0

Yes - this method is suitable for embedded devices with tight resources and/or no writable filesystems (readonly or no free space). Grabbing additional binaries (not just busybox) into RAM is pretty much the only way to go if no write permissions anywhere (and you don't want to risk bricking by flashing the firmware itself).

It's also a good way to test things out first. After all, this is in RAM only, so - reset power and everything should be back to normal.

Less useful if you want the modification to be permanent and independent of network situation.

this also requires to a http server on LAN

This is mostly convenience... netcat works too, or telnet even (with some encoding quirks). But as long as wget is available, a quick http grab is easier.

  • Also, how to run the built-in applets when such busybox placement in the tmpfs? With the full path? – minto Apr 6 at 19:01
  • yes, e.g. /mnt/busybox-armv5l date - or just start a shell with that busybox and see if the commands work ( busybox bbconfig | grep PREFER_APPLETS=y ) – frostschutz Apr 6 at 20:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.