Zaki Mirza’s Blog


… About software and beyond!

ASP.Net Misconfiguration Solution

Many time when creating ASP.Net Application or ASP.Net  XML Web services people get into error reports e.g. Server Application Error, Authentication error in web.config file and more. I can’t really list all the errors that lie under this solution, but most problems are rooted from this very issue. (Im not really a professional solution provider or a troubleshooter, this post happens to come from my own experience. )

The issue is about multiple versions of ASP.Net installed on you machine. For example, you were working with Visual Studio 2003 and then switched to Visual studio 2005 or vice verse. You installed .Net platform 2.0 and even 3.0., usually, is left unconfigured during this configuration and if your very unfortunate, get misconfigured. One of the major root of this problem is, when people install IIS after they install the .Net Framework, or uninstall and reinstall it. If you are having problems with ASP.Net configurations, try the following method.

To solve this problem, following the following simple steps:

navigate to you Windows installation folder. Ill assume its C:\Windows\

navigate to Microsoft.Net\Framework\[version] (depending on which version of you want with IIS.)

You will see that there are many utilities in that folder. (in my case, it is C:\Windows\Microsoft.NET\Framework\v2.0.50727). The utility that we require is aspnet_iisreg.exe. (for a more technical introduction to this utility, click here). This utility reconfigures this version of for IIS. This utility requires command line arguments. Here’s what microsoft has to say about it:

When multiple versions of ASP.NET are installed on a computer, ASP.NET is said to be running side-by-side. In this setup, Internet Information Services (IIS) needs to know which version of the ASP.NET ISAPI (aspnet_isapi.dll) should process a page in an ASP.NET application. The ASP.NET ISAPI version that is associated with an ASP.NET application determines which version of the CLR is used for the application. An ASP.NET application is associated with an ASP.NET ISAPI version using a script map in IIS. To simplify the configuration process for an ASP.NET application, each version of ASP.NET comes with a linked version of Aspnet_regiis.exe.

Goto start menu and click Run and type “cmd”. A terminal window should open. Drag this aspnet_iisreg.exe file onto the terminal window. The terminal window will now be showing this file’s name and a prompt after it. type -i after it. Basically we need to run the command “aspnet_regiis.exe -i”. This will reinstall this version of for iis. It will take some time to configure IIS.

If the above solution does not provide the adequate result, or creates any problems feel free to ask.

A very good online magazine to read for IT professionals is the microsoft TechNet. For more information about configuring versions for IIS refer to this article on TechNet. For more information about .Net Framework tools check this out.

I hope this helps some poor souls out there who are too exhausted having to post on forums and searching on google.

Filed under: .net, Troubleshooter, , , , , , , ,

Channel9, on10 and ResearchChannel

Microsoft has been putting forward a lot of information that is very useful for developers and ametuer programmers. three of the top sites i have discovered yet are channel9, on10 and researchchannel (on MSR).

