0

Im having a major email issue here where some lines of code in my symfony app were generating an error email. we are talking 300K plus emails coming to my inbox which were generated since last friday.

i think they are stacked up in a buffer. i would like to simply delete this buffer.

my config.yml uses this for swiftmailer config

monolog:
    handlers:
        main:
            type:               fingers_crossed
            action_level:       error
            handler:            grouped
        grouped:
            type:               group
            members:            [streamed, buffered]
        streamed:
            type:               stream
            path:               "%kernel.logs_dir%/%kernel.environment%.log"
            level:              debug
        buffered:
            type:    buffer
            handler: swift
        swift:
            type:               swift_mailer
            from_email:         fromemail@site.com
            to_email:           me@site.com
            subject:            "An Error Occurred!"
            #DEBUG, "DEBUG", "INFO", "WARNING", "ERROR", DEBUG will log everything, INFO will log everything except DEBUG, etc.
            level:              debug

        login:
            type:               stream
            path:               "%kernel.logs_dir%/auth.log"
            level:              info
            channels:           security
swiftmailer:
    transport:  "%mailer_transport%"
    host:       "%mailer_host%"
    encryption: "%mailer_encryption%"
    port:       "%mailer_port%"
    username:   "%mailer_user%"
    password:   "%mailer_password%"
    auth_mode:  "%mailer_auth_mode%"
    logging:    true**strong text**

I have already changed the subject in the config to recognize if its new emails, or old emails coming down, but i have yet to see a single email with the new subject, so there must be a large queue line in the hundreds of K's somewhere. I looked in app/cache/ but didnt find anything logical in there to inspect.

Im not well versed in swiftmailer, does anybody know anythign abotu the internals, i.e. where the buffers might be stored, or emails queued?

blamb
  • 4,220
  • 4
  • 32
  • 50

1 Answers1

0

ok i found the answer. I later realized by inspecting the server using iotop that exim had them queued up. This page has an excellent article on this.

they are deleted like this, after stopping exim.

find /var/spool/exim -mindepth 2 -type f -exec rm -rf {} \;
blamb
  • 4,220
  • 4
  • 32
  • 50
  • What page? There's no link. – qooplmao Sep 26 '14 at 09:01
  • looks like now all i have to do is wait out the exchange server to process the remaining that were already sent, its taking days on end, since `$ exim -bpc` shows 0, which means they are no longer being generated. – blamb Sep 26 '14 at 18:31
  • Is this of any help? http://www.cyberciti.biz/faq/exim-remove-all-messages-from-the-mail-queue/ – qooplmao Sep 26 '14 at 20:20
  • well i saw that link at first, thanks. the one i added seemed to be a bit more helpful since it seemed to be a bit more concrete in what it was doing. but yes its helpful. BY THE WAY, the other half of the million emails already landed on the exchange server, and i had to convert it to a pop3 account just get bring them all down in a timely fashion. that just completed a couple hours ago FINALLY, i feel liberated from email hell. – blamb Oct 01 '14 at 01:48