Showing posts with label sql2005. Show all posts
Showing posts with label sql2005. Show all posts

Wednesday, March 7, 2012

Bug (?) in SQL2005 x64 SP1 CTP

We're testing the same DB (~ 5GB, ~ 500 tables) with
Server32 (Win2003 Standard 32 bit, SQL2005 Developer 32 bit SP1 CTP, 1gb Memory) and with
Server64 (Win2003 x64 Standard 64 bit, SQL2005 Developer 64 bit SP1 CTP, 6gb Memory).

exec sp_MSforeachtable @.command1="SET QUOTED_IDENTIFIER ON DBCC DBREINDEX ('?', '', 90)"

On Server32 the SQL above runs without errors. On Server64 there comes the following error message:
Msg 8621, Level 17, State 1, Line 1
The query processor ran out of stack space during query optimization. Please simplify the query.

A 64bit server with 6gb memory has less stack space than a 32bit server with 1gb memory?

Regards
Peter

PS: I know sp_MSforeachtable is not an official stored procedure, but I don't thinkt there's the problem. I got the same error on Server64, when I run the following cursor:
DECLARE tablename CURSOR
READ_ONLY
FOR select [name] from sys.tables where type = 'U'

DECLARE @.name varchar(80)
OPEN tablename

FETCH NEXT FROM tablename INTO @.name
WHILE (@.@.fetch_status <> -1)
BEGIN
IF (@.@.fetch_status <> -2)
BEGIN
DECLARE @.message varchar(800)
SELECT @.message = 'SET QUOTED_IDENTIFIER ON DBCC DBREINDEX (''' + @.name + ''', '''', 90)'
EXEC (@.message)
END
FETCH NEXT FROM tablename INTO @.name
END

CLOSE tablename
DEALLOCATE tablename
GO
Please file a bug using the MSDN Product Feedback Center. And mention the OS platform, server versions, number of tables in the database etc.|||Bug report created

Thanks
Peter

Friday, February 10, 2012

BOOT.INI File for 4GB RAM and SQL 2005