There are very cool video interviews on channel9, my favourite being “behind the code” and “going deep” series. Having seen tony williams (co inventor of COM), anders heljsberg (inventor of C#) and jim gray, it boosts the enthusiasm in this field. also, the Deep Windows series by Probert is also great on channel9 and is a must watch. The recent TechFest coverage has been successful at impressing me as well. Is hard to keep up with channel9 and/or sites like that when you have limited bandwidth 😦

 Im still to explore research channel yet.

Filed under: Blog Log

Great articles at thecodist

found a really cool article by thecodist here. Its a nice thought provoking blog on different aspects of programming.

Filed under: Blog Log

Mounting Windows shared folders in Fedora 6 under vmware

I was lately asked by some taking the Operating systems course for mounting/accessing windows shared folders inside linux installation under vmware virtual machine so here it is. (btw, if you are new to this check out the links i have put in this post for further reference)

Note: this is not a linux/windows security related post. Infact this post might create some security hazards in your enviornment. I do not take the responsibility for any kind of demage since putting security considerations in this problem is out of scope. I expect that these steps are applied in isolated enviornment(no-internet, or atleast firewalled internet). Sharing folders under windows may create security issues.

My Enviornment:

Windows XP sp2.
VMWare version 5.5.1 with vmware tools installed.
Fedora Core 6 Linux (default settings for installation)
Virtual Machine Custom settings (LSI Logic SCSI Harddrive. BusLogic SCSI is not detected by Fedora 6 during installation. either switch it IDE when asked between IDE and SCSI or to LSI Logic SCSI. this is set when creating a new virtual machine. instead of selecting “typical” option, select “custom” option and when asked about SCSI type click in LSI logic SCSI)

I am assuming that you will have the above enviornment or close to it. I also assume that you have not tempered with VMware settings since you installed it. because basically you get two virtual network connections when you install vmware. (to verify, go to control panel>network connections. Vmnet01 and VMnet08 will be connected and firewalled.) VMnet8 is the one we are going to use because it utilizes NAT which you can eventually use to expose linux installation inside your virtual machine to the internet connection in windows XP. To do additional tweaks or settings, vmware provides your with a virtual network editor tool (inside vmware software , edit>virtual network settings) where you can modify DHCP, NAT and other settings. do not temper with them if you have no idea what they mean.

Now on to settings up a shared folder inside windows. Create a folder on you desktop and call it anything (lets call it LINUXSHARE for now). Right click on it and select properties. In the sharing properties, enable sharing for it and check “allow network users to change my files”. Go to control panel>network connections and right click on vmnet8 connection and click properties. enable “show icon in notification area when connected” and click ok. that will show the network’s icon in the notification area of your task bar. right click on it and select “status”. click on support tab and note the IP address alloted to you by the vmnet DHCP server. mine is Yours will be similar as well. DHCP server will allocate IP address to all network connections in this virtual network.

Fire up vmware, and on the home page of your linux installation before starting the virtual machine double click on ethernet icon. In the network connection option, select the “custom” radio button and select vmnet8(NAT) from it. This is the same network that our windows XP is connected to and which is being controllled by the DHCP server.

Start the virtual machine. Login to linux. Hopefully the ethernet card will be detected by your linux distribution and will connect it too. easiest way to connect to the LINUXSHARE folder now in fedora 6 is, goto Places>Network servers. A file browser will open with “busy” icon on your mouse. Thats ok. We’re not dealing with that. Click on File>Connect To Server in that window. A dialog box will apear. in “Service type” select “windows share”. (see picture below)

windows share mounting

Click Connect. If you are lucky, this will take you to your windows shared folder and create a mount point on you desktop as well which will retain between bootups (cool ainnit?:) now you can use this folder in windows and linux both to transfer files.

Another way to do this is by using “mount” (mounting) command under root access. to do that, fireup the terminal. (assuming you have the root access, if not run the “su” command and supply the root password. you will get access of root, if you do not have it, contact your network admin but since we’re installing under vmware i hope you* are the admin). in the terminal type the command

mkdir Desktop/linuxshare
mount -t cifs // Desktop/linuxshare

comment by Bogdan:
Thanks, mounted xp’s shared folder from Topologilinux (cool thing, you may want to try it out). However, for slackware-based Topologilinux the mount command is slightly different:

mount -t smbfs // Desktop/linuxshare

the only changed thing is from ‘cifs’ to ’smbfs’ filesystem type.

(the above command is case-sensitive. also, use the IP address alloted to your window’s side of the network. the command also requires root access). this command will mount your shared drive on the folder on desktop called linuxshare which is now accessible on both windows and linux. To automate this task on bootup (so that you dont have to run this command over and over again) search the internet for details about “/etc/fstab” file and how to use it to automount drives and network shared folders. The earlier method i mentioned using the GUI is lot more easier though and will not require you to repeat steps everytime you boot your linux distribution (atleast in fedora 6).

If you have any problems feel free to ask. I would highly recommend anyone who is doing operating system assignments in linux to install linux directly on your system and not through a virtual machine and get used to it. Since we’re born with windows we find linux very hard but infact that is really not the case. Heck you are CS students and you think a couple of commands are a pain :s. Here are some good tutorials on linux file system (one of the biggest set back for windows users when shifting to linux). Required is a good habit to learn by one’s ownself and have a sense to explore and conquer.  Linux is a stable, secure, robust and highly efficient operating system which is growing in market every minute. It is used by highend servers and is slowly but steadily moving towards desktops (though desktops was never its target audience. But hey im not gonna start that religious debate). Best of all, its opensource and free. It lets you surf the net securely. You can have all you chat sessions in linux. You can access all your office documents in linux. It is a very fertile programming learning enviornment. And it gives you a sense of satisfaction that you are not using a stolen property. and btw commands are not as bad as people think it is. once you start using them your productivity increases manyfolds. (yes, citations needed) 

ah i know im using windows too right now … im in a serious shifting process to linux enviornment. Just too stuck on some windows application development projects. Im also planning to shift to java for a while and linux development in general. Hope i get to do that soon. (this has nothing to do with microsoft btw. microsoft is also a great company with great minds. I need to scale out and explore more frontiers in computing. I need a more free enviornment. Linux is a huge market and is challenging. Thats what attracts me. Most of all, Ill use windows when i can afford it. )

Till then, happy exploring linux and happy coding. Feel free to drop in feedback or queries about this post so that i can add more scenerios and more people can get advantage of this post.

Filed under: linux, Troubleshooter, windows

Intellisense, UI Frameworks and Efficiencies – Discussions with Steve Teixeira

Ive been following Steve’s Teixeira’s (Group Program Manager for Visual C++) blog for a while now. A couple of months ago, i started a discussion with Steve Teixeira –  about intellisense support in Visual Studio .Net 2005 in C# as compared to Visual C++.

Later on his Channel9 video blogpost about vc++ product strategy, i asked about performance degradation in .Net UI frameworks compared to win32 API and MFC stuff. Steve put his point of view on that which started a debate about UI frameworks that have emerged since the advent of .Net Framework including WinForms and WPF. The discussion took a pace which you can see on his post’s comments. The discussion continued with steve’s response to comments on the earlier discussion in response to my question.

I think this kind of discussion breeds good interaction between the people in the business and their customers and users. Microsoft’s recent initiatives to get things right again with customers by starting channel9 and on10 and many different contests and has somewhat saved its reputation. Lets see if Microsoft can turn it around towards up again.

Also, these kinds of discussions are where blogs show their true potential of information sharing. Yes there have been forums which have served the purpose since ages. But i think blogs serve a different purpose than forums. While forums are for discussion, blogs are more about rapid information sharing. Things like these would take ages to make it to the market in a book that are now discussed on blogs by various people around the blogosphere.

Filed under: Blog Log, C++, software, visual studio

Blog Stats

  • 104,198 landed here so far...
April 2007
« Mar   May »


Error: Twitter did not respond. Please wait a few minutes and refresh this page.

RSS Google Shared Items

  • An error has occurred; the feed is probably down. Try again later.

RSS Google Reader Starred Items

  • An error has occurred; the feed is probably down. Try again later.

Top Clicks

  • None