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.

Possible to auto delete old emails after x number of days?

Discussion in 'E-mail Discussions' started by osmium489, Apr 3, 2014.

  1. osmium489

    osmium489 Registered

    Joined:
    Apr 3, 2014
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Website Owner
    I would like to be able to automatically delete anything from my inbox that's older than 30 days. I was trying this as a Cron job but haven't gotten it to work, the info in the curly braces is where I put my email info in:

    /usr/bin/archivemail --quiet --delete --days 30 /home/{mycpanelusername}/mail/{mydomain.com}/{myemailname}/inbox

    Is something wrong with this or is there a better way to go about this?
     
  2. vanessa

    vanessa Well-Known Member
    PartnerNOC

    Joined:
    Sep 26, 2006
    Messages:
    817
    Likes Received:
    22
    Trophy Points:
    18
    Location:
    Virginia Beach, VA
    cPanel Access Level:
    DataCenter Provider
  3. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,723
    Likes Received:
    660
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    Yes, the thread referenced in the previous post should help you to setup a cron job to remove emails at a set time period. In particular, this post:

    Cron Job To Remove Emails

    Thank you.
     
Loading...

Share This Page