Microgrids formed by a network of power sources and power consumers yield significant advantages over the conventional power grid including proximity of power consumption to power generation, distributed generation, resiliency against wide area blackouts and ease of incorporation of renewable energy sources. On the other hand, unlike the conventional grid, microgrids are compliant where a single load or a single generation unit can often form a significant fraction of the total generation capacity. Here large excursions from the nominal operating conditions are possible motivating the need for safety mechanisms which isolate power electronic equipment from damage. Breakers serve the purpose of protecting equipment from surge conditions by shutting off, for example, generation units. However in microgrids, a loss of a single generation unit can have catastrophic impact on the viability of the entire system. Here settings on breakers cannot be chosen too conservatively to protect the equipment at the expense of system viability or too liberally which will result in equipment damage. The ensuing problem of striking a suitable compromise tends to be combinatoric in nature due to numerous states of breakers which is further exacerbated by an uncertain load profile and nonlinear nature of system dynamics. In this article we provide a methodology to determine current thresholds and guard times, the time interval when current is allowed to exceed threshold value, for each inverter for fail-safe operation of microgrid. We employ a machine learning approach to address the problem where we first demonstrate that conventional support vector machine (SVM) methodology does not yield a satisfactory solution. We then develop a one-sided SVM method and generalize it to yield nonlinear support boundaries which captures the need for fail-safe operation against system blackouts while protecting equipment. A simulation engine is developed to model a real microgrid which is used to generate data for assessing and guiding our approach.