The families of Valentine and Ajesh Pink will each receive 10m rupees ($189,000; £117,013), officials said.
The marines were guarding Italian oil tanker Enrica Lexie and have been in custody since the shooting.
Italy said they fired warning shots, mistaking the fishermen for pirates.
Under the agreement signed on Tuesday, the compensation money will be paid to the widow and two children of Valentine alias Jelastine and two sisters of Ajesh Pink.
The families later told the court that they were withdrawing their cases as they had reached a settlement with the Italian government.
It took India and Italy more than two months and a number of meetings between Italian and Indian officials to sort out the row.
Italy insisted that its personnel could not be charged under Indian law. It said the marines had immunity as the tanker was flying an Italian flag and was in international waters when the incident happened.
India insisted that the marines be tried under local laws and registered a case of murder against the men.