Showing posts with label space. Show all posts
Showing posts with label space. Show all posts

Thursday, March 22, 2012

Calculated field

This may be an extremely simple question, but I am trying to combine two text fields (last name, comma, space and first name) into a new field that can be used as a GROUP in my report.

What is the simplest way to accomplish this?

One way would be to modify the SQL statement

[LastName] + ', ' + [FirstName] as FullName

Another would be to use a calculated field.

Fields!LastName.Value + ", " + Fields!FirstName.Value

cheers,

Andrew

Tuesday, March 20, 2012

calculate the size of a database and backup it.

Hi all,
please show me the way how to calculate the size of a database in SQL 2000. Whith this size we have already calculated, how much space need to make a backup file for this database.
thanks.Easiest way is through Enterprise manager - via the View - TaskPad options. This will show you size of data file(s) and log file(s).

Backup size will be the sum of these sizes approx.

You can also get it from the sysfiles table.|||Originally posted by thanhtung2003
Hi all,
please show me the way how to calculate the size of a database in SQL 2000. Whith this size we have already calculated, how much space need to make a backup file for this database.

thanks.
If you want to find out programaticaly use sp_spaceused|||Originally posted by smasanam
If you want to find out programaticaly use sp_spaceused

Hi,
please, tell me how to use it ?|||Please consult the Microsoft Transact-SQL Reference, specifically 'System Stored Procedures'|||create table #DbSize (name nvarchar(30),
rows char(11),
reserved varchar(18),
data varchar(18),
index_size varchar(18),
unused varchar(18))

exec <your database name>..sp_msforeachtable @.command1 = 'insert into #DbSize exec dbs..sp_spaceused [?]'

select sum(cast(replace(Reserved, 'KB','')as int)) From #DbSize

drop table #DbSize

Sunday, March 11, 2012

Caclulate database size and free space left

