Using Telnet to connect to Exchange 2003 POP3 mailboxes and using SMTP to send e-mail for troubleshooting purposes

Telnet to Exchange 2003 POP3 mailboxes and using SMTP to send e-mail for troubleshooting purposes

In this article I will give you tips for troubleshooting Exchange 2003 POP3 access and SMTP E-Mail transfer using the good old Telnet client. Why am I writing an article about POP3 and SMTP troubleshooting with the help of Telnet? Telnet gives you some powerful information about every connection step for POP3 or SMTP processes.

Some basic information about POP3 and SMTP

POP3

Short for Post Office Protocol, a protocol used to retrieve e-mail from a mail server. Most e-mail applications (sometimes called an e-mail client) use the POP protocol, although some can use the newer IMAP (Internet Message Access Protocol).

There are two versions of POP. The first, called POP2, became a standard in the mid-80′s and requires SMTP to send messages. The newer version, POP3, can be used with or without SMTP.

Source: Here

Beginning with Exchange 2003 we have to activate POP3 support after the Exchange installation, because Microsoft has disabled some services for security reasons (POP3 communication is unencrypted per Default – but you can use TLS to ensure security).

SMTP

Short for Simple Mail Transfer Protocol, a protocol for sending e-mail messages between servers. Most e-mail systems that send mail over the Internet use SMTP to send messages from one server to another; the messages can then be retrieved with an e-mail client using either POP or IMAP. In addition, SMTP is generally used to send messages from a mail client to a mail server. This is why you need to specify both the POP or IMAP server and the SMTP server when you configure your e-mail application.

Source: Here

Let’s begin

Connecting to POP3

Open Telnet (Start – Run – CMD – Telnet) and write the following line:

TELNET Servername.Domain.TLD 110 (in our example TELNET some.domain.com 110).


Figure 1: Connecting to your Exchange Server via POP3

What do we see here?

+OK                                             - The Exchange Server accepts Connection to Port 110

Exchange Server 2003 POP3           – It is a Exchange 2003 Server

Version 6.5.7226.0                             – The Exchange Version Number

some.domain.com                                – The FQDN of the Exchange Server

These are some helpful information about our connection.

Let’s go further:


Figure 2: POP3 communication

What do we see here?

USER MSEXchangeORG     – The name of the user to connect to the mailbox

PASS Fake001                  – The password of the user (transmitted unencrypted over the network)

LIST                                 – Lists all E-Mails in the mailbox

RETR 1                             – Display the selected E-Mail

A very interesting part is the displayed body of the E-Mail. You can see the encapsulation of the E-Mail, MIME type, Message ID and much more helpful information.

POP commands

USER

The User you would like to connect to
PASS The password of the user (transmitted unencrypted over the network)
STAT Overview over the POP3 mailbox
LIST Displays every message in listform
RETR Displays selected message (RETR 1)
DELE Deletes selected message (DELE 1)
NOOP NO Operation
RSET Undo DELE function
QUIT End POP3 Session

Connecting to SMTP

Open Telnet (Start – Run – CMD – Telnet) and write the following line:

TELNET Servername.Domain.TLD 25 (in our example TELNET some.domain.com 25).


Figure 3:
EHLO commands

SMTP supports two verbs: HELO an EHLO

The HELO or EHLO verbs in SMTP are how the client identifies itself to the server. Clients that use single-label domain names, or domain names that the server cannot look up in the DNS database, are broken or misconfigured.

EHLO is the successor of the HELO verb and supports many more commands. The supported EHLO verbs are different from Mailserver to Mailserver. Exchange 2003 supports the EHLO verbs displayed in (Figure 3).

A very important EHLO verb is AUTH. AUTH lists the supported authentication methods for connecting to the SMTP Server. Exchange 2003 supports GSSAPI, NTLM and LOGIN.

Some ISP SMTP servers doesn’t support AUTH. They use SMTP after POP. SMTP after POP authenticates a user through a successful POP3 connection and lets him use the SMTP protocol with the applied credentials through the POP3 connect.

In our example we use the basic HELO command to connect.


Figure 4: Write a e-mail through telnet

What do we see here?

220 some.domain.com            – the Server listens on the given SMTP port

Microsoft ESMTP Mail Service         - This Server supports Extended SMTP

Version: 6.0.3790.0 ready             - This SMTP Service is hosted by Windows 2003

HELO                                           - Initiates connection (requires domain name by most SMTP

servers)

250 some.domain.com            – Server accepts connections on IP address 111.111.111.111

MAIL FROM: Name@domain.tld       - The Sender of the Message

RCPT TO: Name@domain.tld          - The Reciepient of the Message

DATA:                                          – Input e-mail data for subject and body

