Hello Arindom
Indeed with the config as you have it set up, the router ID should become 2.2.2.2 since it is the highest loopback ID. However, 192.168.23.2 does remain the router ID even after the clear ip ospf process
command.
The only thing i can think of is that you have the router ID explicitly configured in the OSPF process as 192.168.23.2 and this is why it is not changing. Please confirm that you have no configured router ID in the OSPF configuration.
If all else fails, try rebooting the device. Let us know your results.
I hope this has been helpful!
Laz