Hello All,
I am new to OpenWRT < 1Month. I have a GL-iNet MT6000 and OpenWRT firmware is still in the snapshot phase, hence that is what I am using.
OpenWRT install and configuration seemed to go reasonably well and the device is functioning. It seems however that my partition table/layout was corrupted somewhere along the way. If you can read this, the router is still functioning.
I have worked with partitions on Windows machines but the drives were unmounted. I don't see a way to do that here.
I am new to Linux but can study some utilities. I have not done anything beyond initial investigation at this point.
See the gdisk report below.
I am looking for advice regarding the correct course of action, utilities and procedures. I am not concerned about having to flash and rebuild the configuration
OpenWrt login: root
Password:
BusyBox v1.36.1 (2024-03-11 08:58:20 UTC) built-in shell (ash)
| |.-----.-----.-----.| | | |.----.| |_
| - || _ | -| || | | || || |
|_____|| |||||___||| |____|
|| W I R E L E S S F R E E D O M
OpenWrt SNAPSHOT, r25464-79ee4cb039
root@OpenWrt:~# gdisk /dev/mmcblk0
GPT fdisk (gdisk) version 1.0.9
Caution: invalid backup GPT header, but valid main header; regenerating
backup header from main header.
Warning! Main and backup partition tables differ! Use the 'c' and 'e' options
on the recovery & transformation menu to examine the two tables.
Warning! One or more CRCs don't match. You should repair the disk!
Main header: OK
Backup header: ERROR
Main partition table: OK
Backup partition table: ERROR
Partition table scan:
MBR: protective
BSD: not present
APM: not present
GPT: damaged
Caution: Found protective or hybrid MBR and corrupt GPT. Using GPT, but disk
verification and recovery are STRONGLY recommended.
Warning! Secondary partition table overlaps the last partition by
33 blocks!
You will need to delete this partition or resize it in another utility.
Command (? for help):
Caution: Found protective or hybrid MBR and corrupt GPT. Using GPT, but disk
verification and recovery are STRONGLY recommended.
Warning! Secondary partition table overlaps the last partition by
33 blocks!
You will need to delete this partition or resize it in another utility.
root@OpenWrt:~#
Here is the existing partition table:
Command (? for help): p
Disk /dev/mmcblk0: 15269888 sectors, 7.3 GiB
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): 2BD17853-102B-4500-AA1A-8A21D4D7984D
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 15269854
Partitions will be aligned on 1024-sector boundaries
Total free space is 8158 sectors (4.0 MiB)
Number Start (sector) End (sector) Size Code Name
1 8192 9215 512.0 KiB 8300 u-boot-env
2 9216 13311 2.0 MiB 8300 factory
3 13312 17407 2.0 MiB 8300 fip
4 17408 21503 2.0 MiB 8300 cfg
5 21504 25599 2.0 MiB 8300 log
6 25600 91135 32.0 MiB 8300 kernel
7 91136 15269887 7.2 GiB 8300 rootfs