[GE users] Error with "export -f" shell (bash) functions

ron ron_chen_123 at yahoo.com
Wed Jan 13 21:04:34 GMT 2010


--- On Thu, 1/14/10, rayson <rayrayson at gmail.com> wrote:
> So, I think it is not too hard to fix this problem -- we
> only need to
> make sure that the closing } is recorded during job
> submission, and it
> is set correctly during the environment variable setup
> stage in shepherd.

IMO, if the function body has more than a few lines, then it would be harder to represent it in the environment file, especially the env file just a flat file.

 -Ron


> 
> Rayson
> 
> 
> 
> 
> On Wed, Jan 13, 2010 at 1:06 PM, craffi <dag at sonsorol.org>
> wrote:
> > This is a known and documented bug with SGE and only
> happens with the
> > use of bash when you define functions within ENV
> variables.
> >
> > The bug report is here:
> >
> > SGE Issue 2173 http://bit.ly/8VzAQc
> >
> > .. consider making an account on the site and casting
> your "vote" for
> > this issue to be fixed.
> >
> > There are some workarounds and I do know people who
> use "modules" and
> > bash but I can't recall offhand what the mitigation
> method was. I'll
> > search through my notes.
> >
> > -Chris
> >
> >
> >
> >
> > madskaddie wrote:
> >> Greetings,
> >>
> >> I installed the GridEngine 6.2u4 (open source
> ver.) and whenever the environment has a shell function
> exported via "export -f func_name", it outputs:
> >>
> >> "
> >> /bin/bash: func_name: line 1: syntax error:
> unexpected end of file
> >> /bin/bash: error importing function definition for
> `func_name'
> >> "
> >> Example:
> >>
> >> qrsh -V date
> >>
> >> bash: module: line 1: syntax error: unexpected end
> of file
> >> bash: error importing function definition for
> `module'
> >> bash: test_fun: line 1: syntax error: unexpected
> end of file
> >> bash: error importing function definition for
> `test_fun
> >>
> >>
> >> Can anybody help me fixing this ?
> >>
> >> Thanks
> >>
> >>
> ------------------------------------------------------
> >> http://gridengine.sunsource.net/ds/viewMessage.do?dsForumId=38&dsMessageId=238562
> >>
> >> To unsubscribe from this discussion, e-mail: [users-unsubscribe at gridengine.sunsource.net].
> >
> >
> ------------------------------------------------------
> > http://gridengine.sunsource.net/ds/viewMessage.do?dsForumId=38&dsMessageId=238580
> >
> > To unsubscribe from this discussion, e-mail: [users-unsubscribe at gridengine.sunsource.net].
> >
> 
> ------------------------------------------------------
> http://gridengine.sunsource.net/ds/viewMessage.do?dsForumId=38&dsMessageId=238597
> 
> To unsubscribe from this discussion, e-mail: [users-unsubscribe at gridengine.sunsource.net].
>

------------------------------------------------------
http://gridengine.sunsource.net/ds/viewMessage.do?dsForumId=38&dsMessageId=238603

To unsubscribe from this discussion, e-mail: [users-unsubscribe at gridengine.sunsource.net].



More information about the gridengine-users mailing list