Announcement

Collapse
No announcement yet.

Calling BC2 from a perl/CGI script.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Calling BC2 from a perl/CGI script.

    Hello.
    Ive come across a problem i havent been able to figure out - at all !
    Ive written a file-report formatting script which is then called from a Perl cgi file. When i execute the script(standard perl file) on the command prompt it works fine !!

    But when i try to execute the script calling the perl file from the cgi file. (i.e. have a link in a cgi file that kicks it off ) i.e. ( system(C:\bc2\bc2.exe @C:\script.txt) ) it seems to just hang ? This is in a windows environment.

    Is this a permissions thing?, ive read other posts about bc only being able to run as admin/domain admin user and perhaps apache runs the cgi script as an under priledged user?. Ive tried countless amounts of things about none of them seem to work ( runAs doesnt work cause its interactive only.) Me and my company are registered users of BC. And supports of it alot !! Any help will be appreciated !
    if anyone can help me please email
    - tkhuu@au1.ibm.com
    much appreciated.

    Regards,

  • #2
    Re: Calling BC2 from a perl/CGI script.

    I've run across similar problems, but using Tomcat under Windows. Applets/Scripts I write run successfully interactively, or while debugging under Eclipse (but of course, Eclipse is launched using my credentials, and it launches Tomcat in a debug mode, again using my credentials).

    It is a permission/authentication problem. Tomcat runs under a "LocalSystem" account. This account cannot access network resources, so if your BC2 script is referencing network resources, it will probably hang.

    I've also tried running BC2 scripts off the Windows scheduler to periodically backup my files to a network share. This fails for the same reason.

    One way I got around this was to configure the Tomcat service and the Windows Scheduled Task to start using my credentials (userid/password). This may work with Apache, but I don't know if CGI support would require additional configuration changes.

    Comment

    Working...
    X