AFAIK there is no way to ask for installed size. The information is stored (you can find it in /usr/lib/opkg/status/info/*.control, which has an 'Installed-Size' field), but not retrievable trough opkg.
However, that number is not reliable. The packages are stored on a compressed filesystem, and so it's not easy to tell how much bytes are actually used, and the package system doesn't keep track of it. The 'Installed-Size' is a guess, it is not the size of the file(s), but an estimated compressed size. That estimation is done by the package builder, and it is wrong. There are 3 places where an package can be installed, in squashfs (part of the base system), in jaffs or ubifs (on the remaining build-in flash rom) of on extroot (on an USB stick, or internal harddisk, or ...)
The compression of squashfs is best, jaffs or ubifs has less compression, and extroot normally has no compression. So how to catch that in a single estimation?
Yet you can ask for (uncompressed) sizes of installed files:
du -ah /overlay/upper/
If you want to know which package contributed a file
opkg whatprovides <filename>
or search for it in /usr/lib/opkg/info/*.list
It is easy to compare both installations. Just execute
ls -R /overlay/upper/
on both boxes, and compare the outputs.
Depends if the overwritted file was in the base installation, or in a later installed package. In the latter case the file is actually gone, and the only way to get it back is by extracting it from the package file. (manually or by opkg). When the file was part of the base installation, it's still there. The base installation is in read-only squashfs, and so cannot be changed. To get it back you'll have to understand how the layered filesystem of OpenWrt works. Normally it consists of a readonly squashfs, and a read-write ubi- or jaffs. The readonly part is mounted on /rom/, and the read-write part is mounted on /overlay/upper/. Together, with some magic glue, they are mounted on /. Of you search for a file in /, it first looks in /overlay/upper/, and only if it can't be found there, it looks in /rom/. So if you overwrite a file in squashfs, you can find it in both places, but only the one in /overlay/upper/ is actually used.
So to get the original file back, you only have to delete it in /overlay/upper/. Be careful with this, if the overwritten file does not meet upgraded requirements, your system might render unusable.
BTW, using the layered filesystem it's also possible to delete
a file in the ro layer. In that case in the upper layer an entry is created with a special name, meaning 'no such file'.
Your question suggests that you are running out of space. In your case you can choose to install one or more packages on harddisk. I think it can be done by executing
opkg install <package> --dest /mountpoint/of/disk/subdirectory/
You'd better not install a much used package this way, as a disk is slow, and might to have to spinup.
Another way to preserve space is to use the Image Builder to create a new image with the packages included. That way they are installed in squashfs, which has a (far) better compression than in overlay.