diff --git a/image_manager.cpp b/image_manager.cpp
index 357d3c2..a64c826 100644
--- a/image_manager.cpp
+++ b/image_manager.cpp
@@ -184,6 +184,15 @@
     {
         return;
     }
+
+    if (it->second->isFunctional())
+    {
+        log<level::ERR>(("Error: Version " + entryId + \
+                         " is currently running on the BMC." \
+                         " Unable to remove.").c_str());
+        return;
+    }
+
     // Delete image dir
     fs::path imageDirPath = (*(it->second)).path();
     if (fs::exists(imageDirPath))
diff --git a/item_updater.cpp b/item_updater.cpp
index 4507bcf..6b4ff5e 100644
--- a/item_updater.cpp
+++ b/item_updater.cpp
@@ -235,9 +235,33 @@
 
 void ItemUpdater::erase(std::string entryId)
 {
-    // Delete ReadOnly partitions
-    removeReadOnlyPartition(entryId);
-    removeFile(entryId);
+    // Find entry in versions map
+    auto it = versions.find(entryId);
+    if (it != versions.end())
+    {
+        if (it->second->isFunctional())
+        {
+            log<level::ERR>(("Error: Version " + entryId + \
+                             " is currently running on the BMC." \
+                             " Unable to remove.").c_str());
+             return;
+        }
+
+        // Delete ReadOnly partitions if it's not active
+        removeReadOnlyPartition(entryId);
+        removeFile(entryId);
+    }
+    else
+    {
+        // Delete ReadOnly partitions even if we can't find the version
+        removeReadOnlyPartition(entryId);
+        removeFile(entryId);
+
+        log<level::ERR>(("Error: Failed to find version " + entryId + \
+                         " in item updater versions map." \
+                         " Unable to remove.").c_str());
+        return;
+    }
 
     // Remove the priority environment variable.
     auto serviceFile = "obmc-flash-bmc-setenv@" + entryId + ".service";
@@ -250,14 +274,6 @@
     bus.call_noreply(method);
 
     // Removing entry in versions map
-    auto it = versions.find(entryId);
-    if (it == versions.end())
-    {
-        log<level::ERR>(("Error: Failed to find version " + entryId + \
-                         " in item updater versions map." \
-                         " Unable to remove.").c_str());
-        return;
-    }
     this->versions.erase(entryId);
 
     // Removing entry in activations map
@@ -269,9 +285,6 @@
                          " Unable to remove.").c_str());
         return;
     }
-    // TODO: openbmc/openbmc#1986
-    //       Test if this is the currently running image
-    //       If not, don't continue.
 
     this->activations.erase(entryId);
 }
diff --git a/version.cpp b/version.cpp
index b564416..e6dd9de 100644
--- a/version.cpp
+++ b/version.cpp
@@ -4,6 +4,7 @@
 #include <fstream>
 #include <stdexcept>
 #include <phosphor-logging/log.hpp>
+#include "config.h"
 #include "version.hpp"
 
 namespace phosphor
@@ -101,6 +102,11 @@
     return version;
 }
 
+bool Version::isFunctional()
+{
+    return versionStr == getBMCVersion(OS_RELEASE_FILE);
+}
+
 } // namespace manager
 } // namespace software
 } // namepsace phosphor
diff --git a/version.hpp b/version.hpp
index 3d17213..1e69a6d 100644
--- a/version.hpp
+++ b/version.hpp
@@ -39,7 +39,7 @@
                 const std::string& versionId,
                 VersionPurpose versionPurpose,
                 const std::string& filePath) : VersionInherit(
-                    bus, (objPath).c_str(), true)
+                    bus, (objPath).c_str(), true), versionStr(versionId)
         {
             // Set properties.
             purpose(versionPurpose);
@@ -73,6 +73,17 @@
          * @return The version identifier.
          */
         static std::string getBMCVersion(const std::string& releaseFilePath);
+
+        /* @brief Check if this version matches the currently running version
+         *
+         * @return - Returns true if this version matches the currently running
+         *           version.
+         */
+        bool isFunctional();
+
+    private:
+        /** @brief This Version's version string */
+        const std::string versionStr;
 };
 
 } // namespace manager
