How to install ASP.NET 2.0 Club / Personal Starter kit?

Discussion in 'ASP.NET 2.0' started by Bruce, Dec 10, 2005.

  1. Bruce

    Bruce DiscountASP.NET Staff

    Hello all!!

    We have received many questions as to how to install the ASP.NET 2.0 starter kits (Club / Personal) on our server. Below is a unofficial process that i used to install the kit.

    Requirements:

    VS.NET 2005 or VWD 2005
    SQL Client (Query Analyzer, osql, sqlcmd, Management studio, etc..) for you to execute the SQL script that create the starter kit.

    Procedure:

    I am going to use the club starter kit here as example but the the personal starter kit should work the same way.

    1) Download and install the starter kit if you do not already have it installed on your computer. Grap it at http://www.asp.net

    2) Create a new website / project using VS.NET 2K5 or VWD 2005. Use the Club starter kit template.

    3) Create the Application Services Database on the our SQL

    a) navigate to C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727
    b) execute this aspnet_regsql.exe -S [DB Server Name] -U [DB login] -P [Password] -A all -d [Database name]

    You can also use the wizard by just running aspnet_regsql.exe, but i found couple bugs in the UI. So, just run the command line!!!

    If do not see any error, you are good to go to next step. If you see errors, then you probably typed something wrong or you have some objects in your DB that conflicts w/ the Application Service DB Schema

    4) Create the starter kit database schema (MS suggest you put it on a different Database, but i put both the Application Services Database on the same server and had no problem.. up to you!)

    I am mystified w/ this step.. According to Microsoft, you will need to download a seperate script for SQL 2000 and MSDE. I compared the downloaded sql script w/ the one bundled w/ the starter kit (in App_data directory), they are exactly the same !!!!!

    Anyhow, run either the bundled script or the downloaded script using any SQL client. I used osql.

    osql -S <sql server name> -U <db_user> -P <DB_password> -d <DB_Name> -i club-add.sql

    This should create the club starter kit schema.

    5) Open the Web.config file in VS.NET / VWD.

    Change the connection string to point to the remote SQL server.

    Comment out the orginal connection string (or just delete it if you want). By default, the starter kit uses SQL Express.

    <!--<add name='ClubSiteDB' connectionString='Data Source=.\SQLExpress;Integrated Security=true;AttachDBFileName=|DataDirectory|Club.mdf;User Instance=True' providerName='System.Data.SqlClient'/>-->

    Add the following lines

    a) This configure the club starter kit use the remote SQL server
    <add name='ClubSiteDB' connectionString='Data Source=<DB_Server>;Integrated Security=false;Initial Catalog=<DB_Name>;User ID=<DB_User>;Password=<DB_password>' providerName='System.Data.SqlClient'/>

    b) The next line overide the default setting on the server
    <remove name='LocalSqlServer'/>

    c) This line is for the membership provider. It tell asp.net to use the remote SQL server.

    <add name='LocalSqlServer' connectionString='Data Source=<DB_Server>;Integrated Security=false;Initial Catalog=<DB_Name>;User ID=<DB_User>;Password=<DB_password>' providerName='System.Data.SqlClient' />

    6) Now build the kit by hitting Ctrl-F5. This step will also create the Role in the SQL server.

    7) Create the administrative user.

    Bring up the ASP.NET Configuration Tool. IN VS.NET, website -> Asp.net configuration Tool

    This will pop up a browser with the UI. Note that this configuration is pulled from the remote SQL server for the membership stuff.

    Goto the security tab. Create an admin user for the starter kit. Make sure you give it administrative role.

    8) Deploy your site to a subdirectory (or root if you prefer) using Copy Web Site function in VS.NET. If you don't know how, there is a kb article.. look it up yourself.

    BTW, if you deploy to a sub directory, create the directory using FTP first. If the directory do not exist, VS.NET will crash. This is a bug!

    9) Last step

    Logon to the hosting control panel.

    1) Navigate to IIS Manager -> Framework Version
    2) Make sure you have version 2.0 selected.

    3) Then navigate to the web application tool and mark the club SK as an application.

    That is it!!! Enjoy!

    Bruce

    DiscountASP.NET
    www.DiscountASP.NET
     
  2. Thanks for this great info Bruce.


    Bill Burrows
    MS MVP
     
  3. Hi,


    3) Create the Application Services Database on the our SQL


    What is Application Services Database and how to create it? Please explain. Thanks
     
  4. Rafal,


    Quoting MS, "The aspnet_regsql.exe is used to both create the SQL Server database and to add or remove options from an existing database." (see http://winfx.msdn.microsoft.com/library/default.asp?url=/library/en-us/dv_aspnetgenref/html/48a70e56-9e1c-4a41-a89e-5be7ac8fe18d.asp).


    In this case, step three is creating the default providers for the application - see Creating the Application Services Database for SQL Server located at: http://msdn2.microsoft.com/library/x28wfk74(en-us,vs.80).aspx


    Bill Burrows
    MS MVP
     

Share This Page