Could not send email after install discourse by vagrant


(Kun Zhu) #1

I’m new to rails, so I followed the Discourse as your first rails app post to install my discourse by vagrant.I have already run “mc” to make mailchecker run and run “bundle exec sidekiq” to start sidekiq, then when I test the email feature, I got the following error in the /log/development.log :

----==_mimepart_54b5cde7864b9_360d7ec184e38618--

Job exception: Net::ReadTimeout

Job exception: Wrapped Net::ReadTimeout: Net::ReadTimeout

  User Load (4.0ms)  SELECT  "users".* FROM "users"  WHERE "users"."id" = 27 LIMIT 1
  UserAvatar Load (2.4ms)  SELECT  "user_avatars".* FROM "user_avatars"  WHERE "user_avatars"."id" = 24 LIMIT 1
  User Load (4.3ms)  SELECT  "users".* FROM "users"  WHERE "users"."id" = 27 LIMIT 1
  UserAvatar Load (4.1ms)  SELECT  "user_avatars".* FROM "user_avatars"  WHERE "user_avatars"."id" = 24 LIMIT 1
  User Load (2.3ms)  SELECT  "users".* FROM "users"  WHERE "users"."id" = $1 LIMIT 1  [["id", 27]]
  User Load (3.7ms)  SELECT  "users".* FROM "users"  WHERE "users"."id" = $1 LIMIT 1  [["id", 27]]
  Post Load (11.7ms)  SELECT "posts".* FROM "posts"  WHERE ("posts"."deleted_at" IS NULL) AND "posts"."deleted_at" IS NULL AND "posts"."user_deleted" = 't' AND (NOT EXISTS (
            SELECT 1 FROM topics t
            WHERE t.deleted_at IS NOT NULL AND
                  t.id = posts.topic_id
        )) AND (updated_at < '2015-01-13 02:03:40.620802' AND post_number > 1) AND (NOT EXISTS (
                  SELECT 1
                  FROM post_actions pa
                  WHERE pa.post_id = posts.id AND
                        pa.deleted_at IS NULL AND
                        pa.post_action_type_id IN (3,4,7,8)
              ))
  User Load (3.0ms)  SELECT  "users".* FROM "users"  WHERE "users"."id" = 27 LIMIT 1
  UserAvatar Load (1.5ms)  SELECT  "user_avatars".* FROM "user_avatars"  WHERE "user_avatars"."id" = 24 LIMIT 1
  User Load (0.7ms)  SELECT  "users".* FROM "users"  WHERE "users"."id" = $1 LIMIT 1  [["id", 27]]
Job exception: Connection timed out - connect(2)

Job exception: Connection timed out - connect(2)

Job exception: Wrapped Errno::ETIMEDOUT: Connection timed out - connect(2)

Job exception: Wrapped Errno::ETIMEDOUT: Connection timed out - connect(2)

  User Load (2.2ms)  SELECT  "users".* FROM "users"  WHERE "users"."id" = 27 LIMIT 1
  UserAvatar Load (1.3ms)  SELECT  "user_avatars".* FROM "user_avatars"  WHERE "user_avatars"."id" = 24 LIMIT 1
  User Load (0.5ms)  SELECT  "users".* FROM "users"  WHERE "users"."id" = $1 LIMIT 1  [["id", 27]]
Job exception: Connection timed out - connect(2)

Job exception: Wrapped Errno::ETIMEDOUT: Connection timed out - connect(2)

Job exception: Connection timed out - connect(2)

