mirror of
				https://github.com/librenms/librenms.git
				synced 2024-10-07 16:52:45 +00:00 
			
		
		
		
	@@ -599,4 +599,8 @@ $config['distributed_poller_group']                      = 0;
 | 
			
		||||
$config['distributed_poller_memcached_host']             = 'example.net';
 | 
			
		||||
$config['distributed_poller_memcached_port']             = '11211';
 | 
			
		||||
 | 
			
		||||
// Stats callback system
 | 
			
		||||
$config['callback_post']                                 = 'https://stats.librenms.org/log.php';
 | 
			
		||||
$config['callback_clear']                                = 'https://stats.librenms.org/clear.php';
 | 
			
		||||
 | 
			
		||||
?>
 | 
			
		||||
 
 | 
			
		||||
@@ -1129,4 +1129,15 @@ function convert_delay($delay) {
 | 
			
		||||
    return($delay_sec);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
function guidv4($data) {
 | 
			
		||||
    // http://stackoverflow.com/questions/2040240/php-function-to-generate-v4-uuid#15875555
 | 
			
		||||
    // From: Jack http://stackoverflow.com/users/1338292/ja%CD%A2ck
 | 
			
		||||
    assert(strlen($data) == 16);
 | 
			
		||||
 | 
			
		||||
    $data[6] = chr(ord($data[6]) & 0x0f | 0x40); // set version to 0100
 | 
			
		||||
    $data[8] = chr(ord($data[8]) & 0x3f | 0x80); // set bits 6-7 to 10
 | 
			
		||||
 | 
			
		||||
    return vsprintf('%s%s-%s-%s-%s-%s%s%s', str_split(bin2hex($data), 4));
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
?>
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user