Wednesday, July 25, 2012

Detach and Attach MSSQL DB



-- Get the datafiles location for the DB which you want to move
use MY_DATABASE
go
sp_helpfile
go

-- Deatch the DB which you want to move
use master
go
sp_detach_db 'MY_DATABASE'
go

-- Copy the files listed from step1 to new destination directory

-- Attach the DB with new files location
use master
go
sp_attach_db 'MY_DATABASE','D:\MSSQL\DATA\MY_DATABASE.mdf','D:\MSSQL\DATA\MY_DATABASE_1.ndf','D:\MSSQL\DATA\MY_DATABASE_2.ldf'
go


-- Get the New datafiles location for the DB which you moved
use MY_DATABASE
go
sp_helpfile
go


--For More Help, use below link
--http://support.microsoft.com/kb/224071

Tuesday, July 17, 2012

II6 compatability with II7


Issues Faced with Installer

Error message: 


at least knew how to start the msi package in verbose mode to create the log files.
Launch your msi in verbose mode:
msiexec /i yoursetup.msi /lv "C:\yourdirectory\logfile.txt"

msiexec /i C:\PaperlessRelease\PaperlessWSSetup.msi /lv "C:\PaperlessRelease\logfile.txt"
How to install the IIS 6 Metabase Compatibility components on IIS 7
The ActiveXperts Network Monitor Web Configurator requires that the Windows Server 2008-based or Windows Vista-based computer where you are configuring a Virtual Directory has the IIS 6 Metabase Compatibility components installed.
To install the IIS 6.0 Management Compatibility Components by using the Windows Server 2008 Server Manager
  • Click Start, click Administrative Tools and then Server Manager.
  • In the left navigation pane, expand Roles, and then right-click Web Server (IIS) and select Add Role Services.
  • On the Select Role Services pane, scroll down to IIS 6 Management Compatibility.
  • Select the check boxes for IIS 6 Metabase Compatibility and IIS 6 Management Console.
  • Click Next from the Select Role Services pane, and then click Install at the Confirm Installations Selections pane.
  • Click Close to leave the Add Role Services wizard.
To install the IIS 6.0 Management Compatibility Components by using the Windows Vista Control Panel
  • Click Start, click Control Panel, click Programs and Features, and then click Turn Windows features on or off.
  • Open Internet Information Services.
  • Open Web Management Tools.
  • Open IIS 6.0 Management Compatibility.
  • Select the check boxes for IIS 6 Metabase and IIS 6 configuration compatibility and IIS 6 Management Console.
  • Click OK.
To install the IIS 6.0 Management Compatibility Components by using the Windows 7 Control Panel
If you deploy a Web Forms application to a remote server running IIS 7, or if you publish a smart client application to a local or remote server running IIS 7, the Vista Metabase Compatibility component of IIS 7 must be installed on the server. This component is not installed by default. It is not required to deploy a Web Forms application to a local server.
You can install it from the Programs and Features page in the Windows control panel. Select Turn Windows features on or off, then select Internet Information Services>Web Management Tools>IIS 6 Management Compatibility>IIS Metabase and IIS 6 configuration compatibility.



Issue – 3
“HTTP Error 404.17 - Not Found
The requested content appears to be script and will not be served by the static file handler. "
Solution 
 cmd As Administrator -> cd C:\Windows\Microsoft.NET\Framework64\v2.0.30319 ->aspnet_regiis -i