
398 Mass. 502 (1986)
498 N.E.2d 1056
RICHARD M. DUNBRACK
vs.
COMMONWEALTH.
Supreme Judicial Court of Massachusetts, Suffolk.
September 12, 1986.
October 16, 1986.
Present: HENNESSEY, C.J., WILKINS, LIACOS, & ABRAMS, JJ.
Morris M. Goldings for the plaintiff.
Don L. Carpenter, Assistant District Attorney, for the Commonwealth.
ABRAMS, J.
Pursuant to G.L.c. 211, § 3, Richard M. Dunbrack asked a single justice of this court specifically to enforce a sentencing agreement. After hearing, the single justice denied relief. Dunbrack appeals. We affirm.
The relevant facts are as follows. Dunbrack was arrested on September 4, 1984, and charged with operating a motor vehicle *503 while under the influence of intoxicating liquor, in violation of G.L.c. 90, § 24. On October 26, 1984, Dunbrack entered an admission to sufficient facts pursuant to an agreement reached between defense counsel and an assistant district attorney. In exchange for this admission, the assistant district attorney agreed to recommend that Dunbrack be placed on probation for one year, and, as a condition of this probation, Dunbrack was assigned to an eight-week driver alcohol education program. See G.L.c. 90, § 24D (1984 ed.).[1] The recommendation was based on Dunbrack's probation report, which showed that Dunbrack had no prior record. The judge accepted the recommendation of counsel, and Dunbrack was sentenced to one year's probation, conditioned on his completion of the alcohol education program.[2]
Shortly after this hearing, an error in Dunbrack's probation report was discovered. In fact, Dunbrack had been arrested for operating a motor vehicle while under the influence of alcohol in 1981. As a result of this prior charge, Dunbrack previously had attended the same driver alcohol education program. Because Dunbrack was a second offender, he was not eligible to repeat the education program.[3]
On February 12, 1985, Dunbrack's status as a second offender was called to the attention of the sentencing judge.[4] The *504 sentencing judge cancelled the condition of probation concerning the driver education program and substituted sanctions specified in G.L.c. 90, § 24,[5] for second offenders. Specifically, the sentencing judge assigned Dunbrack to a repeat offender program which included alcohol counseling and a fourteen-day residential alcohol treatment program. Because this modification in the conditions of probation varied from the plea agreement, Dunbrack brought this action to reinstate the terms of the original agreement.
In an application for extraordinary relief under G.L.c. 211, § 3, the party seeking relief must demonstrate both a substantial claim of violation of his substantive rights and error that cannot be remedied under the ordinary review process. Hadfield v. Commonwealth, 387 Mass. 252, 255 n. 2 (1982). Schipani v. Commonwealth, 382 Mass. 685 (1980). Morrisette v. Commonwealth, 380 Mass. 197, 198 (1980). The appropriate method for attacking the lawfulness of the admission to sufficient facts and the sentence imposed is a postconviction motion for new trial pursuant to rule 30 (b) of the Massachusetts Rules of Criminal Procedure, 378 Mass. 900 (1980).[6] See Commonwealth *505 v. Fernandes, 390 Mass. 714, 715 (1984); Commonwealth v. DeMarco, 387 Mass. 481, 482 (1982); Commonwealth v. Huot, 380 Mass. 403, 406 & n. 3 (1980). At oral argument, Dunbrack admitted that he could seek a new trial pursuant to Mass. R. Crim. P. 30 (b). Because Dunbrack's substantive rights can be protected through normal postconviction relief, the single justice correctly denied relief pursuant to G.L.c. 211, § 3.
We comment briefly on Dunbrack's claim. Dunbrack contends that the disposition in this case is controlled by our decision in Buckley v. Quincy Div. of the Dist. Court Dep't, 395 Mass. 815 (1985). We do not agree. In Buckley, a supervisory court sought to modify the terms and conditions of probation imposed by the sentencing court. Further, the supervisory court tried to impose additional conditions on the probation which were unrelated to the original offense. Id. at 817. We said that a supervisory court has no power to modify the conditions of probation absent any material change in the probationer's circumstances since the imposition of probation. Id. at 828. We specifically did not "outline those situations in which the sentencing court might modify the terms of probation" (emphasis in original). Id.
Unlike the Buckley case, the conditions of probation of Dunbrack were modified by the original sentencing judge to make his sentence lawful and within the statutory scheme. Moreover, the modified terms directly related to the offense for which Dunbrack was sentenced. Because the original sentencing judge modified the conditions of Dunbrack's probation in response to the discovery of an error in his probation report, and because the modification related to the original offense, the Buckley case is inapposite.
This case simply presents an instance of the trial court's correction of an error on which Dunbrack's sentence was based. The original agreement and the sentence rested on erroneous information, and as a result, the agreement was not lawful. At the time the sentencing judge was given the correct information, he altered the conditions of probation according to the minimum statutory requirements. There was no prosecutorial *506 misconduct or bad faith. Unlike the circumstances described in Commonwealth v. Benton, 356 Mass. 447, 449 (1969), here, the Commonwealth did not renege on a promise. There was no promise to recommend an unlawful sentence.
This case merely involves the discovery of new information which made the prior sentencing agreement unlawful. The applicable statute mandates that a second offender is not eligible for the nonresidential alcohol education program, and the sentencing judge altered the conditions of probation to comply with the statutory scheme. A sentencing judge has flexibility to respond appropriately if, as in this case, such an error is discovered in a timely manner.
Judgment affirmed.
NOTES
[1]  Dunbrack's driver's license was also suspended for thirty days and fines totaling approximately $340.00 were imposed.
[2]  That portion of the sentence relating to license suspension and the payment of fines has been served. That portion of the sentence concerning rehabilitation has been stayed pending the outcome of this proceeding.
[3]  General Laws c. 90, § 24D, provides: "Any person convicted of or charged with operating a motor vehicle while under the influence of intoxicating liquor, may, if he consents, be placed on probation ... and shall, as a condition of probation, be assigned to a driver alcohol education program.... The provisions of this section shall not apply to any person convicted or assigned to an alcohol education or rehabilitation program because of a like offense by a court ... within a period of six years preceding the date of the commission of the offense...."
[4]  While Dunbrack was aware of his prior arrest for driving while under the influence of intoxicating liquor, neither his counsel nor the Commonwealth discovered this prior offense until after the original sentencing on October 26, 1984. The judge considered Dunbrack's failure to come forward with this information to be a "silent fraud." On the result we reach, we need not decide this issue.
[5]  General Laws c. 90, § 24 (1) (a) (1) (1984 ed.), provides: "If the defendant has been previously convicted or assigned to an alcohol education or rehabilitation program by a court of the commonwealth because of a like violation within six years preceding the date of the commission of the offense for which he has been convicted, the defendant shall be punished by a fine of not less than three hundred nor more than one thousand dollars and by imprisonment for not less than seven days nor more than two years...."

An alternative to the term of imprisonment is provided in subsection (4) of G.L.c. 90, § 24 (1) (a). This provision states that "a defendant who pleads guilty to or is found guilty of a violation of subparagraph (1) and who has not been convicted or assigned to an alcohol education or rehabilitation program by a court ... because of a like offense two or more times within six years of the date of the commission of the offense for which he has been convicted, ... [may be placed] on probation for two years provided that a condition of such probation shall be that the defendant be confined for no less than fourteen days in a residential alcohol treatment program...."
[6]  In their briefs, neither Dunbrack nor the Commonwealth has referred to Mass. R. Crim. P. 30. In oral argument, the Commonwealth argued that this postconviction remedy would be a proper alternative if Dunbrack sought to withdraw his admission to sufficient facts.
