In the High Court in the South Island city of Christchurch, Justice Christine French jailed Abdille for nine years with a non-parole period of six years.
The court heard how Abdille took three knives on board a flight from Blenheim to Christchurch in February 2008 and used one to cut the pilot.
She demanded he fly to Australia, but when he said they did not have enough fuel, she suggested they fly into the sea.
When the plane landed at Christchurch, Abdille was overpowered by the pilot and first officer.
The pilot received cuts to both hands and needed extensive surgery to reattach muscles, tendons and a nerve. He was also cut on his back. The first officer was cut on his foot and a passenger was also wounded.
A depositions hearing in December 2008 was told Abdille wanted to either hijack the plane to Australia or crash and kill everyone on board.
The pilot, whose name has not been made public, told the hearing he feared all on board were going to die after the woman said she had a bomb in her bag.
"I had serious concerns for the safety of myself, the first officer, all the passengers and the aeroplane," the pilot said.
"She said at one stage that we were all going to die."
In court Abdille’s defence lawyer, Elizabeth Bulger, read a statement on her behalf.
“I didn’t want to harm anyone or kill anyone,” she read, “I just wanted to get out of the country and get to Australia.”
Since arriving in New Zealand after fleeing war-torn Somalia, Abdille had a number of convictions including threatening to pour petrol on a Red Cross member and throwing a bucket of faeces over a police officer.
French said the starting point for sentencing for the attempted hijacking was 15 years but Abdille's guilty plea and background of mental health issues were taken into account, reducing it to nine years.