sysupgrade.bin vs factory.bin

General discussion about Gargoyle, OpenWrt or anything else even remotely related to the project

Moderator: Moderators

Post Reply
ispyisail
Moderator
Posts: 5185
Joined: Mon Apr 06, 2009 3:15 am
Location: New Zealand

sysupgrade.bin vs factory.bin

Post by ispyisail »

Hi all

What is the difference between sysupgrade.bin and factory.bin?

The question has been asked a few times on this forum in various forms but I don't think anybody has really answered it well.

I don't know the answer!

This is my hypotheses

The ROM/filesystem is divided up into sections

u-boot
kernel
rootfs_data

I the early days we would flash our atheros routers with

gargoyle_1.3.14-atheros-vmlinux.lzma
gargoyle_1.3.14-atheros-root.squashfs

and we would leave the "redboot/u-boot" alone

Now with the new .bin install files all the data is included in the one file.

I have assumed that the sysupgrade.bin is minus redboot/u-boot and the factory.bin includes redboot/u-boot?

Can somebody help on this topic!

User avatar
DoesItMatter
Moderator
Posts: 1373
Joined: Thu May 21, 2009 3:56 pm

Re: sysupgrade.bin vs factory.bin

Post by DoesItMatter »

U-Boot is never in the firmware.

That is loaded by the manufacturer and almost never updated.

Don't mess with U-Boot - I have a dead router because I tried to
flash a replacement U-Boot on it - U-Boot is tricky!

Sysupgrade.bin is for any router that is currently running either
openwrt or gargoyle and can be flashed via the GUI.

The factory.bin files are meant to be flashed over factory stock
firmware routers - they usually have some extra "magic bytes"
i.e. a trick header - to fool the factory firmware into thinking its
reading its own factory firmware, not 3rd party firmware.

U-Boot and Redboot are never usually included in firmwares.
Upgrading those are very risky and if done incorrectly will brick
the router for most normal users. It will take advanced recovery
steps to try to recover the router.
:twisted: Soylent Green Is People! :twisted:
2x Asus RT-N16 = Asus 3.0.0.4.374.43 Merlin
2x Buffalo WZR-HP-G300NH V1 A0D0 = Gargoyle 1.9.x / LEDE 17.01.x
2x Engenius - ESR900 Stock 1.4.0 / OpenWRT Trunk 49400

ispyisail
Moderator
Posts: 5185
Joined: Mon Apr 06, 2009 3:15 am
Location: New Zealand

Re: sysupgrade.bin vs factory.bin

Post by ispyisail »

The factory.bin files are meant to be flashed over factory stock
firmware routers - they usually have some extra "magic bytes"
i.e. a trick header - to fool the factory firmware into thinking its
reading its own factory firmware, not 3rd party firmware.
I know for a fact that I can flash a TP-link TL-WR1043ND with gargoyle from stock with x.x.sysupgrade.bin

This being the case it probably doesn't matter which file you use for this router?

User avatar
DoesItMatter
Moderator
Posts: 1373
Joined: Thu May 21, 2009 3:56 pm

Re: sysupgrade.bin vs factory.bin

Post by DoesItMatter »

Probably depends on the manufacturer and whether or not they
take precautions in allowing 3rd party firmware to be flashed
onto their routers.

Buffalo routers almost ALWAYS require the extra header with the
magic numbers in it, otherwise it won't allow the file to be flashed.

Once Gargoyle / OpenWRT / DD-WRT is on the router, it no longer
needs those magic #'s to flash the router.
:twisted: Soylent Green Is People! :twisted:
2x Asus RT-N16 = Asus 3.0.0.4.374.43 Merlin
2x Buffalo WZR-HP-G300NH V1 A0D0 = Gargoyle 1.9.x / LEDE 17.01.x
2x Engenius - ESR900 Stock 1.4.0 / OpenWRT Trunk 49400

Post Reply