Our first parents were made righteous in the presence of God. They dwelt and walked with Him. That is the relationship a righteous man desires.

And it means the desire to be free from the power of sin. To get away from the power that drags him down in spite of himself.