CruzIT
Monday June 21, 2021 - 12:09:24 AM

Registered Linux User #440901    


 
Login    Register
Login Required

HowTo Get Disk Information

Copy and paste this code into the page you want to show disk information for your web server:

<p>
<?php
// set partition
$fs = "/";
// display available and used space
echo "Total available space on this partition: " . 
round(disk_total_space($fs) / (1024*1024)) . " MB\r\n<br />"; 
echo "Total free space: " . round(disk_free_space($fs) / (1024*1024)) . " MB\r\n<br />";
// calculate used space
$disk_used_space =
round((disk_total_space($fs) - disk_free_space($fs)) / (1024*1024)); 
echo "Total used space: " . $disk_used_space . " MB\r\n<br />";
// calculate % used space
echo "% used space: " . round((disk_total_space($fs) -
disk_free_space($fs)) / disk_total_space($fs) * 100) . " %";
?>
</p>

That should produce something like this:

Total available space on this partition: 38243 MB
Total free space: 19147 MB
Total used space: 19096 MB
% used space: 50 %

Collecting For A Server Upgrade  

Howto display uptime information like:

Time since last reboot: 9 days, 15 hours, 3 minutes , 55 seconds

 

“Windows - Just Say No”

@ Active Member Project Honeypot  email addresses

This page was last modified on 09/1/18 @ 10:33:50:pm
This file name: howto_diskinfo.php

Questions, Comments, Suggestions or Requests should be sent to:  ronnie@cruzit.com 

There have been  8861  Unique Visitors (IP Addresses) to this site.

Current users online : 24
Maximum users at a time : 38
Last 25 attacks have come from:
142.111.24.10
144.202.46.151
18.229.73.207
183.90.173.95
148.66.6.44
191.96.150.237
13.233.73.212
62.4.16.234
35.180.147.121
51.89.217.135
206.189.24.134
3.8.12.221
157.55.39.63
132.148.130.78
185.49.20.75
37.187.74.49
34.209.105.222
204.44.88.35
46.133.106.68
18.194.196.202
216.177.141.15
40.77.167.97
207.46.13.137
176.123.9.123
178.62.76.138

There are currently 25 unique IP addresses blacklisted.

Public cruzit.com Server Status
server online dbc001  db cluster service
 Is On-Line
server online www03  web service
 Is On-Line
server online www  web service
 Is On-Line
server online mx 08  mail service
 Is On-Line
server online www ha  F/O web service
 Is On-Line
server online mx 11  mail service
 Is On-Line
server online tertiary  DNS service
 Is On-Line
server online mx 10  mail service
 Is On-Line

©Copyright 2004-2021 - cruzit.com - Redd Enterprises™, Inc.,  All Rights Reserved.
Ubuntu® is a registered trademark of Canonical Ltd.
Linux® is a registered trademark of Linus Torvalds.
Apache® is a registered trademark of The Apache Software Foundation.
PHP® is a registered trademark of The PHP Group.
MySQL® is a registered trademark of MySQL AB in the United States, the European Union and other countries.
All other product and service names mentioned are the trademarks of their respective companies.

 

pretrial
pretrial
pretrial
pretrial
Let us know what you think! finance@homelandcomputersecurity.com