Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
ccmail_header.tpl
System
Hi,
I am using TS 6.1 on Solaris.
While trying to configure and send email from workflow using iw_solution_email.ipl I am facing this ccmail_header.tpl issue.
The iw_solutions_debug.log complains of this error -
========== Generate Command (Mail Header) ==========
/opt/Interwoven/TeamSite/bin/iwpt_compile.ipl -pt reviewer_iwmailheader.tpl -iw_pt-dcr /opt/Interwoven/TeamSite/tmp/task_output1363.xml
========== Generate Output (Mail Header) ==========
<ERROR>
Could not process template: ./ccmail_header.tpl
</ERROR>
Try debugging like this: iwpt_compile ... -ocode ****.ipl; ****.ipl
*************************************************************************************************************
I am using default ccmail_header.tpl. For email_map.cfg file I am using this format -
<emailConf>
<user name="user01" fullname="user 01" email="user01@email.com"/>
</emailConf>
I have also tried to hard code <header> section of ccmail_header.tpl like this -
<headers>
<to>
<iw_value name = 'user01@email.com' />
</to>
</headers>
but it still returns the same error.
Can any body suggest what might be going wrong!!
Thanks in advance.
-PB
Find more posts tagged with
Comments
lhdavis
Did you modify the email_map.cfg file under the /iw-home/local/config/wft/solutions directory or the one under just the /iw-home/local/config/wft directory? I think the solutions workflows and the ccmail_****.tpl files use the one under the solutions directory.
Luke Davis
Open Technology Group, Inc.
luke.davis@med.va.gov
Migrateduser
Thanks for the reply.
My email_map.cfg file location is set at /local/config/wft in iw.cfg file. So I assume that email_map.cfg file should be picked up by ccmail_header.tpl.
But in any case when I am not even refering that email_map.cfg in ccmail_header.tpl and simply hardcoding <to> section, it is still complaining of same errors.
Wondering if some thing else going on here. Can this be due to some missing .pm?
Thanks
-Pankaj
iwovGraduate
Can you post the exact line in your iw.cfg which points to the email map file ? And the exact location of the email_map.cfg file that you think you are using.
Also post your ccmail_header.tpl
Migrateduser
I believe if you are going to use the syntax you're using, you need to di it this way:
<to>
<iw_value name='<addr fullname="Dave Smith">Davidh.Smith@.nike.com</addr>' />
</to>
I, too, pulled out my hair getting this stupid header to do the right thing. You don't need the
fullname
attribute, that's just something we do, but I do think you need the <addr> tag..
Dave Smith
Sr. Software Engineer
Nike, Inc.
(503) 671-4238
DavidH.Smith@nike.com
Migrateduser
> My email_map.cfg file location is set at /local/config/wft in iw.cfg file. So I
> assume that email_map.cfg file should be picked up by ccmail_header.tpl.
This is not a valid assumption. As detailed in the workflow develper's guide, the iwov_emailmap tag tries to read the file iw-home/local/config/wft/solutions/email_map.cfg. It does not use the file specified in iw.cfg because that file (for iwsend_mail.ipl) uses a different format.
The developer's guide also has an example of a hard-wired addresses, with and without the fullname attribute.
Brinko Kobrin
Interwoven Staff Engineer
Migrateduser
Hi,
Yes you are correct. Isn't that confusing that two email script uses two different email_map.cfg file.
After I included correct email_map.cfg file under /wft/solutions directory, iw_solution_email.ipl does work from command prompt. I successfully received emails. But from within workflow for some reason it doesn't work. I am using default author_submit_with_email.wft.
My external task looks like as follows -
<externaltask name="Email_Approver"
owner="user02"
start="t"
description="Please complete the task">
<areavpath v="/default/main/Internal_Audit/Business_Mgmt/US/WORKAREA/testmail"/>
<successors>
<successorset description="Author Content Approval">
<succ v="Approver"/>
</successorset>
</successors>
<command v='/opt/Interwoven/TeamSite/local/config/wft/solutions/iw_solution_email.ipl -t "Approver"'/>
<files>
<file path='New File.txt' comment='please review'/></files>
<activation>
<pred v="AuthorWork"/>
</activation>
<variables>
<variable key="iw_mailheader_pt" value="reviewer_iwmailheader.tpl"/>
<variable key="iw_mailbody_pt" value="reviewer_iwmailbody.tpl"/>
<variable key="iw_mailbody_text_pt" value="reviewer_textbody.tpl"/>
</variables>
</externaltask>
The same command when executed from command prompt (adding Job ID and Task ID) does work without any issue. I also noticed that I have turned debug info ON for iw_solution_email.ipl. When I execute from command prompt, debug information gets logged in the log file. But when I execute from workflow no debug information gets logged. I am wondering if the external task is failing to excute the iw_solution_email.ipl.
Any idea why this may be failing?
Thanks much
-PB
iwovGraduate
I am using default author_submit_with_email.wft
Why not use the configurable author submit wft in the wft/solutions directory ?
Migrateduser
I would imagine if all you need is the default version, it's a lot easier to deal with than the configurable version. WHy make life more complicated?
Dave Smith
Sr. Software Engineer
Nike, Inc.
(503) 671-4238
DavidH.Smith@nike.com
Migrateduser
> But from within workflow for some reason it doesn't work.
What does the system do? Does the external task remain active? Are there any entries in iwtrace, iwevents or iwjoberrors that might give a clue to the problem? Are the execute permissions on iw_solution_email.ipl set for all? If debugging is turned on but nothing is being logged, then it is likely that the script is not running at all.
Brinko Kobrin
Interwoven Staff Engineer
lhdavis
Since it is a perl script you need to supply the path to the perl executable like this:
<command v='/opt/Interwoven/TeamSite/iw-perl/bin/iwperl /opt/Interwoven/TeamSite/local/config/wft/solutions/iw_solution_email.ipl -t "Approver"'/>
Luke Davis
Open Technology Group, Inc.
luke.davis@med.va.gov
Adam Stoller
You only need to supply the path to perl for Windows systems - and it's clear from the earlier post that the person who started this thread is working on Unix.
You would only need it on Unix if you did not have the correct #! line at the beginning of the script and/or if the script file itself were not marked as being executable.
--fish
Senior Consultant, Quotient Inc.
http://www.quotient-inc.com
Migrateduser
What does the system do? Does the external task remain active? Are there any entries in iwtrace, iwevents or iwjoberrors that might give a clue to the problem? Are the execute permissions on iw_solution_email.ipl set for all?
Yes external task remains active.
Only entries in iwevents.log is like this
[Mon Jun 14 14:30:47 2004] user02 author TaskCalledBack Author Submit 0x582 Email Reviewer 1 0x583 0 Finish 839
[Mon Jun 14 14:33:57 2004] user02 author TaskCalledBack Author Submit 0x582 Email Reviewer 1 0x583 0 Finish 1029
doesn't disclose any problem.
iw_solution_email.ipl execution permission is set for every one.
Looks like its an issue with external task itself. Is this possible I am missing a lib module??
-PB
lhdavis
My bad. Good catch, fish (as usual).
Luke Davis
Open Technology Group, Inc.
luke.davis@med.va.gov
Migrateduser
Are you sure that you are looking at the right task? The job spec that you posted earlier had an external task named "Email_Approver". However, the log entries that you posted seem to indicate that an external task named "Email Reviewer 1" successfully executed its callback. Does this task also use iw_solution_email.ipl?
Brinko Kobrin
Interwoven Staff Engineer
Migrateduser
That was because I changed to configurable_author_submit.wft to see if that makes any difference.
But there too it is the same thing.
Now I doubt that my external tasks are not able to execute any command. I just changed the command to execute a test script that just creates a text file. But even that is not working.
Any ideas??
Thanks
-PB
iwovGraduate
Now I doubt that my external tasks are not able to execute any command. I just changed the command to execute a test script that just creates a text file. But even that is not working.
Trun on debug flag in the iw_solution_email.ipl script and check the logs.
To make things simple, you might just want to try running the OOTB solutions workflow without changing. Get that working and then make your changes.
Migrateduser
Debug flag is already turned on. But when executed from within Workflow, the script doesn't even create/add to the log file.
When executed from command line, it does and email works just fine.
I am using OOTB solution WF only (tried both author_submit_with_email.wft and configurable_author_submit.wft).
No success so far.
Both works from command line.
I am doubting that my external task is not able to execute commands for some reason.
Any more ideas??
PB
iwovGraduate
OOTB configurable_author_submit wofklow has email notification disabled by default. Did you change this in configurable_author_submit.cfg ?
Migrateduser
Yes, sorry I didn't mention that before.
I am now more sure of the fact that External Task is not executing any command. I just tried a command
<command v='ls -l'/>
in the external task, even that is not being executed and external task remains active.
Not sure if I am missing any lib module!!!
-PB
Adam Stoller
ls -l won't do much because it is unclear where the output is being directed.
Are you sure your externaltask is being run at all? Perhaps when you made the change to the wft you didn't correctly change the successors?
--fish
Senior Consultant, Quotient Inc.
http://www.quotient-inc.com
Migrateduser
Yes, External task is getting activated but command is not being executed.
Now that I am looking into iwjoberrors.log I am seeing these entries -
[Mon Jun 14 16:08:16 2004] Could not run /opt/Interwoven/TeamSite/iw-perl/bin/iwperl /opt/Interwoven/TeamSite/tmp/test.ipl for task 1433; retrying in 1 minute
[Mon Jun 14 16:09:16 2004] Could not run /opt/Interwoven/TeamSite/iw-perl/bin/iwperl /opt/Interwoven/TeamSite/tmp/test.ipl for task 1433; retrying in 1 minute
[Mon Jun 14 16:10:16 2004] Could not run /opt/Interwoven/TeamSite/iw-perl/bin/iwperl /opt/Interwoven/TeamSite/tmp/test.ipl for task 1433; retrying in 1 minute
[Mon Jun 14 16:11:16 2004] Could not run /opt/Interwoven/TeamSite/iw-perl/bin/iwperl /opt/Interwoven/TeamSite/tmp/test.ipl for task 1433; retrying in 1 minute
[Mon Jun 14 16:12:16 2004] Could not run /opt/Interwoven/TeamSite/iw-perl/bin/iwperl /opt/Interwoven/TeamSite/tmp/test.ipl for task 1433; retrying in 1 minute
Same entry even if I try without iwperl path.
For ls -l command too it makes the same entry.
Doesn't that indicate that for some reason WF engine is not able to execute those commands?
-PB
iwovGraduate
When you said you ran the externaltask script from command line and it works fine, did you try to run:
"/opt/Interwoven/TeamSite/iw-perl/bin/iwperl /opt/Interwoven/TeamSite/tmp/test.ipl" ? If not, see if you can.
Whats in test.ipl ? Can you post it ?
Migrateduser
Yes,
The same exact command works just fine from command prompt.
The content of test.ipl -
open (CHECKBOOK, ">/opt/Interwoven/TeamSite/tmp/checkbook.txt");
If executed from command line this creates a file checkbook.txt under /opt/Interwoven/TeamSite/tmp folder.
But from WF External task this doesn't get executed.
Also as I mentioned before in the iwjoberrors.log I see entries that WF engine can not execute commands like -
[Mon Jun 14 18:13:31 2004] Could not run /opt/Interwoven/TeamSite/iw-perl/bin/iwperl /opt/Interwoven/TeamSite/local/config/wft/examples/sample_external_task.ipl "red" "white" "and blue" for task 1445; retrying in 1 minute
[Mon Jun 14 18:14:31 2004] Could not run /opt/Interwoven/TeamSite/iw-perl/bin/iwperl /opt/Interwoven/TeamSite/local/config/wft/examples/sample_external_task.ipl "red" "white" "and blue" for task 1445; retrying in 1 minute
[Mon Jun 14 18:15:31 2004] Could not run /opt/Interwoven/TeamSite/iw-perl/bin/iwperl /opt/Interwoven/TeamSite/local/config/wft/examples/sample_external_task.ipl "red" "white" "and blue" for task 1445; retrying in 1 minute
This is happening for any command in external task.
-PB
Adam Stoller
Although the error is usually something to do with not being able to 'spawn' a job rather than 'run' a job - how much memory do you have on your server? What else is running on the server machine?
Actually, not being able to 'run' a command is probably more likely a file or directory permission issue - do you have the 'iwui' user defined in the system? defined in the master.uid file? It might not be the 'iwui' access, but I would check the access rights on every directory in the path leading upto and including the script as well as the access rights on the script itself.
The fact that you can run it from the command line would seem to suggest that it's 'iwui' because that's not who you're logged in as when you're running it from the command line, but I believe that's who the externaltask script is run as (Brinko - can you confirm or correct this assessment?)
--fish
Senior Consultant, Quotient Inc.
http://www.quotient-inc.com