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

Monday, March 12, 2012

move server

I have to move SQL Server along with three live databases from 'C' drive which runs out of space to 'E' drive (same server).
I will appreciate any guidance you could provide.
Thank you,
Alan.
Alan,
No need to move the database. Just move the Data and Log files.
Right click on each database and in ALL Tasks detach all of them, then
simply move the .mdf and .ldf files to e:. Then use ATTACH database to
attach them again.
Harman Sahni
Database Administrator
Fareportal Inc.
"Alan" <anonymous@.discussions.microsoft.com> wrote in message
news:F59F19C4-EF00-434C-8A5F-DA8514FC4AD0@.microsoft.com...
> I have to move SQL Server along with three live databases from 'C' drive
which runs out of space to 'E' drive (same server).
> I will appreciate any guidance you could provide.
> Thank you,
> Alan.

move server

I have to move SQL Server along with three live databases from 'C' drive whi
ch runs out of space to 'E' drive (same server).
I will appreciate any guidance you could provide.
Thank you,
Alan.Hi,
I will suggest you to move the MDF and LDF files of these 3 databases to E
drive. Let the SQL server program files be there in C drive.If you need to
move the sql server programs then you need to reinstall SQL server.
How to Move the databases from C drive to E Drive
1. detach the databases
SP_DETACH_DB <dbname1>
go
SP_DETACH_DB <dbname2>
go
SP_DETACH_DB <dbname3>
2. Create a new folder in E drive
3. Move the MDF and LDF files of the database detached in step 1
4. Use attach database command to attach it back to sql server
SP_ATTACH_DB
'dbname1','e:\mssql\data\dbname1.mdf','e:\mssql\data\dbname1.ldf'
go
SP_ATTACH_DB
'dbname2','e:\mssql\data\dbname2.mdf','e:\mssql\data\dbname2.ldf'
go
SP_ATTACH_DB
'dbname3','e:\mssql\data\dbname3.mdf','e:\mssql\data\dbname3.ldf'
Note
Replace the database names and physical file names based on ur requirement.
Thanks
Hari
MCDBA
"Alan" <anonymous@.discussions.microsoft.com> wrote in message
news:F59F19C4-EF00-434C-8A5F-DA8514FC4AD0@.microsoft.com...
> I have to move SQL Server along with three live databases from 'C' drive
which runs out of space to 'E' drive (same server).
> I will appreciate any guidance you could provide.
> Thank you,
> Alan.|||Alan,
No need to move the database. Just move the Data and Log files.
Right click on each database and in ALL Tasks detach all of them, then
simply move the .mdf and .ldf files to e:. Then use ATTACH database to
attach them again.
Harman Sahni
Database Administrator
Fareportal Inc.
"Alan" <anonymous@.discussions.microsoft.com> wrote in message
news:F59F19C4-EF00-434C-8A5F-DA8514FC4AD0@.microsoft.com...
> I have to move SQL Server along with three live databases from 'C' drive
which runs out of space to 'E' drive (same server).
> I will appreciate any guidance you could provide.
> Thank you,
> Alan.

Move primary data and log files

I need to move all data from drive e: to another drive due
to space limitations.
My database consists of 2 data files and 2 log files:
e:\data1.mdf
f:\data2.mdf
e:\log1.ldf
f:\log2.ldf
I would like to consolidate the data files into 1 file and
the log files into 1 file.
The files on drive E: are primary filesThis is a multi-part message in MIME format.
--=_NextPart_000_010D_01C3CDF1.B3E7EF40
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
See my answer to your previous post.
--
Tom
---
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinnaclepublishing.com/sql
"Kelly" <anonymous@.discussions.microsoft.com> wrote in message
news:080c01c3ce19$9019cca0$a101280a@.phx.gbl...
I need to move all data from drive e: to another drive due
to space limitations.
My database consists of 2 data files and 2 log files:
e:\data1.mdf
f:\data2.mdf
e:\log1.ldf
f:\log2.ldf
I would like to consolidate the data files into 1 file and
the log files into 1 file.
The files on drive E: are primary files
--=_NextPart_000_010D_01C3CDF1.B3E7EF40
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
&

