No, there is no way to undo commandblock/console/chat commands in vanilla MC. The game has no code to even remember what command was executed (except "command success / fail" message in CB and line in log - but server does not see it), or what it done so it could be reverted. It is all discarded just after the command is finished.
There were some third party monitoring plugins (like HawkEye and similar), that were monitoring what happens in the world, logging it and possibly reverting the change, however it was purely based on per-block data, so all it seen were block changes and causes of that (so it could seen that your
/fill command changed blocks, and it seen what blocks were changed and how, but it did not seen the command itself or whatever). However the revert worked only on going back to last states of the block (it just remembered that this block was initially stone, then grass, then air, nothing more)
Also some plugins (like WorldEdit) have //undo, but it is just because it logs its last action completely and can do action opposite, so it looks like reverting. However it can log only its own actions.
If command kills entity, it is deleted forever and has to be resummoned. That is similar with all other changes, without third party plugins, that will store data about your world on some external place (like MySQL), you won't be able to revert any command. There is not a lot (if any) tools that would save all changes in MC world, that would be really server-wise and HDD-wise expensive and thus not reasonable... Using CommandBlocks is only for OP for reasons. You should know what you do, or don't do it.
Except...loading the backup.