Installing on ASUS RT-AC58U via SSH while in recovery mode

Hi all,

@chunkeey: regarding your post bellow:

I just got myself a AC58U router and a TTL USB 3v3 serial adapter is on its way.

I'm not much of a Linux guy. I do perform Windows administration on a regular basis, so I am quite familiar with partitioning and related concepts. I played around in my youth with serial communication and I have a soldering gun in my workshop, if you know what I mean :slight_smile:

So, I booted the router in recovery mode and got SSH access ... and I have questions :slight_smile:

  1. The only ubi util available is ubinfo (or is the only one accessible via PATH). Could I copy the rest of them via tftp, in a temporary location, just to have them available for manual installation?

  2. If answer to 1) is yes:
    a. What would be that temporary location?
    b. Any idea on how could I build the ubi utils for my router model using the source code from git://git.infradead.org/mtd-utils.git?

  3. How can I identify and backup the ubi volume? And, more importantly, how do I restore it in case something goes awry?

Thanks in advance.

I tried this, but it does not work this easily. I copied the ubi* tools from the OpenWRT image (via scp, no need for tftp for this) but the programs do not run, I guess because of incompatible libraries.
The ASUS firmware uses a different kernel version and a different libc, and I do not know enough to tell if there is a way around that.
Another idea I had was to use a chroot containing all the needed libraries (again, not sure if it makes sense or if it would be possible), but the chroot command is not included in the ASUS busybox.