Job exception: Wrapped Errno::ETIMEDOUT: Connection timed out - connect(2)

   (4.4ms)  SELECT COUNT(*) AS count_all, visited_at AS visited_at FROM "user_visits"  WHERE (visited_at >= '2014-12-14' and visited_at <= '2015-01-14') GROUP BY visited_at  ORDER BY "user_visits"."visited_at" ASC
   (4.4ms)  SELECT COUNT(*) AS count_all, date(created_at) AS date_created_at FROM "users"  WHERE (id > 0) AND (created_at >= '2014-12-14 00:00:00.000000' and created_at <= '2015-01-14 23:59:59.999999') GROUP BY date(created_at)  ORDER BY date(created_at)
   (1.5ms)  SELECT COUNT(*) FROM "users"  WHERE (id > 0)
   (2.3ms)  SELECT COUNT(*) FROM "users"  WHERE (id > 0) AND (created_at >= '2014-11-14 00:00:00.000000' and created_at < '2014-12-14 00:00:00.000000')
   (6.0ms)  SELECT COUNT(*) AS count_all, date(created_at) AS date_created_at FROM "topics"  WHERE ("topics"."deleted_at" IS NULL) AND (topics.archetype <> 'private_message') AND (created_at >= '2014-12-14 00:00:00.000000' and created_at <= '2015-01-14 23:59:59.999999') GROUP BY date(created_at)  ORDER BY date(created_at)
   (2.2ms)  SELECT COUNT(*) FROM "topics"  WHERE ("topics"."deleted_at" IS NULL) AND (topics.archetype <> 'private_message')
   (2.3ms)  SELECT COUNT(*) FROM "topics"  WHERE ("topics"."deleted_at" IS NULL) AND (topics.archetype <> 'private_message') AND (topics.created_at >= '2014-11-14 00:00:00.000000' and topics.created_at < '2014-12-14 00:00:00.000000')
   (6.5ms)  SELECT COUNT(*) AS count_all, date(posts.created_at) AS date_posts_created_at FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype <> 'private_message') AND (posts.created_at >= '2014-12-14 00:00:00.000000' AND posts.created_at <= '2015-01-14 23:59:59.999999') GROUP BY date(posts.created_at)  ORDER BY date(posts.created_at)
   (4.2ms)  SELECT COUNT(*) FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype <> 'private_message')
   (4.3ms)  SELECT COUNT(*) FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype <> 'private_message') AND (posts.created_at >= '2014-11-14 00:00:00.000000' and posts.created_at < '2014-12-14 00:00:00.000000')
   (4.7ms)  SELECT COUNT(*) AS count_all, date(created_at) AS date_created_at FROM "post_actions"  WHERE ("post_actions"."deleted_at" IS NULL) AND (created_at >= '2014-12-14 00:00:00.000000' and created_at <= '2015-01-14 23:59:59.999999') AND "post_actions"."post_action_type_id" IN (3, 4, 7, 8) GROUP BY date(created_at)  ORDER BY date(created_at)
   (2.2ms)  SELECT COUNT(*) FROM "post_actions"  WHERE ("post_actions"."deleted_at" IS NULL) AND "post_actions"."post_action_type_id" IN (3, 4, 7, 8)
   (2.4ms)  SELECT COUNT(*) FROM "post_actions"  WHERE ("post_actions"."deleted_at" IS NULL) AND "post_actions"."post_action_type_id" IN (3, 4, 7, 8) AND (post_actions.created_at >= '2014-11-14 00:00:00.000000' and post_actions.created_at < '2014-12-14 00:00:00.000000')
   (2.9ms)  SELECT COUNT(*) AS count_all, trust_level AS trust_level FROM "users"  WHERE (id > 0) GROUP BY trust_level
   (2.4ms)  SELECT COUNT(*) AS count_all, date(created_at) AS date_created_at FROM "post_actions"  WHERE "post_actions"."post_action_type_id" = 2 AND (created_at >= '2014-12-15 02:06:40.382497') GROUP BY date(created_at)  ORDER BY date(created_at)
   (1.9ms)  SELECT COUNT(*) FROM "post_actions"  WHERE "post_actions"."post_action_type_id" = 2
   (2.0ms)  SELECT COUNT(*) FROM "post_actions"  WHERE "post_actions"."post_action_type_id" = 2 AND (post_actions.created_at >= '2014-11-14 00:00:00.000000' and post_actions.created_at < '2014-12-14 00:00:00.000000')
   (2.2ms)  SELECT COUNT(*) AS count_all, date(created_at) AS date_created_at FROM "post_actions"  WHERE "post_actions"."post_action_type_id" = 1 AND (created_at >= '2014-12-15 02:06:40.425335') GROUP BY date(created_at)  ORDER BY date(created_at)
   (2.4ms)  SELECT COUNT(*) FROM "post_actions"  WHERE "post_actions"."post_action_type_id" = 1
   (2.5ms)  SELECT COUNT(*) FROM "post_actions"  WHERE "post_actions"."post_action_type_id" = 1 AND (post_actions.created_at >= '2014-11-14 00:00:00.000000' and post_actions.created_at < '2014-12-14 00:00:00.000000')
   (5.0ms)  SELECT COUNT(*) AS count_all, date(created_at) AS date_created_at FROM "email_logs"  WHERE (created_at >= '2014-12-14 00:00:00.000000' and created_at < '2015-01-14 23:59:59.999999' AND skipped = false) GROUP BY date(created_at)  ORDER BY date(created_at)
   (2.0ms)  SELECT COUNT(*) FROM "email_logs"
   (2.1ms)  SELECT COUNT(*) FROM "email_logs"  WHERE (created_at >= '2014-11-14 00:00:00.000000' and created_at < '2014-12-14 00:00:00.000000')
   (5.7ms)  SELECT COUNT(*) AS count_all, date(posts.created_at) AS date_posts_created_at FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'user_to_user') AND (posts.created_at > '2014-12-15 02:06:40.521349') GROUP BY date(posts.created_at)  ORDER BY date(posts.created_at)
   (4.3ms)  SELECT COUNT(*) FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'user_to_user')
   (3.1ms)  SELECT COUNT(*) FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'user_to_user') AND (posts.created_at >= '2014-11-14 00:00:00.000000' and posts.created_at < '2014-12-14 00:00:00.000000')
   (3.7ms)  SELECT COUNT(*) AS count_all, date(posts.created_at) AS date_posts_created_at FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'system_message') AND (posts.created_at > '2014-12-15 02:06:40.586899') GROUP BY date(posts.created_at)  ORDER BY date(posts.created_at)
   (3.0ms)  SELECT COUNT(*) FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'system_message')
   (3.7ms)  SELECT COUNT(*) FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'system_message') AND (posts.created_at >= '2014-11-14 00:00:00.000000' and posts.created_at < '2014-12-14 00:00:00.000000')
   (3.7ms)  SELECT COUNT(*) AS count_all, date(posts.created_at) AS date_posts_created_at FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'moderator_warning') AND (posts.created_at > '2014-12-15 02:06:40.645344') GROUP BY date(posts.created_at)  ORDER BY date(posts.created_at)
   (3.4ms)  SELECT COUNT(*) FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'moderator_warning')
   (3.5ms)  SELECT COUNT(*) FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'moderator_warning') AND (posts.created_at >= '2014-11-14 00:00:00.000000' and posts.created_at < '2014-12-14 00:00:00.000000')
   (3.8ms)  SELECT COUNT(*) AS count_all, date(posts.created_at) AS date_posts_created_at FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'notify_moderators') AND (posts.created_at > '2014-12-15 02:06:40.710100') GROUP BY date(posts.created_at)  ORDER BY date(posts.created_at)
   (4.3ms)  SELECT COUNT(*) FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'notify_moderators')
   (3.1ms)  SELECT COUNT(*) FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'notify_moderators') AND (posts.created_at >= '2014-11-14 00:00:00.000000' and posts.created_at < '2014-12-14 00:00:00.000000')
   (3.8ms)  SELECT COUNT(*) AS count_all, date(posts.created_at) AS date_posts_created_at FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'notify_user') AND (posts.created_at > '2014-12-15 02:06:40.768593') GROUP BY date(posts.created_at)  ORDER BY date(posts.created_at)
   (2.7ms)  SELECT COUNT(*) FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'notify_user')
   (5.0ms)  SELECT COUNT(*) FROM "posts" INNER JOIN "topics" ON "topics"."id" = "posts"."topic_id" AND ("topics"."deleted_at" IS NULL) WHERE ("posts"."deleted_at" IS NULL) AND (topics.archetype = 'private_message') AND (topics.subtype = 'notify_user') AND (posts.created_at >= '2014-11-14 00:00:00.000000' and posts.created_at < '2014-12-14 00:00:00.000000')
   (1.9ms)  SELECT COUNT(*) FROM "users"  WHERE "users"."admin" = 't'
   (0.9ms)  SELECT COUNT(*) FROM "users"  WHERE "users"."moderator" = 't'
   (1.0ms)  SELECT COUNT(*) FROM "users"  WHERE (suspended_till IS NOT NULL AND suspended_till > '2015-01-14 02:06:40.885726')
   (0.9ms)  SELECT COUNT(*) FROM "users"  WHERE "users"."blocked" = 't'
   (1.6ms)  SELECT COUNT(*) AS count_all, users.username AS users_username FROM "incoming_links" INNER JOIN "users" ON "users"."id" = "incoming_links"."user_id" WHERE (incoming_links.created_at > '2014-12-15 02:06:40.896563' AND incoming_links.user_id IS NOT NULL) GROUP BY users.username
   (1.8ms)  SELECT COUNT(DISTINCT posts.topic_id) AS count_distinct_posts_topic_id, users.username AS users_username FROM "incoming_links" INNER JOIN "users" ON "users"."id" = "incoming_links"."user_id" INNER JOIN "posts" ON "posts"."id" = "incoming_links"."post_id" AND ("posts"."deleted_at" IS NULL) WHERE (incoming_links.created_at > '2014-12-15 02:06:40.896563' AND incoming_links.user_id IS NOT NULL) GROUP BY users.username
   (3.1ms)  SELECT  COUNT(*) AS count_all, incoming_domains.name AS incoming_domains_name FROM "incoming_links" INNER JOIN "incoming_referers" ON "incoming_referers"."id" = "incoming_links"."incoming_referer_id" INNER JOIN "incoming_domains" ON "incoming_domains"."id" = "incoming_referers"."incoming_domain_id" WHERE (incoming_links.created_at > '2014-12-15 02:06:40.948493') GROUP BY incoming_domains.name  ORDER BY count_all DESC LIMIT 10
   (1.3ms)  SELECT COUNT(DISTINCT posts.topic_id) AS count_distinct_posts_topic_id, incoming_domains.name AS incoming_domains_name FROM "incoming_links" INNER JOIN "incoming_referers" ON "incoming_referers"."id" = "incoming_links"."incoming_referer_id" INNER JOIN "incoming_domains" ON "incoming_domains"."id" = "incoming_referers"."incoming_domain_id" INNER JOIN "posts" ON "posts"."id" = "incoming_links"."post_id" AND ("posts"."deleted_at" IS NULL) WHERE (incoming_links.created_at > '2014-12-15 02:06:41.178057' AND incoming_domains.name IN (NULL)) GROUP BY incoming_domains.name
   (1.2ms)  SELECT COUNT(*) AS count_all, topic_id AS topic_id FROM "incoming_links" INNER JOIN "posts" ON "posts"."id" = "incoming_links"."post_id" AND ("posts"."deleted_at" IS NULL) WHERE (incoming_links.created_at > '2014-12-15 02:06:41.186129' AND topic_id IS NOT NULL) GROUP BY topic_id

Is there anything else I can to to make it work?