I need some help to reduce the physical file size of a database transaction
log. I ran the shrink database option under the System Manager and was able
to shring the logical size of the log file, however, I would also like to
reduce the physical size of the file to free up disk space. I have tried to
run the DBCC Shrinkfile and DBCC shrinkdatabase commands but that does not
appear to be successfull. Can anybody help? I am running SQL 2000. Thanks
.http://www.karaszi.com/SQLServer/info_dont_shrink.asp
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Elbryyan" <Elbryyan@.discussions.microsoft.com> wrote in message
news:67FAF140-014E-4CB2-800E-740AF1B69212@.microsoft.com...[vbcol=seagreen]
>I need some help to reduce the physical file size of a database transaction
> log. I ran the shrink database option under the System Manager and was ab
le
> to shring the logical size of the log file, however, I would also like to
> reduce the physical size of the file to free up disk space. I have tried
to
> run the DBCC Shrinkfile and DBCC shrinkdatabase commands but that does not
> appear to be successfull. Can anybody help? I am running SQL 2000. Thanks.[/vbc
ol]
Showing posts with label shrink. Show all posts
Showing posts with label shrink. Show all posts
Saturday, February 25, 2012
Reducing Backup Size
Hello World,
Are there any obvious reasons not to shrink a database right before backup
with a recovery model of "Simple" and re-allocate the free space right after
backup? This is a ETL intensive database.
Backup strategy: daily differential and weekly full.
Thanks.
Hi,
Backup file will only utilize the used portion of data. So why do you want
to shrink the free portion and re allocate
after the backup?
Thanks
Hari
SQL Server MVP
"C TO" <CTO@.discussions.microsoft.com> wrote in message
news:3A646608-80FC-4277-8403-D73E624A9C75@.microsoft.com...
> Hello World,
> Are there any obvious reasons not to shrink a database right before backup
> with a recovery model of "Simple" and re-allocate the free space right
> after
> backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
|||C TO wrote:
> Hello World,
> Are there any obvious reasons not to shrink a database right before
> backup with a recovery model of "Simple" and re-allocate the free
> space right after backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
SQL Server does not backup empty space; only the data. To save backup
space and reduce backup and recovery time, consider using a 3rd party
backup solution for SQL Server. I work for Quest and we sell LiteSpeed.
There are other 3rd part backup solutions that do this as well.
David Gugick
Quest Software
www.imceda.com
www.quest.com
|||I agree, go the third party route on this one. Download a free eval of
lightspeed from Imceda. You will be amazed by the time and space savings.
For the budget minded, I have found Red-Gate (www.red-gate.com I think) to be
very cost productive. But Lightspeed will proably be as close to an industry
standard that you will get.
"C TO" wrote:
> Hello World,
> Are there any obvious reasons not to shrink a database right before backup
> with a recovery model of "Simple" and re-allocate the free space right after
> backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
Are there any obvious reasons not to shrink a database right before backup
with a recovery model of "Simple" and re-allocate the free space right after
backup? This is a ETL intensive database.
Backup strategy: daily differential and weekly full.
Thanks.
Hi,
Backup file will only utilize the used portion of data. So why do you want
to shrink the free portion and re allocate
after the backup?
Thanks
Hari
SQL Server MVP
"C TO" <CTO@.discussions.microsoft.com> wrote in message
news:3A646608-80FC-4277-8403-D73E624A9C75@.microsoft.com...
> Hello World,
> Are there any obvious reasons not to shrink a database right before backup
> with a recovery model of "Simple" and re-allocate the free space right
> after
> backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
|||C TO wrote:
> Hello World,
> Are there any obvious reasons not to shrink a database right before
> backup with a recovery model of "Simple" and re-allocate the free
> space right after backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
SQL Server does not backup empty space; only the data. To save backup
space and reduce backup and recovery time, consider using a 3rd party
backup solution for SQL Server. I work for Quest and we sell LiteSpeed.
There are other 3rd part backup solutions that do this as well.
David Gugick
Quest Software
www.imceda.com
www.quest.com
|||I agree, go the third party route on this one. Download a free eval of
lightspeed from Imceda. You will be amazed by the time and space savings.
For the budget minded, I have found Red-Gate (www.red-gate.com I think) to be
very cost productive. But Lightspeed will proably be as close to an industry
standard that you will get.
"C TO" wrote:
> Hello World,
> Are there any obvious reasons not to shrink a database right before backup
> with a recovery model of "Simple" and re-allocate the free space right after
> backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
Reducing Backup Size
Hello World,
Are there any obvious reasons not to shrink a database right before backup
with a recovery model of "Simple" and re-allocate the free space right after
backup? This is a ETL intensive database.
Backup strategy: daily differential and weekly full.
Thanks.Hi,
Backup file will only utilize the used portion of data. So why do you want
to shrink the free portion and re allocate
after the backup?
Thanks
Hari
SQL Server MVP
"C TO" <CTO@.discussions.microsoft.com> wrote in message
news:3A646608-80FC-4277-8403-D73E624A9C75@.microsoft.com...
> Hello World,
> Are there any obvious reasons not to shrink a database right before backup
> with a recovery model of "Simple" and re-allocate the free space right
> after
> backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.|||C TO wrote:
> Hello World,
> Are there any obvious reasons not to shrink a database right before
> backup with a recovery model of "Simple" and re-allocate the free
> space right after backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
SQL Server does not backup empty space; only the data. To save backup
space and reduce backup and recovery time, consider using a 3rd party
backup solution for SQL Server. I work for Quest and we sell LiteSpeed.
There are other 3rd part backup solutions that do this as well.
--
David Gugick
Quest Software
www.imceda.com
www.quest.com|||I agree, go the third party route on this one. Download a free eval of
lightspeed from Imceda. You will be amazed by the time and space savings.
For the budget minded, I have found Red-Gate (www.red-gate.com I think) to be
very cost productive. But Lightspeed will proably be as close to an industry
standard that you will get.
--
"C TO" wrote:
> Hello World,
> Are there any obvious reasons not to shrink a database right before backup
> with a recovery model of "Simple" and re-allocate the free space right after
> backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
Are there any obvious reasons not to shrink a database right before backup
with a recovery model of "Simple" and re-allocate the free space right after
backup? This is a ETL intensive database.
Backup strategy: daily differential and weekly full.
Thanks.Hi,
Backup file will only utilize the used portion of data. So why do you want
to shrink the free portion and re allocate
after the backup?
Thanks
Hari
SQL Server MVP
"C TO" <CTO@.discussions.microsoft.com> wrote in message
news:3A646608-80FC-4277-8403-D73E624A9C75@.microsoft.com...
> Hello World,
> Are there any obvious reasons not to shrink a database right before backup
> with a recovery model of "Simple" and re-allocate the free space right
> after
> backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.|||C TO wrote:
> Hello World,
> Are there any obvious reasons not to shrink a database right before
> backup with a recovery model of "Simple" and re-allocate the free
> space right after backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
SQL Server does not backup empty space; only the data. To save backup
space and reduce backup and recovery time, consider using a 3rd party
backup solution for SQL Server. I work for Quest and we sell LiteSpeed.
There are other 3rd part backup solutions that do this as well.
--
David Gugick
Quest Software
www.imceda.com
www.quest.com|||I agree, go the third party route on this one. Download a free eval of
lightspeed from Imceda. You will be amazed by the time and space savings.
For the budget minded, I have found Red-Gate (www.red-gate.com I think) to be
very cost productive. But Lightspeed will proably be as close to an industry
standard that you will get.
--
"C TO" wrote:
> Hello World,
> Are there any obvious reasons not to shrink a database right before backup
> with a recovery model of "Simple" and re-allocate the free space right after
> backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
Reducing Backup Size
Hello World,
Are there any obvious reasons not to shrink a database right before backup
with a recovery model of "Simple" and re-allocate the free space right after
backup? This is a ETL intensive database.
Backup strategy: daily differential and weekly full.
Thanks.Hi,
Backup file will only utilize the used portion of data. So why do you want
to shrink the free portion and re allocate
after the backup?
Thanks
Hari
SQL Server MVP
"C TO" <CTO@.discussions.microsoft.com> wrote in message
news:3A646608-80FC-4277-8403-D73E624A9C75@.microsoft.com...
> Hello World,
> Are there any obvious reasons not to shrink a database right before backup
> with a recovery model of "Simple" and re-allocate the free space right
> after
> backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.|||C TO wrote:
> Hello World,
> Are there any obvious reasons not to shrink a database right before
> backup with a recovery model of "Simple" and re-allocate the free
> space right after backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
SQL Server does not backup empty space; only the data. To save backup
space and reduce backup and recovery time, consider using a 3rd party
backup solution for SQL Server. I work for Quest and we sell LiteSpeed.
There are other 3rd part backup solutions that do this as well.
David Gugick
Quest Software
www.imceda.com
www.quest.com|||I agree, go the third party route on this one. Download a free eval of
lightspeed from Imceda. You will be amazed by the time and space savings.
For the budget minded, I have found Red-Gate (www.red-gate.com I think) to b
e
very cost productive. But Lightspeed will proably be as close to an industr
y
standard that you will get.
--
"C TO" wrote:
> Hello World,
> Are there any obvious reasons not to shrink a database right before backup
> with a recovery model of "Simple" and re-allocate the free space right aft
er
> backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
Are there any obvious reasons not to shrink a database right before backup
with a recovery model of "Simple" and re-allocate the free space right after
backup? This is a ETL intensive database.
Backup strategy: daily differential and weekly full.
Thanks.Hi,
Backup file will only utilize the used portion of data. So why do you want
to shrink the free portion and re allocate
after the backup?
Thanks
Hari
SQL Server MVP
"C TO" <CTO@.discussions.microsoft.com> wrote in message
news:3A646608-80FC-4277-8403-D73E624A9C75@.microsoft.com...
> Hello World,
> Are there any obvious reasons not to shrink a database right before backup
> with a recovery model of "Simple" and re-allocate the free space right
> after
> backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.|||C TO wrote:
> Hello World,
> Are there any obvious reasons not to shrink a database right before
> backup with a recovery model of "Simple" and re-allocate the free
> space right after backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
SQL Server does not backup empty space; only the data. To save backup
space and reduce backup and recovery time, consider using a 3rd party
backup solution for SQL Server. I work for Quest and we sell LiteSpeed.
There are other 3rd part backup solutions that do this as well.
David Gugick
Quest Software
www.imceda.com
www.quest.com|||I agree, go the third party route on this one. Download a free eval of
lightspeed from Imceda. You will be amazed by the time and space savings.
For the budget minded, I have found Red-Gate (www.red-gate.com I think) to b
e
very cost productive. But Lightspeed will proably be as close to an industr
y
standard that you will get.
--
"C TO" wrote:
> Hello World,
> Are there any obvious reasons not to shrink a database right before backup
> with a recovery model of "Simple" and re-allocate the free space right aft
er
> backup? This is a ETL intensive database.
> Backup strategy: daily differential and weekly full.
> Thanks.
Monday, February 20, 2012
reduce log file
I want to reduce my log file. it was 64 gb the other day. I deleted it and
recreated another log file.
What is the correct way to use the shrink file command?
mdb
mdb
http://www.support.microsoft.com/?id=317375 Log File Grows too big
http://www.support.microsoft.com/?id=110139 Log file filling up
http://www.mssqlserver.com/faq/logs-shrinklog.asp Shrink File
http://www.support.microsoft.com/?id=315512 Considerations for Autogrow
and AutoShrink
http://www.support.microsoft.com/?id=256650 INF: How to Shrink the SQL
Server 7.0 Tran Log
http://www.support.microsoft.com/?id=272318 INF: Shrinking Log in SQL
Server 2000 with DBCC SHRINKFILE
http://www.karaszi.com/SQLServer/info_dont_shrink.asp Shrinking
considerations
Andrew J. Kelly SQL MVP
"mdb" <mdb@.discussions.microsoft.com> wrote in message
news:87373855-6995-4660-930F-FAE61DF3650E@.microsoft.com...
> I want to reduce my log file. it was 64 gb the other day. I deleted it
and
> recreated another log file.
> What is the correct way to use the shrink file command?
>
> --
> mdb
> --
> mdb
recreated another log file.
What is the correct way to use the shrink file command?
mdb
mdb
http://www.support.microsoft.com/?id=317375 Log File Grows too big
http://www.support.microsoft.com/?id=110139 Log file filling up
http://www.mssqlserver.com/faq/logs-shrinklog.asp Shrink File
http://www.support.microsoft.com/?id=315512 Considerations for Autogrow
and AutoShrink
http://www.support.microsoft.com/?id=256650 INF: How to Shrink the SQL
Server 7.0 Tran Log
http://www.support.microsoft.com/?id=272318 INF: Shrinking Log in SQL
Server 2000 with DBCC SHRINKFILE
http://www.karaszi.com/SQLServer/info_dont_shrink.asp Shrinking
considerations
Andrew J. Kelly SQL MVP
"mdb" <mdb@.discussions.microsoft.com> wrote in message
news:87373855-6995-4660-930F-FAE61DF3650E@.microsoft.com...
> I want to reduce my log file. it was 64 gb the other day. I deleted it
and
> recreated another log file.
> What is the correct way to use the shrink file command?
>
> --
> mdb
> --
> mdb
Reduce Data file Size
Hi,
Currently our data file size is near to 9GB. I need to reduce the data file
size.
Which one is the better way.
When i try to Shrink the Data file or Database its running for more than 1
hour so i stopped.
Please give me a solution as soon as Possible.
Thanks,
Herbert
you can reduce the size of the data file in small decrements
if there are un-used extents in the database
dbcc shrinkfile(logicalfile_name,targetsize,TRUNCATEONL Y)
pls check BOL for full details
HTH
Olu Adedeji
Deutsche Bank
"Herbert" wrote:
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert
|||Take a look before doing it.
Why you want to be restrictive with shrink of database files
http://www.karaszi.com/SQLServer/info_dont_shrink.asp
AMB
"Herbert" wrote:
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert
|||Hi,
You can shrink the data (MDF) file only if you have free space. Execute the
below command to see the unallocated space.
sp_spaceused
If you have enough space left then use the suggestions mentioned by
Alejandro.
Thanks
Hari
SQL Server MVP
"Herbert" <Herbert@.discussions.microsoft.com> wrote in message
news:3D3C2310-7EAD-495C-A3EC-60F83319AD47@.microsoft.com...
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data
> file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert
|||Thanks all for ur valid informations
Thanks,
Herbert
"Hari Prasad" wrote:
> Hi,
> You can shrink the data (MDF) file only if you have free space. Execute the
> below command to see the unallocated space.
> sp_spaceused
> If you have enough space left then use the suggestions mentioned by
> Alejandro.
> Thanks
> Hari
> SQL Server MVP
>
> "Herbert" <Herbert@.discussions.microsoft.com> wrote in message
> news:3D3C2310-7EAD-495C-A3EC-60F83319AD47@.microsoft.com...
>
>
Currently our data file size is near to 9GB. I need to reduce the data file
size.
Which one is the better way.
When i try to Shrink the Data file or Database its running for more than 1
hour so i stopped.
Please give me a solution as soon as Possible.
Thanks,
Herbert
you can reduce the size of the data file in small decrements
if there are un-used extents in the database
dbcc shrinkfile(logicalfile_name,targetsize,TRUNCATEONL Y)
pls check BOL for full details
HTH
Olu Adedeji
Deutsche Bank
"Herbert" wrote:
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert
|||Take a look before doing it.
Why you want to be restrictive with shrink of database files
http://www.karaszi.com/SQLServer/info_dont_shrink.asp
AMB
"Herbert" wrote:
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert
|||Hi,
You can shrink the data (MDF) file only if you have free space. Execute the
below command to see the unallocated space.
sp_spaceused
If you have enough space left then use the suggestions mentioned by
Alejandro.
Thanks
Hari
SQL Server MVP
"Herbert" <Herbert@.discussions.microsoft.com> wrote in message
news:3D3C2310-7EAD-495C-A3EC-60F83319AD47@.microsoft.com...
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data
> file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert
|||Thanks all for ur valid informations
Thanks,
Herbert
"Hari Prasad" wrote:
> Hi,
> You can shrink the data (MDF) file only if you have free space. Execute the
> below command to see the unallocated space.
> sp_spaceused
> If you have enough space left then use the suggestions mentioned by
> Alejandro.
> Thanks
> Hari
> SQL Server MVP
>
> "Herbert" <Herbert@.discussions.microsoft.com> wrote in message
> news:3D3C2310-7EAD-495C-A3EC-60F83319AD47@.microsoft.com...
>
>
Reduce Data file Size
Hi,
Currently our data file size is near to 9GB. I need to reduce the data file
size.
Which one is the better way.
When i try to Shrink the Data file or Database its running for more than 1
hour so i stopped.
Please give me a solution as soon as Possible.
Thanks,
Herbertyou can reduce the size of the data file in small decrements
if there are un-used extents in the database
dbcc shrinkfile(logicalfile_name,targetsize,T
RUNCATEONLY)
pls check BOL for full details
--
HTH
Olu Adedeji
Deutsche Bank
"Herbert" wrote:
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data fil
e
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert|||Take a look before doing it.
Why you want to be restrictive with shrink of database files
http://www.karaszi.com/SQLServer/info_dont_shrink.asp
AMB
"Herbert" wrote:
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data fil
e
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert|||Hi,
You can shrink the data (MDF) file only if you have free space. Execute the
below command to see the unallocated space.
sp_spaceused
If you have enough space left then use the suggestions mentioned by
Alejandro.
Thanks
Hari
SQL Server MVP
"Herbert" <Herbert@.discussions.microsoft.com> wrote in message
news:3D3C2310-7EAD-495C-A3EC-60F83319AD47@.microsoft.com...
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data
> file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert|||Thanks all for ur valid informations
Thanks,
Herbert
"Hari Prasad" wrote:
> Hi,
> You can shrink the data (MDF) file only if you have free space. Execute th
e
> below command to see the unallocated space.
> sp_spaceused
> If you have enough space left then use the suggestions mentioned by
> Alejandro.
> Thanks
> Hari
> SQL Server MVP
>
> "Herbert" <Herbert@.discussions.microsoft.com> wrote in message
> news:3D3C2310-7EAD-495C-A3EC-60F83319AD47@.microsoft.com...
>
>
Currently our data file size is near to 9GB. I need to reduce the data file
size.
Which one is the better way.
When i try to Shrink the Data file or Database its running for more than 1
hour so i stopped.
Please give me a solution as soon as Possible.
Thanks,
Herbertyou can reduce the size of the data file in small decrements
if there are un-used extents in the database
dbcc shrinkfile(logicalfile_name,targetsize,T
RUNCATEONLY)
pls check BOL for full details
--
HTH
Olu Adedeji
Deutsche Bank
"Herbert" wrote:
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data fil
e
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert|||Take a look before doing it.
Why you want to be restrictive with shrink of database files
http://www.karaszi.com/SQLServer/info_dont_shrink.asp
AMB
"Herbert" wrote:
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data fil
e
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert|||Hi,
You can shrink the data (MDF) file only if you have free space. Execute the
below command to see the unallocated space.
sp_spaceused
If you have enough space left then use the suggestions mentioned by
Alejandro.
Thanks
Hari
SQL Server MVP
"Herbert" <Herbert@.discussions.microsoft.com> wrote in message
news:3D3C2310-7EAD-495C-A3EC-60F83319AD47@.microsoft.com...
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data
> file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert|||Thanks all for ur valid informations
Thanks,
Herbert
"Hari Prasad" wrote:
> Hi,
> You can shrink the data (MDF) file only if you have free space. Execute th
e
> below command to see the unallocated space.
> sp_spaceused
> If you have enough space left then use the suggestions mentioned by
> Alejandro.
> Thanks
> Hari
> SQL Server MVP
>
> "Herbert" <Herbert@.discussions.microsoft.com> wrote in message
> news:3D3C2310-7EAD-495C-A3EC-60F83319AD47@.microsoft.com...
>
>
Reduce Data file Size
Hi,
Currently our data file size is near to 9GB. I need to reduce the data file
size.
Which one is the better way.
When i try to Shrink the Data file or Database its running for more than 1
hour so i stopped.
Please give me a solution as soon as Possible.
Thanks,
Herbertyou can reduce the size of the data file in small decrements
if there are un-used extents in the database
dbcc shrinkfile(logicalfile_name,targetsize,TRUNCATEONLY)
pls check BOL for full details
--
HTH
Olu Adedeji
Deutsche Bank
"Herbert" wrote:
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert|||Take a look before doing it.
Why you want to be restrictive with shrink of database files
http://www.karaszi.com/SQLServer/info_dont_shrink.asp
AMB
"Herbert" wrote:
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert|||Hi,
You can shrink the data (MDF) file only if you have free space. Execute the
below command to see the unallocated space.
sp_spaceused
If you have enough space left then use the suggestions mentioned by
Alejandro.
Thanks
Hari
SQL Server MVP
"Herbert" <Herbert@.discussions.microsoft.com> wrote in message
news:3D3C2310-7EAD-495C-A3EC-60F83319AD47@.microsoft.com...
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data
> file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert|||Thanks all for ur valid informations
Thanks,
Herbert
"Hari Prasad" wrote:
> Hi,
> You can shrink the data (MDF) file only if you have free space. Execute the
> below command to see the unallocated space.
> sp_spaceused
> If you have enough space left then use the suggestions mentioned by
> Alejandro.
> Thanks
> Hari
> SQL Server MVP
>
> "Herbert" <Herbert@.discussions.microsoft.com> wrote in message
> news:3D3C2310-7EAD-495C-A3EC-60F83319AD47@.microsoft.com...
> > Hi,
> >
> > Currently our data file size is near to 9GB. I need to reduce the data
> > file
> > size.
> >
> > Which one is the better way.
> >
> > When i try to Shrink the Data file or Database its running for more than 1
> > hour so i stopped.
> >
> > Please give me a solution as soon as Possible.
> >
> > Thanks,
> > Herbert
>
>
Currently our data file size is near to 9GB. I need to reduce the data file
size.
Which one is the better way.
When i try to Shrink the Data file or Database its running for more than 1
hour so i stopped.
Please give me a solution as soon as Possible.
Thanks,
Herbertyou can reduce the size of the data file in small decrements
if there are un-used extents in the database
dbcc shrinkfile(logicalfile_name,targetsize,TRUNCATEONLY)
pls check BOL for full details
--
HTH
Olu Adedeji
Deutsche Bank
"Herbert" wrote:
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert|||Take a look before doing it.
Why you want to be restrictive with shrink of database files
http://www.karaszi.com/SQLServer/info_dont_shrink.asp
AMB
"Herbert" wrote:
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert|||Hi,
You can shrink the data (MDF) file only if you have free space. Execute the
below command to see the unallocated space.
sp_spaceused
If you have enough space left then use the suggestions mentioned by
Alejandro.
Thanks
Hari
SQL Server MVP
"Herbert" <Herbert@.discussions.microsoft.com> wrote in message
news:3D3C2310-7EAD-495C-A3EC-60F83319AD47@.microsoft.com...
> Hi,
> Currently our data file size is near to 9GB. I need to reduce the data
> file
> size.
> Which one is the better way.
> When i try to Shrink the Data file or Database its running for more than 1
> hour so i stopped.
> Please give me a solution as soon as Possible.
> Thanks,
> Herbert|||Thanks all for ur valid informations
Thanks,
Herbert
"Hari Prasad" wrote:
> Hi,
> You can shrink the data (MDF) file only if you have free space. Execute the
> below command to see the unallocated space.
> sp_spaceused
> If you have enough space left then use the suggestions mentioned by
> Alejandro.
> Thanks
> Hari
> SQL Server MVP
>
> "Herbert" <Herbert@.discussions.microsoft.com> wrote in message
> news:3D3C2310-7EAD-495C-A3EC-60F83319AD47@.microsoft.com...
> > Hi,
> >
> > Currently our data file size is near to 9GB. I need to reduce the data
> > file
> > size.
> >
> > Which one is the better way.
> >
> > When i try to Shrink the Data file or Database its running for more than 1
> > hour so i stopped.
> >
> > Please give me a solution as soon as Possible.
> >
> > Thanks,
> > Herbert
>
>
Subscribe to:
Posts (Atom)