我使用SOL server 2012
作为数据库服务器。现在,mdf
文件大小大约是10 GB
。每当我对这个数据库进行任何事务处理时,sql server
低谷都会出现以下错误
错误号: 1105错误消息:无法为对象dbo.tblsdr分配空间。PK_tblsdr_3213E83F0AD2A005在数据库hwbsssdr中,因为主文件组已满。通过删除不需要的文件、删除文件组中的对象、向文件组添加其他文件或为文件组中的现有文件设置自动增长,创建磁盘空间。
在我的光盘上几乎有免费空间的400 GB
。有谁能告诉我什么是问题,我如何解决这个问题。
发布于 2015-10-26 06:45:09
由于您使用的是Server 2012的Express版本,因此每个数据库的限制是10 so,所以这是您的问题。
顺便说一句,问题不一定要与正在耗尽的磁盘有关。
另外,如果您有将MAXSIZE设置为特定值的数据库,并且如果数据库达到该值,那么下一个事务将从您的问题中报告错误。
因此,如果您确信您有足够的磁盘空间用于下一个事务,请检查执行下一段代码的数据库的MAXSIZE属性:
use master;
go
exec sp_helpdb [YourDatabase]
如果要更改MAXSIZE数据库属性,可以使用下面的代码:
alter database [YourDatabase]
modify file
(
name = 'YourDatabaseFile',
maxsize = X MB
)
发布于 2013-12-03 01:59:55
解释
The specified filegroup has run out of free space.
Action
To gain more space, you can free disk space on any disk drive containing a file in the full filegroup, allowing files in the group to grow. Or you can gain space using a data file with the specified database.
释放磁盘空间
You can free disk space on your local drive or on another disk drive. To free disk space on another drive:
Move the data files in the filegroup with an insufficient amount of free disk space to a different disk drive.
Detach the database by executing sp_detach_db.
Attach the database by executing sp_attach_db, pointing to the moved files.
使用数据文件
Another solution is to add a data file to the specified database using the ADD FILE clause of the ALTER DATABASE statement. Or you can enlarge the data file by using the MODIFY FILE clause of the ALTER DATABASE statement, specifying the SIZE and MAXSIZE syntax.
https://stackoverflow.com/questions/20347624
复制