See my answer to your previous =post.
-- Tom
---T=homas A. Moreau, BSc, PhD, MCSE, MCDBASQL Server MVPColumnist, SQL =Server ProfessionalToronto, ON Canadahttp://www.pinnaclepublishing.com/sql">www.pinnaclepublishing.com=/sql
"Kelly" wrote in message news:080c01c3ce19$90=19cca0$a101280a@.phx.gbl...I need to move all data from drive e: to another drive due to space limitations.My database consists of 2 data files and 2 log files:e:\data1.mdff:\data2.mdfe:\log1.ldff:\log2.=ldfI would like to consolidate the data files into 1 file and the log =files into 1 file.The files on drive E: are primary files

--=_NextPart_000_010D_01C3CDF1.B3E7EF40--|||I did that but SQL Server will not let me remove the
primary file. That is the drive I'm out of space on.
I guess I could move all the data files to antoher drive
first and then drop do the DBCC Shrinkile and Alter Remove
File.
>--Original Message--
>See my answer to your previous post.
>--
>Tom
>----
--
>Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
>SQL Server MVP
>Columnist, SQL Server Professional
>Toronto, ON Canada
>www.pinnaclepublishing.com/sql
>
>"Kelly" <anonymous@.discussions.microsoft.com> wrote in
message
>news:080c01c3ce19$9019cca0$a101280a@.phx.gbl...
>I need to move all data from drive e: to another drive due
>to space limitations.
>My database consists of 2 data files and 2 log files:
>e:\data1.mdf
>f:\data2.mdf
>e:\log1.ldf
>f:\log2.ldf
>I would like to consolidate the data files into 1 file and
>the log files into 1 file.
>The files on drive E: are primary files
>|||This is a multi-part message in MIME format.
--=_NextPart_000_0152_01C3CDF4.0A5AE830
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
You're not removing the primary file. by detaching the database, you're
temporarily removing it from SQL Server. At that point, you can move the
files to a new location, using a regular file copy. Once in the new
location, just reattach.
--
Tom
---
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinnaclepublishing.com/sql
"Kelly" <anonymous@.discussions.microsoft.com> wrote in message
news:078301c3ce1c$ae22aca0$a301280a@.phx.gbl...
I did that but SQL Server will not let me remove the
primary file. That is the drive I'm out of space on.
I guess I could move all the data files to antoher drive
first and then drop do the DBCC Shrinkile and Alter Remove
File.
>--Original Message--
>See my answer to your previous post.
>--
>Tom
>----
--
>Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
>SQL Server MVP
>Columnist, SQL Server Professional
>Toronto, ON Canada
>www.pinnaclepublishing.com/sql
>
>"Kelly" <anonymous@.discussions.microsoft.com> wrote in
message
>news:080c01c3ce19$9019cca0$a101280a@.phx.gbl...
>I need to move all data from drive e: to another drive due
>to space limitations.
>My database consists of 2 data files and 2 log files:
>e:\data1.mdf
>f:\data2.mdf
>e:\log1.ldf
>f:\log2.ldf
>I would like to consolidate the data files into 1 file and
>the log files into 1 file.
>The files on drive E: are primary files
>
--=_NextPart_000_0152_01C3CDF4.0A5AE830
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
&

You're not removing the primary =file. by detaching the database, you're temporarily removing it from SQL =Server. At that point, you can move the files to a new location, using a regular =file copy. Once in the new location, just reattach.
-- Tom
---T=homas A. Moreau, BSc, PhD, MCSE, MCDBASQL Server MVPColumnist, SQL =Server ProfessionalToronto, ON Canadahttp://www.pinnaclepublishing.com/sql">www.pinnaclepublishing.com=/sql
"Kelly" wrote in message news:078301c3ce1c$ae=22aca0$a301280a@.phx.gbl...I did that but SQL Server will not let me remove the primary file. =That is the drive I'm out of space on.I guess I could move all the data =files to antoher drive first and then drop do the DBCC Shrinkile and Alter =Remove File.>--Original Message-->See my answer to =your previous post.>>-->Tom>>--=---->Thomas A. Moreau, BSc, PhD, MCSE, MCDBA>SQL Server MVP>Columnist, =SQL Server Professional>Toronto, ON Canada>www.pinnaclepublishing.com/sql>>>"Kell=y" wrote in message>news:080c01c3ce19$9019cca0$a101280a@.phx.gbl...>=I need to move all data from drive e: to another drive due>to space limitations.>>My database consists of 2 data files and 2 =log files:>>e:\data1.mdf>f:\data2.mdf>>e:\=log1.ldf>f:\log2.ldf>>I would like to consolidate the data files into 1 file and>the log =files into 1 file.>>The files on drive E: are primary files>

