Due to the low inertia of inverter-based islanded microgrids (IMGs), these systems require a delicate and accurate load frequency control (LFC) scheme. The deployment of such a control scheme, which preserves the balance between the load and generation, needs a cyber layer on top of the physical system that makes IMGs an appealing target for a variety of cyber-physical attacks (CPAs). Among these CPAs, there is a family of malicious CPAs whose aim is to compromise the LFC scheme by changing the topology of IMG and its parameters. On this basis, an online system identification method is developed to estimate the parameters of IMG using the recursive least square forgetting factor (RLS-FF) approach. Then, based on the estimated parameters, an anomaly-based intrusion detection system (IDS) is developed to identify CPAs and distinguish them from the uncertainties in the normal operation of IMG. Following anomaly detection, a mitigation scheme is proposed to regulate the IMG's frequency using an adaptive interval type-2 fuzzy logic controller (IT2FLC). The proposed IT2FLC uses different types of distributed energy resources (DERs)i.e., tidal power plants and solar panels which are, respectively, equipped with inertia emulation and droop-based controllersto improve the frequency excursion resulting from CPAs. The simulation results verify the performance of the developed detection and mitigation schemes, particularly when the RLS-FF parameters, i.e., forgetting factor, covariance matrix, and reset parameter, are obtained through the grey wolf optimization (GWO) algorithm. Furthermore, the designed mitigation scheme is corroborated by comparing its performance with several well-known attack-resilient control frameworks in LFC studies, e.g., linear quadratic regulator (LQR) and H∞, using real-time simulations.