bitcoin core – How to remove a tx from a local node mempool that has been removed from all other nodes
The default value for mempoolexpiry is 336. This is 2 weeks. Your value is 48, which means transactions in the mempool for more than 2 days will be deleted. Considering the current mempool size (+300 blocks), we believe that value is inappropriate (too low). Does the node have a reason for its value?
Also, no node will (re)transmit a tx that is already in mempoool. This is an anti-spam measure. When you start a node (badly connected), it is possible that other starting nodes are also poorly connected and are receiving transactions. So the transaction is stuck in both mempools. Additionally, the agent that originally sent the transaction (presumably itself) has not sent the transaction again since.
There is no way to remove that tx from the mempool, but you can rebroadcast it again via another method (e.g. https://bitaccelerate.com/pushtx/) and wait for it to be mined.
I’ve also noticed that my node (which serves my webpage https://mempoolexplorer.com) sometimes has transactions from other services. Probably for the same reason.