{"action":"closed","issue":{"url":"https://api.github.com/repos/udhos/qpimd/issues/3","labels_url":"https://api.github.com/repos/udhos/qpimd/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/udhos/qpimd/issues/3/comments","events_url":"https://api.github.com/repos/udhos/qpimd/issues/3/events","html_url":"https://github.com/udhos/qpimd/issues/3","id":54794537,"number":3,"title":"reading configuration from file fails upon startup","user":{"login":"donaldsharp","id":10601296,"avatar_url":"https://avatars.githubusercontent.com/u/10601296?v=3","gravatar_id":"","url":"https://api.github.com/users/donaldsharp","html_url":"https://github.com/donaldsharp","followers_url":"https://api.github.com/users/donaldsharp/followers","following_url":"https://api.github.com/users/donaldsharp/following{/other_user}","gists_url":"https://api.github.com/users/donaldsharp/gists{/gist_id}","starred_url":"https://api.github.com/users/donaldsharp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/donaldsharp/subscriptions","organizations_url":"https://api.github.com/users/donaldsharp/orgs","repos_url":"https://api.github.com/users/donaldsharp/repos","events_url":"https://api.github.com/users/donaldsharp/events{/privacy}","received_events_url":"https://api.github.com/users/donaldsharp/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":{"login":"udhos","id":2634722,"avatar_url":"https://avatars.githubusercontent.com/u/2634722?v=3","gravatar_id":"","url":"https://api.github.com/users/udhos","html_url":"https://github.com/udhos","followers_url":"https://api.github.com/users/udhos/followers","following_url":"https://api.github.com/users/udhos/following{/other_user}","gists_url":"https://api.github.com/users/udhos/gists{/gist_id}","starred_url":"https://api.github.com/users/udhos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/udhos/subscriptions","organizations_url":"https://api.github.com/users/udhos/orgs","repos_url":"https://api.github.com/users/udhos/repos","events_url":"https://api.github.com/users/udhos/events{/privacy}","received_events_url":"https://api.github.com/users/udhos/received_events","type":"User","site_admin":false},"milestone":null,"comments":3,"created_at":"2015-01-19T18:01:39Z","updated_at":"2015-01-19T19:14:39Z","closed_at":"2015-01-19T19:14:39Z","body":"I am getting this error message:\r\n\r\npim_if_add_vif: ifindex=0 < 1 on interface swp1\r\n\r\nIt is happening because in pim_main.c:main() we are initializing zebra with pim_zebra_init() after we read in the configuration with vty_read_config().  This patch fixes this issue:\r\ndiff --git a/pimd/pim_main.c b/pimd/pim_main.c\r\nindex c646356..b57f881 100644\r\n--- a/pimd/pim_main.c\r\n+++ b/pimd/pim_main.c\r\n@@ -216,6 +216,11 @@ int main(int argc, char** argv, char** envp) {\r\n   zlog_default->maxlvl[ZLOG_DEST_STDOUT] = ZLOG_DISABLED;\r\n #endif\r\n \r\n+  /*\r\n+    Initialize zclient \"update\" and \"lookup\" sockets\r\n+   */\r\n+  pim_zebra_init(zebra_sock_path);\r\n+\r\n   zlog_notice(\"Loading configuration - begin\");\r\n \r\n   /* Get configuration file. */\r\n@@ -278,12 +283,6 @@ int main(int argc, char** argv, char** envp) {\r\n   zlog_notice(\"!HAVE_CLOCK_MONOTONIC\");\r\n #endif\r\n \r\n-\r\n-  /*\r\n-    Initialize zclient \"update\" and \"lookup\" sockets\r\n-   */\r\n-  pim_zebra_init(zebra_sock_path);\r\n-    \r\n   while (thread_fetch(master, &thread))\r\n     thread_call(&thread);\r\n \r\ndonald"}}