The following scripts seems to allow to open a shell that has an editable "/", without modifying the actual rootfs of the phone AND the phone does reboot unmodified without any problem!
Apt (or rather dpkg) does not work just (yet ?) , because of its advanced filesystem usage, but I hope some tricks could be found for that. Anyway this is already useful to experiment modifying configuration files.
WARNING this is very experimental use at your OWN RISKS, I DO NOT TAKE ANY RESPONSABILITY in case of a problem.
#!/bin/sh
set -e
mkdir -p /tmp/upper /tmp/work /tmp/merged /tmp/merged/.old
exec unshare -m --propagation private /bin/sh -c '
mkdir -p /tmp/upper /tmp/work /tmp/merged /tmp/merged/.old
mount -t overlay overlay \
-o lowerdir=/,upperdir=/tmp/upper,workdir=/tmp/work \
/tmp/merged
mkdir -p /tmp/merged/.old
pivot_root /tmp/merged /tmp/merged/.old
mount -t proc proc /proc || true
mount -t sysfs sysfs /sys || true
mount -t tmpfs tmpfs /dev || true
cd /
exec bash
'