diff --git a/src/communication/sync-logic-handler.cpp b/src/communication/sync-logic-handler.cpp
index 705a721..1434aa4 100644
--- a/src/communication/sync-logic-handler.cpp
+++ b/src/communication/sync-logic-handler.cpp
@@ -138,8 +138,18 @@
 }
 
 void
-SyncLogicHandler::createSyncSocket()
+SyncLogicHandler::createSyncSocket(const ndn::Name& syncPrefix)
 {
+  if (m_syncSocket != nullptr) {
+    _LOG_WARN("Trying to create Sync socket, but Sync socket already exists");
+    return;
+  }
+
+  m_syncPrefix = syncPrefix;
+
+  // Build LSA sync update prefix
+  buildUpdatePrefix();
+
   _LOG_DEBUG("Creating Sync socket. Sync Prefix: " << m_syncPrefix);
 
   // The face's lifetime is managed in main.cpp; SyncSocket should not manage the memory
@@ -254,6 +264,12 @@
 void
 SyncLogicHandler::publishRoutingUpdate()
 {
+  if (m_syncSocket == nullptr) {
+    _LOG_FATAL("Cannot publish routing update; SyncSocket does not exist");
+
+    throw SyncLogicHandler::Error("Cannot publish routing update; SyncSocket does not exist");
+  }
+
   m_sequencingManager.writeSeqNoToFile();
 
   publishSyncUpdate(m_updatePrefix, m_sequencingManager.getCombinedSeqNo());
diff --git a/src/communication/sync-logic-handler.hpp b/src/communication/sync-logic-handler.hpp
index 36caae7..7df3671 100644
--- a/src/communication/sync-logic-handler.hpp
+++ b/src/communication/sync-logic-handler.hpp
@@ -44,10 +44,17 @@
 class SyncLogicHandler
 {
 public:
-  SyncLogicHandler(ndn::Face& face, Lsdb& lsdb, ConfParameter& conf, SequencingManager& seqManager);
+  class Error : public std::runtime_error
+  {
+  public:
+    explicit
+    Error(const std::string& what)
+      : std::runtime_error(what)
+    {
+    }
+  };
 
-  void
-  createSyncSocket();
+  SyncLogicHandler(ndn::Face& face, Lsdb& lsdb, ConfParameter& conf, SequencingManager& seqManager);
 
   void
   onNsyncUpdate(const std::vector<Sync::MissingDataInfo>& v, Sync::SyncSocket* socket);
@@ -59,15 +66,12 @@
   publishRoutingUpdate();
 
   void
-  setSyncPrefix(const std::string& sp)
-  {
-    m_syncPrefix = sp;
-  }
+  createSyncSocket(const ndn::Name& syncPrefix);
 
+private:
   void
   buildUpdatePrefix();
 
-private:
   void
   processUpdateFromSync(const SyncUpdate& updateName);
 
diff --git a/src/lsdb.cpp b/src/lsdb.cpp
index 1374906..c0fb765 100644
--- a/src/lsdb.cpp
+++ b/src/lsdb.cpp
@@ -597,17 +597,9 @@
 
   m_nlsr.getSequencingManager().increaseAdjLsaSeq();
 
-  bool isInstalled = installAdjLsa(adjLsa);
-
-  // Delay Sync prefix registration until the first Adjacency LSA is built
-  if (isInstalled && !m_hasSyncPrefixBeenRegistered) {
-    m_nlsr.getSyncLogicHandler().createSyncSocket();
-    m_hasSyncPrefixBeenRegistered = true;
-  }
-
   m_sync.publishRoutingUpdate();
 
-  return isInstalled;
+  return installAdjLsa(adjLsa);
 }
 
 bool
diff --git a/src/lsdb.hpp b/src/lsdb.hpp
index 3cf74c6..417c978 100644
--- a/src/lsdb.hpp
+++ b/src/lsdb.hpp
@@ -45,7 +45,6 @@
     : m_nlsr(nlsr)
     , m_scheduler(scheduler)
     , m_sync(sync)
-    , m_hasSyncPrefixBeenRegistered(false)
     , m_lsaRefreshTime(0)
     , m_adjLsaBuildInterval(static_cast<uint32_t>(ADJ_LSA_BUILD_INTERVAL_DEFAULT))
   {
@@ -278,8 +277,6 @@
   std::list<AdjLsa> m_adjLsdb;
   std::list<CoordinateLsa> m_corLsdb;
 
-  bool m_hasSyncPrefixBeenRegistered;
-
   seconds m_lsaRefreshTime;
   std::string m_thisRouterPrefix;
 
diff --git a/src/nlsr.cpp b/src/nlsr.cpp
index 2d58b19..1176b69 100644
--- a/src/nlsr.cpp
+++ b/src/nlsr.cpp
@@ -134,8 +134,7 @@
   m_sequencingManager.setSeqFileName(m_confParam.getSeqFileDir());
   m_sequencingManager.initiateSeqNoFromFile();
 
-  m_syncLogicHandler.setSyncPrefix(m_confParam.getChronosyncPrefix().toUri());
-  m_syncLogicHandler.buildUpdatePrefix();
+  m_syncLogicHandler.createSyncSocket(m_confParam.getChronosyncPrefix());
 
   /* Logging start */
   m_confParam.writeLog();
