thank you for your question.
It depends- as each case is individual.
Before receiving the resident permit one has to have a positive answer on the asylum claim.
Then there are two types for resident permits:
The two types of residence permits are limited (Aufenthaltserlaubnis) and unlimited (Niederlassungserlaubnis). The Niederlassungserlaubnis can normally only be applied for after several years of continuous residence or if certain special requirements are met. The limited permit carries an expiration date. You may be allowed to apply for an extension of that permit when the expiry date nears.
But to get the first one it might take from the day you claim asylum about 1-1 1/2 years- this is if you get a positive answer and do not have to appeal.
I hope I could assist you.