File permission "mask" for cacti.log creation

Post support questions that directly relate to Linux/Unix operating systems.

Moderators: Developers, Moderators

Post Reply
mdw162
Posts: 23
Joined: Fri Feb 04, 2005 7:49 pm

File permission "mask" for cacti.log creation

Post by mdw162 »

When poller.php is run through cron, the cron or "cactiuser" user needs write access to log/cacti.log for logging to happen. On the other hand, clearing the log file under the "System Utilities" page works only if the web server user (usually "apache" or "nobody") has write permission on that file.

It's easy enough to set the permissions as needed, but when you "clear" the log the PHP script recreates it according to the file system permissions "mask." In my case that's rw-r--r-- permissions. Is it possible to have PHP set the permissions as rw-rw-r-- when it creates the file?
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

This issue is going away in the next version of cacti. :)

No more permission issues, the log is moving into the database. And there will be neat and configurable purning options.
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
JVandermark
Posts: 14
Joined: Tue Dec 14, 2004 9:54 am

Post by JVandermark »

Great! I always wondered why Cacti logged to the file system rather than the DB. :D
User avatar
TheWitness
Developer
Posts: 16997
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Post by TheWitness »

JVandermark,

There is a place for you to poll statistics on this board. Why don't you take advantage of it. ;-)

TheWitness
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests