Armed pirates raided a Japanese oil tanker in the Strait of Malacca, pumping millions of litres of diesel and taking three crew members hostage, according to Malaysian maritime police.

Six pirates used a speedboat to approach the Naninwa Maru vessel at 0100 local time before boarding off the coast of west Malaysia, Maritime Police Commander Abdul Aziz Yusof told Reuters.

"It was only realised by the crew members when they saw about five or six men armed with a pistol and a machete aboard the ship," according to Norzaid Muhammad Said, police commander of nearby Port Klang.

The ship was headed for Myanmar from Singapore and was holding Indonesian, Thai, Myanmar and Indian crew members on board.

The assailants proceeded to pump over 2.5 million litres of diesel being transported by the tanker into two waiting vessels before taking three Indonesian men hostage.

The Malacca Strait represents the route for approximately a quarter of the world's sea oil trade, especially important for China's energy imports from the Middle East and Africa.

There are now concerns that piracy - after a notable decline in the Horn of Africa - may be increasing in the Asian waterway, driving an increase in insurance prices for shipowners.

A coordinated international piracy effort has broughts numbers of piracy attacks down to its lowest level for six years.

Some 264 attacks were recorded in 2013, a 40% decrease on the height of Somali piracy in 2011, according to the International Maritime Bureau (IMB).

Indonesia - which runs alongside the Malacca Strait - saw the most pirate attacks in 2013, representing more than 50% of all recorded incidents.