What is qmail send




















Archived Forums. Exchange Server This forum provides a place for you to discuss the Exchange You are welcome to come and post questions and comments about your experience with this software. Sign in to vote. Hi, I have just one user on our Exchange server who has reported that a few people have tried to email him and get the following bounceback. Monday, June 24, AM. Luo 0. Hi Lolly, Is this an issue with an external company? Best regards. Tuesday, June 25, AM. With all due respect to Zi Feng, you have not addressed the problem.

I do not think you understand the nature of the problem. So we sent an e-mail to qmail in a futile attempt to get an answer; copy below of response note obvious e-mail change : Hi. Wednesday, February 22, PM. The daemontools package provides a consistent way to run continuous daemons, optionally but almost invariably also arranging to collect log information that the daemons produce. For each daemon to be controlled, supervise uses a directory containing information about the daemon. The only file that you must create in that directory is run , the program to run.

Once supervise is running, you can use the svc program to stop and start the daemon, and send signals to it. Every five seconds it looks again and creates new processes for any new subdirectories. If a subdirectory has a sub-subdirectory called log , svscan arranges to log the output of the program.

In this case, it starts a pair of processes connected by a pipe, equivalent to:. The log subdirectory contains a run file that invariably runs multilog to write the output into a rotating set of log files. One of the least standardized aspects of Unix and Unix-like systems is the way that you start daemons at system boot time. Even if you use supervise as I recommend, you still must start the svscan daemon to get everything else going.

Here are some hints to start svscan. If you ignore my advice and run daemons directly, start each of them the way I recommend you start svscan.

Versions 0. It sets up the environment and runs svscan , piping its output into a new program called readproctitle that copies anything it reads on top of its program arguments, which means that any error messages from svscan will show up in ps listings in the arguments to readproctitle. If not, just run svscanboot from a root shell prompt, detaching it from the terminal:.

Then, to tell the system to rescan inittab , type:. Again, check with ps to be sure that svscan is running. The final hurdle before starting up qmail is to create a minimal set of configuration files. I suggest you run the config script, then look at the files to see what it did and fix the files up as needed. The ones you need to create include:.

The name of this host, e. This provides the default to use for many other configuration files. The hostname to add to unqualified addresses in submitted mail.

If your email addresses are of the form mailbox example. Note that this rewriting happens only to locally submitted mail sent via qmail-inject , not to mail that arrives via SMTP. The domain to add to unqualified domains in submitted mail addresses, usually your base domain, such as example.

This would rewrite fred duluth to fred duluth. This rewriting also happens only in locally submitted mail. Domain names to be delivered locally, one per line. Mail to any domain listed in locals is delivered by treating the mailbox part as a local address.

This usually contains the name of the host and the name of the domain used for user mailboxes, such as example. Do not list virtual domains domains hosted on this machine but with their own separate sets of mailboxes in locals. I discuss them later. Domains for which this host should accept mail via SMTP.

This generally contains all of the domains in locals , as well as any virtual domains and any domains for which this host is a backup mail server. Be sure your rcpthosts file exists before starting qmail. Starting qmail is easy in principle. You run qmail-start and it starts the four communicating daemons that qmail needs. Two details complicate the situation: the default delivery instructions, and connecting the daemons to whatever you want to use for logging. I find daemontools greatly preferable, so I primarily discuss how to set up qmail using supervise.

Qmail 1. The differences among them only affect what happens when mail is delivered to a user who has no. They include:. Same as binm1 , also providing dot-forward emulation. Same as binm2 , also providing dot-forward emulation.

Same as binm3 , also providing dot-forward emulation. Same as home , also providing dot-forward emulation. Same as proc , also providing dot-forward emulation. Which flavor of startup depends mostly on your existing mail configuration. If you use procmail, keep using it. If you have a lot of users with. If you only have a few. For testing and usually for production, I suggest either plain home-directory mailbox delivery or procmail.

