Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

size of database

Status
Not open for further replies.

Scunningham99

Programmer
Sep 20, 2001
815
GB
Hi

I want to know the size of my vowkrs database.

I am trying to run the command


function getDbSize(vworks){
$size=shell_exec("du -b /var/lib/mysql/vworks");
$size=explode(' ',$size);
return $size[0];
}

but am unsure if it is correct and where to run it from?

As you can tell I have no experience of mysql at all so please be gentle :)


Sy UK
 
This
Code:
function getDbSize(vworks){
$size=shell_exec("du -b /var/lib/mysql/vworks");
$size=explode(' ',$size);
return $size[0];
}
is a php function, specifically for a *nix platform.






______________________________________________________________________
There's no present like the time, they say. - Henry's Cat.
 
du -h /path/to/database_dir

______________________________________________________________________
There's no present like the time, they say. - Henry's Cat.
 
just so you know that when folks specify *nix, they generally mean UNIX, LINUX, Mac OSX etc.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top