From Malaysia Factbook
The word Melayu originated from the name of the Melayu River (near to today's Muara Jambi) in the province of Jambi, Sumatra, Indonesia. A Melayu Kingdom also existed in Jambi between the 4th and 13th century, with large numbers of ancient artifacts and ancient architectures of the kingdom being found by archaelogists.
2. One theory says that Melayu comes from the Tamil word Malaiyur, meaning "Land of Mountains" (Malai, mountain; and yur, land), a reference to the hilly nature of the Malay Archipelago. Malaiyur, also spelt Mazhaiyur, is also the name of a small town in the Thiruvannamalai district of Tamil Nadu, south-west of Chennai in India. Other ancient Indian sources include Malayadvipa, a reference to Sumatra ('dvipa' means 'land surrounded by water'), while the ancient Sanskrit word, Himalaya, means 'snow mountain'. According to G. E. Gerini, Ptolemy used "Maleu-kolon", derived from Sanskrit 'malayakom' or 'malaikurram', to refer to Tanjung Kuantan, while Roland Bradell claimed it on Tanjung Penyabung, both in the Malay peninsula (see Tamil place names in Malaysia)
3. The word Melayu began in use during the time of the Sultanate of Melaka, founded by the fleeing prince Parameswara from the declining Melayu Kingdom of Srivijaya in Palembang. In popular use from the 17th century onwards, the word was adopted into the English language during the European colonization via the Dutch word "Malayo", itself from Portuguese "Malaio" which originates from the Malay word, "Melayu". According to one popular theory, the word Melayu means "migrating" or "fleeing", which might refer to the high mobility of these people across the region (cf. Javanese verb mlayu means "to run", cognate with Malay verb melaju, "to accelerate") or perhaps the original meaning is "distant, far away" (cf. Tagalog, 'malayo') with the root word 'layo', meaning 'distance' or 'far' in Tagalog and some Malayo-Polynesian languages.