Leinster 35-21 Ospreys
John McWeeney scored Leinster's second try
Leinster got their first win under new coach Gary Ella in Friday night's opening round Celtic Cup tie at Donnybrook.
Having lost their two opening Celtic League fixtures against Munster and Celtic Warriors, Leinster badly needed a victory.
And, despite having 10 players away with Ireland's World Cup squad, they had enough strength in depth to topple the Ospreys and earn a quarter-final away to Irish rivals Ulster.
Third-string fly-half Matt Leek, signed by former coach Matt Williams at the beginning of last season, fired 20 of the Leinster points.
The Englishman has had little chance to shine since moving to Ireland from Wasps, finding himself behind Christian Warner and Felipe Contepomi in the race for the number 10 shirt.
However, with Contepomi preparing for World Cup duty with Argentina and Warner starting at centre, Leek tok his chance to shine.
Despite missing an early long-range effort he quickly settled down to run in Leinster's first try in the sixth minute, which he then converted.
Leinster were in charge and in the 20th minute, scrum-half Brian O'Riordan broke the Welsh line to feed John McWeeney for a second try, again converted by Leek.
Gavin Henson got the Ospreys up and running with a penalty only for the visitors to lose Lyndon Bateman to the sin bin, Leinster compounding the error with a try from Des Dillon.
Leek converted but two more Henson penalties kept the Ospreys in touch, 21-9, at half-time.
Elvis Sevalal'l closed the gap further with a try just after the restart only
for Leek to chip in with a drop goal.
Again the Ospreys hit back, this time from Henson who converted his own try to bring the visitors to within three points of their hosts.
Leek again increased Leinster's lead, however, with a penalty when flanker Steve Tandy was sin-binned for a deliberate offside.
Leinster won another penalty in the 78th minute which Leek took successfully before Warner made sure of victory with a fine solo run
from inside his own half.
Leinster: G. D'Arcy; J. McWeeney, K. Lewis, C. Warner, B. Burke; M. Leek, B. O'Riordan; J. Lyne, G. Hickie, E. Byrne, A. Kearney, B. Gissing, A. McCullen, S. Jennings, D. Dillon.
Replacements: P Coyle, D Blaney, N Breslin, N Ronan, B O'Meara, D Quinlan, G Brown.
Ospreys: Henson, Tiueti, Storey, Gibbs, Seveali'i,
Connor, A. Williams, James, Wells, Millward, Newman, Bateman,
Thomas, Tandy, Bonner-Evans.
Replacements: Morris, Durston, Richards, B. Williams, Griffiths,