openmptcprouter icon indicating copy to clipboard operation
openmptcprouter copied to clipboard

jffs2reset command does not reset the system back to vanilla install

Open sigkill opened this issue 4 years ago • 1 comments

Ran into a strange issue tonight with regards to how to reset openmptcprouter back to vanilla install on a Raspberry Pi 3B.

Following a guide for Openwrt, I was attempting to reset the OS back to what it was at when installed, however, it appear the support for this may not be present as of yet. (Via ssh, using jffs2reset)

Following the guide here: https://openwrt.org/docs/guide-user/troubleshooting/failsafe_and_factory_reset

I realize I can take the sdcard out and reimage it, but I believe it would be ideal to have the firmware reset work via the ssh method too, as the pi was configured without a monitor when I ran into trouble.

It might be ideal to map a gpio switch to reset the pi too.

Anyhow, I hope this helps, I'll gather more info if needed.

Thanks!

sigkill avatar Dec 06 '20 05:12 sigkill

I just tried to do this with owrt and can confirm it did not reset the system so I think it's a problem with jffs2reset.

If you run with /dev/loop0 mounted it claims "/dev/loop0 is mounted as /overlay, only erasing files" but it will not erase .* "hidden" files (e.g. .ssh) . If you umount /overlay then it claims" /dev/loop0 is not mounted. /dev/loop0 will be erased on next mount" but it isn't erased next mount.

I am using an APU4 (so x86_64).

/dev/root on /rom type squashfs (ro,relatime)
/dev/loop0 on /overlay type f2fs (rw,lazytime,noatime,background_gc=on,no_heap,user_xattr,inline_xattr,inline_data,inline_dentry,flush_merge,extent_cache,mode=adaptive,active_logs=6)
overlayfs:/overlay on / type overlay (rw,noatime,lowerdir=/,upperdir=/overlay/upper,workdir=/overlay/work)

MagmaiKH avatar Dec 08 '20 19:12 MagmaiKH