I have 3 questions regarding memory configuration on a Windows Server 2003
SP2 Enterprise Edition with SQL2005 SP2.
1. Can someone advise on the correct boot.ini file configuration to utilize
4GB of local memory? I'm not sure if I need the 3GB switch?
multi(0)rdisk(0)partition(1)\WINDOWS="Windows Server 2003,
Enterprise"/3GB/fastdetect/PAE/NoExectute=OptOut
2. Once Boot.ini configured, is the only setting in SQL 2005 to modify is
the sp_configure awe enabled config_value=1 and run_value=1 ?
3. Assuming nothing else is to be done to have SQL 2005 utilize more than
the 2GB memory space, how do you verify or validate SQL 2005 is using more
memory?
Thanks in advancezorro
Is it 64 bit or 32 bit?
> 1. Can someone advise on the correct boot.ini file configuration to
> utilize
> 4GB of local memory? I'm not sure if I need the 3GB switch?
You do need 3GB switch
> 2. Once Boot.ini configured, is the only setting in SQL 2005 to modify is
> the sp_configure awe enabled config_value=1 and run_value=1 ?
AWE is for utilyze more than 4GB
Yes, unless you use 64 bit , then you do not need AWE , make sure that an
account SQL Serverc runs under is added to LockPages in Memory Local Group
Policy
> 3. Assuming nothing else is to be done to have SQL 2005 utilize more than
> the 2GB memory space, how do you verify or validate SQL 2005 is using more
> memory?
Task Manager
"zorro" <zorro@.discussions.microsoft.com> wrote in message
news:C2009B55-7B5D-4F65-8986-3AF00547FA1E@.microsoft.com...
>I have 3 questions regarding memory configuration on a Windows Server 2003
> SP2 Enterprise Edition with SQL2005 SP2.
> 1. Can someone advise on the correct boot.ini file configuration to
> utilize
> 4GB of local memory? I'm not sure if I need the 3GB switch?
> multi(0)rdisk(0)partition(1)\WINDOWS="Windows Server 2003,
> Enterprise"/3GB/fastdetect/PAE/NoExectute=OptOut
> 2. Once Boot.ini configured, is the only setting in SQL 2005 to modify is
> the sp_configure awe enabled config_value=1 and run_value=1 ?
> 3. Assuming nothing else is to be done to have SQL 2005 utilize more than
> the 2GB memory space, how do you verify or validate SQL 2005 is using more
> memory?
> Thanks in advance
>|||>> 3. Assuming nothing else is to be done to have SQL 2005 utilize more than
>> the 2GB memory space, how do you verify or validate SQL 2005 is using
>> more
>> memory?
> Task Manager
Actually, I would use performance monitor. Task manager tends to
under-report what SQL Server is actually using.|||Aaron
I agreee. I assumed the OP wants to utilize 4GB ONLY , so after adding
3GB switch you can actually observe in TM.
"Aaron Bertrand [SQL Server MVP]" <ten.xoc@.dnartreb.noraa> wrote in message
news:%23qL67StfIHA.5088@.TK2MSFTNGP02.phx.gbl...
>> 3. Assuming nothing else is to be done to have SQL 2005 utilize more
>> than
>> the 2GB memory space, how do you verify or validate SQL 2005 is using
>> more
>> memory?
>> Task Manager
> Actually, I would use performance monitor. Task manager tends to
> under-report what SQL Server is actually using.|||Thanks Uri,
1. 32 bit Windows Server 2003 version.
2. To verify 3GB switch is needed for my 5GB physically installed RAM?
3. Also good catch on the LockPages in Memory setting within the gpedit.msc
Thanks,
zorro
"Uri Dimant" wrote:
> zorro
> Is it 64 bit or 32 bit?
> > 1. Can someone advise on the correct boot.ini file configuration to
> > utilize
> > 4GB of local memory? I'm not sure if I need the 3GB switch?
> You do need 3GB switch
> > 2. Once Boot.ini configured, is the only setting in SQL 2005 to modify is
> > the sp_configure awe enabled config_value=1 and run_value=1 ?
> AWE is for utilyze more than 4GB
> Yes, unless you use 64 bit , then you do not need AWE , make sure that an
> account SQL Serverc runs under is added to LockPages in Memory Local Group
> Policy
> > 3. Assuming nothing else is to be done to have SQL 2005 utilize more than
> > the 2GB memory space, how do you verify or validate SQL 2005 is using more
> > memory?
> Task Manager
>
>
> "zorro" <zorro@.discussions.microsoft.com> wrote in message
> news:C2009B55-7B5D-4F65-8986-3AF00547FA1E@.microsoft.com...
> >I have 3 questions regarding memory configuration on a Windows Server 2003
> > SP2 Enterprise Edition with SQL2005 SP2.
> >
> > 1. Can someone advise on the correct boot.ini file configuration to
> > utilize
> > 4GB of local memory? I'm not sure if I need the 3GB switch?
> >
> > multi(0)rdisk(0)partition(1)\WINDOWS="Windows Server 2003,
> > Enterprise"/3GB/fastdetect/PAE/NoExectute=OptOut
> >
> > 2. Once Boot.ini configured, is the only setting in SQL 2005 to modify is
> > the sp_configure awe enabled config_value=1 and run_value=1 ?
> >
> > 3. Assuming nothing else is to be done to have SQL 2005 utilize more than
> > the 2GB memory space, how do you verify or validate SQL 2005 is using more
> > memory?
> >
> > Thanks in advance
> >
> >
>
>|||See comments inline.
Linchi
"Uri Dimant" wrote:
> zorro
> Is it 64 bit or 32 bit?
> > 1. Can someone advise on the correct boot.ini file configuration to
> > utilize
> > 4GB of local memory? I'm not sure if I need the 3GB switch?
> You do need 3GB switch
>
Why?
> > 2. Once Boot.ini configured, is the only setting in SQL 2005 to modify is
> > the sp_configure awe enabled config_value=1 and run_value=1 ?
> AWE is for utilyze more than 4GB
I keep hearing that AWE is for utilizing more than 4GB. Not sure where that
comes from. Technically, it's not.
> Yes, unless you use 64 bit , then you do not need AWE , make sure that an
> account SQL Serverc runs under is added to LockPages in Memory Local Group
> Policy
> > 3. Assuming nothing else is to be done to have SQL 2005 utilize more than
> > the 2GB memory space, how do you verify or validate SQL 2005 is using more
> > memory?
> Task Manager
>
>
> "zorro" <zorro@.discussions.microsoft.com> wrote in message
> news:C2009B55-7B5D-4F65-8986-3AF00547FA1E@.microsoft.com...
> >I have 3 questions regarding memory configuration on a Windows Server 2003
> > SP2 Enterprise Edition with SQL2005 SP2.
> >
> > 1. Can someone advise on the correct boot.ini file configuration to
> > utilize
> > 4GB of local memory? I'm not sure if I need the 3GB switch?
> >
> > multi(0)rdisk(0)partition(1)\WINDOWS="Windows Server 2003,
> > Enterprise"/3GB/fastdetect/PAE/NoExectute=OptOut
> >
> > 2. Once Boot.ini configured, is the only setting in SQL 2005 to modify is
> > the sp_configure awe enabled config_value=1 and run_value=1 ?
> >
> > 3. Assuming nothing else is to be done to have SQL 2005 utilize more than
> > the 2GB memory space, how do you verify or validate SQL 2005 is using more
> > memory?
> >
> > Thanks in advance
> >
> >
>
>|||Hi Linchi
You are right, that technically, it's not. If I have 4GB RAM and want tio
utilize 3GB for SQL Server, so I simple add switch in BOOT.INI and why
bother enabling AWE? What do you think?
"Linchi Shea" <LinchiShea@.discussions.microsoft.com> wrote in message
news:61A4195E-F98E-4AE2-A24F-0BC6AC668D08@.microsoft.com...
> See comments inline.
> Linchi
> "Uri Dimant" wrote:
>> zorro
>> Is it 64 bit or 32 bit?
>> > 1. Can someone advise on the correct boot.ini file configuration to
>> > utilize
>> > 4GB of local memory? I'm not sure if I need the 3GB switch?
>> You do need 3GB switch
> Why?
>> > 2. Once Boot.ini configured, is the only setting in SQL 2005 to modify
>> > is
>> > the sp_configure awe enabled config_value=1 and run_value=1 ?
>> AWE is for utilyze more than 4GB
> I keep hearing that AWE is for utilizing more than 4GB. Not sure where
> that
> comes from. Technically, it's not.
>> Yes, unless you use 64 bit , then you do not need AWE , make sure that
>> an
>> account SQL Serverc runs under is added to LockPages in Memory Local
>> Group
>> Policy
>> > 3. Assuming nothing else is to be done to have SQL 2005 utilize more
>> > than
>> > the 2GB memory space, how do you verify or validate SQL 2005 is using
>> > more
>> > memory?
>> Task Manager
>>
>>
>> "zorro" <zorro@.discussions.microsoft.com> wrote in message
>> news:C2009B55-7B5D-4F65-8986-3AF00547FA1E@.microsoft.com...
>> >I have 3 questions regarding memory configuration on a Windows Server
>> >2003
>> > SP2 Enterprise Edition with SQL2005 SP2.
>> >
>> > 1. Can someone advise on the correct boot.ini file configuration to
>> > utilize
>> > 4GB of local memory? I'm not sure if I need the 3GB switch?
>> >
>> > multi(0)rdisk(0)partition(1)\WINDOWS="Windows Server 2003,
>> > Enterprise"/3GB/fastdetect/PAE/NoExectute=OptOut
>> >
>> > 2. Once Boot.ini configured, is the only setting in SQL 2005 to modify
>> > is
>> > the sp_configure awe enabled config_value=1 and run_value=1 ?
>> >
>> > 3. Assuming nothing else is to be done to have SQL 2005 utilize more
>> > than
>> > the 2GB memory space, how do you verify or validate SQL 2005 is using
>> > more
>> > memory?
>> >
>> > Thanks in advance
>> >
>> >
>>

