Compare/strip running config script?

Is there a tool / script to compare .configs or a way to strip a config from a running system?


I always compare both the full .config from the previous build to the current one, and also compare the much shorter scripts/ output, which shows only the changes made by you (deviations from the device defaults). Also the manifest file gives you nice overview of included exact package versions. After a build I always store also those files along the firmware binaries and source diffs in my PC.

Note that it is also possible to config build system to also store the diffconfig output (build config) into the firmware binary itself, into a file in /etc. I do also that. Then the config info is permanently stored inside the firmware in the router.


Yes I use the diffconfig script when building firmware betweeen upgrade images to create a seed file to create a new config but I would be intrested in how you imbed the config file in the image?

I guess you are basically manually copying the config file into the file/etc directory after running menuconfig?

so I guess there is no tool or script I can run on a running openwrt device to create alist of software installed in the image or a config seed?

By using the config symbol for that:

		bool "Include build configuration in firmware" if DEVEL
		default n
		  If enabled, buildinfo files will be stored in /etc/build.* of firmware.

If I remember right, you need to first select the advanced build options, then you can select this one.

1 Like

opkg list-installed

But that lists also the default packages, does not give info about other build config options, and the package list is not formatted for .config

Awesome that will at least give me a basis to work from.

I use the GUI tools "Meld" to compare/edit the old and new .config files, and compare/edit any files/folders also.

The default config file, included too many "=m", I have to change it to "is not set" every time, not easy.

On windows, I use WinMerge .

I use winmerge.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.