<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Vinay&#039;s  Blog</title>
	<atom:link href="http://rdbmsexperts.com/Blogs/feed" rel="self" type="application/rss+xml" />
	<link>http://rdbmsexperts.com/Blogs</link>
	<description>Sql Server Porfessional</description>
	<lastBuildDate>Tue, 31 Aug 2010 09:59:44 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Maintenance Plan &#8220;No description found&#8221; error</title>
		<link>http://rdbmsexperts.com/Blogs/archives/148</link>
		<comments>http://rdbmsexperts.com/Blogs/archives/148#comments</comments>
		<pubDate>Tue, 31 Aug 2010 09:57:39 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Bug]]></category>
		<category><![CDATA[General]]></category>
		<category><![CDATA[Installation]]></category>
		<category><![CDATA[What I learned Today]]></category>
		<category><![CDATA[Registery]]></category>

		<guid isPermaLink="false">http://rdbmsexperts.com/Blogs/?p=148</guid>
		<description><![CDATA[for Sql server 2005, It was a bug when you modify maintainance plan you may get the error
&#8220;no description found&#8221; and you cannot edit the Maitainance plan.
problem could be the software you install is confilicting with sql server
to resolve this register following dll
regsvr32 msxml3.dll
regsvr32 msxml6.dll
Reference:
https://connect.microsoft.com/SQLServer/feedback/details/243850/ss2005-cannot-save-maintenance-plan-no-description-found-error?wa=wsignin1.0&#8243;
HTH
Vinay
]]></description>
			<content:encoded><![CDATA[<p>for Sql server 2005, It was a bug when you modify maintainance plan you may get the error<br />
&#8220;no description found&#8221; and you cannot edit the Maitainance plan.<br />
problem could be the software you install is confilicting with sql server</p>
<p>to resolve this register following dll<br />
regsvr32 msxml3.dll<br />
regsvr32 msxml6.dll</p>
<p>Reference:<br />
https://connect.microsoft.com/SQLServer/feedback/details/243850/ss2005-cannot-save-maintenance-plan-no-description-found-error?wa=wsignin1.0&#8243;<br />
HTH<br />
Vinay</p>
]]></content:encoded>
			<wfw:commentRss>http://rdbmsexperts.com/Blogs/archives/148/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Lock page memory</title>
		<link>http://rdbmsexperts.com/Blogs/archives/143</link>
		<comments>http://rdbmsexperts.com/Blogs/archives/143#comments</comments>
		<pubDate>Mon, 16 Aug 2010 09:30:01 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Memory]]></category>
		<category><![CDATA[Performance Tunning]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[What I learned Today]]></category>

		<guid isPermaLink="false">http://rdbmsexperts.com/Blogs/?p=143</guid>
		<description><![CDATA[When you configure the memory and on your system if other applications are also present, in such cases specially for 64 bit operating system the de-allocation of memory may impact huge performance issue. so lock page memory is useful here as to prevent/reserve the memory for Sql server.
1.       Run [...]]]></description>
			<content:encoded><![CDATA[<p>When you configure the memory and on your system if other applications are also present, in such cases specially for 64 bit operating system the de-allocation of memory may impact huge performance issue. so lock page memory is useful here as to prevent/reserve the memory for Sql server.<br />
1.       Run “secpol.msc” from windows run dialog -Local Security Setting</p>
<p>2.       Expand “Local Policies” in the left pane</p>
<p>3.       Click “User Rights Assignment”</p>
<p>4.       Double-click “”Lock Pages in Memory”</p>
<p>5.       In the “Local Security Setting” page, please check if the account used by SQL Server in the list box</p>
<p>Following is the link which shows how to configure Lock page memory.</p>
<p>http://www.sqlservercentral.com/blogs/sqldbauk/archive/2010/06/25/lock-pages-in-memory.aspx</p>
<p>HTH<br />
Vinay</p>
]]></content:encoded>
			<wfw:commentRss>http://rdbmsexperts.com/Blogs/archives/143/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Difference between Mirroring and Log Shipping</title>
		<link>http://rdbmsexperts.com/Blogs/archives/137</link>
		<comments>http://rdbmsexperts.com/Blogs/archives/137#comments</comments>
		<pubDate>Sat, 07 Aug 2010 13:42:14 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Disaster Recovery]]></category>
		<category><![CDATA[High Avaliability]]></category>
		<category><![CDATA[Log Shipping]]></category>
		<category><![CDATA[Mirroring]]></category>
		<category><![CDATA[Transaction Log]]></category>
		<category><![CDATA[What I learned Today]]></category>
		<category><![CDATA[High Availability]]></category>

		<guid isPermaLink="false">http://rdbmsexperts.com/Blogs/?p=137</guid>
		<description><![CDATA[It’s been quite some time that I blog, Sorry about that I was busy with my movement from USA to India and changed my job  part of life ,okay  back to India (Pune).
Lastly I wrote a blog on High Availability techniques here and How to setup simple Mirroring Here.  Continue on that following are some of [...]]]></description>
			<content:encoded><![CDATA[<p>It’s been quite some time that I blog, Sorry about that I was busy with my movement from USA to India and changed my job  part of life ,okay  back to India (Pune).</p>
<p>Lastly I wrote a blog on High Availability techniques <a href="http://rdbmsexperts.com/Blogs/archives/73" target="_blank">here </a>and How to setup simple Mirroring <a href="http://rdbmsexperts.com/Blogs/archives/83" target="_blank">Here</a>.  Continue on that following are some of the common difference of log shipping and Mirroring, actually both uses log and move the transaction “Mirroring used to call <strong>Real time Log shipping&#8221;. </strong>but the way it works makes it difference.</p>
<table border="1" cellspacing="0" cellpadding="0" width="767">
<tbody>
<tr>
<td width="359">
<p style="text-align: center;">Mirroring</p>
</td>
<td width="408">
<p style="text-align: center;">Log Shipping</p>
</td>
</tr>
<tr>
<td width="359">Principle can have single mirror</td>
<td width="408">Multiple stand by servers can be possible.</td>
</tr>
<tr>
<td width="359">generally good to have 10 DB&#8217;s for one server</td>
<td width="408">No limit</td>
</tr>
<tr>
<td width="359">No data loss and can be used as high availability like Clustering</td>
<td width="408">May be some data loss as per schedule. And secondary server takes some manual work and time to be primary</td>
</tr>
<tr>
<td width="359">Read log read and transfer the committed transaction through endpoints.</td>
<td width="408">Transfer the log back up and restored at standby server.</td>
</tr>
<tr>
<td width="359">only committed transaction</td>
<td width="408">Committed as well as uncommitted and whole log backup restores.</td>
</tr>
<tr>
<td width="359">PAGE repair is possible if principle database page gets corrupt</td>
<td width="408">N/A</td>
</tr>
<tr>
<td width="359">Mirrored DB can only be accessed using snapshot DB</td>
<td width="408">Secondary server can be reporting server (read-only)</td>
</tr>
<tr>
<td width="359">Principle and Mirror server should have same edition</td>
<td width="408">Primary and secondary server should be compatible server for restore.</td>
</tr>
<tr>
<td width="359">Require FULL recovery model</td>
<td width="408">Require  FULL or Bulk-Logged recovery model</td>
</tr>
<tr>
<td width="359">requires Sql Server 2005 SP1 or higher &#8211; Enterprise or Developer Editions</td>
<td width="408">Enterprise edition for Sql Server 2000 and even Standard edition for 2005 can works</td>
</tr>
<tr>
<td width="359">Immediate data moved depending on SEND and WAIT queue</td>
<td width="408">Can control the flow of data by scheduling jobs</td>
</tr>
<tr>
<td width="359">As Immediate data moves, user error reflects at mirrored DB</td>
<td width="408">As delay in data transfer can avoided user error.</td>
</tr>
</tbody>
</table>
<p>Hope this will help someone.</p>
<p>Thanx.</p>
<p>Vinay</p>
]]></content:encoded>
			<wfw:commentRss>http://rdbmsexperts.com/Blogs/archives/137/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Important: System Objects/Views/DMV/DMF</title>
		<link>http://rdbmsexperts.com/Blogs/archives/134</link>
		<comments>http://rdbmsexperts.com/Blogs/archives/134#comments</comments>
		<pubDate>Thu, 17 Jun 2010 07:48:09 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[DMV]]></category>
		<category><![CDATA[General]]></category>
		<category><![CDATA[Index]]></category>
		<category><![CDATA[Memory]]></category>
		<category><![CDATA[Performance Tunning]]></category>

		<guid isPermaLink="false">http://rdbmsexperts.com/Blogs/?p=134</guid>
		<description><![CDATA[Important: System Objects/Views/DMV/DMF
This is the some of the list of System Objects/Views/DMV/DMF. 
Catalog View:
All system information is stored on catalog views which look like
Sys.xxx
Eg. Sys.databases
Compatibile views:
This are views to manage old compatibility
Select * from master.dbo.sysprocesses
Server Side DMV

Sys.dm_exec* (query exection)
Sys.dm_io* (io level)
Sys.dm_db* (database level  like index….)
Sys.dm_tran* (transaction level)
Sys.dm_os* (os level)

Component level DMV:

Sys.dm_Repl* (replication)
Sys.dm_broker* (service broker)
Sys.dm_fts* (full [...]]]></description>
			<content:encoded><![CDATA[<p><strong>Important: System Objects/Views/DMV/DMF</strong></p>
<p>This is the some of the list of <strong>System Objects/Views/DMV/DMF. </strong></p>
<p>Catalog View:</p>
<p>All system information is stored on catalog views which look like</p>
<p>Sys.xxx</p>
<p>Eg. Sys.databases</p>
<p>Compatibile views:</p>
<p>This are views to manage old compatibility</p>
<p>Select * from master.dbo.sysprocesses</p>
<p>Server Side DMV</p>
<ol>
<li>Sys.dm_exec* (query exection)</li>
<li>Sys.dm_io* (io level)</li>
<li>Sys.dm_db* (database level  like index….)</li>
<li>Sys.dm_tran* (transaction level)</li>
<li>Sys.dm_os* (os level)</li>
</ol>
<p>Component level DMV:</p>
<ol>
<li>Sys.dm_Repl* (replication)</li>
<li>Sys.dm_broker* (service broker)</li>
<li>Sys.dm_fts* (full Text Search)</li>
<li>Sys.dm_clr*( CLR)</li>
</ol>
<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211; Understand the dmv:</p>
<p>Require permission as <strong>view database stats or view server stats</strong></p>
<p>1.  select count(1) from sys.all_objects –1841</p>
<p>2.  select * from sys.databases</p>
<p>3.  select count(*) from sys.system_objects &#8211;1763</p>
<p>4.  select * from sys.sysobjects –- show all the objects in present database</p>
<p>5.  select * from sys.system_sql_modules where object_id=object_id(&#8217;sys.sysobjects&#8217;)—-shows code for system objects</p>
<p>6.  select * from sys.dm_exec_sessions -– like sysprocesses info</p>
<p>7.  select * from sys.dm_exec_requests order by logical_reads desc -– like sysprocesses info</p>
<p>select * from sys.dm_exec_requests r cross apply sys.dm_exec_sql_text(r.sql_handle) where session_id&gt;50</p>
<p>8.  select * from sys.dm_os_waiting_tasks  &#8212; current waits</p>
<p>9.  select * from sys.dm_os_wait_stats  &#8212; report for waits</p>
<p>10.select * from sys.dm_os_latch_stats –report for latchs</p>
<p>11.select db_name(database_id),* from sys.dm_io_virtual_file_stats(NULL , NULL )</p>
<p>order by io_stall desc</p>
<p>12.select * from sys.dm_os_wait_stats</p>
<p>13.select * from sys.dm_db_index_operational_stats(db_id(),NULL,NULL,NULL)</p>
<p>14.select * from sys.dm_db_partition_stats</p>
<p>15.select * from sys.dm_exec_query_stats</p>
<p>Sys.dm_exec_query_stats:</p>
<p>Select * from Sys.dm_exec_query_stats qs</p>
<p>cross apply sys.dm_exec_sql_text(qs.sql_handle)</p>
<p>cross apply sys.dm_exec_query_plan(qs.plan_handle)</p>
<p>16.select * from sys.dm_db_index_usage_stats</p>
<p>17.select object_name(object_id),* from sys.dm_db_index_physical_stats (</p>
<p>db_id(),null,null,null,default)  &#8212; index fragmentation information</p>
<p>18.select * from sys.dm_os_latch_stats</p>
<p>19.select * from sys.dm_db_missing_index_group_stats</p>
<ol>
<li>select * from sys.dm_exec_query_optimizer_info</li>
<li>select * from sys.dm_exec_cached_plans</li>
</ol>
<p>22.select * from sys.system_internals_allocation_units  &#8212; inside information about object first root and next page address.</p>
<ol>
<li>select * from sys.system_internals_partitions  &#8211;more inforation abt views useful for join of system_internals_allocation_units</li>
</ol>
<p>22, 23 used to be achieve using DBCC IND for DBCC Page() with dbcc traceon(3604)</p>
<ol>
<li>select * from sys.dm_io_pending_io_requests  &#8212; any pending io</li>
<li>select * from sys.dm_tran_locks  &#8211;lock info</li>
<li>select * from sys.dm_tran_active_transactions</li>
<li>select * from sys.dm_os_sys_info  &#8211;sys info</li>
<li>select * from sys.dm_os_performance_counters  &#8211;perfmon info</li>
<li>select * from sys.dm_os_schedulers  &#8211;CPU info</li>
<li>select * from sys.dm_os_ring_buffers  &#8211;memory</li>
<li>select * from sys.dm_os_buffer_descriptors  &#8211;memory</li>
</ol>
<p>32.select * from sys.dm_os_memory_cached_counters  &#8211;Sql server 2008</p>
<p>33.select * from sys.dm_os_sys_memory &#8211;Sql server 2008</p>
<p>DBCC MEMORYSTATS</p>
<p>Thanx.</p>
<p>Vinay</p>
<p>Reference:</p>
<p><a href="http://technet.microsoft.com/en-us/library/bb838723(office.12).aspx">http://technet.microsoft.com/en-us/library/bb838723(office.12).aspx</a></p>
]]></content:encoded>
			<wfw:commentRss>http://rdbmsexperts.com/Blogs/archives/134/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>List of indexes and Parallel queries</title>
		<link>http://rdbmsexperts.com/Blogs/archives/128</link>
		<comments>http://rdbmsexperts.com/Blogs/archives/128#comments</comments>
		<pubDate>Thu, 03 Jun 2010 12:42:01 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Index]]></category>
		<category><![CDATA[Performance Tunning]]></category>
		<category><![CDATA[Personal]]></category>
		<category><![CDATA[What I learned Today]]></category>

		<guid isPermaLink="false">http://rdbmsexperts.com/Blogs/?p=128</guid>
		<description><![CDATA[Today while being on forum found this information so though to blog for future reference. thanx Uri Dimant for sharing this. 
WITH cte 
AS 
( 
SELECT object_name(ic.object_id) as object_name , index_name = i.name,
&#8216;column&#8217; = c.name,
        &#8216;column usage&#8217; = CASE ic.is_included_column
                    WHEN 0 then &#8216;KEY&#8217;
                    ELSE &#8216;INCLUDED&#8217;
        END
FROM sys.index_columns ic JOIN sys.columns c
    ON ic.object_id = c.object_id
    AND ic.column_id = [...]]]></description>
			<content:encoded><![CDATA[<p>Today while being on forum found this information so though to blog for future reference. thanx <strong>Uri Dimant</strong> for sharing this. </p>
<p>WITH cte </p>
<p>AS </p>
<p>( </p>
<p>SELECT object_name(ic.object_id) as object_name , index_name = i.name,<br />
&#8216;column&#8217; = c.name,<br />
        &#8216;column usage&#8217; = CASE ic.is_included_column<br />
                    WHEN 0 then &#8216;KEY&#8217;<br />
                    ELSE &#8216;INCLUDED&#8217;<br />
        END<br />
FROM sys.index_columns ic JOIN sys.columns c<br />
    ON ic.object_id = c.object_id<br />
    AND ic.column_id = c.column_id<br />
JOIN sys.indexes i<br />
    ON i.object_id = ic.object_id<br />
    AND i.index_id = ic.index_id </p>
<p>) SELECT * FROM cte WHERE object_name =&#8217;tablename&#8217; </p>
<p>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211; </p>
<p>Below is the query which give information about parallel queries: </p>
<p>&#8211;This first thing to check if CPU is at 100% is to look for parallel queries: </p>
<p>&#8211; Tasks running in parallel (filtering out MARS requests below): </p>
<p><span style="font-size: x-small; color: #0000ff;"><span style="font-size: x-small; color: #0000ff;">select * from sys.dm_os_tasks as t<span style="font-size: x-small;"> </span> </p>
<p> where t.session_id in ( select t1.session_id<span style="font-size: x-small;"> </span>from sys.dm_os_tasks as t1<span style="font-size: x-small;">  </span>group by t1.session_id<span style="font-size: x-small;"> </span>having count(*) &gt; 1<span style="font-size: x-small;"> </span> </p>
<p> and min(t1.request_id) = max(t1.request_id)); </p>
<p>&#8211; Requests running in parallel: </p>
<p><span style="font-size: x-small;"> </p>
<p> select *<span style="font-size: x-small;"> from sys.dm_exec_requests as r<span style="font-size: x-small;"> </span> </p>
<p> join (<span style="font-size: x-small;">select t1.session_id, min(t1.request_id) </p>
<p><span style="font-size: x-small;"> </p>
<p> from sys.dm_os_tasks as t1<span style="font-size: x-small;"> </span> </p>
<p> group by t1.session_id<span style="font-size: x-small;"> </span> </p>
<p> having count(*) &gt; 1<span style="font-size: x-small;"> </span> </p>
<p> and min(t1.request_id) = max(t1.request_id) </p>
<p><span style="font-size: x-small;"> </p>
<p> ) as t(session_id, request_id) </p>
<p><span style="font-size: x-small;"> </p>
<p> on r.session_id = t.session_id<span style="font-size: x-small;"> </span> </p>
<p> and r.request_id = t.request_id; </p>
<p> Thanx. </p>
<p>Vinay </p>
<p>Reference: </p>
<p><a href="http://social.msdn.microsoft.com/Forums/en-US/transactsql/thread/383c0712-9416-4e23-9f45-d74148202596">http://social.msdn.microsoft.com/Forums/en-US/transactsql/thread/383c0712-9416-4e23-9f45-d74148202596</a> </p>
<p><a href="http://social.msdn.microsoft.com/Forums/en-US/sqldatabaseengine/thread/e5a72c22-56c9-420a-bf2f-05b834665e41">http://social.msdn.microsoft.com/Forums/en-US/sqldatabaseengine/thread/e5a72c22-56c9-420a-bf2f-05b834665e41</a> </p>
<p></span></p>
<p></span></p>
<p></span></p>
<p></span></p>
<p></span></p>
<p></span></p>
<p></span></span></p>
]]></content:encoded>
			<wfw:commentRss>http://rdbmsexperts.com/Blogs/archives/128/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Introduction to Memory configuration</title>
		<link>http://rdbmsexperts.com/Blogs/archives/120</link>
		<comments>http://rdbmsexperts.com/Blogs/archives/120#comments</comments>
		<pubDate>Sun, 16 May 2010 17:38:05 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Memory]]></category>
		<category><![CDATA[Performance Tunning]]></category>
		<category><![CDATA[Webcast]]></category>
		<category><![CDATA[What I learned Today]]></category>

		<guid isPermaLink="false">http://rdbmsexperts.com/Blogs/?p=120</guid>
		<description><![CDATA[Introduction to Memory configuration
Yesterday I was discussion with one of my friend on memory management and internals to expertise in sql server. So started working more on it and found very fundamental information everyone should aware of it. Memory management for MS sql server is very important. We should have a basic knowledge of memory information, [...]]]></description>
			<content:encoded><![CDATA[<p>Introduction to Memory configuration</p>
<p>Yesterday I was discussion with one of my friend on memory management and internals to expertise in sql server. So started working more on it and found very fundamental information everyone should aware of it. Memory management for MS sql server is very important. We should have a basic knowledge of memory information, how it works and how to configure to effectively usage of it. Memory is a common resource of the system.</p>
<p>Memory stores everything about sql server.</p>
<p><strong>For 32 Bits system(x86):-</strong></p>
<p>Memory has a limit of 4GB x86 (32bit 2<sup>32</sup>) of VAS (Virtual Address Space) which divides as 64KB for Null blocks which stores NULL Pointers, 2GB is for USER MODE and 2 GB for Kernel Mode. This is the default behavior of the memory configuration.</p>
<p>We can increase the USER mode to 3GB by adding <strong>/3GB </strong>option with /USERVA at <strong>BOOT.ini </strong>file till Windows server 2003 and earlier version, for Windows server 2008 is BCDEdit.exe. This will be good for USERMODE but restricting KERNEL mode to 1GB which may impact performance somewhere.</p>
<p>What if we wanted to use more than 4GB of memory? For Windows to recognize more than 4GB of memory we have to enable <strong>PAE </strong>option. PAE option will increase the system to recognize more than 4GB of memory, which is up to 64GB for x86.</p>
<p>Now our system has more than 4GB of memory, but for MS Sql server to use more than 3GB of memory requires to enable <strong>AWE </strong>configuration option. Using AWE option Sql server will recognize that extra memory enabled by PAE. <span style="text-decoration: underline;">This extra memory is only good for database cache pages not procedure cache.</span></p>
<p>USER Mode of Memory is divided into two parts:</p>
<ol>
<li>MemToLeave (Stack Size  * Max Worker Thread ) + (-g startup option)</li>
</ol>
<p>Default values</p>
<p>Stack size =512k</p>
<p>Max worker thread = 256k</p>
<p>-g option =256mb (we can change this)</p>
<ol>
<li>Buffer Pool (USERMode (2GB) – MemToLeave).</li>
</ol>
<p><strong><span style="text-decoration: underline;">For 64 Bits system:-</span></strong></p>
<p>The system is having same partitions but here the system has huge capacity for the system. 2 64. so here USER MODE could be 2GB to 8TB which is very high and generally nobody uses this. And Kernel Mode uses up to 8TB, means for 64 Bit system there is no upper limit for memory. Hence no need for <strong>PAE </strong>option. But we can use AWE ability to increase the VAS is used.</p>
<p><span style="text-decoration: underline;">WOW (Windows on windows)</span></p>
<p>System, which has 32 Bit Sql server on 64 Bit Windows system(WOW). We can have 4GB of USER Mode space. And still use AWE for extra USER Memory.</p>
<p>Additional information:</p>
<p><strong>Buffer Pool Stores:</strong></p>
<p>&gt;&gt;  Sql server connection requires 32 bits of Memory</p>
<p>&gt;&gt;  Lock requires 96 Bytes of memory.</p>
<p>&gt;&gt;  Data Pages</p>
<p>&gt;&gt;  Compile plan</p>
<p>&gt;&gt; Execution Plan</p>
<p>&gt;&gt; Workable</p>
<p>As this is my first blog exclusive on memory, will try to write some more blogs on Memory in future.</p>
<p>Thanx.</p>
<p>Vinay</p>
<p><a href="http://vinay-thakur.spaces.live.com/blog/">http://vinay-thakur.spaces.live.com/blog/</a></p>
<p><a href="http://rdbmsexperts.com/Blogs/wp-admin/post-new.php">http://rdbmsexperts.com/Blogs/</a></p>
<p>https://twitter/thakurvinay</p>
<p>Reference:</p>
<p><a href="http://blogs.msdn.com/slavao/archive/category/9005.aspx">http://blogs.msdn.com/slavao/archive/category/9005.aspx</a></p>
<p>Bob Ward&#8217;s PASS Webcast.</p>
]]></content:encoded>
			<wfw:commentRss>http://rdbmsexperts.com/Blogs/archives/120/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Audio Webcast &#8211; Whats News</title>
		<link>http://rdbmsexperts.com/Blogs/archives/110</link>
		<comments>http://rdbmsexperts.com/Blogs/archives/110#comments</comments>
		<pubDate>Wed, 12 May 2010 07:30:32 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Webcast]]></category>
		<category><![CDATA[Whats New]]></category>
		<category><![CDATA[Audio]]></category>

		<guid isPermaLink="false">http://rdbmsexperts.com/Blogs/?p=110</guid>
		<description><![CDATA[Yesterday I though of doing an audio webcast what all I blog.
So started audio webcast, its a series of webcasts on Whats New blog category which I blog here and here please refer blog when listen.
Today I uploaded it on public folder. Hope you will enjoy it same as I did while recording.
Following are the audio [...]]]></description>
			<content:encoded><![CDATA[<p>Yesterday I though of doing an audio webcast what all I blog.</p>
<p>So started audio webcast, its a series of webcasts on <strong>Whats New </strong>blog category which I blog <a href="http://vinay-thakur.spaces.live.com/?_c11_BlogPart_BlogPart=blogview&amp;_c=BlogPart&amp;partqs=cat%3dWhats%2520New" target="_blank">here </a>and <a href="http://rdbmsexperts.com/Blogs/?p=57" target="_blank">here</a> please refer blog when listen.</p>
<p>Today I uploaded it on public folder. Hope you will enjoy it same as I did while recording.</p>
<p>Following are the audio webcasts and their link to it</p>
<p>1. History of MS Sql Server</p>
<p>Audio Webcast:</p>
<p><a href="http://cid-645e3fc14d5130f2.skydrive.live.com/self.aspx/.Public/History%5E_of%20%5E_MSSqlServer.wma">http://cid-645e3fc14d5130f2.skydrive.live.com/self.aspx/.Public/History^_of%20^_MSSqlServer.wma</a></p>
<p>2. Whats New MS Sql Server 7</p>
<p>Audio Webcast:</p>
<p><a href="http://cid-645e3fc14d5130f2.skydrive.live.com/self.aspx/.Public/History%5E_of%20%5E_MSSqlServer.wma#resId/645E3FC14D5130F2!744">http://cid-645e3fc14d5130f2.skydrive.live.com/self.aspx/.Public/History^_of%20^_MSSqlServer.wma#resId/645E3FC14D5130F2!744</a></p>
<p>3.  Whats New in MS Sql Server 2000</p>
<p>Audio Webcast:</p>
<p><a href="http://cid-645e3fc14d5130f2.skydrive.live.com/self.aspx/.Public/History%5E_of%20%5E_MSSqlServer.wma#resId/645E3FC14D5130F2!746">http://cid-645e3fc14d5130f2.skydrive.live.com/self.aspx/.Public/History^_of%20^_MSSqlServer.wma#resId/645E3FC14D5130F2!746</a></p>
<p>4. Whats New in MS Sql Server 2005</p>
<p>Audio Webcast:</p>
<p><a href="http://cid-645e3fc14d5130f2.skydrive.live.com/self.aspx/.Public/History%5E_of%20%5E_MSSqlServer.wma#resId/645E3FC14D5130F2!747">http://cid-645e3fc14d5130f2.skydrive.live.com/self.aspx/.Public/History^_of%20^_MSSqlServer.wma#resId/645E3FC14D5130F2!747</a></p>
<p>5. Whats New in MS Sql Server 2008 &amp; MS Sql Server 2008 R2</p>
<p>Audio Webcast:</p>
<p><a href="http://cid-645e3fc14d5130f2.skydrive.live.com/self.aspx/.Public/History%5E_of%20%5E_MSSqlServer.wma#resId/645E3FC14D5130F2!748">http://cid-645e3fc14d5130f2.skydrive.live.com/self.aspx/.Public/History^_of%20^_MSSqlServer.wma#resId/645E3FC14D5130F2!748</a></p>
<p>Please let me know your feedback on this.</p>
<p>Please read the <strong>Blog </strong>as a reference for this Audio Webcast.</p>
<p><a href="http://vinay-thakur.spaces.live.com/?_c11_BlogPart_BlogPart=blogview&amp;_c=BlogPart&amp;partqs=cat%3dWhats%2520New">http://vinay-thakur.spaces.live.com/?_c11_BlogPart_BlogPart=blogview&amp;_c=BlogPart&amp;partqs=cat%3dWhats%2520New</a></p>
<p>and</p>
<p><a href="http://rdbmsexperts.com/Blogs/?p=57">http://rdbmsexperts.com/Blogs/?p=57</a></p>
<p><a href="http://vinay-thakur.spaces.live.com/?_c11_BlogPart_BlogPart=blogview&amp;_c=BlogPart&amp;partqs=cat%3dWhats%2520New"></a></p>
<p>Thanks and Happy Learning.</p>
<p>Thanx.</p>
<p>Vinay</p>
<p><a href="http://rdbmsexperts.com/Blogs/wp-admin/post-new.php">http://rdbmsexperts.com/Blogs</a></p>
<p><a href="http://vinay-thakur.spaces.live.com/">vinay-thakur.spaces.live.com/</a></p>
<p>twitter/thakurvinay</p>
]]></content:encoded>
			<wfw:commentRss>http://rdbmsexperts.com/Blogs/archives/110/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Performance Tunning -Checklist</title>
		<link>http://rdbmsexperts.com/Blogs/archives/106</link>
		<comments>http://rdbmsexperts.com/Blogs/archives/106#comments</comments>
		<pubDate>Thu, 06 May 2010 05:50:56 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Performance Tunning]]></category>

		<guid isPermaLink="false">http://rdbmsexperts.com/Blogs/?p=106</guid>
		<description><![CDATA[continue with performace tunning stuff, I would like to make a checklist (kind of) for general performance tunning or dba checklist.
I highly recommend to read my earlier post on performance tunning here
Performance Monitoring (Activities):

Dashboard report (2005) Data collector (2008)
Performance Monitor (Counters-CPU/Memory/IO/Network/Sql Level)
Profiler Utility trace/ Server Side trace….. (can insert into table and analyze)
Periodically snapshot for Stats (waits and file [...]]]></description>
			<content:encoded><![CDATA[<p>continue with performace tunning stuff, I would like to make a checklist (kind of) for general performance tunning or dba checklist.</p>
<p>I highly recommend to read my earlier post on performance tunning <a href="http://vinay-thakur.spaces.live.com/?_c11_BlogPart_BlogPart=summary&amp;_c=BlogPart&amp;partqs=cat%3dPerformance" target="_blank">here</a></p>
<p>Performance Monitoring (Activities):</p>
<ol>
<li>Dashboard report (2005) Data collector (2008)</li>
<li>Performance Monitor (Counters-CPU/Memory/IO/Network/Sql Level)</li>
<li>Profiler Utility trace/ Server Side trace….. (can insert into table and analyze)</li>
<li>Periodically snapshot for Stats (waits and file stats) and other DMV’s</li>
<li>Using DMV to find the query which needs to optimize.</li>
<li>Use of Database Tuning Advices</li>
<li>Analyze the query compilation plan and time for compilation/execution</li>
<li>Check the index /statistics</li>
<li>Check the tempDB bottleneck</li>
</ol>
<p>Other DBA checks:</p>
<ol>
<li>System configuration</li>
<li>Check jobs – Backup/reindex/statistics</li>
<li>Check disk space</li>
<li>Check Error log (can insert into table and analyze)</li>
<li>Check Event Viewver</li>
</ol>
<p>Other checks specific to the components like High Availability and other components is not discuss here.</p>
<p>Will blog in detail of each one.  also try to keep  updated this blog as and when require&#8230;. appreciate your comments on this. please help me to make this list better.</p>
<p>Thanx.</p>
<p>Vinay</p>
]]></content:encoded>
			<wfw:commentRss>http://rdbmsexperts.com/Blogs/archives/106/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>TempDB Internals</title>
		<link>http://rdbmsexperts.com/Blogs/archives/87</link>
		<comments>http://rdbmsexperts.com/Blogs/archives/87#comments</comments>
		<pubDate>Sat, 01 May 2010 07:46:03 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Books]]></category>
		<category><![CDATA[TempDB]]></category>
		<category><![CDATA[What I learned Today]]></category>
		<category><![CDATA[Performance Tunning]]></category>

		<guid isPermaLink="false">http://rdbmsexperts.com/Blogs/?p=87</guid>
		<description><![CDATA[TempDB Internals:
TempDB is very important DB in sql server, generally sql server automatically takes care of the storage management of the system, and we do not require bothering much about this storage, also now days we are having good/much resources (IO/CPU/Memory) so we don’t need to think much about the TempDB usage. But for the [...]]]></description>
			<content:encoded><![CDATA[<p><strong>TempDB Internals:</strong></p>
<p>TempDB is very important DB in sql server, generally sql server automatically takes care of the storage management of the system, and we do not require bothering much about this storage, also now days we are having good/much resources (IO/CPU/Memory) so we don’t need to think much about the TempDB usage. But for the system which has very heavy activity and huge database size may have to consider the usage of tempDB and may be sometime tempDB goes out of disk. Especially after Sql server 2005 were there was a huge improvement at system includes versioning which requires heavy usage of tmepDB.  Hence now a days its very important for everyone to know what is tempDB stores and how it works ,Also what all general recommendation/consideration about tempDB.</p>
<p><span style="text-decoration: underline;">TempDB has following properties:</span></p>
<ol>
<li>This is the <strong>System database</strong> can only be <strong>“Simple”</strong> Recovery mode.</li>
<li>Every Sql server instance is having <strong>only one</strong> TempDB Database</li>
<li><strong>Auto creates</strong> same as Model whenever sql server restarts</li>
<li><strong>Initial size</strong> of TempDB data file is 8MB<strong> </strong>and log file is 512KB</li>
<li>Does not allow <strong>Auto shrink</strong>.</li>
<li>TempDB will have only one <strong>filegroup</strong> but can add any number of files.</li>
<li>Stores all temporary data means all <strong>data will lost once sql server stop/restarts</strong></li>
<li>Cannot <strong>drop</strong> the tempDB database and cannot <strong>change the mode</strong> of if(readonly/emergency/Offline…)</li>
<li><strong>Database snapshot</strong> is not supported.</li>
<li>Cannot take backup of TempDB.</li>
<li>Database checksum is not supported.</li>
<li>Objects of TempDB can be cached : if we have small temp objects that can be cached due to drop and create of frequent table (size is less then 8mb).</li>
<li>Log growth always on disk whereas for small data it keeps on memory for tempdb</li>
<li>For tempdb Log file “REDO” operation not required. After value is not logged(eg update x set y=’abc’ where y=’xyz’ here tempdb does not log ‘abc’)</li>
<li>Instance file initialization, when autogrowh happens space of growth is “Zeroed” them out. Make autogrowh fast but could cause security issue-</li>
</ol>
<p><span style="text-decoration: underline;">TempDB stores:</span></p>
<p>a)      Temporary objects</p>
<p>b)      Internal Objects</p>
<p><strong>c) </strong><strong>Version Stored Objects – New in sql server 2005</strong></p>
<p><strong>a) </strong><strong><span style="text-decoration: underline;">Temporary objects: </span></strong></p>
<p>Temporary objects are objects which is created temporary using #, ## or veritable @, @@  etc.</p>
<p>eg. If you create a temp table #abc</p>
<p>create table #abc (a int,b varchar(8000),c varchar(8000))</p>
<p>Irrespective of the database you are using this table will create at tempDB database</p>
<p>select * from tempdb.sys.all_objects where name like &#8216;%abc%&#8217;</p>
<p>You will see the object name something like this</p>
<p>#abc________________________________________________________________________________________________________________000000000006 (xxx –connection number)tab</p>
<p>So always remember when you create any temporary objects there is a cost of it as they reside at tmepDB database.</p>
<p><strong>b) </strong><strong><span style="text-decoration: underline;">Internal Objects: </span></strong></p>
<p>This is very important thing and generally most of the Developers/DBA does not aware of this. Internal objects are not visible but it uses tempDB storage. When we run a query which requires temporary object to be created to perform that operation is created in tempDB.</p>
<p>Eg. Restart the sql services. And check the size of TempDB data files.</p>
<p>Generally it will be 8mb.</p>
<p>Now suppose you have one big table. Here I am using charge table from credit database download from <a href="http://www.sqlskills.com/">www.sqlskills.com</a></p>
<p>select * from charge order by category_no</p>
<p>Now once you run above select statement the size of tempDB data file grows to appx 80MB (wow) …. Howz that. As “order by” clause require creating a temp object for ordering the records from charge table because category_no does not have index on it (not ordered).</p>
<p>There are some other operations which generates internal objects are: <strong>Hash join, hash aggregates, DBCC check, Order By etc.</strong></p>
<p><strong>c) </strong><strong><span style="text-decoration: underline;">Version Stored Objects:</span></strong></p>
<p>Sql server 2005 has improved the engine and enables the row versioning; Following are some of the features which use row versioning.</p>
<p><em>&gt;&gt; Snapshot Isolation.</em></p>
<p><em>&gt;&gt;Triggers:</em></p>
<p>In previous version of Sql server 2000 and earlier triggers used to store into log file. On sql server 2005 onwards it keeps into TempDB. After trigger store Versioning.</p>
<p><em>&gt;&gt;Online index Build:</em></p>
<p>When online index rebuild and at the same time any DML statements happens it stores as versioning.</p>
<p><span style="text-decoration: underline;">Recommendations:-</span></p>
<p>For Sql Server 2005 multiple data files would be good to improve the performance of TempDB.</p>
<p>For 2000 number of data file better to be good as number   of CPU.</p>
<p>Set 80% of estimated growth, and let 20% be handed by auto growth.</p>
<p>TempDB Shrink can be done  at startup parameter <strong>–c –f</strong> this will start the sql server with minimum tempdb size.</p>
<p><strong><span style="text-decoration: underline;">Errors:</span></strong></p>
<p>1101 or 1105: no space in tempDB</p>
<p>3959: Version store is full (after 1101 or 1105)</p>
<p>3967: Version store is force to shrink</p>
<p>3958 or 3966: Transaction cannot find required version record.</p>
<p><strong><span style="text-decoration: underline;">Troubleshooting tempDB issue:</span></strong></p>
<p>Generally TempDB issues are TempDB FULL and tempDB performance.</p>
<p>Generally Tempdb will have two issues</p>
<p>TempDB Full:</p>
<p>To troubleshoot the tempDB issue we have two dmvs:</p>
<p>Sys.dm_db.file_space_usage</p>
<p>Sys.dm_db.trask_space_usage</p>
<p>Sys.dm_db_session_space_usage</p>
<p>This issue occurs due to:</p>
<p>Query used in application requires heavy internal objects tempdb &#8211; to solve that use nested look join instead of hash join/aggregates can be achieve using creating proper indexes on the table or use hints.</p>
<p>Sys,Dm_os_waiting_task – resource like (2:1:%) where % 1:PFS and 3 GAMs contention issue</p>
<p>Also if require don’t use snapshot isolation level, and things which usages tempDB.</p>
<p>Hope this will help someone to understand more about tmepDB.</p>
<p>Thanx.</p>
<p>Vinay</p>
<p>Reference:</p>
<p>Practical Troubleshooting –Ken Henderson.</p>
<p><a href="http://msdn.microsoft.com/en-us/library/ms345368.aspx">http://msdn.microsoft.com/en-us/library/ms345368.aspx</a><br />
<a href="http://msdn.microsoft.com/en-us/library/cc966545.aspx">http://msdn.microsoft.com/en-us/library/cc966545.aspx</a><br />
<a href="http://msdn.microsoft.com/en-us/library/ms175527.aspx">http://msdn.microsoft.com/en-us/library/ms175527.aspx</a></p>
<p><a href="http://msdn.microsoft.com/en-us/library/ms190768.aspx">http://msdn.microsoft.com/en-us/library/ms190768.aspx</a></p>
]]></content:encoded>
			<wfw:commentRss>http://rdbmsexperts.com/Blogs/archives/87/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Mirroring</title>
		<link>http://rdbmsexperts.com/Blogs/archives/83</link>
		<comments>http://rdbmsexperts.com/Blogs/archives/83#comments</comments>
		<pubDate>Tue, 27 Apr 2010 10:28:34 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Disaster Recovery]]></category>
		<category><![CDATA[General]]></category>
		<category><![CDATA[High Avaliability]]></category>
		<category><![CDATA[Installation]]></category>
		<category><![CDATA[Tool]]></category>
		<category><![CDATA[Webcast]]></category>
		<category><![CDATA[What I learned Today]]></category>
		<category><![CDATA[Whitepapers]]></category>
		<category><![CDATA[High Availability]]></category>

		<guid isPermaLink="false">http://rdbmsexperts.com/Blogs/?p=83</guid>
		<description><![CDATA[As discussed about Disaster Recovery and High Availbility topic here continue on this. today would like to discuss some more information about mirroring.
As stated in my ealier post about mirroring, today I would like to write about how to conifigure mirroring, mirroring is very simple to configure. before going for it we should deside what time [...]]]></description>
			<content:encoded><![CDATA[<p>As discussed about Disaster Recovery and High Availbility topic <a href="http://rdbmsexperts.com/Blogs/?p=73" target="_blank">here</a> continue on this. today would like to discuss some more information about mirroring.</p>
<p>As stated in my ealier post about mirroring, today I would like to write about how to conifigure mirroring, mirroring is very simple to configure. before going for it we should deside what time of mirroring we want to go with</p>
<p>High Availability</p>
<p>High Protection</p>
<p>High Performance</p>
<p>depending upon that we have to configure Witness.</p>
<p>I would say there are only two steps for it.</p>
<p>1. Create End points</p>
<p>2. alter database &#8220;&#8221; set PARTNER</p>
<p>this is the simple procedure I want to discuss there are other several ways to setup the mirroring.</p>
<p>1. need to decide what is your &#8220;priceple&#8221; database server , &#8220;Mirror&#8221; database server and &#8220;Witness&#8221; database server. this can be seperate box or difference named instance on the same server, but should be on differenct instance as on one  sql server you can create multiple &#8220;endpoints&#8221; which is the way Mirroring works(interacts)</p>
<p>the simple command for creating endpoints could be</p>
<p><strong><em>CREATE ENDPOINT EndPointName<br />
STATE=STARTED AS TCP(LISTENER_PORT =5022)</em></strong><br />
FOR DATABASE_MIRRORING    (ROLE = ALL )<br />
if you are on same server(box) with different instances then we have to give different port number(eg. 5023, 5024)</p>
<p>* Principle and Mirrored database should be having same edition of sql server. witness can be express edition, and should be of &#8220;FULL RECOVERY MODEL&#8221;</p>
<p>Backup the Principle and restore it on Mirrored database with NORecovery<br />
once you create the &#8220;Endpoints&#8221; then we have to alter the database PARTNER to listen to that endpoint port like.</p>
<p>at principle</p>
<p>alter database MirrorDB  set Partner=&#8217;TCP://MirroredServer:5022&#8242;</p>
<p>at mirror server</p>
<p>alter database MirrorDB  set Partner=&#8217;TCP://PricipleSrv:5024&#8242;</p>
<p>we can check the property of the principle database of option &#8220;Mirror&#8221; you will see the end point specified and other mirroring related info.</p>
<p>you are done. this is quick and short way of configuring mirror, once priciple is down it will rollover to mirror database server and Mirror server will become priciple and when Priciple is up that will become &#8220;mirror&#8221; server ie. reverse the setup.</p>
<p>*You cannot mirror the <strong>master</strong>, <strong>msdb</strong>, <strong>temp</strong>, or <strong>model</strong> system databases.</p>
<p>You can add on the securites and other configuration on it.</p>
<p>This is what I learned today.</p>
<p>Thanx.</p>
<p>Vinay</p>
<p><a href="http://rdbmsexperts.com/Blogs/">http://rdbmsexperts.com/Blogs/</a></p>
<p><a href="http://vinay-thakur.spaces.live.com/blog">http://vinay-thakur.spaces.live.com/blog</a></p>
<p>twitter\thakurvinay</p>
]]></content:encoded>
			<wfw:commentRss>http://rdbmsexperts.com/Blogs/archives/83/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