--=_NextPart_000_0152_01C3CDF4.0A5AE830--

Saturday, February 25, 2012

Move database to a different drive

Hi,
Someone installed all the data base on the C: drive, Which is now running
out of space. I need to move them to the D: drive.
I found this http://support.microsoft.com/default.aspx?scid=kb;en-us;224071
but it unclear if i need to move just my created database or all of the
database.
I really need a step by step instructions if possable - its a windows 2000
box running sql 2000.
thanks
leeyou can detach \ reattach (See SQL Books On Line)
OR you can do a Backup and RESTORE with "MOVE"
Again, see SQL Books On Line
Greg Jackson
PDX, Oregon|||Move whatever databases you need based on space usage requirements. The
article is pretty self-explanatory. You may move one or all of your user
databases.
--
Geoff N. Hiten
Microsoft SQL Server MVP
Senior Database Administrator
Careerbuilder.com
I support the Professional Association for SQL Server
www.sqlpass.org
"Lee" <Lee@.discussions.microsoft.com> wrote in message
news:2E6E3840-CBB0-4FBE-BC92-E0B45A3ED4E8@.microsoft.com...
> Hi,
> Someone installed all the data base on the C: drive, Which is now running
> out of space. I need to move them to the D: drive.
> I found this
http://support.microsoft.com/default.aspx?scid=kb;en-us;224071
> but it unclear if i need to move just my created database or all of the
> database.
> I really need a step by step instructions if possable - its a windows 2000
> box running sql 2000.
> thanks
> lee|||Hi,
1.First,detach your database using
EXEC sp_detach_db '<<dbname>>', 'true'
2. Move your mdf file & ldf file from c: drive to other partition where you
have space. it is recommended to have mdf & ldf on different folder.
3. Once you copied in to appropriate drives then attach your database using
EXEC sp_attach_db @.dbname = N'<<dbname>>',
@.filename1 = N'<<D:\destinationfolder\dbdata.mdf',
@.filename2 = N'<<E:\destinationfolder\dblog.ldf'
after running this scripts you should see your database running fine as
normal.
Best of luck!
S.Lakshminarayanan.
--
Message posted via http://www.sqlmonster.com

Move database to a different drive

Hi,
Someone installed all the data base on the C: drive, Which is now running
out of space. I need to move them to the D: drive.
I found this http://support.microsoft.com/default...b;en-us;224071
but it unclear if i need to move just my created database or all of the
database.
I really need a step by step instructions if possable - its a windows 2000
box running sql 2000.
thanks
lee
you can detach \ reattach (See SQL Books On Line)
OR you can do a Backup and RESTORE with "MOVE"
Again, see SQL Books On Line
Greg Jackson
PDX, Oregon
|||Move whatever databases you need based on space usage requirements. The
article is pretty self-explanatory. You may move one or all of your user
databases.
Geoff N. Hiten
Microsoft SQL Server MVP
Senior Database Administrator
Careerbuilder.com
I support the Professional Association for SQL Server
www.sqlpass.org
"Lee" <Lee@.discussions.microsoft.com> wrote in message
news:2E6E3840-CBB0-4FBE-BC92-E0B45A3ED4E8@.microsoft.com...
> Hi,
> Someone installed all the data base on the C: drive, Which is now running
> out of space. I need to move them to the D: drive.
> I found this
http://support.microsoft.com/default...b;en-us;224071
> but it unclear if i need to move just my created database or all of the
> database.
> I really need a step by step instructions if possable - its a windows 2000
> box running sql 2000.
> thanks
> lee
|||Hi,
1.First,detach your database using
EXEC sp_detach_db '<<dbname>>', 'true'
2. Move your mdf file & ldf file from c: drive to other partition where you
have space. it is recommended to have mdf & ldf on different folder.
3. Once you copied in to appropriate drives then attach your database using
EXEC sp_attach_db @.dbname = N'<<dbname>>',
@.filename1 = N'<<D:\destinationfolder\dbdata.mdf',
@.filename2 = N'<<E:\destinationfolder\dblog.ldf'
after running this scripts you should see your database running fine as
normal.
Best of luck!
S.Lakshminarayanan.
Message posted via http://www.sqlmonster.com

