It occurs mostly while decending down. Keep chewing gum with you. Before decending, try sips of hot water.
30 minutes before, use otrivin nasal spray in both the nose. Also, keep chew chewing gum while the plane is landing. Also do Valaslva frequently when you have ear pain.