PLEASE HELP!! URGENT!  How can I see howmuch disk space I have left?

Posted on 2005-04-26
Last Modified: 2010-04-20
I am having major problems with my server, and one of the errors was a mysql 1030 - which means no disk space left.

How can I see what's going on with my server space?
Question by:foreverdita
    LVL 13

    Assisted Solution

    Execute df -k from a command prompt. It will show you how much space is used in each of your filesystems.
    LVL 6

    Assisted Solution

    or a more useful use of df is:

    df -hT  (gives sizes in GB and displays the filesystem type)

    Author Comment

    OK, I checked this.  The problem is my root partition has no more space left.  It contains all the website information including the database.  Other partitions have tons of space left.  Can someone help me move some stuff to another partition to clear up some space?

    LVL 6

    Accepted Solution

    What you could do is run the following commands:

    as root:
    du -h --max-depth=1            which will tell you roughly how much space is used under each top level directory. Then consider moving one of the larger ones off to the other partitions. The place a symbolic link between the old location and the new one thus:

    cd /
    ln -s /some/partition/dir/usr /usr

    this will in effect allow existing programs to still work but just shift the physical data. Thus allowing you to use the newly free'd space.

    Featured Post

    Highfive Gives IT Their Time Back

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    Join & Write a Comment

    Little introduction about CP: CP is a command on linux that use to copy files and folder from one location to another location. Example usage of CP as follow: cp /myfoder /pathto/destination/folder/ cp abc.tar.gz /pathto/destination/folder/ab…
    Setting up Secure Ubuntu server on VMware 1.      Insert the Ubuntu Server distribution CD or attach the ISO of the CD which is in the “Datastore”. Note that it is important to install the x64 edition on servers, not the X86 editions. 2.      Power on th…
    Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…
    Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

    729 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    15 Experts available now in Live!

    Get 1:1 Help Now