BOOT.INI File for 4GB RAM and SQL 2005

I have 3 questions regarding memory configuration on a Windows Server 2003
SP2 Enterprise Edition with SQL2005 SP2.
1. Can someone advise on the correct boot.ini file configuration to utilize
4GB of local memory? I'm not sure if I need the 3GB switch?
multi(0)rdisk(0)partition(1)\WINDOWS="Windows Server 2003,
Enterprise"/3GB/fastdetect/PAE/NoExectute=OptOut
2. Once Boot.ini configured, is the only setting in SQL 2005 to modify is
the sp_configure awe enabled config_value=1 and run_value=1 ?
3. Assuming nothing else is to be done to have SQL 2005 utilize more than
the 2GB memory space, how do you verify or validate SQL 2005 is using more
memory?
Thanks in advance
zorro
Is it 64 bit or 32 bit?
> 1. Can someone advise on the correct boot.ini file configuration to
> utilize
> 4GB of local memory? I'm not sure if I need the 3GB switch?
You do need 3GB switch

> 2. Once Boot.ini configured, is the only setting in SQL 2005 to modify is
> the sp_configure awe enabled config_value=1 and run_value=1 ?
AWE is for utilyze more than 4GB
Yes, unless you use 64 bit , then you do not need AWE , make sure that an
account SQL Serverc runs under is added to LockPages in Memory Local Group
Policy

