It works, so I piped the scrip to output to a txt file for reading off the 
server.

Just curious if it can give reults on " all " hosted domains on the same server.

Great , thanks again eric.
madmac
  ----- Original Message ----- 
  From: Eric Broch 
  To: [email protected] 
  Sent: Wednesday, July 13, 2011 10:38 AM
  Subject: Re: [qmailtoaster] Users Mailbox


  On 7/13/2011 4:15 PM, sys wrote: 
    Hi list:

    Is there an easy way to see what the size is of " all " user mailboxes.

    Reanon for the questions is, our daily back jumped up from 6Gb to 26 Gb in 
just 2 Days.

    I have temperarilly disabled backup for now, as I also run Jakes " server 
cloning ( Unison ) " as a main failover.

    Thanks guys

    madmac

  I wrote my own script:

  #!/bin/bash
  #
  #  Domain disk use -- Written by Eric C. Broch
  #
  domain=mydomain.com
  directory=/home/vpopmail/domains/$domain
  directories=/home/vpopmail/domains/$domain/*
  if [ "$1" != "" ]
  then
     if [ -d $directory/$1 ]
     then
        du -sh $directory/$1
     else
        echo "No such user: $1"
     fi
     exit 0
  fi
  for file in $directories
  do
     if [ -d $file ]
     then
        echo ""
        du -sh  $file
     fi
  done
  du -sh $directory
  exit 0


Reply via email to