How to safely install a new IOS image on a Cisco device when the installed flash memory size isn't enough for two of them?
Solution 1:
There isn't really a solution, from a file compression standpoint, that you can use. The router's bootloader decompresses the IOS image and, since you can't alter the bootloader adding support for new compression algorithms isn't possible.
Having an out-of-band management connection would the best techncal means to safely handle these situations. In the case of a remote device (one where you can't just walk over to it and plug in your console cable), unfortunately, you could be talking about expensive things like serial terminal servers.
Solution 2:
It's possible your images are already compressed. Exact naming conventions vary by major version, but this guide is still pretty good. If that's the case, you're in a spot of trouble. You can upgrade your flash space or take the risk and go through the recovery procedure (which really isn't that bad, depending on your patience for TFTP transfers)
If the image isn't compressed, you may be able to compress it. Cisco only recommends using the UNIX 'compress' command, and I wouldn't test them on that. However, I'm not entirely certain you can compress your own images for a Cisco 800 series router. I strongly suspect you can, but I haven't been able to identify that absolutely. Put plainly, I'm more confident that the upgrade will go well than I am that you can load a self-compressed IOS image.