Abiding in him is habitual obedience to the King's Word. Jesus made this statement while speaking to His disciples. Abide in Me, and I in you. As the branch cannot bear fruit of itself, unless it abides in the vine, neither can you, unless you abide in Me. It has the idea of settling down in Christ or resting in His Word.
When John made the statement "ought....to walk", he is stating that we should follow Christ's example and stay in the Word. We are not to live in hypocrisy. Our responsibility is to lead others to Christ through our behavior. By doing so they will seek the Kingdom and seek to learn the Kingdom concept. But seek first the kingdom of God and His righteousness, and all these things shall be added to you.
John made it plain that walking in God's Word was no new commandment.
Brethren, I write no new commandment to you, but an old commandment which you have had from the beginning. The old commandment is the word which you heard from the beginning. Again, a new commandment I write to you, which thing is true in Him and in you, because the darkness is passing away, and the true light is already shining.
I John 2:6 John 15:4 Matthew 6:33 I John 2:7-8