Running LTP on musl based systems


LTP is freely available testsuite used for validating the reliability and stability of Linux systems. It has functionality, stress as well as regression tests. Thus far it has been mainly run on Linux systems running glibc for C library, and its natural that there will be areas in the project which would have assumptions on glibc coded in. We have ported LTP to run on MUSL based systems. The patches are still being upstreamed. A recent series is ported to LTP mailing list


LTP patches are currently residing on a branch ‘oe/master’ on git:// repository, There still are few more patches in addition to above patchset ported to mailing list.

Building and Running LTP


LTP depends on ftw library and we need to install external ftw on musl based systems

On OpenEmbedded based systems just add “libfts-dev” to IMAGE_INSTALL


git clone git:// -b oe/master
cd ltp
make autotools
./configure --without-numa --without-tirpc --with-power-management-testsuite --with-realtime-testsuite

make LIBC=musl -j8 all
make LIBC=musl install
rm /opt/ltp/testcases/bin/getdents01

getdents01 runs into infinite loop and fills the disk. This would install the ltp test suite under /opt/ltp


/opt/ltp/runltp -p -l "${hst}-$(date +%FT%T).log" -o "${hst}-$(date +%FT%T).out"


We can build and execute the testsuite on raspberryPI3, however the results dont look good. Many tests fail. Here are results of a run on raspberrypi3 running OpenEmbedded/Yocto