RE: Deployment Architecture/Attach SQL MDF



Hi Richard,

For the setup requirement you mentioned, I think most of them may need to
be done through custom action of windows installer package. Also, as you
mentioned that you're using installsheild, would you consider using windows
setup project(provided in visual studio) or use platform sdk to build the
MSI package? Here are some of my understanding and suggestion for the
three questions you mentioned:

1. SQL 2005 provide the SMO(.net based) programming interface for you to
manage SQL Server instance in code(like what management studio does). Here
are some examples:

Backup and Restore with User Instances
http://blogs.msdn.com/sqlexpress/rss_tag_Samples.xml

http://www.codeproject.com/useritems/SMODemo.asp

http://www.sqlteam.com/item.asp?ItemID=23185

you can use such code in your custom action program or class. Also, SQL
2005 expression edition provide a "User instance" feature which allow you
to connect a database file(mdf) without attaching it to the server
instance. See the following BOL for detail on "user instance"

#SQL Server 2005 Express Edition User Instances
http://msdn2.microsoft.com/en-us/library/bb264564.aspx

#User Instances for Non-Administrators
http://msdn2.microsoft.com/en-us/library/ms143684.aspx

For enable remote connection, I'm afraid you may need to configure it
after SQL Server has been installed since the setup options(commandline
prompt options) only contains setting for enable/disable network protocols:

#How to: Install SQL Server 2005 from the Command Prompt
http://msdn2.microsoft.com/en-us/library/ms144259.aspx#disablenetworkprotoco
ls

The following MSDN blog entry has mentioned some MSDN blog articles
introducing on using WMI to manage SQL Express:

#How to allow remote connections to SQL Server 2005 Express database
http://forums.microsoft.com/msdn/showpost.aspx?postid=271795&siteid=1&sb=0&d
=1&at=7&ft=11&tf=0&pageid=1



2. Yes, you're right. This is a typical scenario of using custom action and
here is a MSDN walkthrough example demonstrate on this:

http://msdn2.microsoft.com/en-us/library/5k10s063(VS.80).aspx



3. I'm not very familar with the SMS configuration settings, however, for
SQL Server installation, it has provide many command line
options/parameters you can configure.

#How to: Install SQL Server 2005 from the Command Prompt
http://msdn2.microsoft.com/en-us/library/ms144259.aspx#disablenetworkprotoco
ls

Also, if you're using the VS 2005's built-in bootstrapper package(under the
following location):

C:\Program Files\Microsoft Visual Studio
8\SDK\v2.0\BootStrapper\Packages\SqlExpress

You can customize it to change its commandline syntax. Here is a good
article introducing developing custom bootstrapper package that can be used
in VS 2005 setup project.

#Authoring a Custom Bootstrapper Package for Visual Studio 2005
http://msdn2.microsoft.com/en-us/library/aa730839(VS.80).aspx

Hope this helps.

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead



==================================================

Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.



Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.

==================================================



This posting is provided "AS IS" with no warranties, and confers no rights.




.



Relevant Pages

  • Silent install w/ an app needs to restore....
    ... the files on install of a custom application? ... silent install of SQL Server Express 2005 already. ... if there's any command line...commands...to do the restore or if I have to ...
    (microsoft.public.sqlserver.msde)
  • MSDE 2000 SP4 install gets to very end then rolls it all back
    ... On most machines my msde install goes fine. ... exuisting SQL server. ... Starting custom action SaveSqlServerServiceStates() ... Action start 14:23:53: RegisterClassInfo. ...
    (microsoft.public.sqlserver.setup)
  • Re: Critical Alert Update - W32.Slammer
    ... The .net SDK 1.0 sp1 comes with a very basic SQL Server engine for testing ... >> Microsoft SQL Desktop ... >>>cumulative SQL security patch, is completely safe from ... >> may install SQL ...
    (microsoft.public.security)
  • RE: SBS 2003 SP1 Upgrade - MSDE 2000 Service Pack 4 did not instal
    ... registry keys of the Microsoft SQL server and mail to me for analyze. ... This newsgroup only focuses on SBS technical issues. ... SBS 2003 SP1 Upgrade - MSDE 2000 Service Pack 4 did not install ...
    (microsoft.public.windows.server.sbs)
  • Re: Installed VS 2005 want to Manage SQL 2005 Server
    ... Microsoft SQL Server Management Studio 9.00.3042.00 ... Microsoft Analysis Services Client Tools 2005.090.3042.00 ... If you later install a more recent service pack, this service pack will be uninstalled automatically. ... How to uninstall SQL Server Management Studio ...
    (microsoft.public.sqlserver.setup)

Loading