In bitcoin, when a transaction is under-priced and stuck unconfirmed on the blockchain, it is possible to bump it by setting up a CPFP transaction. Is there a similar way to achieve this in Ethereum? Say, transaction #1 has gas price set to 5Gwei and nobody is picking it up. Can I set up a transaction #2 whose code is something like "execute transaction #1 first" and price it at 10Gwei? How could this be achieved?
You can just resend the same transaction with the same nonce with a higher gas price. Two transactions with the same nonce can't be mined, so miners will mine the better one