|
Home > Archive > MS SQL Server > March 2006 > Re: -S.O.S- Error 927: Error 21776:
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Re: -S.O.S- Error 927: Error 21776:
|
|
| cdiazs 2006-03-29, 9:23 am |
| Thank's for your note.
But, I believe that you not understand me.
The problem is the next:
I was restore process from a backup old, it backup is 1 month ago.
Tha backup is not Ok for me, because I lost data. it is very old for my
use.
When I begin the process restores from backup, I cancel the action with
Button CANCEL.
Then, the DB say "Loading", and click properties and say me: Error 927
.... the BD is in restoring accion.
That is the FIRST ERROR, I see that message, I do next:
I copy X.mdf, X.ldf doing click right on the archieves and copy them
other place.
I execute this action and the error now is other, the error after war
ERROR 927 .. etc,,, NOW the Error is: Error 21776: The name 'dbo' was
not found in de users collection, if
the name is a qualified name .. etc.. and try again.
I see that NEW error, I Execute:
DECLARE @ChangeDBOwner nvarchar(4000)
DECLARE ChangeDBOwner CURSOR
LOCAL FAST_FORWARD READ_ONLY FOR
SELECT N'USE ' + CATALOG_NAME + N'
EXEC sp_changedbowner ''sa'''
FROM INFORMATION_SCHEMA.SCHEMATA
WHERE CATALOG_NAME NOT IN
(
'master',
'model',
'msdb',
'tempdb',
'distribution'
)
OPEN ChangeDBOwner
WHILE 1 = 1
BEGIN
FETCH NEXT FROM ChangeDBOwner INTO @ChangeDBOwner
IF @@FETCH_STATUS = -1 BREAK
EXEC(@ChangeDBOwner)
END
CLOSE ChangeDBOwner
DEALLOCATE ChangeDBOwner
GO
And the Db "X" is not in the CONSOLE MANAGER.
I not see the DB "X" Now.
With yhe las action, the DB "X", Is NOT.
What can I do?
| |
| John Bell 2006-03-29, 9:23 am |
| Hi
The confusion seems to be when you say you copy the mdf and ldf files. Does
this mean that you have detached or dropped the database? If not try dropping
the database before trying the second restore. You should not need to change
the database owner, but if it is only change it for the one database, first
change it to be a different user, and change it to sa.
Is the backup from a different system?
John
"cdiazs" wrote:
> Thank's for your note.
>
> But, I believe that you not understand me.
>
> The problem is the next:
> I was restore process from a backup old, it backup is 1 month ago.
> Tha backup is not Ok for me, because I lost data. it is very old for my
> use.
>
> When I begin the process restores from backup, I cancel the action with
> Button CANCEL.
>
> Then, the DB say "Loading", and click properties and say me: Error 927
> .... the BD is in restoring accion.
>
> That is the FIRST ERROR, I see that message, I do next:
> I copy X.mdf, X.ldf doing click right on the archieves and copy them
> other place.
>
> I execute this action and the error now is other, the error after war
> ERROR 927 .. etc,,, NOW the Error is: Error 21776: The name 'dbo' was
> not found in de users collection, if
> the name is a qualified name .. etc.. and try again.
>
> I see that NEW error, I Execute:
>
> DECLARE @ChangeDBOwner nvarchar(4000)
> DECLARE ChangeDBOwner CURSOR
> LOCAL FAST_FORWARD READ_ONLY FOR
> SELECT N'USE ' + CATALOG_NAME + N'
> EXEC sp_changedbowner ''sa'''
> FROM INFORMATION_SCHEMA.SCHEMATA
> WHERE CATALOG_NAME NOT IN
> (
> 'master',
> 'model',
> 'msdb',
> 'tempdb',
> 'distribution'
> )
> OPEN ChangeDBOwner
> WHILE 1 = 1
> BEGIN
> FETCH NEXT FROM ChangeDBOwner INTO @ChangeDBOwner
> IF @@FETCH_STATUS = -1 BREAK
> EXEC(@ChangeDBOwner)
> END
> CLOSE ChangeDBOwner
> DEALLOCATE ChangeDBOwner
> GO
>
> And the Db "X" is not in the CONSOLE MANAGER.
>
> I not see the DB "X" Now.
>
> With yhe las action, the DB "X", Is NOT.
>
> What can I do?
>
>
| |
| John Bell 2006-03-29, 1:23 pm |
| Hi
I suggest you start again and try to restore the database again as you can
not guarantee the stat your data is in.
John
"cdiazs" wrote:
> I copy the mdf and ldf files, without detached or dropped the database.
> I simply did, copy click right and paste in other place.
> I NOT DROP Database
> I Not detached or attach process.
> I not delete ldf and mdf from your place original.
>
> The database was "LOADING" first, the same as database OFF LINE, to be
> off line, the operative system allow do the "copy click right" process
> to the archives mdf and ldf. for that, I could do the copy files.
>
> Then, to do the ACTION Copy Files: The DB was in Gray color and the
> message was "LOADING" yet.
> but, I did properties the message error NOW is: Error 21776 ----
> etc---.
>
> I see that, new error, I excute the procedure ---changedbowner--, for
> TO SOLVE that error.
> And, I have now is: DATABASE is NOT in console manager.
> The database was gray color and then all actions executed, the dabase
> is not in onsole manager and it is not in sysaltfiles, and it is not
> sysdatabase.
>
> Why database is not in the console manager? I do not kwow.
>
> But, that is the situation.
>
> Please.
>
>
| |
| John Bell 2006-03-30, 3:23 am |
| Hi
Log Explorerr can be used to recover database log files, but if you have
partially restored the backup you may not have a log file that you can work
with.
If you have a backup and log backups that you can restore from then you can
follow the topic "How to restore to a point in time (Transact-SQL)" in books
online to recover the database.
Failing that you may want to call PSS http://tinyurl.com/mpbbf a call to see
if there is anything they can do.
John
"cdiazs" wrote:
> Yes.
> But, I am losing data.
>
> Is there other way for recovery the *.ldf when it is corrupt.
>
> You have use the tool "LOG EXPLORER" by Lumigent tecnologies for
> recovery *.ldf
>
>
|
|
|
|
|