sm is actually not a binary, it is a shell script for java program which does not exist/work on 5.1-lollipop
# Script to start "sm" on the device, which has a very rudimentary
# shell.
#
base=/system
export CLASSPATH=$base/framework/sm.jar
exec app_process $base/bin com.android.commands.sm.Sm "$@"
to answer the headline
a completely another solution for rooted devices only:
you can mount ext4 disk image (or ext4 partition) with same permissions like /data
(mount script example)
/su/su.d/40sdextimg
start-up script with executable permissions
#!/system/bin/sh
until grep -qw /data/sdext2 /proc/mounts
do
mount -t ext4 -o loop,rw,nosuid,nodev,noatime /storage/31D1-1308/data.sdext2.img /data/sdext2
sleep 1
done &
then you can move apps and create symbolic links
(that's what Link2SD does)
mkdir /data/sdext2/com.textra-1
mv /data/app/com.textra-1/base.apk /data/sdext2/com.textra-1/
ln -s /data/sdext2/com.textra-1/base.apk /data/app/com.textra-1/base.apk
or bind mount whole folder
(assuming 2nd partition is mounted /data/sdext2)
mkdir /data/sdext2/media
chmod 0770 /data/sdext2/media
chown 1023.1023 /data/sdext2/media
chcon u:object_r:media_rw_data_file:s0 /data/sdext2/media
mv /data/media/. /data/sdext2/media
mount -o bind /data/sdext2/media /data/media
sm
) is deeply integrated with other parts of Android code. It's not a standalone command, so can't be used independently. That's explained in the accepted answer to linked question.