If you have followed the steps described by Microsoft to enable WSL 2 on Windows 10 but still facing issue similar to the one shown below then you can follow these steps that will help you resolve this issue.
Open CMD as administrator and run below commands.
wsl --shutdown netsh winsock reset
You should be able to run your WSL 2 without an issue.
Leave a comment below if you have any question or suggestions.
Happy Posting! See you in the next one.