SUBJECT:                                     - the subject line of the message

Enter the data for the message body. At the end of the message click <CRLF> “.” <CRLF>

The message will be transmitted through the destination address through exchange.

SMTP commands

HELO Identifies the Client
MAIL Specifies Mail Sender
RCPT The Reciepient of the message
DATA The Data part of the message
RSET Resets message transmiting
VRFY Verifies e-mail address
EXPN Expand a mailing list
DSN Delivery Status Notification
HELP Displays help
NOOP NO Operation
TURN Mail TURN
ETRN Extended TURN
VERB Verbose Mode
QUIT End SMTP Session

Conclusion

Connecting to POP3 Mailboxes and sending E-Mails through SMTP with the help of Telnet will give you a good understanding about the functions of these processes. I like Telnet to troubleshoot POP3 and SMTP issues.

Related Links

POP3 RFC
Here

SMTP RFC
Here

Administering POP3/SMTP/IMAP
Here

 

Articles Original Posted by: Here

  • Published: Jul 29, 2004
  • Updated: Jul 29, 2004
  • Author: Marc Grote
Filed in Microsoft Exchange | Comment Now

Someone keeps using my exchange server

The queue keeps filling up. 2k messages in 2hrs. I have enabled message
filtering and check there is no relay. I tested using one of the microsoft articles
and I don’t get 550 5.7.1 Unable to relay for user@spam.com -or- 250 2.1.5 user@spam.com
I get unrecognized email address.

I created a forward mail to (111.111.111.111) to try and stop the messages so i can clear it but they keep coming.

I am trying to use this http://support.microsoft.com/kb/324958
but the queue never stops filling up.
Right-click Small-business SMTP Connector, and then click Properties. If you
have more than one SMTP Connector, the one that you want to work with in the
following steps is the one that contains the “*” (asterisk) for the SMTP
address on the Address Space tab.
3. Click the General tab. Make a note of all the settings on this tab. You
have to return these settings later in this article.
4. Click Forward all mail through this connector to the following smart
hosts.
5. In the field provided, type a false IP address and enclose it in
brackets. For example, type [111.111.111.111].
6. Click the Deliver Options tab .
7. Click Specify when messages are sent through this connector.

I checked these settings and they are correct.

Verify that your Exchange computer is not an open mail relay. To do this,
follow these steps:

a. Click Start, point to Programs, point to Microsoft
Exchange, and then click System Manager.
b. In Exchange System Manager, expand the following object:
ServersYour_Exchange_Server_NameProtocolsSMTP
c. Right-click the virtual SMTP server where you want to prevent mail
relay, and then click Properties.
d. Click the Access tab, and then click Relay.
e. By default, open relay is blocked. The default settings are as follows:
? The Only the list below check box is selected.
? The Allow all computers which successfully authenticate to relay,
regardless of the list above check box is selected.

Filed in Microsoft Exchange | Comment Now

How to remove virus from PC:

Problem:

  • Everything is running slow.
  • Random pop up when opening browser.
  • Pop up in Task bar saying you need to purchase anti-virus because you have so many virus.

Solution:

  1. Reboot machine into safe mode
  2. Restore system if you have it ON
  3. download three or four anti spy-ware software like: Spybot/Malwarebites/Ad-Aware AE/Webroot Spy Sweeper
  4. Run each spy-ware software in Safe Mode with network.
  5. Important to remember when you do the scans and it finds the malware on the machine you need to locate it and make sure everything is deleted.
  6. After all scans are done and you have located and deleted run MSCONFIG
  7. And make sure there is no Service or command line to restart the spy-ware from running.

Once these steps are done, You are Ready to reboot and run your PC again.

Filed in Windows OS | Comment Now

outgoing email not working using Exchange 2000/2003/2007

Problem:

Outgoing emails not sending.

Solution:

Changing the SMTP settings from (mail.yourdomain.com) to
(Your provider) Having problem sending using
mail.yourdomain.com.
Suggested that if for some reason it stops working you
should call Hosting Company to tell them that you can’t
connect to send email using there SMTP server.
(There is a few reason why it would have stopped.
Your server is sending spam if infected by virus. Someone
is using your server for sending emails if you have not locked it down.)

Filed in Microsoft Exchange | Comment Now

Moving (IMAP) mDaemon to Cloud Exchange.

Problems:

  • 1. When creating PST file from your outlook some emails might not Export to PST file (some could be missing).
    2. Depending on the size of PST file it will take a very long time to sync so you will not see all the emails until it fully snyc (when it does you will be able to see all online in OWA site)
    3. Make backup before doing anything which will cause you losing any data.

