This topic has been archived. It cannot be replied.
-
工作学习 / IT技术讨论 / Sybase问题,急急急!!!我要在同一sybase server上建两database (不建在master device上),我自己建了两database device, one for data one for log. 结果呢,第一个database没有问题,建第二个的时候总是报no space, 可那device上明明还有多得多的space!
不明白啊,一点头绪都没有。
HELP!!!!!!!!!!
多谢多谢!!!1!
-zxcvb(朝天椒);
2004-2-13
{274}
(#1602950@0)
-
没有人理, up!
-zxcvb(朝天椒);
2004-2-13
(#1603310@0)
-
What is your script for creating database and creating device?
-blackswan(uglyduck);
2004-2-13
(#1603320@0)
-
heredeclare @vdevno int
select @vdevno = max(convert(tinyint, substring(convert(binary(4),d.low), v.low,1))) + 1
from master.dbo.sysdevices d, master.dbo.spt_values v
where v.type = 'E' and v.number = 3
disk init name='MyDevice',physname='\\Mypath', vdevno = @vdevno ,size=409600,vstart=134217728,cntrltype=0
go
Create database MyDt1 on MyDevice=100
log on MyLog=50
with override
go
Create database MyDt2 on MyDevice=100
log on MyLog=50
with override
go
第二个建不上
-zxcvb(朝天椒);
2004-2-13
{499}
(#1603431@0)
-
I don't know why you need to specify the vstart number. Can you put it as "0", then retry it?
-blackswan(uglyduck);
2004-2-13
(#1603465@0)
-
成了!!!!!WHY?高手高手,说说道理,不明白为什么.
-zxcvb(朝天椒);
2004-2-13
(#1603493@0)
-
I didn't see your script for creating log device.
-blackswan(uglyduck);
2004-2-13
(#1603457@0)
-
见内,谢谢declare @vdevno int
select @vdevno = max(convert(tinyint, substring(convert(binary(4),d.low), v.low,1))) + 1
from master.dbo.sysdevices d, master.dbo.spt_values v
where v.type = 'E' and v.number = 3
disk init name='MyLog',physname='\\Path', vdevno = @vdevno ,size=51200,vstart=150994944,cntrltype=0
go
-zxcvb(朝天椒);
2004-2-13
{321}
(#1603461@0)
-
I did the test, here is the script.disk init name='MyLog',physname='/usr/apps/sybase/julia/log.dat', vdevno =23 ,size=51200,vstart=0,cntrltype=0
go
disk init name='MyDevice',physname='/usr/apps/dump/julia/testdev.dat', vdevno =22 ,size=409600,vstart=0,cntrltype=0
go
Create database MyDt1 on MyDevice=100
log on MyLog=50
with override
go
Create database MyDt2 on MyDevice=100
log on MyLog=50
with override
go
it runs well. The only difference is vstart value.
-blackswan(uglyduck);
2004-2-13
{454}
(#1603500@0)
-
还有个问题,为什么你的vdevno可以是设那么大,我的都不让我过10?再次感谢,你给我扫扫盲吧
-zxcvb(朝天椒);
2004-2-13
(#1603506@0)
-
If you use the optional vstart parameter, the physical device must contain the sum of the blocks specified by both the vstart and size parameters, or the command fails.
-blackswan(uglyduck);
2004-2-13
(#1603507@0)
-
可我一开始是用Sybase Central建的device啊,它自己就给了我vstart 的value
-zxcvb(朝天椒);
2004-2-13
(#1603522@0)
-
run sp_configure "number of devices", 100, then re-boot your sybase, you can have 100 database device.
-blackswan(uglyduck);
2004-2-13
(#1603515@0)
-
thank you so much!
-zxcvb(朝天椒);
2004-2-13
(#1603533@0)