Dear all,
Is that possible to calculate the database size and free space left by t-sql
script?
Ivan
Ivan
sp_helpdb 'northwind'
There is an article in the BOL for this subject
"Ivan" <ivan@.microsoft.com> wrote in message
news:ug9q%233L8FHA.1028@.TK2MSFTNGP11.phx.gbl...
> Dear all,
> Is that possible to calculate the database size and free space left by
> t-sql script?
> Ivan
>
|||It had the db size and file size. However, I need the space available in the
file.
The most similar function is sp_space_used.
But I found the space left is not match with the one I saw in Enterprise
Manager.
Do you know how to calculate the space left in enterprise manager?
Ivan
"Uri Dimant" <urid@.iscar.co.il> glsD:e%23JXCgM8FHA.3752@.tk2msftngp13.phx .gbl...
> Ivan
> sp_helpdb 'northwind'
> There is an article in the BOL for this subject
>
>
> "Ivan" <ivan@.microsoft.com> wrote in message
> news:ug9q%233L8FHA.1028@.TK2MSFTNGP11.phx.gbl...
>
|||Ivan
sp_spaceused in the BOL
"Ivan" <ivan@.microsoft.com> wrote in message
news:%23FcO0QO8FHA.2304@.TK2MSFTNGP10.phx.gbl...
> It had the db size and file size. However, I need the space available in
> the file.
> The most similar function is sp_space_used.
> But I found the space left is not match with the one I saw in Enterprise
> Manager.
> Do you know how to calculate the space left in enterprise manager?
> Ivan
>
> "Uri Dimant" <urid@.iscar.co.il>
> glsD:e%23JXCgM8FHA.3752@.tk2msftngp13.phx .gbl...
>
|||I once wrote a post for that:
http://groups.google.de/group/comp.d...94eacf442935d5
HTH, jens SUessmeyer.
|||Hi Ivan,
I use the below mentioned script for this purpose. This provides me separate
result set for Data Files and Log Files. The only possible issue with this
script is that it is using undocumented SP (DBCC SHOWFILESTATS). The positive
side is that it gives the sizes as shown in EM.
--Script to calculate information about the Data Files
SET QUOTED_IDENTIFIER OFF
SET NOCOUNT ON
DECLARE @.dbname varchar(50)
declare @.string varchar(250)
set @.string = ''
create table #datafilestats
(Fileid tinyint,
FileGroup1 tinyint,
TotalExtents1 dec (8, 2),
UsedExtents1 dec (8, 2),
[Name] varchar(50),
[FileName] sysname )
create table #dbstats
(dbname varchar(50),
FileGroupId tinyint,
FileGroupName varchar(25),
TotalSizeinMB dec (8, 2),
UsedSizeinMB dec (8, 2),
FreeSizeinMB dec (8, 2))
DECLARE dbnames_cursor CURSOR FOR SELECT name FROM master..sysdatabases
OPEN dbnames_cursor
FETCH NEXT FROM dbnames_cursor INTO @.dbname
WHILE (@.@.fetch_status = 0)
BEGIN
set @.string = 'use ' + @.dbname + ' DBCC SHOWFILESTATS'
insert into #datafilestats exec (@.string)
insert into #dbstats (dbname, FileGroupId, TotalSizeinMB, UsedSizeinMB)
select @.dbname, FileGroup1, sum(TotalExtents1)*65536.0/1048576.0,
sum(UsedExtents1)*65536.0/1048576.0
from #datafilestats group by FileGroup1
set @.string = 'use ' + @.dbname + ' update #dbstats set FileGroupName =
sysfilegroups.groupname from #dbstats, sysfilegroups where
#dbstats.FileGroupId = sysfilegroups.groupid and #dbstats.dbname =''' +
@.dbname + ''''
exec (@.string)
update #dbstats set FreeSizeinMB = TotalSizeinMB - UsedSizeinMB where
dbname = @.dbname
truncate table #datafilestats
FETCH NEXT FROM dbnames_cursor INTO @.dbname
END
CLOSE dbnames_cursor
DEALLOCATE dbnames_cursor
drop table #datafilestats
select * from #dbstats
drop table #dbstats
--Script to calculate information about the Log Files
set nocount on
create table #LogUsageInfo
( db_name varchar(50),
log_size dec (8, 2),
log_used_percent dec (8, 2),
status dec (7, 1) )
insert #LogUsageInfo exec ('dbcc sqlperf(logspace) with no_infomsgs')
select * from #LogUsageInfo
drop table #LogUsageInfo
"Ivan" wrote:

> Dear all,
> Is that possible to calculate the database size and free space left by t-sql
> script?
> Ivan
>
>
|||I have another new task for finding free space left.
Before, I need get the free space left in SQL 2000 databse.
Now, I need get the free space left in SQL 6.5
Need help~~~~~~~~~
Ivan
"Uri Dimant" <urid@.iscar.co.il> glsD:uu74eVO8FHA.1188@.TK2MSFTNGP12.phx.g bl...
> Ivan
> sp_spaceused in the BOL
>
> "Ivan" <ivan@.microsoft.com> wrote in message
> news:%23FcO0QO8FHA.2304@.TK2MSFTNGP10.phx.gbl...
>
|||See my post below.
HTH, Jens Suessmeyer.
|||Any SQL 6.5 version?
there's no sysfiles in sql 6.5
Ivan
"Jens" <Jens@.sqlserver2005.de>
??:1132912972.019598.201170@.g47g2000cwa.googl egroups.com...
> See my post below.
> HTH, Jens Suessmeyer.
>

Caclulate database size and free space left

Dear all,
Is that possible to calculate the database size and free space left by t-sql
script?
IvanIvan
sp_helpdb 'northwind'
There is an article in the BOL for this subject
"Ivan" <ivan@.microsoft.com> wrote in message
news:ug9q%233L8FHA.1028@.TK2MSFTNGP11.phx.gbl...
> Dear all,
> Is that possible to calculate the database size and free space left by
> t-sql script?
> Ivan
>|||It had the db size and file size. However, I need the space available in the
file.
The most similar function is sp_space_used.
But I found the space left is not match with the one I saw in Enterprise
Manager.
Do you know how to calculate the space left in enterprise manager?
Ivan
"Uri Dimant" <urid@.iscar.co.il> ¼¶¼g©ó¶l¥ó·s»D:e%23JXCgM8FHA.3752@.tk2msftngp13.phx.gbl...
> Ivan
> sp_helpdb 'northwind'
> There is an article in the BOL for this subject
>
>
> "Ivan" <ivan@.microsoft.com> wrote in message
> news:ug9q%233L8FHA.1028@.TK2MSFTNGP11.phx.gbl...
>> Dear all,
>> Is that possible to calculate the database size and free space left by
>> t-sql script?
>> Ivan
>|||Ivan
sp_spaceused in the BOL
"Ivan" <ivan@.microsoft.com> wrote in message
news:%23FcO0QO8FHA.2304@.TK2MSFTNGP10.phx.gbl...
> It had the db size and file size. However, I need the space available in
> the file.
> The most similar function is sp_space_used.
> But I found the space left is not match with the one I saw in Enterprise
> Manager.
> Do you know how to calculate the space left in enterprise manager?
> Ivan
>
> "Uri Dimant" <urid@.iscar.co.il>
> ¼¶¼g©ó¶l¥ó·s»D:e%23JXCgM8FHA.3752@.tk2msftngp13.phx.gbl...
>> Ivan
>> sp_helpdb 'northwind'
>> There is an article in the BOL for this subject
>>
>>
>> "Ivan" <ivan@.microsoft.com> wrote in message
>> news:ug9q%233L8FHA.1028@.TK2MSFTNGP11.phx.gbl...
>> Dear all,
>> Is that possible to calculate the database size and free space left by
>> t-sql script?
>> Ivan
>>
>|||I once wrote a post for that:
http://groups.google.de/group/comp.databases.ms-sqlserver/browse_frm/thread/7494eacf442935d5
HTH, jens SUessmeyer.|||Hi Ivan,
I use the below mentioned script for this purpose. This provides me separate
result set for Data Files and Log Files. The only possible issue with this
script is that it is using undocumented SP (DBCC SHOWFILESTATS). The positive
side is that it gives the sizes as shown in EM.
--Script to calculate information about the Data Files
SET QUOTED_IDENTIFIER OFF
SET NOCOUNT ON
DECLARE @.dbname varchar(50)
declare @.string varchar(250)
set @.string = ''
create table #datafilestats
( Fileid tinyint,
FileGroup1 tinyint,
TotalExtents1 dec (8, 2),
UsedExtents1 dec (8, 2),
[Name] varchar(50),
[FileName] sysname )
create table #dbstats
( dbname varchar(50),
FileGroupId tinyint,
FileGroupName varchar(25),
TotalSizeinMB dec (8, 2),
UsedSizeinMB dec (8, 2),
FreeSizeinMB dec (8, 2))
DECLARE dbnames_cursor CURSOR FOR SELECT name FROM master..sysdatabases
OPEN dbnames_cursor
FETCH NEXT FROM dbnames_cursor INTO @.dbname
WHILE (@.@.fetch_status = 0)
BEGIN
set @.string = 'use ' + @.dbname + ' DBCC SHOWFILESTATS'
insert into #datafilestats exec (@.string)
insert into #dbstats (dbname, FileGroupId, TotalSizeinMB, UsedSizeinMB)
select @.dbname, FileGroup1, sum(TotalExtents1)*65536.0/1048576.0,
sum(UsedExtents1)*65536.0/1048576.0
from #datafilestats group by FileGroup1
set @.string = 'use ' + @.dbname + ' update #dbstats set FileGroupName =sysfilegroups.groupname from #dbstats, sysfilegroups where
#dbstats.FileGroupId = sysfilegroups.groupid and #dbstats.dbname =''' +
@.dbname + ''''
exec (@.string)
update #dbstats set FreeSizeinMB = TotalSizeinMB - UsedSizeinMB where
dbname = @.dbname
truncate table #datafilestats
FETCH NEXT FROM dbnames_cursor INTO @.dbname
END
CLOSE dbnames_cursor
DEALLOCATE dbnames_cursor
drop table #datafilestats
select * from #dbstats
drop table #dbstats
--
--Script to calculate information about the Log Files
set nocount on
create table #LogUsageInfo
( db_name varchar(50),
log_size dec (8, 2),
log_used_percent dec (8, 2),
status dec (7, 1) )
insert #LogUsageInfo exec ('dbcc sqlperf(logspace) with no_infomsgs')
select * from #LogUsageInfo
drop table #LogUsageInfo
---
"Ivan" wrote:
> Dear all,
> Is that possible to calculate the database size and free space left by t-sql
> script?
> Ivan
>
>|||I have another new task for finding free space left.
Before, I need get the free space left in SQL 2000 databse.
Now, I need get the free space left in SQL 6.5
Need help~~~~~~~~~
Ivan
"Uri Dimant" <urid@.iscar.co.il> ¼¶¼g©ó¶l¥ó·s»D:uu74eVO8FHA.1188@.TK2MSFTNGP12.phx.gbl...
> Ivan
> sp_spaceused in the BOL
>
> "Ivan" <ivan@.microsoft.com> wrote in message
> news:%23FcO0QO8FHA.2304@.TK2MSFTNGP10.phx.gbl...
>> It had the db size and file size. However, I need the space available in
>> the file.
>> The most similar function is sp_space_used.
>> But I found the space left is not match with the one I saw in Enterprise
>> Manager.
>> Do you know how to calculate the space left in enterprise manager?
>> Ivan
>>
>> "Uri Dimant" <urid@.iscar.co.il> ¼¶¼g©ó¶l¥ó·s»D:e%23JXCgM8FHA.3752@.tk2msftngp13.phx.gbl...
>> Ivan
>> sp_helpdb 'northwind'
>> There is an article in the BOL for this subject
>>
>>
>> "Ivan" <ivan@.microsoft.com> wrote in message
>> news:ug9q%233L8FHA.1028@.TK2MSFTNGP11.phx.gbl...
>> Dear all,
>> Is that possible to calculate the database size and free space left by
>> t-sql script?
>> Ivan
>>
>>
>|||See my post below.
HTH, Jens Suessmeyer.|||Any SQL 6.5 version?
there's no sysfiles in sql 6.5
Ivan
"Jens" <Jens@.sqlserver2005.de>
'?:1132912972.019598.201170@.g47g2000cwa.googlegroups.com...
> See my post below.
> HTH, Jens Suessmeyer.
>

Caclulate database size and free space left

Dear all,
Is that possible to calculate the database size and free space left by t-sql
script?
IvanIvan
sp_helpdb 'northwind'
There is an article in the BOL for this subject
"Ivan" <ivan@.microsoft.com> wrote in message
news:ug9q%233L8FHA.1028@.TK2MSFTNGP11.phx.gbl...
> Dear all,
> Is that possible to calculate the database size and free space left by
> t-sql script?
> Ivan
>|||It had the db size and file size. However, I need the space available in the
file.
The most similar function is sp_space_used.
But I found the space left is not match with the one I saw in Enterprise
Manager.
Do you know how to calculate the space left in enterprise manager?
Ivan
"Uri Dimant" <urid@.iscar.co.il> glsD:e%23JXCgM8FHA.3752@.tk2msftngp13.phx.gbl...[vb
col=seagreen]
> Ivan
> sp_helpdb 'northwind'
> There is an article in the BOL for this subject
>
>
> "Ivan" <ivan@.microsoft.com> wrote in message
> news:ug9q%233L8FHA.1028@.TK2MSFTNGP11.phx.gbl...
>[/vbcol]|||Ivan
sp_spaceused in the BOL
"Ivan" <ivan@.microsoft.com> wrote in message
news:%23FcO0QO8FHA.2304@.TK2MSFTNGP10.phx.gbl...
> It had the db size and file size. However, I need the space available in
> the file.
> The most similar function is sp_space_used.
> But I found the space left is not match with the one I saw in Enterprise
> Manager.
> Do you know how to calculate the space left in enterprise manager?
> Ivan
>
> "Uri Dimant" <urid@.iscar.co.il>
> glsD:e%23JXCgM8FHA.3752@.tk2msftngp13.phx.gbl...
>|||I once wrote a post for that:
http://groups.google.de/group/comp... />
cf442935d5
HTH, jens SUessmeyer.|||Hi Ivan,
I use the below mentioned script for this purpose. This provides me separate
result set for Data Files and Log Files. The only possible issue with this
script is that it is using undocumented SP (DBCC SHOWFILESTATS). The positiv
e
side is that it gives the sizes as shown in EM.
--Script to calculate information about the Data Files
SET QUOTED_IDENTIFIER OFF
SET NOCOUNT ON
DECLARE @.dbname varchar(50)
declare @.string varchar(250)
set @.string = ''
create table #datafilestats
( Fileid tinyint,
FileGroup1 tinyint,
TotalExtents1 dec (8, 2),
UsedExtents1 dec (8, 2),
[Name] varchar(50),
[FileName] sysname )
create table #dbstats
( dbname varchar(50),
FileGroupId tinyint,
FileGroupName varchar(25),
TotalSizeinMB dec (8, 2),
UsedSizeinMB dec (8, 2),
FreeSizeinMB dec (8, 2))
DECLARE dbnames_cursor CURSOR FOR SELECT name FROM master..sysdatabases
OPEN dbnames_cursor
FETCH NEXT FROM dbnames_cursor INTO @.dbname
WHILE (@.@.fetch_status = 0)
BEGIN
set @.string = 'use ' + @.dbname + ' DBCC SHOWFILESTATS'
insert into #datafilestats exec (@.string)
insert into #dbstats (dbname, FileGroupId, TotalSizeinMB, UsedSizeinMB)
select @.dbname, FileGroup1, sum(TotalExtents1)*65536.0/1048576.0,
sum(UsedExtents1)*65536.0/1048576.0
from #datafilestats group by FileGroup1
set @.string = 'use ' + @.dbname + ' update #dbstats set FileGroupName =
sysfilegroups.groupname from #dbstats, sysfilegroups where
#dbstats.FileGroupId = sysfilegroups.groupid and #dbstats.dbname =''' +
@.dbname + ''''
exec (@.string)
update #dbstats set FreeSizeinMB = TotalSizeinMB - UsedSizeinMB where
dbname = @.dbname
truncate table #datafilestats
FETCH NEXT FROM dbnames_cursor INTO @.dbname
END
CLOSE dbnames_cursor
DEALLOCATE dbnames_cursor
drop table #datafilestats
select * from #dbstats
drop table #dbstats
--
--Script to calculate information about the Log Files
set nocount on
create table #LogUsageInfo
( db_name varchar(50),
log_size dec (8, 2),
log_used_percent dec (8, 2),
status dec (7, 1) )
insert #LogUsageInfo exec ('dbcc sqlperf(logspace) with no_infomsgs')
select * from #LogUsageInfo
drop table #LogUsageInfo
---
"Ivan" wrote:

> Dear all,
> Is that possible to calculate the database size and free space left by t-s
ql
> script?
> Ivan
>
>|||I have another new task for finding free space left.
Before, I need get the free space left in SQL 2000 databse.
Now, I need get the free space left in SQL 6.5
Need help~~~~~~~~~
Ivan
"Uri Dimant" <urid@.iscar.co.il> glsD:uu74eVO8FHA.1188@.TK2MSFTNGP12.phx.gbl...[vbco
l=seagreen]
> Ivan
> sp_spaceused in the BOL
>
> "Ivan" <ivan@.microsoft.com> wrote in message
> news:%23FcO0QO8FHA.2304@.TK2MSFTNGP10.phx.gbl...
>[/vbcol]|||See my post below.
HTH, Jens Suessmeyer.|||Any SQL 6.5 version?
there's no sysfiles in sql 6.5
Ivan
"Jens" <Jens@.sqlserver2005.de>
'?:1132912972.019598.201170@.g47g2000cwa.googlegroups.com...
> See my post below.
> HTH, Jens Suessmeyer.
>

Saturday, February 25, 2012

C2 Auditing: How to change to directory to save log files

I need to turn on C2 auditing on a sql 2K cluster server.
I do not have any space on C drive which according to the articles (and bol)
is the default place.
How I can change the directory so these traces can be save into the location
I want.
Any solid experience anyone has on C2?
Thank you,
ktf
Hi
C2 auditing writes to \mssql\data directory for default instances of SQL
Server 2000, or the \mssql$instancename\data directory for named instances.
If you change the default database data location in EM, or
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSSQLServer\ MSSQLServer\DefaultData,
it will place them there.
Regards
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"ktf" <ktf@.discussions.microsoft.com> wrote in message
news:D1ACF0EF-410E-4306-B826-17C76081C275@.microsoft.com...
> I need to turn on C2 auditing on a sql 2K cluster server.
> I do not have any space on C drive which according to the articles (and
bol)
> is the default place.
> How I can change the directory so these traces can be save into the
location
> I want.
> Any solid experience anyone has on C2?
> Thank you,
> ktf
>
|||Well Mr. Epprecht,
I have C and D drive which are the local drives and S and R from the SAN.
The only location that I can is on S drive. The registry setting is deferent.
Is there a specific registry object for that mater? I can try to run it and
see where it is saving it but is there a specific place that I can change the
setting that is for C2 ONLY?
Other question I have a passive site for disaster recovery (I am not talking
about passive node) do I have to replicate the trace data? The passive site
has a different virtual server name and ip address. As you know the sql is
sleep but I have a third party replication system going. Do you know if I
replace the trace that will be readable at the passive site?
Do you recommend any site for anything on C2?
Thank you,
ktf
"Mike Epprecht (SQL MVP)" wrote:

> Hi
> C2 auditing writes to \mssql\data directory for default instances of SQL
> Server 2000, or the \mssql$instancename\data directory for named instances.
> If you change the default database data location in EM, or
> HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSSQLServer\ MSSQLServer\DefaultData,
> it will place them there.
> Regards
> --
> --
> Mike Epprecht, Microsoft SQL Server MVP
> Zurich, Switzerland
> IM: mike@.epprecht.net
> MVP Program: http://www.microsoft.com/mvp
> Blog: http://www.msmvps.com/epprecht/
> "ktf" <ktf@.discussions.microsoft.com> wrote in message
> news:D1ACF0EF-410E-4306-B826-17C76081C275@.microsoft.com...
> bol)
> location
>
>

C2 Auditing: How to change to directory to save log files

I need to turn on C2 auditing on a sql 2K cluster server.
I do not have any space on C drive which according to the articles (and bol)
is the default place.
How I can change the directory so these traces can be save into the location
I want.
Any solid experience anyone has on C2?
Thank you,
ktfHi
C2 auditing writes to \mssql\data directory for default instances of SQL
Server 2000, or the \mssql$instancename\data directory for named instances.
If you change the default database data location in EM, or
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSSQLServer\MSSQLServer\DefaultData,
it will place them there.
Regards
--
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"ktf" <ktf@.discussions.microsoft.com> wrote in message
news:D1ACF0EF-410E-4306-B826-17C76081C275@.microsoft.com...
> I need to turn on C2 auditing on a sql 2K cluster server.
> I do not have any space on C drive which according to the articles (and
bol)
> is the default place.
> How I can change the directory so these traces can be save into the
location
> I want.
> Any solid experience anyone has on C2?
> Thank you,
> ktf
>|||Well Mr. Epprecht,
I have C and D drive which are the local drives and S and R from the SAN.
The only location that I can is on S drive. The registry setting is deferent.
Is there a specific registry object for that mater? I can try to run it and
see where it is saving it but is there a specific place that I can change the
setting that is for C2 ONLY?
Other question I have a passive site for disaster recovery (I am not talking
about passive node) do I have to replicate the trace data? The passive site
has a different virtual server name and ip address. As you know the sql is
sleep but I have a third party replication system going. Do you know if I
replace the trace that will be readable at the passive site?
Do you recommend any site for anything on C2?
Thank you,
ktf
"Mike Epprecht (SQL MVP)" wrote:
> Hi
> C2 auditing writes to \mssql\data directory for default instances of SQL
> Server 2000, or the \mssql$instancename\data directory for named instances.
> If you change the default database data location in EM, or
> HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSSQLServer\MSSQLServer\DefaultData,
> it will place them there.
> Regards
> --
> --
> Mike Epprecht, Microsoft SQL Server MVP
> Zurich, Switzerland
> IM: mike@.epprecht.net
> MVP Program: http://www.microsoft.com/mvp
> Blog: http://www.msmvps.com/epprecht/
> "ktf" <ktf@.discussions.microsoft.com> wrote in message
> news:D1ACF0EF-410E-4306-B826-17C76081C275@.microsoft.com...
> >
> > I need to turn on C2 auditing on a sql 2K cluster server.
> > I do not have any space on C drive which according to the articles (and
> bol)
> > is the default place.
> > How I can change the directory so these traces can be save into the
> location
> > I want.
> > Any solid experience anyone has on C2?
> >
> > Thank you,
> > ktf
> >
>
>

C2 Auditing: How to change to directory to save log files

I need to turn on C2 auditing on a sql 2K cluster server.
I do not have any space on C drive which according to the articles (and bol)
is the default place.
How I can change the directory so these traces can be save into the location
I want.
Any solid experience anyone has on C2?
Thank you,
ktfHi
C2 auditing writes to \mssql\data directory for default instances of SQL
Server 2000, or the \mssql$instancename\data directory for named instances.
If you change the default database data location in EM, or
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MS
SQLServer\MSSQLServer\DefaultData,
it will place them there.
Regards
--
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"ktf" <ktf@.discussions.microsoft.com> wrote in message
news:D1ACF0EF-410E-4306-B826-17C76081C275@.microsoft.com...
> I need to turn on C2 auditing on a sql 2K cluster server.
> I do not have any space on C drive which according to the articles (and
bol)
> is the default place.
> How I can change the directory so these traces can be save into the
location
> I want.
> Any solid experience anyone has on C2?
> Thank you,
> ktf
>|||Well Mr. Epprecht,
I have C and D drive which are the local drives and S and R from the SAN.
The only location that I can is on S drive. The registry setting is deferent
.
Is there a specific registry object for that mater? I can try to run it and
see where it is saving it but is there a specific place that I can change th
e
setting that is for C2 ONLY?
Other question I have a passive site for disaster recovery (I am not talking
about passive node) do I have to replicate the trace data? The passive site
has a different virtual server name and ip address. As you know the sql is
sleep but I have a third party replication system going. Do you know if I
replace the trace that will be readable at the passive site?
Do you recommend any site for anything on C2?
Thank you,
ktf
"Mike Epprecht (SQL MVP)" wrote:

> Hi
> C2 auditing writes to \mssql\data directory for default instances of SQL
> Server 2000, or the \mssql$instancename\data directory for named instances
.
> If you change the default database data location in EM, or
> HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MS
SQLServer\MSSQLServer\DefaultData,
> it will place them there.
> Regards
> --
> --
> Mike Epprecht, Microsoft SQL Server MVP
> Zurich, Switzerland
> IM: mike@.epprecht.net
> MVP Program: http://www.microsoft.com/mvp
> Blog: http://www.msmvps.com/epprecht/
> "ktf" <ktf@.discussions.microsoft.com> wrote in message
> news:D1ACF0EF-410E-4306-B826-17C76081C275@.microsoft.com...
> bol)
> location
>
>