16 December 2009

Test de courriel à la main avec telnet

Bien pratique de pouvoir avoir des traces quand un problème de serveur de courriel survient. Une façon d'en savoir un peu plus long est de faire nôtre test en envoyant un courriel avec l'utilitaire telnet:
  1. You can start a Telnet session by using the Telnet command in the following format:

    Note Press ENTER after you type each line.
    telnet servername portnumber
    For example, type:
    telnet mail.contoso.com 25
    Note You can replace servername with the IP address or the FQDN of the SMTP server that you want to connect to. Remember to press ENTER after each command.

    If the command works, you receive a response from the SMTP server that is similar to the following:
    220 site.contoso.com Microsoft Exchange Internet Mail Connector 
    Note There are different versions of Microsoft SMTP or third party SMTP servers, and you may receive different responses from the receiving server. What is important is that you receive the 220 response with the FQDN of the server and the version of SMTP. Additionally, all versions of Microsoft SMTP include the term "Microsoft" in the 220 response.
  2. Start communication by typing the following command:
    EHLO test.com
    Note You can use the HELO command, but EHLO is a verb that exists in the Extended SMTP verb set that is supported in all current Microsoft implementations of SMTP. It is a good idea to use EHLO, unless you believe that there is a problem with the Extended SMTP Verbs.

    If the command is successful, you receive the following response:
    250 OK
  3. Type the following command to tell the receiving SMTP server who the message is from:
    MAIL FROM:Admin@test.com
    Note This address can be any SMTP address that you want, but it is a good idea to consider the following issues:
    1. Some SMTP mail systems filter messages based on the MAIL FROM: address and may not permit certain IP addresses to connect or may not permit the IP address to send e-mail to the SMTP mail system if the connecting IP address does not match the domain where the SMTP mail system resides. In this example, that domain is test.com.
    2. If you do not use a valid e-mail address when you send a message, you cannot determine if the message had a delivery problem, because the non-delivery report (NDR) cannot reach an IP address that is not valid. If you use a valid e-mail address, you receive the following response from the SMTP server:
      250 OK - MAIL FROM Admin@test.com
  4. Type the following command to tell the receiving SMTP server whom the message is to.

    Note It is a good idea to always use a valid recipient SMTP address in the domain that you are sending to. For example, if you are sending to john@domain.com, you must be certain that john@domain.com exists in the domain. Otherwise, you will receive an NDR.

    Type the following command with the SMTP address of the person you want to send to:
    RCPT TO: User@Domain.Com
    You receive the following response:
    250 OK - Recipient User@ Domain.Com
  5. Type the following command to tell the SMTP server that you are ready to send data:
    DATA
    You receive the following response:
    354 Send data. End with CRLF.CRLF
  6. You are now ready to start typing the 822/2822 section of the message. The user will see this part of the message in their inbox. Type the following command to add a subject line:
    Subject: test message
    Press ENTER two times. You do not receive a response from this command.

    Note The two ENTER commands comply with Request for Comments (RFC) 822 and 2822. 822 commands must be followed by a blank line.
  7. Type the following command to add message body text:
    This is a test message you will not see a response from this command.
  8. Type a period (.) at the next blank line, and then press ENTER. You receive the following response:
    250 OK
  9. Close the connection by typing the following command:
    QUIT
    You receive the following response:
    221 closing connection
  10. Verify that the recipient received the message that you sent. If any error event messages appear in the application event log, or if there are problems receiving the message, check the configuration or the communication to the host.

15 December 2009

Pervasive SQL - Erreur 3012

Un représentant aux États-Unis avait de la misère à nous communiquer des informations par son CRM. Après quelques minutes de recherche je remarque dans les journaux un événement étrange :

DATAMANAGER returned an error code of 3012: Local engine is not accessible to the MicroKernel router

Pour régler ce problème on doit mettre le Pervasive SQL Engine en Pré-load et non en mode automatique. Cela est vrai pour Windows Xp et également Windows Vista / 7.

Voici la marhce à suivre:
On créer un nouveau raccourcis dans le "startup" de Windows et on ajoute ceci:
C:\PVSW\BIN\W3DBSMGR.EXE –SRDE

Redémarrer ensuite l'ordinateur et passer la sourirs par dessus l'icône du service pervasive. Si vous voyez pre-load vous ne devriez plus jamais voir l'erreur plus haut.

Bon une chose qui est très tannante dans une entreprise c'est de ne pas avoir la même heure partout. Imaginer avoir une rencontre a 13:30 et que la moitié des gens arrivent en retart car l'heure sur l'ordinateur est pas paramétré correctement. Ce n'est pas génial.

Voici comment y remédier:
Premièrement il faut voir sur quel serveur de temps on va chercher l'heure:
On entre en command line et on tape :
net time /querysntp

Deuxièmement: On doit synchroniser vers une source de temps proche sinon on devra corriger les skew / offset manuellement...
Dans nôtre cas on syncrhonise sur un cluster de temps canadien avec cette commande:
net time /setsntp:ca.pool.ntp.org

Troisièmement: On redémarrer le service de temps avec cette commande:
net stop w32time
net start w32time
ou
net stop & net start w32time

Pour finir on vérifie que tout est correct avec la commande query:
net time /querysntp

C'est tout !

13 October 2009

Ce que vous retrouverez

Bonjour, vous retrouvez ici des informations collectez tout au long de ma carriere en tant que consultant en informatique.