Current User: Guest Login
Please consider registering

Lost Your Password?

Search Forums:


Minimum search word length is 4 characters – Maximum search word length is 84 characters
Wildcard Usage:
*  matches any number of characters    %  matches exactly one character

Problems with system call from another scripts

Reply to Post Add a New Topic

1:47 am
June 12, 2009



posts 7

Hi all,
        I have placed a system call like

system(”perl -config=worldcircle -update >logerrors.txt”);

in a seperate script(  to update stats and  to create awstats  db files in specified path given by DirData parameter in the config file .

But this system call  is not getting executed when i run that program  from Cgi(from browser) and the logerrors.txt looks like that is it is looking for awstats.(ipaddress of the machine).conf(i.e say awstats.  instead of looking for awstats.worldcirle.conf  in the current path .

But inturn this system call is getting executed and it is working  perfectly when i run this program with command line.

so my doubt is that is there any settings for executing program that contains system call  , from the CGI (browser).

Thanks in Advance………….

6:37 am
June 12, 2009



posts 1125


The problem is that AWStats "knows" that you started the program from the browser and it disregards the command line arguments. To solve that, you need to use an environment variable that says AWStats to work as if it had been started from the command line interface :

system("env AWSTATS_DEL_GATEWAY_INTERFACE=1 perl -config=worldcircle -update >logerrors.txt");

11:48 pm
June 15, 2009



hello jean-luc,

                   Thanks a lot,i got my issue resolved,this system  call is perfectly working within the script…Thanks for responding…

Reply to Post

Reply to Topic:
Problems with system call from another scripts

Guest Name (Required):

Guest Email (Required):

NOTE: New Posts are subject to administrator approval before being displayed

Confused Cool Cry Embarassed Frown Kiss Laugh Smile Surprised Wink Yell
Post New Reply

Guest URL (required)

Math Required!
What is the sum of:
12 + 8

About the Forum

Forum Timezone: UTC 1

Most Users Ever Online: 302

Currently Online:
15 Guests

Currently Browsing this Topic:
1 Guest

Forum Stats:

Groups: 2
Forums: 9
Topics: 639
Posts: 2710


There are 257 Members
There have been 304 Guests

There is 1 Admin
There is 1 Moderator

Top Posters:

cssfsu – 55
deepakgupta – 34
albert_newton – 30
cosminpana – 20
DTNMike – 19
ahtshun83 – 17

Recent New Members: raju, todd2taylor, sbdcunha, mansigill1987, ThomasDuh, ThomasKic

Administrators: Jean-Luc (1125 Posts)

Moderators: Jean-Luc (1125 Posts)