Nov
16
2004

Back to correct speed

Over the weekend I realized that my notebook became quite slow and was always reading something on the HD, even without any memory pressure. When I was to some music, starting an application was really corrupting the sound. So after some I realized that my Primary IDE controller went from DMA back to the old PIO mode. To solve this issue I reinstalled the the primary IDE port using the Device Manager, and after two reboots it went back to DMA and a acceptable speed.

You might find more information about that issue here: IDE ATA and ATAPI disks use PIO mode after multiple time-out or CRC errors occur.

Looking to the cause in the KnowledgeBase: "After the Windows IDE/ATAPI Port driver (Atapi.sys) receives a cumulative total of six time-out or cyclical redundancy check (CRC) errors, the driver reduces the communications speed (the transfer mode) from the highest Direct Memory Access (DMA) mode to lower DMA modes in steps. If the driver continues to receive time-out or CRC errors, the driver eventually reduces the transfer mode to the slowest mode (PIO mode)." makes me thing that I need to take care about my HD, so I made a backup.

Jul
23
2004

Managing IIS with scripts

I needed to create a virtual directory in IIS 6 during the deployment of one of our backend application on a Windows 2003 server. This application is a COM component written in C++ that I developed wrapping a very old VB6 COM component. The whole exposed as a Web Service using the SOAP Toolkit 3. I already discussed about it here.

So I created a script that will register both COM component, by the way regsvr32 is really bad cause it doesn't return different value if it fails. Right now I have no verification in the script that let me know if the registration went well. I plan to add it in a second step by reading the content of the registry using the reg command. The script is using the SOAPVDIR.CMD packaged with the SOAP Toolkit 3 to create the Virtual Directory with the soap ISAPI of the SOAP Toolkit 3:

>"c:\Program Files\MSSOAP\Binaries\SOAPVDIR.CMD" CREATE $VDIR_NAME path

Then I needed to change the user name used for the anonymous access:

>cscript c:\Inetpub\AdminScripts\adsutil.vbs SET /W3SVC/1/ROOT/$VDIR_NAME/AnonymousUserName myusername

and his password:

>cscript c:\Inetpub\AdminScripts\adsutil.vbs SET /W3SVC/1/ROOT/$VDIR_NAME/AnonymousUserPass mypassword

At this point I am not that happy about this method cause I have to specify in clear text a password in a script. I have two options. Either the user has to pass the password when running the script, but as it is a script calling this new script and I don't want to change it, I find that I could implement my own command using .NET and the namespace: System.DirectoryServices with such code:

using System;
using System.DirectoryServices;
using System.Reflection;

namespace ADSI1
{
  class ConfigIIS
  {
    [STAThread]
    static void Main(string[] args)
    {
      string serverName = "localhost";
      string password = "";
      string serverID = "1234";

      CreateNewWebSite(serverName, password, serverID);
      CreateVDir(serverName, password, serverID);
    }

    static void CreateNewWebSite(string serverName, string password, string serverID)
    {
      DirectoryEntry w3svc = new DirectoryEntry ("IIS://" + serverName + "/w3svc",serverName + "\\administrator", password,AuthenticationTypes.Secure);
      DirectoryEntries sites = w3svc.Children;
      DirectoryEntry newSite = sites.Add(serverID,"IIsWebServer"); //create a new site
      newSite.CommitChanges();
    }

    static DirectoryEntry CreateVDir (string vdirname, string serverID)
    {
      DirectoryEntry newvdir;
      DirectoryEntry root=new DirectoryEntry("IIS://localhost/W3SVC/" + serverID + "/Root");
      newvdir=root.Children.Add(vdirname, "IIsWebVirtualDir");
      newvdir.Properties["Path"][0]= "c:\\inetpub\\wwwroot";
      newvdir.Properties["AccessScript"][0] = true;
      newvdir.CommitChanges();
      return newvdir;
    }
  }
}

And then I could save the encrypted password in the config file of the tool.

Update: I found some articles about the namespace System.DirectoryServices here:

Jul
8
2004

How I restored my notebook after uninstalling issues of V2i from Symantec

After uninstalling V2i from Symantec I was asked to reboot my notebook. The reboot took for ever so I decide after 30 minutes to switch it off. Problems started when I rebooted, lots of drivers where missing and it seems that I lost the plug and play features. One of the first driver I decided to recover was the Sound driver. This is the way I recover from that sound driver issue.

  1. In services, check that WinAudio service is enabled, set to automatic, and running.
  2. In Device Manager, System Devices check that Plug and Play Software Device Enumerator is installed and running

If not , then you need to reinstall it:

  1. Copy machine.inf from %windir%\inf to your desktop
  2. Remove line ExcludeFromSelect=*
  3. Use Add new hardware wizard using the Have Disk option
  4. Select the machine.inf you saved on the desktop
  5. Install Plug and Play Software Device

If the sound card is listed in the device manager, then uninstall it and start a scan for hardware changes. Afer installing it again I got the sound back live.

I did the same for several other drivers that were missing on my notebook. And now it seems to be ok.

Apr
28
2004

Exchange 2003 working :-)

Now DNS are updated and I have Exchange 2003 working. I get a new email that I will have to share with my contacts. Thats will be lots of work. There is still something I need to fix: Outlook Web Access

I also installed Open Relay Filter Enterprise Edition from Vamsoft. Thanks to them for gracefully providing me a version.

Apr
27
2004

Exchange 2003 almost working

I continued the installation of Exchange 2003 and I am almost done with it. Currently I am able to send email, to get email from my different internet pop emails using Pullmail. But I can't get directly emails for my domain. As I have a dynamic ip i used DynDns and changed the MX record of my DNS provider to point to a CNAME with the domain name used in DynDns. It seems that the problem is coming from there, but I could not fix it, and I don't have any idea.

I want to thanks Benoit Hamet for his wonderful support. I used also a really good article: Hosting Your Own SMTP Mail Using Exchange 2000 by Mark Fugatt. Thanks Mark.

Apr
24
2004

Domain Controller :-) Starting Exchange 2003 installation.

Finally I managed to install my DC, DNS... I stopped this morning at 2 AM and restarted at 7:30 AM. Thanks to Thierry Mille (always of good support) and Tim Hines for his message that solved my issue. Now I start installing Exchange 2003, and hope that I will be successfull. For the moment it goes ok. When it will be finished I will need to reimport my user profile, that will tough, I guess. Thanks to Julia Lerman for her kind message, thats right we are only developers ;-)
Apr
24
2004

Domain Controller :-(

I decided to change my home installation and to promote my server as a domain controller. It is now almost 2 AM and I uninstalled it cause I made a i mistake. I didn't knew before doing that mistake that it will not migrate back the users. What a hell !!! I still have the profile on the disk but don't really know how it will react when I recreate a user. I think I will make a backup first on my external disk of the profile. I'd better learn how to do things then just trying.

About Laurent

Laurent Kempé

Laurent Kempé is the editor, founder, and primary contributor of Tech Head Brothers, a French portal about Microsoft .NET technologies.

He is currently employed by Innoveo Solutions since 10/2007 as a Senior Solution Architect and certified Scrum Master.

Founder, owner and Managing Partner of Jobping, which provides a unique and efficient platform for connecting Microsoft skilled job seekers with employers using Microsoft technologies.

Laurent was awarded Most Valuable Professional (MVP) by Microsoft from April 2002 to April 2012.

JetBrains Academy Member
Certified ScrumMaster
My status

Twitter

Flickr

www.flickr.com
This is a Flickr badge showing public photos and videos from Laurent Kempé. Make your own badge here.

Month List

Page List