I am calculating service availability for a month. For that I have outage start time and outage end time. I want to know out of total time in minutes for a month, how much percentage of service was disrupted.
E.g Service Availability = Total time - Total_outage_time / Total time.
However, I am not able to exclude the overlapping outage time. I do not want to calculate the overlapping duration. Can someone help?
| Outages | Start time | End time |
| Outage 1 | 2019-11-04 13:04:00 | 2019-11-05 16:57:34 |
| Outage 2 | 2019-10-05 11:20:00 | 2019-10-05 02:18:03 |
| Outage 3 | 2019-10-20 16:19:00 | 2019-10-21 02:18:29 |
| Outage 4 | 2019-10-30 02:29:00 | 2019-10-31 06:46:56 |