Re: Suggestions for managing large tables
From: Mike Hodgson (mwh_junk_at_hotmail.com)
Date: 12/19/04
- Next message: Ken Schaefer: "Re: Cached Logon"
- Previous message: Andrew: "Re: Newbie: Deleting Huge Log"
- In reply to: evan b: "Re: Suggestions for managing large tables"
- Next in thread: evan b: "Re: Suggestions for managing large tables"
- Reply: evan b: "Re: Suggestions for managing large tables"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 20 Dec 2004 10:07:42 +1100
> When I get the new logical drive setup I will create another data file
> and link it up to the DB but do i need to setup one for each DB I run as
> they will all run out of space on my Drive E (data drive) and this one 3rd
> party db will be the cause.
Yep, data files are contained within a filegroup and filegroups are
groupings of data files within a specific DB. So each DB you want to
extend to the new LUN, when you get it set up, will need its own
secondary data file on that new LUN.
> If I split the DB byt moving tables/indices to another file in drive <new>
> then should i lock the DB file growth on the first file and allow unlimted
> on the new datafile?
You don't need to "move" anything. Just add a new file to whichever
filegroup (presumedly "PRIMARY") the tables reside on and they'll start
using the space in the new file (data is striped across all files in the
filegroup). If you want to move specific tables and/or indexes to
another disk you'll need to create a 2nd filegroup (called something
other than PRIMARY) containing a data file on the new disk and then move
the table data (ie. clustered index) or indexes as appropriate.
I read a good explanation on this newsgroup a few months ago about how
multiple files within a filegroup fill up. I think it was posted by
Mike Epprecht. And having a 30 second look through SQL BOL I found the
info I'm sure Mike referred to in posting the article:
<http://msdn.microsoft.com/library/default.asp?url=/library/en-us/createdb/cm_8_des_02_2ak3.asp>
Basically, the files in a filegroup fill up proportionally according to
their free space, so the bottom line is all files within a filegroup
should become 100% full at the same time. Then the files are expanded
round-robin fashion one at a time (which is pretty dumb IMHO as it kinda
defeats the purpose of striping the data within the filegroups). So if
I were you I'd set your file on the disk that's almost full to not
autogrow, then only the new file (on your new LUN) will autogrow when
they're all full.
>
> It seems to work (tried it on lappy) but need some ressurance.
>
Hope this provides some reassurance.
Cheers,
Mike.
- Next message: Ken Schaefer: "Re: Cached Logon"
- Previous message: Andrew: "Re: Newbie: Deleting Huge Log"
- In reply to: evan b: "Re: Suggestions for managing large tables"
- Next in thread: evan b: "Re: Suggestions for managing large tables"
- Reply: evan b: "Re: Suggestions for managing large tables"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|