Russ Thompson on 9 Apr 2012 11:50:39 -0700


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: [PLUG] Why does -t option of ssh cause mail to not be sent?...


Before calling your script, perhaps source /etc/profile so the appropriate environment paths are set.  The sourcing should be done during connection, prior to running your script.

I've ran into issues like this before with ptty and it was usually environment related, but in your case, doesn't make a ton of sense since it works with different conditions (sleep etc).

Is the script executing cleanly by viewing the return variable $?

- Russ



On Mon, Apr 9, 2012 at 2:22 PM, Martin Dellwo <martin.dellwo@gmail.com> wrote:
Just out of curiosity, can you try it with tcsh instead of csh?  Or with bash?


On Mon, Apr 9, 2012 at 1:58 PM, Pat Barron <pat@lectroid.com> wrote:
On 04/09/2012 1:54 PM, Fred Stluka wrote:
I'm not having any trouble finding the junk script.  It runs just fine.
The only problem is that the mail doesn't get sent unless there is
enough stuff after it in the script to give the mail time to be sent
before the script ends.  So, specifying the full path to the junk script
should not matter, right?

I wonder if, because you're attached to a terminal, the mail process is catching a SIGHUP or something and dying when the script ends?  Maybe try invoking the mailer with "nohup"?

--Pat.


___________________________________________________________________________
Philadelphia Linux Users Group         --        http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug



--
Martin Dellwo
cell: (484) 437-3662
martin.dellwo@gmail.com
http://www.linkedin.com/in/martindellwo


___________________________________________________________________________
Philadelphia Linux Users Group         --        http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug


___________________________________________________________________________
Philadelphia Linux Users Group         --        http://www.phillylinux.org
Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce
General Discussion  --   http://lists.phillylinux.org/mailman/listinfo/plug