How do I restart the server?
On NT, type in: net start surgemail
On 95/98, type in: /surgemail/surgemail
On Unix, type in: /usr/local/surgemail/surgemail_start.sh
To start it remotely use SurgeMail monitor on http://your.mail.server:7027
How do I get to the web manager?
Use your web browser and type in a link like this: https://your.mail.server:7025 If you are on the machine itself this link should work https://127.0.0.1:7025
How do I set the web manager username and password?
*nix systems you need to go to the shell and type
cd /usr/local/surgemail
./surgemail -password
Windows systems you need to go to the command prompt
cd \surgemail
surgemail -password
I moved some users in one domain to office 365? (Split domain)
Lets be really clear, never do this, split domains are a dumb idea, the whole point of the 'domain' is to allow systems to figure out where the domain is hosted, so splitting your users between two systems with one domain is breaking the whole principle on which email is based. Splitting a domain will come back and bite you one day soon, and make managing your system and tracking down faults virtually impossible. :-). The correct solution is to move the other users to a new domain name (e.g. fred@xxx.your.domain). Then it's easy, and you can add some redirection rules to make it almost invisible. e.g. people who send to fred@your.domain will have the email automatically forwarded to fred@xxx.your.domain for the users that exist on the other system.
So, you still want to do it the wrong way...... 🙂
- Step 1) Delete the moved users from the surgemail system.
- Step 2) Add a setting fallback_relay "other.mail.server" to send messages to non existent local users to the other system
- Step 3) Add setting: fallback_users "c:\surgemail\fallback.txt", in that file list the users (one per line) that exist on the other mail system.
- Again, this is the WRONG solution, see comments above in bold for correct solution 🙂
How do I enter my registration key?
In the web manager click on the 'Register' link on the navigation pane.
Alternatively run tellmail activate on the command line with your registration details:
tellmail activate N123 myemail@mydomain.com
Where are the SurgeMail configuration files?
SurgeMails main configuration file is surgemail.ini which is store in /etc on UNIX systems and your Windows directory on Windows systems (eg c:\winnt). This file can be edited by hand after which a "tellmail reload" would need to be issued or edited via the web interface. Backups of this file are stored in the SurgeMail directory as ini_YYMMDD.rec.
WebMail has a separate configuration file stored in surgemail/scripts/webmail.ini.
Al
How can I use "sendmail" style command line syntax to send mail?
SurgeMail installs a sendmail stub. This will allow your PHP scripts and the like to continue sending mail using the same syntax they have always done. You will need to ensure SurgeMail is allowing relaying for your local IP. If it is not working pass the stub the "-debug" parameter it should create a sendmail.debug file that will give you information as to why it is not working.
How do I fix "DNS lookup failed" errors?
Set g_dns_host to point to your own DNS server, try 8.8.8.8 until you have a working one to use.
note: You must restart SurgeMail when changing g_dns_host
How do I add users on the command line?
Users can be added on the command line as follows (You need to run the path etc for your authentication module as specified in surgemail.ini)
./nwauth -path . -set username@domain password
Alternatively for a more efficient process create a text file of nwath
commands and pipe it to nwauth as follows:
>>Start of file nwauth.in<<
set user1@domain.com password
set user2@domain.com password2
set user3@domain2.com password3
>>End of file<<
./nwauth -path . < nwauth.in
or for list of nwauth command lin commands:
./nwauth -help
In new versions built later than the 25th of April 2004 you can now use a tellmail command
tellmail add_user <user@domain> <password>
This automatically uses the correct authent module etc
How do I move SurgeMail to a new machine?
Use mirroring to do this
How do I backup SurgeMail?
- Backup surgemail.ini which is found in the windows directory or /etc if on UNIX
- To backup the mail you need to backup the directory that stores all the mail. You will need to check this location in surgemail.ini look for "g_mailbox_path" and that will give you the directory to backup.
- To backup the user accounts, if you are using NWAuth for your user database (which is the default) then you should backup all the nwauth* files in the SurgeMail directory.
- Finally you can backup the SurgeMail directory which contains the programs, the temporary work area for queued messages, and the templates etc etc.
On Windows you can just use something like winzip to copy everything, on UNIX based platforms you can use tar and gzip or whatever you prefer.
To restore a backup
- Install SurgeMail on the new box
- Shutdown SurgeMail on both machines
- Copy your backup over to the new machine and untar/unzip (If you are on linux using tar is a good idea as this will preserve file permissions)
- Check the file permissions if you are linux (ls -l) they should be owned by mail
- Copy surgemail.ini over to the new machine and check the paths in it to make sure they are correct.
- Restart SurgeMail
If you are moving SurgeMail to a new machine you can check this guide http://www.netwinsite.com/surgemail/help/faq.htm#moving_surgemail
How do I send my mail through my ISPs server or some other mail server?
If you need to send your mail via another SMTP server then you can use the gateway setting. This setting lets you choose which domains to send to a server so you can send one domain to one server and another domain to another server or you can send all domains to one server. This is useful if your ISP won't allow you to connect to port 25 on remote machines or if you are on cable/DSL and domains like AOL won't accept mail from you because of this so instead you can send all your mail through your ISPs mail server.
Example 1: Sending all mail through a differerent server
g_gateway domain="*" to="ip of server to use" relay="false"
If you need to authenticate on the server you are going to use you can do this
g_gateway domain="*" to="ip of server to use" relay="false" user="user to auth with" pass="password of user"
Example 2: Sending mail going to AOL via a different server
g_gateway domain="aol.com" to="ip of server to use" relay="false"
You can add SMTP AUTHentication like in example 1.
You can find more information on using the gateway setting here g_gateway
How can I change a domain name in SurgeMail?
- Stop Surgemail
- Make a backup of nwauth.* and surgemail.ini
- If using nwauth, then Run ./nwauth -rename old.domain.name new.domain.name
- If not using nwauth change the domain names in your database!
- Edit surgemail.ini and change the vdomain name="OLD.DOMAIN.NAME" TO "NEW.DOMAIN.NAME"
- And add 'host_alias "old.domain.name" if desired.
I can't receive mail
Usually this is one of the following
- Firewall not letting traffic in on port 25
- Router not configured to let traffic in on port 25
- ISP blocking incoming traffic on port 25
- DNS records not setup correctly.
So first check that you can connect locally to the server. At the command prompt on the server type
telnet localhost 25
You should receive a welcome message like this
220 mydomain.com SurgeSMTP (Version 3.1b-1) http://surgemail.com
If you get unable to connect then it's probably due to a firewall running on that machine that is stopping surgemail.
If you are running SurgeMail on a Windows operating system you can restart surgemail and then check mail.log and check it says
"03 10:32:22.89:Info:2156: Listening on (all interfaces:25)"
You can use this page to help test sending mail to your server.
http://email-test.com
How do I whitelist a domain?
There are several steps involved as there are various whitelists, for RBL's , ASPAM etc. RBL's & ASPAM
g_orbs_late "true" (allows RBL based exceptions based on rctp and from address)
g_spf_skip_to "*@domain" (applies to RBL's and ASPAM)
g_spf_skip_from "*@domain" (applies to RBL's and ASPAM)
g_smite_skip "*@domain.com" (applies to smite scoring and thus friends - this is the source domain)
g_smite_skip_to "*@domain.com" (applies to smite score & friends - this is the destination domain)
If you know the IP's of the domain you want to whitelist you can also whitelist based on them.
g_spf_skip "ip" - skips spf checks for emails from this ip
g_orbs_exception "ip" - skips RBL checks for emails from this ip
g_mfilter_skip "ip" - skips mfilter processing for emails from this ip
g_spam_allow "ip" - skips spam throttle limits, ideal for the ip address of a mailing list server.
To whitelist an ip address use:
g_user_send_white "1.2.3.4"
g_gateway_allow "1.2.3.4"
g_iplimit_whitelist "1.2.3.4"
g_spam_allow "1.2.3.4"
g_con_perip_except "1.2.3.4"
Sendmail - My forms can no longer send mail
SurgeMail replaces the sendmail binary with a sendmail stub, this basically pretends to be sendmail and redirects everything to SurgeMail. Your programs should not have any problems but sometimes there are.
-
Create a file called sendmail_surge.ini in /etc on *nix or the windows directory on Windows.
-
in this file add the following settings
host 127.0.0.1
debug true
Then try sending a message with the sendmail binary
/usr/sbin/sendmail -debug
From: yourusername@yourdomain
To: user@whateverdomain
Subject: test
This is a test
.
You can then view sendmail.debug to check what has happened. If you still have problems please send us the sendmail.debug log and also the output from a
/usr/sbin/sendmail -version (surgemail-support@netwinsite.com)
To convert a PFX file to a PEM file, follow these steps on a Windows machine:
1. Download and install the Win32 OpenSSL package from http://gnuwin32.sourceforge.net/packages/openssl.htm.
2. Create a folder c:\certs and copy the file yourcert.pfx into the c:\certs folder
3. Open a command prompt and change into the GnuWin32\bin directory:
cd %ProgramFiles%\GnuWin32\bin
4. Type the following command to convert the PFX file to an unencrypted PEM file (all on one line):
openssl pkcs12 -in c:\certs\yourcert.pfx -out c:\certs\cag.pem -nodes
5. When prompted for the import password, enter the password you used when exporting the certificate to a PFX file. You should receive a message that says MAC verified OK.
Copy the resulting file to the surgemail certificate file surge_priv.pem
How do I get Push email alerts on IOS/iphone
The secret is to install a better email app, we recommend Spark, see
https://sparkmailapp.com
Message send fails to multiple destinations on any large message.
Check your MTU setting, if it's wrong then large network packets will fail. This will result in closed connections during the DATA send stage.
Notes to find this clue: (tcp_window, protocol, data, tcp_read_dot got 0 bytes)
Make users connect to surgeweb with SSL
g_url_redirect from="http://*/surgeweb" to="https://%1/surgeweb" ports="80"
# or you may wish to make surgeweb the default page for users connecting:
g_url_redirect from="/" to="/surgeweb" ports="443,80"
Best practices for improved delivery
- Check you aren't sending spam.
- Check you don't have a hacker sending spam. http://netwinsite.com/surgemail/help/hackers.htm
- Lookup your ip addresse in rbl databases to see if you are blacklisted.
- Ensure you have a good reverse dns entry, helo name, and spf and dkim entries