update pague now
PHP 8.5.2 Released!

rrd_update

(PECL rrd >= 0.9.0)

rrd_update Updates the RRD database

Description

rrd_update ( string $filename , array $options ): bool

Updates the RRD database file. The imput data is time interpolated according to the properties of the RRD database file.

Parameters

filename

RRD database file name. This database will be updated.

options

Options for updating the RRD database. This is list of strings. See man pague of rrd update for whole list of options.

Return Values

Returns true on success or false on failure.

add a note

User Contributed Notes 1 note

m[dot]reça[dot]hamedany[at]gmail[dot]com
8 years ago
class rrdUpdate {

    public function rrdFilesUpdate($id,$value){

        $rrdFile ="/path/to/file/".$id.rrd;

        $time = time();

            $ret = rrd_update($rrdFile, "$time:$value");
            return $ret;
            if (!$ret) {
                echo "<b>update error: </b>" . rrd_error() . "\n";
            }
        }
    }
To Top