Create them like this as the super-user, which is why the following command lines start with a prompt :. The log directory contains a subdirectory main that contains the actual logs. It belongs to qmaill, the qmail log pseudo-user. Then create run files in both the main qmail and log directories, as in Example The two limit commands on lines 3 and 4 ensure that qmail can run many deliveries in parallel.

Set maxproc to be larger than the number of parallel remote deliveries permitted. Also set open , the per process open-file limit, to be at least twice the greater of the number of simultaneous local or remote deliveries permitted, because qmail-lspawn and qmail-rspawn use two pipes per delivery subprocess. Then the exec env command on line 6 clears out the environment, sets PATH to a known value, and runs qmail-start.

The arguments say to prefix each line with a time stamp, and to create log files of up to 4 MB in the subdirectory main. Supervise starts the run scripts directly, so they need to be executable:. Be sure the initial! Assuming you have svscan running, within a few seconds of making the line, qmail will start.

It should contain a line similar to this:. Now try telling qmail to send some local mail:. Use your own username instead of me , of course. The log file should now contain lines logging the local delivery:. Your file Mailbox should contain the message. If not, the log should contain evidence of the problem, which is usually files or directories not created with the correct owner or permissions. The log should look like this:. Finally, try a test message to a mailbox on a remote system.

It will send a response message telling you how clever you were to write to it, with a blurb for my books. If there are deliveries in progress, qmail will wait for them to finish or time out. Then it exits. Use svc -u to bring qmail back up. Next, install the SMTP daemon to receive incoming mail. For simple applications, rcpthosts can contain the same list of domains as locals. It is very important that you set up r cpthosts before starting your SMTP daemon.

Setting up SMTP involves three layers of daemons. Supervise runs tcpserver , which waits for incoming network connections. Each time a remote system connects, tcpserver starts a copy of qmail-smtpd , which collects the incoming message and passes it to qmail-queue for delivery. The run script eventually becomes rather complex as you add code to handle local versus remote users, spam filters, and the like, but this is adequate to start see Example The limit command on line 2 defends against a denial-of-service attack in which the attacker feeds the SMTP daemon a gargantuan message that fills up all of memory and crashes the machine.

Then the tcpserver command on line 3 accepts SMTP connections and runs qmail-smtpd for each one. The -u and -g flags on line 4 set the user and group numbers; substitute the values on your system for qmaild. The -R flag means to not try to collect ident information from the remote host. Ident information is rarely useful and a failed ident request can stall the daemon startup for 25 seconds. On line 5, host number 0 means to accept connections on any IP address assigned to this machine, and 26 means to use port 26 rather than standard SMTP port 25, which allows you to run the daemon for testing without interfering with an existing MTA on port Finally, line 6 has the command for tcpserver to run once a connection is open.

Once you have all the files created, symlink the smtpservice directory so svscan starts it up:. If this works, you now have a working mail system. The most likely problems are missing directories or configuration files, or incorrect file modes. If you want to stop the SMTP daemon, use svc -td just as you did to stop qmail. Once you believe that qmail works, kill any other mail daemon listening on port 25, change port 26 to 25 in the run file, and restart the daemon with svc -t to start receiving mail on the standard port.

The rest of the examples in this chapter use port 25 rather than port 26, on the assumption that qmail is now your production mail system, but for testing, they all work equally well on port Every mail system on the Internet should define a few standard addresses, such as postmaster, webmaster, and mailer-daemon. The last is the return address in the From: line of bounce messages. To define an address, just create a. Now try using qmail to send mail to postmaster and check that it lands in your mailbox.

Your qmail system most likely is a mail hub for a bunch of PCs or workstations. If we run qmHandle -a, qmail-send starts sending up to emails in parallel, but soon after an initial burst of emails, it goes back to sending up to 20 emails concurrently at best. I really don't know what is going on and how to diagnose this.

It may be a hardware-related issue e. Gabriel Torres June 19, Sam Tang April 4, I would like to share my qmailctl script here, this is what I had updated:.