Move database to a different drive

Hi,
Someone installed all the data base on the C: drive, Which is now running
out of space. I need to move them to the D: drive.
I found this http://support.microsoft.com/defaul...kb;en-us;224071
but it unclear if i need to move just my created database or all of the
database.
I really need a step by step instructions if possable - its a windows 2000
box running sql 2000.
thanks
leeyou can detach \ reattach (See SQL Books On Line)
OR you can do a Backup and RESTORE with "MOVE"
Again, see SQL Books On Line
Greg Jackson
PDX, Oregon|||Move whatever databases you need based on space usage requirements. The
article is pretty self-explanatory. You may move one or all of your user
databases.
Geoff N. Hiten
Microsoft SQL Server MVP
Senior Database Administrator
Careerbuilder.com
I support the Professional Association for SQL Server
www.sqlpass.org
"Lee" <Lee@.discussions.microsoft.com> wrote in message
news:2E6E3840-CBB0-4FBE-BC92-E0B45A3ED4E8@.microsoft.com...
> Hi,
> Someone installed all the data base on the C: drive, Which is now running
> out of space. I need to move them to the D: drive.
> I found this
http://support.microsoft.com/defaul...kb;en-us;224071
> but it unclear if i need to move just my created database or all of the
> database.
> I really need a step by step instructions if possable - its a windows 2000
> box running sql 2000.
> thanks
> lee|||Hi,
1.First,detach your database using
EXEC sp_detach_db '<<dbname>>', 'true'
2. Move your mdf file & ldf file from c: drive to other partition where you
have space. it is recommended to have mdf & ldf on different folder.
3. Once you copied in to appropriate drives then attach your database using
EXEC sp_attach_db @.dbname = N'<<dbname>>',
@.filename1 = N'<<D:\destinationfolder\dbdata.mdf',
@.filename2 = N'<<E:\destinationfolder\dblog.ldf'
after running this scripts you should see your database running fine as
normal.
Best of luck!
S.Lakshminarayanan.
Message posted via http://www.droptable.com

Monday, February 20, 2012

Move Database

We are running out of space on our D: drive and are going to add an
additional drive (E:). I was thinking that there was a wizard in which we
could move our database from its location on the D: over to drive E:. We
would keep our log files on d:, and just move the database to the new E:
drive.
JohnThis is a multi-part message in MIME format.
--=_NextPart_000_016F_01C38D8E.0D24BDD0
Content-Type: text/plain;
charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable
Check out sp_attach_db and sp_detach_db in the BOL.
-- Tom
---
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinnaclepublishing.com/sql
"John Navara" <jnavara@.nospam.com> wrote in message =news:#JyNb8ajDHA.1656@.tk2msftngp13.phx.gbl...
We are running out of space on our D: drive and are going to add an
additional drive (E:). I was thinking that there was a wizard in which =we
could move our database from its location on the D: over to drive E:. =We
would keep our log files on d:, and just move the database to the new E:
drive.
John
--=_NextPart_000_016F_01C38D8E.0D24BDD0
Content-Type: text/html;
charset="Windows-1252"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
&

Check out sp_attach_db and =sp_detach_db in the BOL.
-- Tom
---T=homas A. Moreau, BSc, PhD, MCSE, MCDBASQL Server MVPColumnist, SQL =Server ProfessionalToronto, ON Canadahttp://www.pinnaclepublishing.com/sql">www.pinnaclepublishing.com=/sql
"John Navara" wrote in =message news:#JyNb8ajDHA.1656=@.tk2msftngp13.phx.gbl...We are running out of space on our D: drive and are going to add =anadditional drive (E:). I was thinking that there was a wizard in which =wecould move our database from its location on the D: over to drive E:. Wewould keep our log files on d:, and just move the database to the =new E:drive.John

--=_NextPart_000_016F_01C38D8E.0D24BDD0--