Troubleshoot Sitescape email to forum
From PTAGISWiki
Problem: emails to ptagis_support@ptagis.org are not getting posted into the User support forum in sitescape. Test emails were successfully posted a few weeks ago, but today an email came through that should have been entered into the forum and was not. To trace the path of the trouble, I sent an email from an external email address (one that is not registered with sitescape), like this:
Subject: test request to sitescape forum From: Ryan Finnin Day <rday@finninday.net> Date: 1:01 PM To: ptagis_support@ptagis.org Message-ID: <4395FC1A.8070503@finninday.net>
Moments after sending the mail, I received a copy at rday@psmfc.org so I know that the mailing list was parsed and the message was delivered to the members of the list. The alias looks like this on salmo in acctmgr:
ptagis_support: carters, davem, john, nadia, rday, sef_ptagis_support@pitpop.psmfc.org, kristiana.kroneck ptagis.support: ptagis_support
First stop in the logs is chum:/var/log/maillog which has this entry:
Dec 6 13:01:14 chum sendmail[5153]: jB6L1EL05153: from=<rday@finninday.net>, size=918, class=0, nrcpts=1, msgid=<4395FC1A.8070503@finninday.net>, proto=ESMTP, daemon=MTA, relay=blueback [199.170.103.51] Dec 6 13:01:14 chum sendmail[5154]: jB6L1EL05153: forward /home/sef_ptagis_support/.forward.chum: Group writable directory Dec 6 13:01:14 chum sendmail[5154]: jB6L1EL05153: forward /home/sef_ptagis_support/.forward: Group writable directory Dec 6 13:01:14 chum sendmail[5154]: jB6L1EL05153: to=<sef_ptagis_support@chum.psmfc.org>, delay=00:00:00, xdelay=00:00:00, mailer=local, pri=30048, dsn=2.0.0, stat=Sent
So the message was successfully handed off to sef_ptagis_support. Since Sitescape checks for mail every ten minutes, I checked for the POP transaction in the same log, a few lines down...
Dec 6 13:05:11 chum ipop3d[12204]: Login user=sef_ptagis_support host=rufus.psmfc.org [205.230.28.72] nmsgs=1/1 Dec 6 13:05:12 chum ipop3d[12204]: Logout user=sef_ptagis_support host=rufus.psmfc.org [205.230.28.72] nmsgs=0 ndele=1
So far, so good. It looks like the mail was delivered to sef_ptagis_support and was picked up by that user from rufus. So next, I checked the sitescape logs on rufus:/usr/local/sitescape/logs...
rufus.psmfc.org-broker.log:Tue Dec 06 13:05:11: (5109) TaskHandle: task-30:(7193) stdout: Retrieving messages from account sef_ptagis_support@pitpop.psmfc.org... rufus.psmfc.org-broker.log:Tue Dec 06 13:05:12: (5109) TaskHandle: task-30:(7193) stdout: 1 messages retrieved from account sef_ptagis_support@pitpop.psmfc.org, and removed from server.
That looks good...
However, rufus.psmfc.org-emailPostings.log does not have any record of
the message.
The sitescape configuration looks like this:
Sitescape email agent queue
The queue of messages to be delivered by the email agent can be viewed at this location:
- Manage > theZone > ManageNewsSources > emailPostingAgent
> ViewMessages This queue currently has 518 messages waiting to be delivered. Messages have been stuck since the outage of the cluster on Dec 1.
Resolution: file permissions
Tried to post to riaevent forum manually through the sitescape admin web interface. Got a 500 server error. This error showed up in the logs:
ni2_abort (1, "/global/ds1/pitweb/sitescape/hidden/ptagis/tw.ria_saic_events/ni2/dat_F.1", "../../indexlib/index.c", 2657), errno: 13
Looked at the file dat_F.1 and found that it was owned by root instead of nobody. When I set the permissions to be owned by nobody and group other, the manual post to riaevent forum was successful. Did a find on the hidden/ptagis tree for other files owned by root and found 107 files. A spot check on some of those root-owned files shows that they were last touched on Dec 1 when the server outage occurred. Did a "chown -R nobody ." and "chgrp -R other ." to clean up permissions on the whole tree.