> 3. Assuming nothing else is to be done to have SQL 2005 utilize more than
> the 2GB memory space, how do you verify or validate SQL 2005 is using more
> memory?
Task Manager
"zorro" <zorro@.discussions.microsoft.com> wrote in message
news:C2009B55-7B5D-4F65-8986-3AF00547FA1E@.microsoft.com...
>I have 3 questions regarding memory configuration on a Windows Server 2003
> SP2 Enterprise Edition with SQL2005 SP2.
> 1. Can someone advise on the correct boot.ini file configuration to
> utilize
> 4GB of local memory? I'm not sure if I need the 3GB switch?
> multi(0)rdisk(0)partition(1)\WINDOWS="Windows Server 2003,
> Enterprise"/3GB/fastdetect/PAE/NoExectute=OptOut
> 2. Once Boot.ini configured, is the only setting in SQL 2005 to modify is
> the sp_configure awe enabled config_value=1 and run_value=1 ?
> 3. Assuming nothing else is to be done to have SQL 2005 utilize more than
> the 2GB memory space, how do you verify or validate SQL 2005 is using more
> memory?
> Thanks in advance
>
|||>> 3. Assuming nothing else is to be done to have SQL 2005 utilize more than
> Task Manager
Actually, I would use performance monitor. Task manager tends to
under-report what SQL Server is actually using.
|||Aaron
I agreee. I assumed the OP wants to utilize 4GB ONLY , so after adding
3GB switch you can actually observe in TM.
"Aaron Bertrand [SQL Server MVP]" <ten.xoc@.dnartreb.noraa> wrote in message
news:%23qL67StfIHA.5088@.TK2MSFTNGP02.phx.gbl...
> Actually, I would use performance monitor. Task manager tends to
> under-report what SQL Server is actually using.
|||Thanks Uri,
1. 32 bit Windows Server 2003 version.
2. To verify 3GB switch is needed for my 5GB physically installed RAM?
3. Also good catch on the LockPages in Memory setting within the gpedit.msc
Thanks,
zorro
"Uri Dimant" wrote:

> zorro
> Is it 64 bit or 32 bit?
> You do need 3GB switch
>
> AWE is for utilyze more than 4GB
> Yes, unless you use 64 bit , then you do not need AWE , make sure that an
> account SQL Serverc runs under is added to LockPages in Memory Local Group
> Policy
>
> Task Manager
>
>
> "zorro" <zorro@.discussions.microsoft.com> wrote in message
> news:C2009B55-7B5D-4F65-8986-3AF00547FA1E@.microsoft.com...
>
>
|||See comments inline.
Linchi
"Uri Dimant" wrote:

> zorro
> Is it 64 bit or 32 bit?
> You do need 3GB switch
>
Why?

> AWE is for utilyze more than 4GB
I keep hearing that AWE is for utilizing more than 4GB. Not sure where that
comes from. Technically, it's not.

> Yes, unless you use 64 bit , then you do not need AWE , make sure that an
> account SQL Serverc runs under is added to LockPages in Memory Local Group
> Policy
>
> Task Manager
>
>
> "zorro" <zorro@.discussions.microsoft.com> wrote in message
> news:C2009B55-7B5D-4F65-8986-3AF00547FA1E@.microsoft.com...
>
>
|||Hi Linchi
You are right, that technically, it's not. If I have 4GB RAM and want tio
utilize 3GB for SQL Server, so I simple add switch in BOOT.INI and why
bother enabling AWE? What do you think?
"Linchi Shea" <LinchiShea@.discussions.microsoft.com> wrote in message
news:61A4195E-F98E-4AE2-A24F-0BC6AC668D08@.microsoft.com...[vbcol=seagreen]
> See comments inline.
> Linchi
> "Uri Dimant" wrote:
>
> Why?
>
> I keep hearing that AWE is for utilizing more than 4GB. Not sure where
> that
> comes from. Technically, it's not.