A SAILOR shot three civilians, killing two of them, before taking his own life at Pearl Harbour, just days before thousands were scheduled to gather at the military base to mark the 78th anniversary of the Japanese bombing that launched the US into the Second World War.

Rear Admiral Robert Chadwick, the commander of Navy Region Hawaii, said the service would evaluate whether security would need to be upgraded ahead of the annual ceremony.

About a dozen survivors of the 1941 bombing were expected to attend, along with dignitaries and service members.

Rear Admiral Chadwick said he did not know the motive behind Wednesday’s shooting at the naval shipyard within the base.

“We have no indication yet whether they were targeted or if it was a random shooting,” he said.

The third victim was taken to hospital.

The sailor was assigned to the fast attack submarine USS Columbia, which is at Joint Base Pearl Harbor-Hickam for maintenance. The base went into lockdown at about 2.30pm local time when the first reports were received. The base reopened a few hours later. Witnesses were still being interviewed for hours after.

The shipyard repairs, maintains and modernises the ships and submarines of the US Pacific Fleet, which has its headquarters at Pearl Harbour. The base is the home port for 10 destroyers and 15 submarines. It also hosts Air Force units.

Hawaii had the lowest gun death rate among the US states in 2017, according to the Giffords Law Centre to Prevent Gun Violence.

The islands have strict firearms laws, including a ban on assault weapons and large capacity ammunition magazines.

The shipyard is across the harbour from the wreckage of USS Arizona, which sank in the December 7, 1941, Japanese attack.

More than 2,300 Americans were killed in the bombing.