0

I'm using standard routers2.cgi to display MRTG graphs using .rrd data files in a linux server.

This routers.cgi file reads rrd data files and create MRTG graphs to display them from a web url.

This system is working fine. Only problem is the .png graphs creates with 600 permissions. But it needs 644 permission to display from the web page. So I had to change the permissions manually. How can I fix this, any suggestions?

url:

domain.com/cgi-bin/routers2.cgi

graphs located at:

domain.com/graphs/

apache2 config:

cgi bin: <path>/domain.com/cgi-bin
doc root: <path>/domain.com/public_html/

1 Answer 1

1

Well finally I have fixed it.

It got fix by adding following code in top of the script. In my case a have added it just below the ##CONFIG#START# comment line in the routers2.cgi

umask(0033);

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.