The Portuguese initially attempted to obtain trading privileges in 1498, but soon had troubles because the pressure from the Muslim Arabs over the Zamorin, since they had traditionally been trading in his ports, and did not want to lose the monopoly in trading spices. The Zamorin resisted these attempts which resulted in the Portuguese trying to destabilise his rule by negotiating a treaty with his arch enemy, the Kingdom of Cochin in 1503. Sensing the Portuguese superiority at sea, the Zamorin set about improving his navy. He appointed Kunjali Marakkar to the task.