The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

how to remove emails via ssh

Discussion in 'E-mail Discussions' started by ccccanada, Aug 12, 2003.

  1. ccccanada

    ccccanada Well-Known Member

    Joined:
    Jan 17, 2003
    Messages:
    279
    Likes Received:
    0
    Trophy Points:
    16
    can someone please tell me how to empty an email account that has 11000 emails in it from ssh.

    what would be the command to empty a certain users emailbox.

    Thanks

    cPanel.net Support Ticket Number:
     
  2. ciphervendor

    ciphervendor Well-Known Member

    Joined:
    Aug 26, 2002
    Messages:
    1,052
    Likes Received:
    0
    Trophy Points:
    36
    Code:
    echo -n > /home/USERNAME/mail/DOMAIN.COM/MAILUSER/inbox
     
  3. ccccanada

    ccccanada Well-Known Member

    Joined:
    Jan 17, 2003
    Messages:
    279
    Likes Received:
    0
    Trophy Points:
    16
    Thank you!

    I have been searching everywhere to find that.
    It works great.

    cPanel.net Support Ticket Number:
     
  4. sparek-3

    sparek-3 Well-Known Member

    Joined:
    Aug 10, 2002
    Messages:
    1,384
    Likes Received:
    23
    Trophy Points:
    38
    cPanel Access Level:
    Root Administrator
    You should be able to use just

    Code:
    >/home/user/mail/domain.com/mailbox/inbox
    
    but the above line should work as well.

    cPanel.net Support Ticket Number:

    cPanel.net Support Ticket Number:
     
  5. ciphervendor

    ciphervendor Well-Known Member

    Joined:
    Aug 26, 2002
    Messages:
    1,052
    Likes Received:
    0
    Trophy Points:
    36
    There's a reason for the echo -n, I didn't just write it because I was feeling good about myself.

    cPanel.net Support Ticket Number:
     
Loading...

Share This Page