# What's the equation to use for finding availability in software architecture?

I was trying to solve the following question in software architecture.

A software system crashed 20 times in an year and for each crash, it takes 2 minutes to restart. Calculate availability in that year

I used the formula MTBF/(MTBF+MTTR) as given MTTR =2 minutes. But how can I calculate MTBF and availability?

• MTBF = Mean Time Between Failures
• MTTR = Mean Time To Repair

Update : I did it like

MTBF = 365*24*60-40/ 20, MTTR = 2*20

## 1 Answer

You would normally assume a system has 24/7 (i.e. 'round the clock) availability. Therefore, in minutes, it needs to be available for 365 (days) * 24 (hours) * 60 (minutes) = `525600` minutes.

Your MTBF then becomes fairly simple, it's just that amount of time divided by the number of failures (20). Therefore: MTBF = `525600 / 20 =``26280` (minutes MTBF).

Then applying MTBF/(MTBF+MTTR) gives: 26280 (MTBF) / (26280+2) = 0.99992390229054105471425310098166 - or approx. 99.99% availability.

Hope that makes sense!