Roberto Puzzanghera Sam Tang April 4, Kevin Salt Roberto Puzzanghera August 1, All have the same error. Roberto Puzzanghera Kevin Salt August 2, Kevin Salt Roberto Puzzanghera August 2, As my comment says, i tried all the sources. I've also found lots of issues with warnings and some errors when coming with gcc 4. In the end i just have to and referred to my old installation with upgraded spamassassin and cclamav.

GoofY zinkro April 10, Kenneth Dalbjerg September 19, But if we got a bounce back, the mail will not be deliver to the right sender address, it will try deliver it to the SRS rewrite address. Steve Conrad April 27, One minor typo I noticed was that your supervise script has the pop server running on port 89 the vpopmail uid rather than the usual port Probably this wasn't what you had in mind. Thanks for the great guide. Steve Conrad Steve Conrad April 29, That last 89 should probably be a instead.

Looks like the vpopmail UID got typoed in place of the intended port number. Not so sure about running vpopmaild as root either.

I think you want to be doing that as vpopmail so as to access the maildirs it owns. No it is not the pop3 service pop3 is served by dovecot in my configuration. Dovecot and roundcube can use it to change the passwords, for instance. I don't remember to have published any note about qmail-pop3d Al March 21, I set everithing like you wrote in this tutorial and everithing works well, but I have a problem with receieving error message from postmaster when I send email to unknown user.

Instead from postmaster example. Do you know how can I fix that to get message from postfix domain. Al roberto puzzanghera March 22, George Cooke October 1, Hi Roberto once again thanks for this guide, it's the best Linux guide i've ever seen, so perfect and thourough! But I have a problem, when I send mail from gmail to a valid vpopmail user at my qmail server, the mail is delivered fine, but the external sender additionally gets a postmaster bounce email from my qmail server about a log [myserver.

You can see what it's doing in the qmail-send log below, it seems to be generating a log email for every send, hence the double bounce at the end. In the below log: - myserver. Hi George, I can't garantee that the patch you applayed on top of my package will not interfere in some way.. Anyway, as mentioned above in the "Improved qmail-send log" paragraph, you have an email to log yourdomain just to record the Message-ID in the qmail-send log. You may want to revert that qmail-queue-extra patch or double check your configuration, in particular the content of the file.

George Cooke roberto puzzanghera October 1, Thanks for getting back to me Roberto it's really appreciated! I did realise it was something to do with the logging, but now I realise how it actually works, it's smart, you send an internal email to the log which is the command to log!

So I can tell now, something is thinking log doesn't exist and therefore:. So I just have to figure out why it's deciding log doesn't exist when actually it does according to qmail alias config.

Norbert George Cooke October 14, Marc August 23, Marc August 17, I have to use the option -4 in the run files to use it with ipv4. But then ipv6 ist not possible anymore.

In your standard run files the Option 0 is used which should bind tcpserver to any available IP address on any interface according to the tcpserver doc.

Do you have a clue wyh tcpserver binds the service ports only to ipv6? Are you using the new e. In that case I would try to test the -6 option. Marc roberto puzzanghera August 17, I have tried the -6 option and the result is the same as without the option binding only to ipv6.

For now i will use the -4 option so that i can use the installation with ip4. When i have more time i will take a closer look. Thank you for this tutorial. It has helped me much. Otto Dandenell August 14, I am building a new server 10 years after the last time I did it. It's so wonderful to have these step-by-step instructions, and all the patches consolidated. I am curious about the 5 second greet delay in the submission service. Even that low number causes IT stress when I test tghe outgoing mail using Thunderbird.

From time to time I get heavy attacks on port due to spammers who tries to guess users' passwords. Last time it was 2 days with 1 attempt avery few seconds.

I think that 5 seconds is a little stress for users, but a verrrry big loss of cpu time for spammers, if you multiply 5s times the number of attempts spanned in a couple of days Maybe it's better to comment out that line on the run script and advise to use it just in case fail2ban is not active. Otto Dandenell roberto puzzanghera August 15,



0コメント

  • 1000 / 1000