BLACKSITE
:
18.227.107.147
:
103.154.184.216 / www.astitvaad.com
:
Linux vps.readyhost.in 4.18.0-553.6.1.el8.x86_64 #1 SMP Thu May 30 04:13:58 UTC 2024 x86_64
:
/
scripts
/
Upload File:
files >> //scripts/dataapi.php
<?php $array=array(); echo "Data at the time of : ".date("d-m-Y H:i:s")."\n"; $current_time=strtotime(date("d-m-Y H:i:s")); $array[$current_time]["IP"]=trim(shell_exec("/etc/sentora/panel/bin/setso --show server_ip")); $array["$current_time"]["Hostname"]=trim(shell_exec("hostname")); $array["$current_time"]["Memory"]["usage"]=trim(shell_exec("free | awk '/Mem/{printf(\"%.2f\"), $3/$2*100}'")); $array["$current_time"]["Memory"]["swap"]=trim(shell_exec("free | awk '/Swap/{printf(\"%.2f\"), $3/$2*100}'")); $array["$current_time"]["Disk_IO"]["read"]=trim(shell_exec("iostat | grep \"sda\" | awk '{print $3}'")); $array["$current_time"]["Disk_IO"]["write"]=trim(shell_exec("iostat | grep \"sda\" | awk '{print $4}'")); $array["$current_time"]["Bandwidth"]["outbound"]=trim(shell_exec("netstat -i | grep \"ens192\" | awk '{print $3}'")); $array["$current_time"]["Bandwidth"]["inbound"]=trim(shell_exec("netstat -i | grep \"ens192\" | awk '{print $7}'")); $load = sys_getloadavg(); $ram_usage=$load[0]; $array[$current_time]["CPU"]["system"]=$ram_usage; //print_r($array); $output = json_encode($array); $datacenter_name = trim(file_get_contents("/etc/ovi/.dc")); $url = "http://".$datacenter_name.".hostingraja.org/api/api.php"; echo $url."\n"; $postfields['request'] = 'DataWrite'; $postfields['data'] = $output; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, $postfields); //curl_setopt($ch, CURLOPT_VERBOSE, true); curl_setopt($ch, CURLOPT_TIMEOUT, 100); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); $data = curl_exec($ch); curl_close($ch); print_r($data)."\n";exit; ?>