Solution:

  • 1. Best option here is to Export folder by folder. (which I ended up doing)
    2. Best thing to do is just leave it online until it fully sync.
    3. Copy the files to external hard drive, or even keep the mDaemon in network but offline. (just in case)
Filed in Cloud Exchange | Comment Now

Moving Exchange Stores to a Different Disk

How to move Exchange databases and logs in Exchange Server 2003
View products that this article applies to.
For a Microsoft Exchange 2000 version of this article, see 257184 (http://support.microsoft.com/kb/257184/EN-US/ ) .



SUMMARY

Exchange Server 2003 does not include the Performance Optimizer program (Perfwiz.exe) that is included with previous versions of Exchange Server.
This article describes how to move log files or database files in Exchange Server 2003.


MORE INFORMATION

If you want to move log files or database files to another drive, use the following procedures.
Back to the top
To move log files

1. Start Exchange System Manager.
2. Click Administrative Groups.

Note If Administrative Groups does not appear, it may not be turned on.
To turn on Administrative Groups, right-click Exchange Organization in Exchange System Manager,
and then click Properties. Click to select the Display Administrative Groups check box.
3. Locate the storage group where you want to change log file paths,
right-click the storage group, and then click Properties.
4. Click the General tab, click the Browse button next to the Transaction log location box,
and then specify the new drive or folder location for the log files.



To move databases

1. Start Exchange System Manager.
2. Open the administrative group that contains the database that you want to change.
3. Under Storage Group, right-click the mailbox store or the public folder store that you want to change, and then click Properties.
4. Click the Database tab.
5. Next to the database that you want to change, click Browse, and then specify a new drive or folder location for the files.



Notes

* With the databases, you can decide to move the Exchange Database (.edb file), the Exchange Streaming Database (.stm file), or both.
* If the databases are still mounted, you receive the following message:
You are about to perform the following operation(s):
- change Exchange database location
To perform the requested operation(s), the store must be temporarily dismounted which will make it inaccessible to any user.

Do you want to continue?
Click Yes to dismount the database automatically and move the location.
6. When you finish moving the databases, remount the databases manually.

You can move the log files and database files to any folder that you want to create. When you move logs and database files, you may want to create the Exchsrvr\Mdbdata file structure for consistency reasons, but you are not obligated to do so.

You must grant the following default permissions to the new Mdbdata folder that contains the log files and database files:

* Administrators: Full Control
* Authenticated Users: Read and Execute, List Folder Contents, Read
* Creator Owner: None
* Server Operators: Modify, Read and Execute, List Folder Contents, Read, Write
* System: Full Control

Note Only assign permissions to the Server Operators group if the Exchange server is a domain controller. Otherwise, assign permissions to the Power Users group. Only domain controllers should have permissions to the built-in Server Operators group. Stand-alone and member servers should have permissions to the built-in Power Users group.

You may also have to grant the following permissions to the root drive that contains the new Mdbdata folder:

* System: Full Control

During the process of moving log files and database files, your store is temporarily dismounted. Because the store is temporarily dismounted, it is inaccessible to your users until the process is completed. Moving log files or database files invalidates all existing incremental and differential backups; therefore, make a full backup after these changes.

Do not delete or rename the Old MDBdata Folder path after you move the Exchange database. If you want to delete the old MDBdata folder, make sure that the following working directory parameter in the registry points to the new location:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\MSExchangeIS\ParametersSystem
Value name: Working Directory
Value type: REG_SZ
Value data: C:\Program Files\Exchsrvr\Mdbdata
For more information, click the following article number to view the article in the Microsoft Knowledge Base:
298415 (http://support.microsoft.com/kb/298415/ ) Messages that have attachments are not delivered as expected, and Event ID 12003 and 327 messages are logged in Exchange 2000 Server and in Exchange Server 2003

Do not move databases to the root of a drive. Instead, move databases at least one subfolder down from the root drive. For example, do not use C:\ as the path of the database or log files. Instead, you could use the C:\Subfolder path. In an organization that uses Exchange 2003 and Exchange 2007, the 2007 management tools will flag database or log files that are the root of a drive as an error. For more information, visit the following Microsoft Web site:
http://technet.microsoft.com/en-us/library/cc411334(EXCHG.80).aspx

Filed in Microsoft Exchange | Comment Now

Dell Poweredge SC440 – Beeping sound

Problem:

Just keeps beeping for no reason no errors popping up

Solve:

Check to see if you have the dyndns service installed under your services. If you do, disable it and see if the beep goes away. If it does, then check with that software vendor.

Filed in Hardware | Comment Now

Event ID: 2250

Workstation service error 2250 in Microsoft XP Professional
Symptoms:

Will be able to connect to the INTERNET fine
Will not be able to connect to Shared folders from Server on the Domain.
Will not be able to change Domain Name on PC it will be grayed out.
Solving Problem:

Try running the network setup wizard first it might activate or install any missing services or files.
Still not working? Try importing backup of your Regedit Key.

If its still not working it might be because 1 or more of the files needed are missing or corrupt. Search your computer for “wkssvc.dll” to see if it exists.

Try, extracting it from the cd using SFC. Path should be c:\windows\system32.

If it still doesn’t work try running SFC /scannow

This will take a long time to check all system files.

Filed in Event ID: | Comment Now

Microsoft Exchange 2007 Information Mailbox Store service (Stopped) not working

MS SBS 2008 & MS Exchange Server 2007:

Microsoft Exchange Information Store service stopped working and will not start working.
I tried to restart the Exchange Information store it would load half way then i would get an error 0

So how did i fix this problem !

I found that my NIC card was using IPv4 and i remember that both IPv4 and IPv6 where running when i installed SBS 2008 server
When I clicked on IPv6 to activite it and click apply and went to the Service Panel to Start the Exchnage Information Store it worked.

Hope this help !

Filed in Microsoft Exchange | Comment Now

Mapped Drive Connection to Network Share May Be Lost

SYMPTOMS

On a computer that runs one of the versions of Windows that is listed at the beg…On a computer that runs one of the versions of Windows that is listed at the beginning of this article, if you map a drive to a network share, the mapped drive may be disconnected after a regular interval of inactivity, and Windows Explorer may display a red “X” on the icon of the mapped drive. However, if you try to access or browse the mapped drive, it reconnects quickly. This behavior occurs if the network share computer runs Microsoft Windows NT 4.0, Windows 2000, or Windows Server 2003.

CAUSE

This behavior occurs because Windows NT Server 4.0, Windows 2000 Server, and Win…This behavior occurs because Windows NT Server 4.0, Windows 2000 Server, and Windows Server 2003 can drop idle connections after a specified time-out period (by default, 15 minutes) to prevent wasting server resources on unused sessions. The connection can be re-established very quickly, if required.

RESOLUTION

To resolve this behavior, change the default time-out period on the shared netwo…To resolve this behavior, change the default time-out period on the shared network computer. To do this, use one of the following methods.

NOTE:
You cannot change the default time-out period for Microsoft Windows 95-based computers and Microsoft Windows 98-based computers that have shared resources.
Back to the top
Registry Editor

NOTE:

You cannot use this method to turn off the autodisconnect feature of the Server service. You can only use this method to change the default time-out period for the autodisconnect feature. WARNING: If you use Registry Editor incorrectly, you may cause serious problems that may require you to reinstall your operating system. Microsoft cannot guarantee that you can solve problems that result from using Registry Editor incorrectly. Use Registry Editor at your own risk.

Use Registry Editor to increase the default time-out period. To do this, follow these steps, and then quit Registry Editor:
Click Start, click Run, type regedit (Windows 2000 or Windows Server 2003) or type regedt32 (Windows NT 4.0), and then click OK.
Locate and then click the following key in the registry:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\lanmanserver\parameters

NOTE:
The client side session is automatically disconnected when the idling time lasts more than the duration that is set in KeepConn. For this reason, the session is disconnected according to the less set duration value between AutoDisConnect and KeepConn. To modify the timeout duration in the client side during a UNC connection, specify the arbitrary time in KeepConn from registry value.
Locate and then click the following key in the registry:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Service\lanmanworkstation\parameters
Value: KeepConn
Data type : REG_DWORD
Range : 1 to 65535 (sec)
Default value: 600 sec = 10 mins

In the right pane, click the autodisconnect value, and then on the Edit menu, click Modify. If the autodisconnect value does not exist, follow these steps:
On the Edit menu, point to New, and then click REG_DWORD.
Type autodisconnect, and then press ENTER.
On the Edit menu, click Modify.
Click Hexadecimal.
In the Value data box, type ffffffff, and then click OK.

Command Line

NOTE: If you use this method, you may turn off the autotuning feature for the Server service.

To change the default time-out period for the autodisconnect feature of the Server service, open a command prompt, type the following line, and then press ENTER
net config server /autodisconnect:number
where number is the number of minutes that you want the server to wait before it disconnects a mapped network drive. The maximum value for this command is 65,535.

NOTE: If you set the autodisconnect value to 0 (zero), the autodisconnect feature is not turned off, and the Server service disconnects mapped network drives after only a few seconds of idle time.

To turn off the autodisconnect feature, open a command prompt, type the following line, and then press ENTER:
net config server /autodisconnect:-1



Filed in Network | Comment Now