DDWRT and Saving an EXT2 Installation

wiki.TerraBase.info
Revision as of 18:05, 25 April 2020 by Root (talk | contribs)
Jump to navigation Jump to search

It seems like Entware and DD-WRT like to fail on a somewhat regular basis if the router crashes and corrupts the EXT2 (or whatever format) Partition Entware is installed on.

A trick that I've learned is to take a page from high end routers that have two separate NVRAM segments. IE, whatever disk or USB FlashDrive Entware is to be installed on, divide it in two. USB FlashDrives are fairly big and cheap these days, so no big deal. Install Entware on one of the partitions, get it the way you like it and copy it to the other partition. If the first one ever craps out, boot to the second one and recover (format, re-partition, whatever) the first one. Then copy the files back.

  • To install any of the below utilities if they're missing: opk install XYZ
  • To display information about a "disk" or file system: mount OR df OR dumpe2fs
  • To "CHKDSK" a file system:e2fsck /dev/sdaX OR fsck.ext2 (remember, make sure it is not mounted) (to install utility, with additional utilities for other stuff:opkg install e2fsprogs)
    • umount /dev/sdaX
    • mke2fs or mkfs.ext2 -L WhatEverLabel /dev/sdaX
    • ...wait FOREVER if it is a USB drive
  • General Information:
    • SuperBlock: 1st one typically at 32768