Showing posts with label running. Show all posts
Showing posts with label running. Show all posts

Thursday, March 29, 2012

Cannot Remove SQL 2005 June CTP

I have SQL 2005 June CTP installed and running. I previously had VS 2005 CTP installed as well. I removed VS with the beta removal tool and installed the release version. I am now trying to remove SQL and cannot do it.

First I tried Add / Remove programs. I chose remove for SQL 2005 and it removed the entry from Add / Remove programs but did nothing else. I then tried the beta removal tool sqlbuw.exe on the CD which detectes 3 instances of SQL 2005 but when it tries to remove them it says "There are no SQL Server 2005 or .NET Framework components to uninstall. You may now run the setup wizard to install new instances."

When I run the setup wizard it says i must uninstall the previous incompatible beta versions first.

Talk about catch 22. Are there instructions for manually removing SQL 2005 June CTP?

Thanks
MartinMartin,

It sounds like you got yourself into trouble by removing VS prior to SQL Server. The SQL Server uninstall requires that .Net Framework 2.0 still be present on the machine. The reason for this is some assemblies are placed in the GAC (Global Assembly Cache) and the only way to clean up the GAC is through the .Net Framework.

We have an uninstall script that I can send you. You should know that this script is not supported and is not tested to a full release level. We've been using it internally and I've given it out to some folks - we've had no reports of the script causing any machine corruption, however, this is a run at your own risk deal. If you're interested in the script email me at dan.jones@.microsoft.com.

Cheers,
Dan|||Unfortuantly the script did not work and a rebuild was required. At least my computer is faster now :o)

Martin

Cannot remove replication

Hi,
I have a box running SQL 7 with replication. I restored one of the
replicated database to another SQL 7 with no replication. A developer needed
to test an upgrade of an application (MS Great Plains) using that database.
The application states that the tables are part of a replication. As far as I
know, when you restore a replicated DB to another server (with no
replication), the replication infomation is lost. I have also ran
sp_removedbreplication successfully but we still have the same problem.
Any ideas?
--
--
I saw it work in a cartoon once so I am pretty sure I can do it.The tables in question are still marked for replication.
I think you may need to manually update some of the system tables to remove
the marking for replication on the object.
I don't have my poster here at the office, so i couldn't tell you which
tables specically to look at.
I would guess sysobjects.xtype....
Rick Sawtell
MCT, MCSD, MCDBA
"Sasan Saidi" <SasanSaidi@.discussions.microsoft.com> wrote in message
news:260846C9-A09A-415A-8028-715D66021376@.microsoft.com...
> Hi,
> I have a box running SQL 7 with replication. I restored one of the
> replicated database to another SQL 7 with no replication. A developer
needed
> to test an upgrade of an application (MS Great Plains) using that
database.
> The application states that the tables are part of a replication. As far
as I
> know, when you restore a replicated DB to another server (with no
> replication), the replication infomation is lost. I have also ran
> sp_removedbreplication successfully but we still have the same problem.
> Any ideas?
> --
> --
> I saw it work in a cartoon once so I am pretty sure I can do it.|||I don't have a SQL 7.0 box at work anymore, but if it
also exists on SQL 7.0, please try using
sp_MSunmarkreplinfo which takes a tablename as a parameter
HTH,
Paul Ibison (SQL Server MVP)
>> (recommended sql server 2000 replication book:
>> http://www.nwsu.com/0974973602p.html)|||Before updatnig system tables, I would recommend making sure you've dropped
the distributor and publisher. In EM from Tools...Replication...configure
publishing subscribers and distributors. Make sure there are no selections
(uncheck all boxes).
Colleen
"Paul Ibison" wrote:
> I don't have a SQL 7.0 box at work anymore, but if it
> also exists on SQL 7.0, please try using
> sp_MSunmarkreplinfo which takes a tablename as a parameter
> HTH,
> Paul Ibison (SQL Server MVP)
> >> (recommended sql server 2000 replication book:
> >> http://www.nwsu.com/0974973602p.html)
>
>

Cannot remove replication

Hi,
I have a box running SQL 7 with replication. I restored one of the
replicated database to another SQL 7 with no replication. A developer needed
to test an upgrade of an application (MS Great Plains) using that database.
The application states that the tables are part of a replication. As far as
I
know, when you restore a replicated DB to another server (with no
replication), the replication infomation is lost. I have also ran
sp_removedbreplication successfully but we still have the same problem.
Any ideas?
--
I saw it work in a cartoon once so I am pretty sure I can do it.The tables in question are still marked for replication.
I think you may need to manually update some of the system tables to remove
the marking for replication on the object.
I don't have my poster here at the office, so i couldn't tell you which
tables specically to look at.
I would guess sysobjects.xtype....
Rick Sawtell
MCT, MCSD, MCDBA
"Sasan Saidi" <SasanSaidi@.discussions.microsoft.com> wrote in message
news:260846C9-A09A-415A-8028-715D66021376@.microsoft.com...
> Hi,
> I have a box running SQL 7 with replication. I restored one of the
> replicated database to another SQL 7 with no replication. A developer
needed
> to test an upgrade of an application (MS Great Plains) using that
database.
> The application states that the tables are part of a replication. As far
as I
> know, when you restore a replicated DB to another server (with no
> replication), the replication infomation is lost. I have also ran
> sp_removedbreplication successfully but we still have the same problem.
> Any ideas?
> --
> --
> I saw it work in a cartoon once so I am pretty sure I can do it.

Tuesday, March 27, 2012

Cannot remove replication

Hi,
I have a box running SQL 7 with replication. I restored one of the
replicated database to another SQL 7 with no replication. A developer needed
to test an upgrade of an application (MS Great Plains) using that database.
The application states that the tables are part of a replication. As far as I
know, when you restore a replicated DB to another server (with no
replication), the replication infomation is lost. I have also ran
sp_removedbreplication successfully but we still have the same problem.
Any ideas?
--
I saw it work in a cartoon once so I am pretty sure I can do it.
The tables in question are still marked for replication.
I think you may need to manually update some of the system tables to remove
the marking for replication on the object.
I don't have my poster here at the office, so i couldn't tell you which
tables specically to look at.
I would guess sysobjects.xtype....
Rick Sawtell
MCT, MCSD, MCDBA
"Sasan Saidi" <SasanSaidi@.discussions.microsoft.com> wrote in message
news:260846C9-A09A-415A-8028-715D66021376@.microsoft.com...
> Hi,
> I have a box running SQL 7 with replication. I restored one of the
> replicated database to another SQL 7 with no replication. A developer
needed
> to test an upgrade of an application (MS Great Plains) using that
database.
> The application states that the tables are part of a replication. As far
as I
> know, when you restore a replicated DB to another server (with no
> replication), the replication infomation is lost. I have also ran
> sp_removedbreplication successfully but we still have the same problem.
> Any ideas?
> --
> --
> I saw it work in a cartoon once so I am pretty sure I can do it.

cannot register local SQL server

I had SQL Server running locally on my pc and now I
suddenly can't connect. I deleted the registration and
tried re-registering it in EM. When I use Windows
authentication I get a msg saying "cannot open default
database, using master database instead"..but it doesn't
register.
When I use SQL authentication using the sa login, I get a
msg saying "login failed for sa, not associated with a
trusted SQL Server connection". (The SQL Server service
is still running OK on my pc).
Any ideas as to how to fix it, and why it went wrong in
the first place?
Thanks
DaveLooks like you:
1. Run in Windows authentication mode, no sa is permitted
2. you deleted the database (or sent it offline) you specified as defautl
database for the
Windows user you try to connect.
TO sign on as sa change the reg key use this manual:
---
http://support.microsoft.com/default.aspx?scid=kb;EN-US;q285097
---
INF: How to Change the Default Login Authentication Mode to SQL While
Installing SQL Server 2000 Desktop Engine by Using Windows Installer
---
<snip>
Another way to change the security mode after installation is to stop
SQL Server and set the appropriate registry key for your installation:
Default instance:
HKLM\Software\Microsoft\MSSqlserver\MSSqlServer\LoginMode
Named instance:
HKLM\Software\Microsoft\Microsoft SQL Server\Instance
Name\MSSQLServer\LoginMode
to 2 for mixed-mode or 1 for integrated. (Integrated is the default
setup for the SQL Server 2000 Data Engine.)
</snip>
HTH, Jens Süßmeyer.
"dave" <anonymous@.discussions.microsoft.com> schrieb im Newsbeitrag
news:06d901c3b41f$68325220$a001280a@.phx.gbl...
> I had SQL Server running locally on my pc and now I
> suddenly can't connect. I deleted the registration and
> tried re-registering it in EM. When I use Windows
> authentication I get a msg saying "cannot open default
> database, using master database instead"..but it doesn't
> register.
> When I use SQL authentication using the sa login, I get a
> msg saying "login failed for sa, not associated with a
> trusted SQL Server connection". (The SQL Server service
> is still running OK on my pc).
> Any ideas as to how to fix it, and why it went wrong in
> the first place?
> Thanks
> Dave|||dave
>When I use Windows
> authentication I get a msg saying "cannot open default
> database, using master database instead"..but it doesn't
> register.
Do you have a login like (DOMAIN\Dave) ?
> When I use SQL authentication using the sa login, I get a
> msg saying "login failed for sa, not associated with a
> trusted SQL Server connection".
You can change an authentication settings of the server
Right click on the server ,then Properties ,then under Security Tab change
Authentication to SQL and Windows.
"dave" <anonymous@.discussions.microsoft.com> wrote in message
news:06d901c3b41f$68325220$a001280a@.phx.gbl...
> I had SQL Server running locally on my pc and now I
> suddenly can't connect. I deleted the registration and
> tried re-registering it in EM. When I use Windows
> authentication I get a msg saying "cannot open default
> database, using master database instead"..but it doesn't
> register.
> When I use SQL authentication using the sa login, I get a
> msg saying "login failed for sa, not associated with a
> trusted SQL Server connection". (The SQL Server service
> is still running OK on my pc).
> Any ideas as to how to fix it, and why it went wrong in
> the first place?
> Thanks
> Dave|||> You can change an authentication settings of the server
> Right click on the server ,then Properties ,then under Security Tab change
> Authentication to SQL and Windows.
But if you can´t register you are really f.... :)
Jens Süßmeyer.|||An alternative to change login mode to mixed is to login using ISQL.EXE (it will let you in even if
your default database doesn't exist) and use sp_defaultdb to change the default database to an
existing database.
I do not recommend changing default database for sysadmins (for the very reason we see here).
--
Tibor Karaszi, SQL Server MVP
Archive at: http://groups.google.com/groups?oi=djq&as_ugroup=microsoft.public.sqlserver
"dave" <anonymous@.discussions.microsoft.com> wrote in message
news:06d901c3b41f$68325220$a001280a@.phx.gbl...
> I had SQL Server running locally on my pc and now I
> suddenly can't connect. I deleted the registration and
> tried re-registering it in EM. When I use Windows
> authentication I get a msg saying "cannot open default
> database, using master database instead"..but it doesn't
> register.
> When I use SQL authentication using the sa login, I get a
> msg saying "login failed for sa, not associated with a
> trusted SQL Server connection". (The SQL Server service
> is still running OK on my pc).
> Any ideas as to how to fix it, and why it went wrong in
> the first place?
> Thanks
> Dave|||Thanks Jens
Changed the registry setting to 2 and it worked using SQL authentication.
>--Original Message--
>Looks like you:
>1. Run in Windows authentication mode, no sa is permitted
>2. you deleted the database (or sent it offline) you specified as defautl
>database for the
>Windows user you try to connect.
>TO sign on as sa change the reg key use this manual:
>----
--
>http://support.microsoft.com/default.aspx?scid=3Dkb;EN-
US;q285097
>----
--
>INF: How to Change the Default Login Authentication Mode to SQL While
>Installing SQL Server 2000 Desktop Engine by Using Windows Installer
>----
--
><snip>
>Another way to change the security mode after installation is to stop
>SQL Server and set the appropriate registry key for your installation:
>Default instance:
>HKLM\Software\Microsoft\MSSqlserver\MSSqlServer\LoginMode
>Named instance:
>HKLM\Software\Microsoft\Microsoft SQL Server\Instance
>Name\MSSQLServer\LoginMode
>to 2 for mixed-mode or 1 for integrated. (Integrated is the default
>setup for the SQL Server 2000 Data Engine.)
></snip>
>HTH, Jens S=FC=DFmeyer.
>
>
>"dave" <anonymous@.discussions.microsoft.com> schrieb im Newsbeitrag
>news:06d901c3b41f$68325220$a001280a@.phx.gbl...
>> I had SQL Server running locally on my pc and now I
>> suddenly can't connect. I deleted the registration and
>> tried re-registering it in EM. When I use Windows
>> authentication I get a msg saying "cannot open default
>> database, using master database instead"..but it doesn't
>> register.
>> When I use SQL authentication using the sa login, I get a
>> msg saying "login failed for sa, not associated with a
>> trusted SQL Server connection". (The SQL Server service
>> is still running OK on my pc).
>> Any ideas as to how to fix it, and why it went wrong in
>> the first place?
>> Thanks
>> Dave
>
>.
>|||just change the loginmode parameter in the register to sa..
It should work
--
Shaju Thomas
"dave" <anonymous@.discussions.microsoft.com> wrote in message
news:06d901c3b41f$68325220$a001280a@.phx.gbl...
> I had SQL Server running locally on my pc and now I
> suddenly can't connect. I deleted the registration and
> tried re-registering it in EM. When I use Windows
> authentication I get a msg saying "cannot open default
> database, using master database instead"..but it doesn't
> register.
> When I use SQL authentication using the sa login, I get a
> msg saying "login failed for sa, not associated with a
> trusted SQL Server connection". (The SQL Server service
> is still running OK on my pc).
> Any ideas as to how to fix it, and why it went wrong in
> the first place?
> Thanks
> Dave

Sunday, March 25, 2012

Cannot register 2000 on 7 (HELP!)

I am running SQL 7 and trying to connect to a SQL2000
server on the network. I can ping the other machine, and
I have mapped a network drive, but I cannot register it.
It gives me a General Network error. Any Ideas?Brett,
If you try the Register Server Wizard on a SQL 7.0 server, you should see
the following message:
<SQL Server 2000 server name> - You must upgrade your SQL Enterprise Manager
and SQL-DMO(SQLOLE) to SQL Server 2000 (SQLDMO) to connect to this server.
Keith Wilson
This posting is provided "AS IS" without express or implied warranty,
guarantee, or rights.
"Brett" <levi71@.swbell.net> wrote in message
news:0ec801c3d9ea$61c87e50$a301280a@.phx.gbl...
quote:

> I am running SQL 7 and trying to connect to a SQL2000
> server on the network. I can ping the other machine, and
> I have mapped a network drive, but I cannot register it.
> It gives me a General Network error. Any Ideas?

Cannot read unicode data from SQL Server

Hi all,
I have a SQL Server 2000 running as the database and there
is a table contain some multi-language data, the table
structure is as follow:
CREATE TABLE mytable
(
english nvarchar(255),
japanese nvarchar(255),
chinese nvarchar(255)
)
The chinese column will store traditional chinese
characters while the japanese column will store japanese
character.
I have already imported all the record from an well-
defined Excel file to mytable, and I can read all the
chinese and japanese characters properly from Enterprise
manager and Query Analyzer, however, when I use ADO
recordset to get the data from mytable in the ASP, the
data cannot be shown properly, all the japanese and
chinese data is shown as question marks (ie,"'?").
Here is my ASP Code,
Set dbCon = Server.CreateObject("ADODB.Connection")
dbCon.Open "Provider=SQLOLEDB.1;Persist Security
Info=False;User ID=sa;Initial Catalog=mydatabase;Data
Source=myserver"
Set rs = Server.CreateObject("ADODB.RecordSet")
rs.CursorLocation = 3
rs.CursorType = 3
rs.LockType = 3
rs.ActiveConnection = dbCon
rs.Open "Select * from mytable"
Even though I have changed the charset to "big5" in the
ASP, only chinese character can be shown properly, but not
japanese. I have already try all the charset in my ASP,
but none of them can show the japanese characters properly.
rmk:
1. I am running Traditional Chinese Windows 2k and in the
regional setting, I have set the default locate to
traditional chinese.
2. The collation of the my database is
SQL_Latin1_General_CP1_CI_AS
Is it the collation problem, window OS locate problem,data
type problem or the ASP coding problem ?
Anyone can help me ?
Many thanks
ongMake sure Japanses font is installed.
Do not use charset Big5. You want utf-8
Use the directive <%@. CodePage=65001 %> at the top of your asp page
"ong" <on_g@.sinatown.com> wrote in message
news:011c01c35012$1b1bb560$a001280a@.phx.gbl...
> Hi all,
> I have a SQL Server 2000 running as the database and there
> is a table contain some multi-language data, the table
> structure is as follow:
> CREATE TABLE mytable
> (
> english nvarchar(255),
> japanese nvarchar(255),
> chinese nvarchar(255)
> )
> The chinese column will store traditional chinese
> characters while the japanese column will store japanese
> character.
> I have already imported all the record from an well-
> defined Excel file to mytable, and I can read all the
> chinese and japanese characters properly from Enterprise
> manager and Query Analyzer, however, when I use ADO
> recordset to get the data from mytable in the ASP, the
> data cannot be shown properly, all the japanese and
> chinese data is shown as question marks (ie,"'?").
> Here is my ASP Code,
> Set dbCon = Server.CreateObject("ADODB.Connection")
> dbCon.Open "Provider=SQLOLEDB.1;Persist Security
> Info=False;User ID=sa;Initial Catalog=mydatabase;Data
> Source=myserver"
> Set rs = Server.CreateObject("ADODB.RecordSet")
> rs.CursorLocation = 3
> rs.CursorType = 3
> rs.LockType = 3
> rs.ActiveConnection = dbCon
> rs.Open "Select * from mytable"
>
> Even though I have changed the charset to "big5" in the
> ASP, only chinese character can be shown properly, but not
> japanese. I have already try all the charset in my ASP,
> but none of them can show the japanese characters properly.
> rmk:
> 1. I am running Traditional Chinese Windows 2k and in the
> regional setting, I have set the default locate to
> traditional chinese.
> 2. The collation of the my database is
> SQL_Latin1_General_CP1_CI_AS
>
> Is it the collation problem, window OS locate problem,data
> type problem or the ASP coding problem ?
> Anyone can help me ?
> Many thanks
> ong
>

Thursday, March 22, 2012

Cannot perform a differential backup for database

hi seniors ,

I am running sql server 2005 under details

Microsoft SQL Server 2005 - 9.00.3033.00 (X64)

Copyright (c) 1988-2005 Microsoft Corporation
Standard Edition (64-bit)
on Windows NT 5.2 (Build 3790: Service Pack 1)

When i attempt to take differentail backup i receieved following message


"Cannot perform a differential backup for database "abc",
because a current database backup does not exist.
Perform a full database backup by reissuing BACKUP DATABASE,
omitting the WITH DIFFERENTIAL option. [SQLSTATE 42000] (Error 3035)
BACKUP DATABASE is terminating abnormally. [SQLSTATE 42000] (Error 3013)."

when i search this msg on net than i find that it is microsoft bug 863 so i found hotfixes
about this problem and tried to install but unable to install (On installation screen select feature i am unable to click on check box)

Can any one help me regarding to this issue .And more is.. full back of db "abc" exists and i never changed its location nor rename file name.

Regards

First action of any backup activity should be full backup. For differential backup u should have a Baseline/Full backup. SO first take full backup and the try differential backup

backup database SomeDtabase to Disk='D:\Somefile.bak' with init

the above statment will create the full backup of your database. then do the diffrential backup . Read more in BOL

Madhu

|||

thanxs madhu , When i saw deatils about with INIT...I think it should work now. But one thing more wheather i should use this clasue with differential backup or not...

thanxs again

Ahmad Drshen

|||

it depends .... whether u need to overwrite the backup file or not... its again depend upon the Backup strategy of your server....

Read more about INIT in BOL

Madhu

|||

Hi Madhu K Nair and other Seinors ,

Agian , i am fall in problem

" Cannot perform a differential backup for database "AAA", because a current database backup does not exist. Perform a full database backup by reissuing BACKUP DATABASE, omitting the WITH DIFFERENTIAL option. [SQLSTATE 42000] (Error 3035) BACKUP DATABASE is terminating abnormally. [SQLSTATE 42000] (Error 3013).

I have just Taken backup of db "AAA" on friday at 7:30 PM through script

BACKUP DATABASE AAA TO DISK = 'C:\LV_full_AAA_20071702.bkp'

WITH INIT , NOUNLOAD ,

NAME = 'AAAbackup', NOSKIP , STATS = 10,

NOFORMAT

DECLARE @.i INT

select @.i = position from msdb..backupset where database_name='AAA'

and backup_set_id=(select max(backup_set_id) from msdb..backupset where database_name='AAA')

RESTORE VERIFYONLY FROM DISK = 'C:\LV_full_AAA_20071702.bkp' WITH FILE = @.i

Database backup has done successfully. :)

Again I ran the script to take differentail backup on friday at 11:30 PM through script

BACKUP DATABASE AAA TO DISK = 'C:\LV_Diff_AAA_20071702.bkp'

WITH INIT , NOUNLOAD , DIFFERENTIAL ,

NAME = 'AAAbackup', NOSKIP , STATS = 10,

NOFORMAT

DECLARE @.i INT

select @.i = position from msdb..backupset where database_name='AAA'

and backup_set_id=(select max(backup_set_id) from msdb..backupset where database_name='AAA')

RESTORE VERIFYONLY FROM DISK = 'C:\LV_Diff_AAA_20071702.bkp' WITH FILE = @.i

Differentail backup has also done successfully.

But on saturaday when the script ran for taking differentail backup of db AAA on 11:30 PM

it repoted follwoing error

" Cannot perform a differential backup for database "AAA", because a current database backup does not exist. Perform a full database backup by reissuing BACKUP DATABASE, omitting the WITH DIFFERENTIAL option. [SQLSTATE 42000] (Error 3035) BACKUP DATABASE is terminating abnormally. [SQLSTATE 42000] (Error 3013). "

while these script are working properly on another production server even there is not mention WITH INIT option with full backup.

wat the hell is going in taking backup my this server .One thing more i just installed the SP2 exe name was "SQLServer2005SP2-KB921896-x64-ENU.exe" on my server perhaps i am stucking with this problem after installing this plz let me know wat is the solution to fix this hell.

thanxs in advance

Ahmad Drshen

|||

How recent is your full backup of the database? Have there been any significant changes since then?

This is CTP2 for SP2. Did you enable the VarDecimal compression? This would invalidate the previous full, as the database version number is changed.

|||

thanxs ,VarDecimal compression ! as far as i know this is not supported in standard edtion of Sql server. any how i also try to enable this anf got the messahe that "

Vardecimal Storage Format is not supported on Standard Edition (64-bit).

"

I just tookfull backup on friday on 7:30 and then took differential backup on 11:30 on firday it happened successfully.

But on saturady i was unable to take differential backup again due to this error.

"Cannot perform a differential backup for database "abc",
because a current database backup does not exist.
Perform a full database backup by reissuing BACKUP DATABASE,
omitting the WITH DIFFERENTIAL option. [SQLSTATE 42000] (Error 3035)
BACKUP DATABASE is terminating abnormally. [SQLSTATE 42000] (Error 3013)."

plz any other solution

|||

ooh i just solve it by the help of follwoing article

http://support.microsoft.com/kb/903643

|||

Hi there,

I've had a similar problem with Differential Backups for SQL Server however I am on SP2 for SQL Server 2005 and SP2 of Windows Server 2003. The differential backups work perfectly until an NTBACKUP is run with the snapSurprisen option so that it uses the Volume Shadow Copy. The next differential backup executed by SQL Server then fails with the same sorts of errors reported here in this thread. If I run NTBACKUP with snapSurpriseff then the problem disappears and SQL Server differential backups carry on working as usual.

Kind Regards

|||

HI there specially Post21, u r quite right , this problem is due to Ntbackup utility but unluckly i change the option sanp oFF but still facing problem. can u guide me some Backup command switches which can help in this issue.

|||

I found the solution to my problem. I posted on a thread in Newsgroups on this but thought I'd post my findings here as well.

I couldn't understand why all of a sudden I was getting broken differential chains when NT BACKUP was run using volume shadow copy service after
upgrading the servers to SP2 of SQL Server 2005 and SP2 of Windows Server 2003. As in this KB http://support.microsoft.com/kb/903643. I hadn't had
this problem until this upgrade.

Here's the reason:

The "Readme for Microsoft SQL Server 2005 Service Pack 2" at
http://download.microsoft.com/download/2/b/5/2b5e5d37-9b17-423d-bc8f-b11ecd4195b4/ReadmeSQL2005SP2.htm
states:

3.2.6 SQL Server 2005 SP2 Changes the SQL Writer Service Default Startup Type and Default State

Note the following changes to the SQL Writer service default startup type and default state:

The SQL Writer service startup type is changed from Manual to Automatic.

The SQL Writer service default state is changed from Stopped to Started.


So I changed the service back to manual and stopped the service. This of course
behaved as expected, the VSS didn't try to lock my Full recovery model
databases and break the differential chain. I can still allow /volsnapSurprisen
option with my NTBACKUP commands to backup all the other "open" files on the
volume without breaking the database differential chain.

The thing that started me looking into this was this line in the BOL article
that a guy on the newsgroup mentioned.

This SQL Writer Service is automatically installed but not enabled by
default. It must be explicitly enabled to run on the server machine and must
be running at the time that the Volume Shadow Copy Service (VSS) application
requests a backup or restore. Use the Microsoft Windows Services applet to
configure the service. The SQL Writer Service installs on all operating
systems but is only needed on server systems. For Microsoft Windows XP, use
the MSDE Writer.

Hope the above helps somebody else out of the same situation.

Regards
Nick

|||thats quite fine and i have got the solution . thanks for all of participents.

Cannot perform a differential backup for database

hi seniors ,

I am running sql server 2005 under details

Microsoft SQL Server 2005 - 9.00.3033.00 (X64)

Copyright (c) 1988-2005 Microsoft Corporation
Standard Edition (64-bit)
on Windows NT 5.2 (Build 3790: Service Pack 1)

When i attempt to take differentail backup i receieved following message


"Cannot perform a differential backup for database "abc",
because a current database backup does not exist.
Perform a full database backup by reissuing BACKUP DATABASE,
omitting the WITH DIFFERENTIAL option. [SQLSTATE 42000] (Error 3035)
BACKUP DATABASE is terminating abnormally. [SQLSTATE 42000] (Error 3013)."

when i search this msg on net than i find that it is microsoft bug 863 so i found hotfixes
about this problem and tried to install but unable to install (On installation screen select feature i am unable to click on check box)

Can any one help me regarding to this issue .And more is.. full back of db "abc" exists and i never changed its location nor rename file name.

Regards

First action of any backup activity should be full backup. For differential backup u should have a Baseline/Full backup. SO first take full backup and the try differential backup

backup database SomeDtabase to Disk='D:\Somefile.bak' with init

the above statment will create the full backup of your database. then do the diffrential backup . Read more in BOL

Madhu

|||

thanxs madhu , When i saw deatils about with INIT...I think it should work now. But one thing more wheather i should use this clasue with differential backup or not...

thanxs again

Ahmad Drshen

|||

it depends .... whether u need to overwrite the backup file or not... its again depend upon the Backup strategy of your server....

Read more about INIT in BOL

Madhu

|||

Hi Madhu K Nair and other Seinors ,

Agian , i am fall in problem

" Cannot perform a differential backup for database "AAA", because a current database backup does not exist. Perform a full database backup by reissuing BACKUP DATABASE, omitting the WITH DIFFERENTIAL option. [SQLSTATE 42000] (Error 3035) BACKUP DATABASE is terminating abnormally. [SQLSTATE 42000] (Error 3013).

I have just Taken backup of db "AAA" on friday at 7:30 PM through script

BACKUP DATABASE AAA TO DISK = 'C:\LV_full_AAA_20071702.bkp'

WITH INIT , NOUNLOAD ,

NAME = 'AAAbackup', NOSKIP , STATS = 10,

NOFORMAT

DECLARE @.i INT

select @.i = position from msdb..backupset where database_name='AAA'

and backup_set_id=(select max(backup_set_id) from msdb..backupset where database_name='AAA')

RESTORE VERIFYONLY FROM DISK = 'C:\LV_full_AAA_20071702.bkp' WITH FILE = @.i

Database backup has done successfully. :)

Again I ran the script to take differentail backup on friday at 11:30 PM through script

BACKUP DATABASE AAA TO DISK = 'C:\LV_Diff_AAA_20071702.bkp'

WITH INIT , NOUNLOAD , DIFFERENTIAL ,

NAME = 'AAAbackup', NOSKIP , STATS = 10,

NOFORMAT

DECLARE @.i INT

select @.i = position from msdb..backupset where database_name='AAA'

and backup_set_id=(select max(backup_set_id) from msdb..backupset where database_name='AAA')

RESTORE VERIFYONLY FROM DISK = 'C:\LV_Diff_AAA_20071702.bkp' WITH FILE = @.i

Differentail backup has also done successfully.

But on saturaday when the script ran for taking differentail backup of db AAA on 11:30 PM

it repoted follwoing error

" Cannot perform a differential backup for database "AAA", because a current database backup does not exist. Perform a full database backup by reissuing BACKUP DATABASE, omitting the WITH DIFFERENTIAL option. [SQLSTATE 42000] (Error 3035) BACKUP DATABASE is terminating abnormally. [SQLSTATE 42000] (Error 3013). "

while these script are working properly on another production server even there is not mention WITH INIT option with full backup.

wat the hell is going in taking backup my this server .One thing more i just installed the SP2 exe name was "SQLServer2005SP2-KB921896-x64-ENU.exe" on my server perhaps i am stucking with this problem after installing this plz let me know wat is the solution to fix this hell.

thanxs in advance

Ahmad Drshen

|||

How recent is your full backup of the database? Have there been any significant changes since then?

This is CTP2 for SP2. Did you enable the VarDecimal compression? This would invalidate the previous full, as the database version number is changed.

|||

thanxs ,VarDecimal compression ! as far as i know this is not supported in standard edtion of Sql server. any how i also try to enable this anf got the messahe that "

Vardecimal Storage Format is not supported on Standard Edition (64-bit).

"

I just tookfull backup on friday on 7:30 and then took differential backup on 11:30 on firday it happened successfully.

But on saturady i was unable to take differential backup again due to this error.

"Cannot perform a differential backup for database "abc",
because a current database backup does not exist.
Perform a full database backup by reissuing BACKUP DATABASE,
omitting the WITH DIFFERENTIAL option. [SQLSTATE 42000] (Error 3035)
BACKUP DATABASE is terminating abnormally. [SQLSTATE 42000] (Error 3013)."

plz any other solution

|||

ooh i just solve it by the help of follwoing article

http://support.microsoft.com/kb/903643

|||

Hi there,

I've had a similar problem with Differential Backups for SQL Server however I am on SP2 for SQL Server 2005 and SP2 of Windows Server 2003. The differential backups work perfectly until an NTBACKUP is run with the snapSurprisen option so that it uses the Volume Shadow Copy. The next differential backup executed by SQL Server then fails with the same sorts of errors reported here in this thread. If I run NTBACKUP with snapSurpriseff then the problem disappears and SQL Server differential backups carry on working as usual.

Kind Regards

|||

HI there specially Post21, u r quite right , this problem is due to Ntbackup utility but unluckly i change the option sanp oFF but still facing problem. can u guide me some Backup command switches which can help in this issue.

|||

I found the solution to my problem. I posted on a thread in Newsgroups on this but thought I'd post my findings here as well.

I couldn't understand why all of a sudden I was getting broken differential chains when NT BACKUP was run using volume shadow copy service after
upgrading the servers to SP2 of SQL Server 2005 and SP2 of Windows Server 2003. As in this KB http://support.microsoft.com/kb/903643. I hadn't had
this problem until this upgrade.

Here's the reason:

The "Readme for Microsoft SQL Server 2005 Service Pack 2" at
http://download.microsoft.com/download/2/b/5/2b5e5d37-9b17-423d-bc8f-b11ecd4195b4/ReadmeSQL2005SP2.htm
states:

3.2.6 SQL Server 2005 SP2 Changes the SQL Writer Service Default Startup Type and Default State

Note the following changes to the SQL Writer service default startup type and default state:

The SQL Writer service startup type is changed from Manual to Automatic.

The SQL Writer service default state is changed from Stopped to Started.


So I changed the service back to manual and stopped the service. This of course
behaved as expected, the VSS didn't try to lock my Full recovery model
databases and break the differential chain. I can still allow /volsnapSurprisen
option with my NTBACKUP commands to backup all the other "open" files on the
volume without breaking the database differential chain.

The thing that started me looking into this was this line in the BOL article
that a guy on the newsgroup mentioned.

This SQL Writer Service is automatically installed but not enabled by
default. It must be explicitly enabled to run on the server machine and must
be running at the time that the Volume Shadow Copy Service (VSS) application
requests a backup or restore. Use the Microsoft Windows Services applet to
configure the service. The SQL Writer Service installs on all operating
systems but is only needed on server systems. For Microsoft Windows XP, use
the MSDE Writer.

Hope the above helps somebody else out of the same situation.

Regards
Nick

|||thats quite fine and i have got the solution . thanks for all of participents.

Cannot open user defualt database. Login failed.

Hi,

I know that there have been numerous posts on this topic, however none of the suggestions seems to resolve my problem. I am running a ASP 2.0 web application locally using SQL server 2005 express, but after using SQL Server Management Studio to browse the database of the application i get the following error everytime i log into the website:

Cannot open user default database. Login failed. Login failed for user '<<machine name>>\ASPNET'

All i had done is attach then detatch the database in SSMS and it seems to have changed the access permissions somehow.
I have ensured that the ASPNET user has full permissions (server roles and User mapping) in SSMS and i have granted the ASPNET user full rights to the ASPNETDB.MDF and log file, but i still get the same error.

Its really urgent i sort this problem out as soon as possible, so if anyone has tackled this problem before please help. Ideally i don't want to have to reinstall sql server, but if that is the only option and it will definitely fix the problem then i will.

Thanks,

Jack

Hey,

No, it didn't change permissions. It probably set the ASPNET account to that database, and now that database is detached and gone. With an admin account, go in, and change the default database for the ASPNET account.

|||

Thanks for your quick reply.

Currently when i log into SSMS i use windows authentication, and am an administrator on the system. So do you mean that when i go into SSMS that i need to attach ASPNETDB.mdf and then change the default database for the ASPNET account underSecurity > Logins. Then detach the db again?

I'm pretty new to sql server express, so if you could walk me through the steps i'd really appreciate it.

Thanks again.

|||

Hey,

Actually, that sounds about right. You know more than you think.

Tuesday, March 20, 2012

Cannot open database "xx" requested by the login. The login failed.

Hi,
we are running a webapplication, using IIS6, Windows 2003 64 bit in classic Asp.
In the asp pages we connect to our SQL server (SQL Server 2005 64bit,windows 2003 64 bit), mirrored on a third sql server (same software setup as the first sql server).

The mirroring is without witness.

This works perfectly but sometimes we get the following error :

Description: [Microsoft][SQL Native Client][SQL Server]Cannot open database

"OBJECTS" requested by the login. The login failed.

In the logs of sql, we see that the offending connection does not go the principal but to the mirror. Which would cause the problem of course..

The name of the database varies, and there is no consistent error. Most of the time there are no problems (95%), but sometimes we get these errors.

Connection from the asp to sql is done using ADO, using following driver in the connectionstring :

Driver="{SQL Native Client}"

Does anyone have an idea what could be the problem ?
We can of course increase timouts for the mirroring, but is this the solution ?

Greets
Tom

Looks like your application attempts to login using "OBJECTS" as the default database and the database does not exist. Is that database supposed to always exist or is it occasionally dropped and recreated? Your application should not attempt to connect to the database if it might not exist.

Thanks
Laurentiu

|||Hi Laurentiu,

the database always exists. So it must always be available for connection.
But for some reason SQL fails to see the database.

Also, it's not one and the same database that has this problems. We have more than 100 databases on the sql server, and the connection error popups randomly with other databases.

Greets
Tom|||

Can you check your server errorlog and post the errors that show up there? Also, does this happen during server startup by any chance? Is your database on a special volume, such that it would take longer to start up, for example, is it on an EFS volume?

Thanks
Laurentiu

|||Hi Laurentiu,

I'll check the correct SQL serverlogs when this error occurs.

The server is not starting up but running as normally. Remember, this is a production server.
No special volumes.

Additional information :

As told the connection is made in our ASP pages , using an ADO connectionstring.

Now it seems that the initial connection setup works :
e.g

set pCn = Server.CreateObject("ADODB.Connection")
pCn.connectionstring=lstr
pCn.Open

And the first executes always seem to work :
e.g.
pcn.Execute ("select * from thetable")

But in the same page, more executes are performed with the same connection (pC).
And after some executes, it fails with the above error.

Again, this does not happen always, and not with the same database !
And we are not starting up the server, or doing special tasks (aka backups,etc) which would add an extra load on the server.
The moments that this error occures are random, as are the databases with which the error occurs.

Greetings
Tom

|||

If you hit the error again, can you please provide the errorlog entries?

Thanks
Laurentiu

|||

Hi Laurentiu,

sorry for the delay in getting back to you.

There are no error entries in the primary sql server error logs
Only an error pops up in the secondary (mirror) server, stating the login failed.
And this of cours makes sense, as the connection does not go to the primary but to the secondary, which is acting as mirror. And therefore can not be accessed.

The question is : why does the connection sometimes jumps in stead from the primary server, to the mirror server ? Nowhere in my code I give a secondary server as reference.

The connection is made through ODBC in an ASP web application (IIS6) , simelar to :

Set oCn = Server.CreateObject("ADODB.Connection")
oCn.CommandTimeout = 180
oCn.Open lconstirng lconstring

where lconstring is a dsn param : e.g. "filedsn=c:\data\dsn\mastercon.dsn"
where the dsn file contains following info :

[ODBC]
DRIVER={SQL Native Client}
UID=myuserid
pwd=mypwd
Address=xxx.yyy.zzz.qqq,myport
Network=DBMSSOCN
DATABASE=MyDatabaseName
WSID=xxx.yyy.zzz.qqq
APP=Microsoft Open Database Connectivity
SERVER=xxx.yyy.zzz.qqq
Description=blabla


I tried the above without the DSN, so a dsnless connection string. Nothing changed.
I tried following drivers :{SQL Native Client} and SQLNCLI
Nothing changed

Any ideas ?

Greets
Tom|||

Hi Tom,

For these questions, I suggest trying the Database Mirroring forum or the SQL Server Data Access forum. These are the forums that address issues related to mirroring and server connections.

Thanks
Laurentiu

Monday, March 19, 2012

Cannot open database "xx" requested by the login. The login failed.

Hi,
we are running a webapplication, using IIS6, Windows 2003 64 bit in classic Asp.
In

the ASP pages we connect to our SQL server (SQL Server 2005

64bit,windows 2003 64 bit), mirrored on a third sql server (same

software /hardware setup as the first sql server).

The mirroring is without witness.

This works but sometimes we get the following ODBC error in our ASP application :

Description: [Microsoft][SQL Native Client][SQL Server]Cannot open database

"OBJECTS" requested by the login. The login failed.

No error can be seen in the principal SQL error logs.
But a failed authorization can be found on the mirror server..
And this of course this makes

sense, as the connection does not go to the primary but to the

secondary, which is acting as mirror. And therefore can not be accessed.

The question is : why

does the connection sometimes jumps in stead from the primary server,

to the mirror server ? Nowhere in the code I give a secondary server as

reference.

Most of

the time there are no problems (97%), but sometimes we get these errors.

The moments that this error occures are random, as are the databases with which the error occurs.

The connection is made through ODBC in an ASP web application (IIS6) , simelar to :

Set oCn = Server.CreateObject("ADODB.Connection")
oCn.CommandTimeout = 180
oCn.Open lconstring

where lconstring is a dsn param : e.g. "filedsn=c:\data\dsn\mastercon.dsn"
where the dsn file contains following info :

[ODBC]
DRIVER={SQL Native Client}
UID=myuserid
pwd=mypwd
Address=xxx.yyy.zzz.qqq,myport
Network=DBMSSOCN
DATABASE=MyDatabaseName
WSID=xxx.yyy.zzz.qqq
APP=Microsoft Open Database Connectivity
SERVER=xxx.yyy.zzz.qqq
Description=blabla


I tried the above without the DSN, so a dsnless connection string. Nothing changed.
I tried following drivers :{SQL Native Client} and SQLNCLI
Nothing changed


Does anyone have an idea what could be the problem ?
We can of course increase timouts for the mirroring, but is this the solution ?
Before we started using SQL 2005 and mirroring this problem did not occur.

Greets

Tom

This will occur if you client has intermittent problems accessing the principal. The mirroring principal will send the name of the mirror server to the client after the first connection. If the client loses connection, it does not know if the principal has failed (it could have been destroyed by a natural disaster for example) so it will try to connect to the mirror to see if there has been a failover to the mirror. Since there was no server side failover in this case, you will get the connection failure logged on the mirror server. I recommend you monitor your network to see if there are intermittent problems causing this behavior.

Regards,

Matt Hollingsworth

Sr. Program Manager

SQL Server High Availability

|||At this point we can't find any immediate problems.

What information could help us to identify the reason causing the 'intermittent problems accessing the principal' ?

Are there logs I can consult ?

Greetings

Tom|||

I found an interesting link, which could be the reason for our problem.

But we are unaware that we disbled pooling :

http://groups-beta.google.com/group/microsoft.public.sqlserver.odbc/browse_thread/thread/9c79f6f4e8adce7b/f99b340d2fd76aef

Would this fix help even when pooling is enabled ?

Greetings,
Tom

|||Any solution for this with SP2 for 2005 ?

Cannot open database "xx" requested by the login. The login failed.

Hi,
we are running a webapplication, using IIS6, Windows 2003 64 bit in classic Asp.
In

the ASP pages we connect to our SQL server (SQL Server 2005

64bit,windows 2003 64 bit), mirrored on a third sql server (same

software /hardware setup as the first sql server).

The mirroring is without witness.

This works but sometimes we get the following ODBC error in our ASP application :

Description: [Microsoft][SQL Native Client][SQL Server]Cannot open database

"OBJECTS" requested by the login. The login failed.

No error can be seen in the principal SQL error logs.
But a failed authorization can be found on the mirror server..
And this of course this makes

sense, as the connection does not go to the primary but to the

secondary, which is acting as mirror. And therefore can not be accessed.

The question is : why

does the connection sometimes jumps in stead from the primary server,

to the mirror server ? Nowhere in the code I give a secondary server as

reference.

Most of

the time there are no problems (97%), but sometimes we get these errors.

The moments that this error occures are random, as are the databases with which the error occurs.

The connection is made through ODBC in an ASP web application (IIS6) , simelar to :

Set oCn = Server.CreateObject("ADODB.Connection")
oCn.CommandTimeout = 180
oCn.Open lconstring

where lconstring is a dsn param : e.g. "filedsn=c:\data\dsn\mastercon.dsn"
where the dsn file contains following info :

[ODBC]
DRIVER={SQL Native Client}
UID=myuserid
pwd=mypwd
Address=xxx.yyy.zzz.qqq,myport
Network=DBMSSOCN
DATABASE=MyDatabaseName
WSID=xxx.yyy.zzz.qqq
APP=Microsoft Open Database Connectivity
SERVER=xxx.yyy.zzz.qqq
Description=blabla


I tried the above without the DSN, so a dsnless connection string. Nothing changed.
I tried following drivers :{SQL Native Client} and SQLNCLI
Nothing changed


Does anyone have an idea what could be the problem ?
We can of course increase timouts for the mirroring, but is this the solution ?
Before we started using SQL 2005 and mirroring this problem did not occur.

Greets

Tom

This will occur if you client has intermittent problems accessing the principal. The mirroring principal will send the name of the mirror server to the client after the first connection. If the client loses connection, it does not know if the principal has failed (it could have been destroyed by a natural disaster for example) so it will try to connect to the mirror to see if there has been a failover to the mirror. Since there was no server side failover in this case, you will get the connection failure logged on the mirror server. I recommend you monitor your network to see if there are intermittent problems causing this behavior.

Regards,

Matt Hollingsworth

Sr. Program Manager

SQL Server High Availability

|||At this point we can't find any immediate problems.

What information could help us to identify the reason causing the 'intermittent problems accessing the principal' ?

Are there logs I can consult ?

Greetings

Tom|||

I found an interesting link, which could be the reason for our problem.

But we are unaware that we disbled pooling :

http://groups-beta.google.com/group/microsoft.public.sqlserver.odbc/browse_thread/thread/9c79f6f4e8adce7b/f99b340d2fd76aef

Would this fix help even when pooling is enabled ?

Greetings,
Tom

|||Any solution for this with SP2 for 2005 ?

Cannot open database "xx" requested by the login. The login failed.

Hi,
we are running a webapplication, using IIS6, Windows 2003 64 bit in classic Asp.
In

the ASP pages we connect to our SQL server (SQL Server 2005

64bit,windows 2003 64 bit), mirrored on a third sql server (same

software /hardware setup as the first sql server).

The mirroring is without witness.

This works but sometimes we get the following ODBC error in our ASP application :

Description: [Microsoft][SQL Native Client][SQL Server]Cannot open database

"OBJECTS" requested by the login. The login failed.

No error can be seen in the principal SQL error logs.
But a failed authorization can be found on the mirror server..
And this of course this makes

sense, as the connection does not go to the primary but to the

secondary, which is acting as mirror. And therefore can not be accessed.

The question is : why

does the connection sometimes jumps in stead from the primary server,

to the mirror server ? Nowhere in the code I give a secondary server as

reference.

Most of

the time there are no problems (97%), but sometimes we get these errors.

The moments that this error occures are random, as are the databases with which the error occurs.

The connection is made through ODBC in an ASP web application (IIS6) , simelar to :

Set oCn = Server.CreateObject("ADODB.Connection")
oCn.CommandTimeout = 180
oCn.Open lconstring

where lconstring is a dsn param : e.g. "filedsn=c:\data\dsn\mastercon.dsn"
where the dsn file contains following info :

[ODBC]
DRIVER={SQL Native Client}
UID=myuserid
pwd=mypwd
Address=xxx.yyy.zzz.qqq,myport
Network=DBMSSOCN
DATABASE=MyDatabaseName
WSID=xxx.yyy.zzz.qqq
APP=Microsoft Open Database Connectivity
SERVER=xxx.yyy.zzz.qqq
Description=blabla


I tried the above without the DSN, so a dsnless connection string. Nothing changed.
I tried following drivers :{SQL Native Client} and SQLNCLI
Nothing changed


Does anyone have an idea what could be the problem ?
We can of course increase timouts for the mirroring, but is this the solution ?
Before we started using SQL 2005 and mirroring this problem did not occur.

Greets

Tom

This will occur if you client has intermittent problems accessing the principal. The mirroring principal will send the name of the mirror server to the client after the first connection. If the client loses connection, it does not know if the principal has failed (it could have been destroyed by a natural disaster for example) so it will try to connect to the mirror to see if there has been a failover to the mirror. Since there was no server side failover in this case, you will get the connection failure logged on the mirror server. I recommend you monitor your network to see if there are intermittent problems causing this behavior.

Regards,

Matt Hollingsworth

Sr. Program Manager

SQL Server High Availability

|||At this point we can't find any immediate problems.

What information could help us to identify the reason causing the 'intermittent problems accessing the principal' ?

Are there logs I can consult ?

Greetings

Tom|||

I found an interesting link, which could be the reason for our problem.

But we are unaware that we disbled pooling :

http://groups-beta.google.com/group/microsoft.public.sqlserver.odbc/browse_thread/thread/9c79f6f4e8adce7b/f99b340d2fd76aef

Would this fix help even when pooling is enabled ?

Greetings,
Tom

|||Any solution for this with SP2 for 2005 ?

Cannot open database "xx" requested by the login. The login failed.

Hi,
we are running a webapplication, using IIS6, Windows 2003 64 bit in classic Asp.
In the asp pages we connect to our SQL server (SQL Server 2005 64bit,windows 2003 64 bit), mirrored on a third sql server (same software setup as the first sql server).

The mirroring is without witness.

This works perfectly but sometimes we get the following error :

Description: [Microsoft][SQL Native Client][SQL Server]Cannot open database

"OBJECTS" requested by the login. The login failed.

In the logs of sql, we see that the offending connection does not go the principal but to the mirror. Which would cause the problem of course..

The name of the database varies, and there is no consistent error. Most of the time there are no problems (95%), but sometimes we get these errors.

Connection from the asp to sql is done using ADO, using following driver in the connectionstring :

Driver="{SQL Native Client}"

Does anyone have an idea what could be the problem ?
We can of course increase timouts for the mirroring, but is this the solution ?

Greets
Tom

Looks like your application attempts to login using "OBJECTS" as the default database and the database does not exist. Is that database supposed to always exist or is it occasionally dropped and recreated? Your application should not attempt to connect to the database if it might not exist.

Thanks
Laurentiu

|||Hi Laurentiu,

the database always exists. So it must always be available for connection.
But for some reason SQL fails to see the database.

Also, it's not one and the same database that has this problems. We have more than 100 databases on the sql server, and the connection error popups randomly with other databases.

Greets
Tom|||

Can you check your server errorlog and post the errors that show up there? Also, does this happen during server startup by any chance? Is your database on a special volume, such that it would take longer to start up, for example, is it on an EFS volume?

Thanks
Laurentiu

|||Hi Laurentiu,

I'll check the correct SQL serverlogs when this error occurs.

The server is not starting up but running as normally. Remember, this is a production server.
No special volumes.

Additional information :

As told the connection is made in our ASP pages , using an ADO connectionstring.

Now it seems that the initial connection setup works :
e.g

set pCn = Server.CreateObject("ADODB.Connection")
pCn.connectionstring=lstr
pCn.Open

And the first executes always seem to work :
e.g.
pcn.Execute ("select * from thetable")

But in the same page, more executes are performed with the same connection (pC).
And after some executes, it fails with the above error.

Again, this does not happen always, and not with the same database !
And we are not starting up the server, or doing special tasks (aka backups,etc) which would add an extra load on the server.
The moments that this error occures are random, as are the databases with which the error occurs.

Greetings
Tom

|||

If you hit the error again, can you please provide the errorlog entries?

Thanks
Laurentiu

|||

Hi Laurentiu,

sorry for the delay in getting back to you.

There are no error entries in the primary sql server error logs
Only an error pops up in the secondary (mirror) server, stating the login failed.
And this of cours makes sense, as the connection does not go to the primary but to the secondary, which is acting as mirror. And therefore can not be accessed.

The question is : why does the connection sometimes jumps in stead from the primary server, to the mirror server ? Nowhere in my code I give a secondary server as reference.

The connection is made through ODBC in an ASP web application (IIS6) , simelar to :

Set oCn = Server.CreateObject("ADODB.Connection")
oCn.CommandTimeout = 180
oCn.Open lconstirng lconstring

where lconstring is a dsn param : e.g. "filedsn=c:\data\dsn\mastercon.dsn"
where the dsn file contains following info :

[ODBC]
DRIVER={SQL Native Client}
UID=myuserid
pwd=mypwd
Address=xxx.yyy.zzz.qqq,myport
Network=DBMSSOCN
DATABASE=MyDatabaseName
WSID=xxx.yyy.zzz.qqq
APP=Microsoft Open Database Connectivity
SERVER=xxx.yyy.zzz.qqq
Description=blabla


I tried the above without the DSN, so a dsnless connection string. Nothing changed.
I tried following drivers :{SQL Native Client} and SQLNCLI
Nothing changed

Any ideas ?

Greets
Tom|||

Hi Tom,

For these questions, I suggest trying the Database Mirroring forum or the SQL Server Data Access forum. These are the forums that address issues related to mirroring and server connections.

Thanks
Laurentiu

Cannot open database "xx" requested by the login. The login failed.

Hi,
we are running a webapplication, using IIS6, Windows 2003 64 bit in classic Asp.
In

the ASP pages we connect to our SQL server (SQL Server 2005

64bit,windows 2003 64 bit), mirrored on a third sql server (same

software /hardware setup as the first sql server).

The mirroring is without witness.

This works but sometimes we get the following ODBC error in our ASP application :

Description: [Microsoft][SQL Native Client][SQL Server]Cannot open database

"OBJECTS" requested by the login. The login failed.

No error can be seen in the principal SQL error logs.
But a failed authorization can be found on the mirror server..
And this of course this makes

sense, as the connection does not go to the primary but to the

secondary, which is acting as mirror. And therefore can not be accessed.

The question is : why

does the connection sometimes jumps in stead from the primary server,

to the mirror server ? Nowhere in the code I give a secondary server as

reference.

Most of

the time there are no problems (97%), but sometimes we get these errors.

The moments that this error occures are random, as are the databases with which the error occurs.

The connection is made through ODBC in an ASP web application (IIS6) , simelar to :

Set oCn = Server.CreateObject("ADODB.Connection")
oCn.CommandTimeout = 180
oCn.Open lconstring

where lconstring is a dsn param : e.g. "filedsn=c:\data\dsn\mastercon.dsn"
where the dsn file contains following info :

[ODBC]
DRIVER={SQL Native Client}
UID=myuserid
pwd=mypwd
Address=xxx.yyy.zzz.qqq,myport
Network=DBMSSOCN
DATABASE=MyDatabaseName
WSID=xxx.yyy.zzz.qqq
APP=Microsoft Open Database Connectivity
SERVER=xxx.yyy.zzz.qqq
Description=blabla


I tried the above without the DSN, so a dsnless connection string. Nothing changed.
I tried following drivers :{SQL Native Client} and SQLNCLI
Nothing changed


Does anyone have an idea what could be the problem ?
We can of course increase timouts for the mirroring, but is this the solution ?
Before we started using SQL 2005 and mirroring this problem did not occur.

Greets

Tom

This will occur if you client has intermittent problems accessing the principal. The mirroring principal will send the name of the mirror server to the client after the first connection. If the client loses connection, it does not know if the principal has failed (it could have been destroyed by a natural disaster for example) so it will try to connect to the mirror to see if there has been a failover to the mirror. Since there was no server side failover in this case, you will get the connection failure logged on the mirror server. I recommend you monitor your network to see if there are intermittent problems causing this behavior.

Regards,

Matt Hollingsworth

Sr. Program Manager

SQL Server High Availability

|||At this point we can't find any immediate problems.

What information could help us to identify the reason causing the 'intermittent problems accessing the principal' ?

Are there logs I can consult ?

Greetings

Tom|||

I found an interesting link, which could be the reason for our problem.

But we are unaware that we disbled pooling :

http://groups-beta.google.com/group/microsoft.public.sqlserver.odbc/browse_thread/thread/9c79f6f4e8adce7b/f99b340d2fd76aef

Would this fix help even when pooling is enabled ?

Greetings,
Tom

|||Any solution for this with SP2 for 2005 ?

Cannot obtain the schema rowset "DBSCHEMA_TABLES_INFO"

I see others having this problem when trying to run a query across a link from 2005 to a 2000 server. But we are already running SP4 on our 2000 server. What gives?

OLE DB provider "SQLNCLI" for linked server "s-1" returned message "Unspecified error".

OLE DB provider "SQLNCLI" for linked server "s-1" returned message "The stored procedure required to complete this operation could not be found on the server. Please contact your system administrator.".

Msg 7311, Level 16, State 2, Line 5

Cannot obtain the schema rowset "DBSCHEMA_TABLES_INFO" for OLE DB provider "SQLNCLI" for linked server "s-1". The provider supports the interface, but returns a failure code when it is used.

Is your server 64-bit? There was a discussion of that case http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=62887&SiteID=1|||64 bit. And I have tested the link against several sql server 2000 instances which report they are all SP4 buy yield the same error messages.

Cannot obtain the schema rowset "DBSCHEMA_TABLES_INFO"

I see others having this problem when trying to run a query across a link from 2005 to a 2000 server. But we are already running SP4 on our 2000 server. What gives?

OLE DB provider "SQLNCLI" for linked server "s-1" returned message "Unspecified error".

OLE DB provider "SQLNCLI" for linked server "s-1" returned message "The stored procedure required to complete this operation could not be found on the server. Please contact your system administrator.".

Msg 7311, Level 16, State 2, Line 5

Cannot obtain the schema rowset "DBSCHEMA_TABLES_INFO" for OLE DB provider "SQLNCLI" for linked server "s-1". The provider supports the interface, but returns a failure code when it is used.

Is your server 64-bit? There was a discussion of that case http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=62887&SiteID=1|||64 bit. And I have tested the link against several sql server 2000 instances which report they are all SP4 buy yield the same error messages.

Sunday, March 11, 2012

Cannot make server as Target server or link from Master Server

Sql Server 7 Standard Edition
My Server was renamed and the normal steps of reinstalling
and running sp_dropserver and sp_addserver were followed.
Everything seems to work fine but jobs from the master server.
I did defect the server as a target server since it appeared as offline
anyway.

On trying to re establish the status of the server as a target server

Failed to make "serverName" a target server
Enlist into Master Server "MasterServerName" Failed(Error 14262)

Your insight is appreciated
Vincento"Vincento Harris" <wumutek@.yahoo.com> wrote in message
news:2fa13ee7.0405100422.632f4324@.posting.google.c om...
> Sql Server 7 Standard Edition
> My Server was renamed and the normal steps of reinstalling
> and running sp_dropserver and sp_addserver were followed.
> Everything seems to work fine but jobs from the master server.
> I did defect the server as a target server since it appeared as offline
> anyway.
>
> On trying to re establish the status of the server as a target server
> Failed to make "serverName" a target server
> Enlist into Master Server "MasterServerName" Failed(Error 14262)
> Your insight is appreciated
> Vincento

Is @.@.SERVERNAME returning the correct (new) name? Error 14262 should be "The
specified %s ('%s') does not exist" - what is the full error message you
see? Are there any name resolution issues, ie. can both servers see each
other (ping.exe or NET VIEW) on the network?

Simon|||"Simon Hayes" <sql@.hayes.ch> wrote in message news:<409fc26e$1_1@.news.bluewin.ch>...
> "Vincento Harris" <wumutek@.yahoo.com> wrote in message
> news:2fa13ee7.0405100422.632f4324@.posting.google.c om...
> > Sql Server 7 Standard Edition
> > My Server was renamed and the normal steps of reinstalling
> > and running sp_dropserver and sp_addserver were followed.
> > Everything seems to work fine but jobs from the master server.
> > I did defect the server as a target server since it appeared as offline
> > anyway.
> > On trying to re establish the status of the server as a target server
> > Failed to make "serverName" a target server
> > Enlist into Master Server "MasterServerName" Failed(Error 14262)
> > Your insight is appreciated
> > Vincento
> Is @.@.SERVERNAME returning the correct (new) name? Error 14262 should be "The
> specified %s ('%s') does not exist" - what is the full error message you
> see? Are there any name resolution issues, ie. can both servers see each
> other (ping.exe or NET VIEW) on the network?
> Simon

Thanks for your response.
@.@.servername returns the right value.
I did forget to mention that the master server is sql server 2000 and
target server, sql server 7.
When the master server is pinged from the client it returns packets
with no error.

When originating_server is selected from sysjobs it returns 'local'

I did notice that the target server name has been added as an alias
when you open
the client network utilities.Not sure if that will make any difference

This is the exact error message

Failed to make "serverName" a target server
Enlist into Master Server "MasterServerName" Failed(Error 14262)

Vincento|||"Vincento Harris" <wumutek@.yahoo.com> wrote in message
news:2fa13ee7.0405110339.23cb3558@.posting.google.c om...
> "Simon Hayes" <sql@.hayes.ch> wrote in message
news:<409fc26e$1_1@.news.bluewin.ch>...
> > "Vincento Harris" <wumutek@.yahoo.com> wrote in message
> > news:2fa13ee7.0405100422.632f4324@.posting.google.c om...
> > > Sql Server 7 Standard Edition
> > > My Server was renamed and the normal steps of reinstalling
> > > and running sp_dropserver and sp_addserver were followed.
> > > Everything seems to work fine but jobs from the master server.
> > > I did defect the server as a target server since it appeared as
offline
> > > anyway.
> > > > > > On trying to re establish the status of the server as a target server
> > > > Failed to make "serverName" a target server
> > > Enlist into Master Server "MasterServerName" Failed(Error 14262)
> > > > Your insight is appreciated
> > > Vincento
> > Is @.@.SERVERNAME returning the correct (new) name? Error 14262 should be
"The
> > specified %s ('%s') does not exist" - what is the full error message you
> > see? Are there any name resolution issues, ie. can both servers see each
> > other (ping.exe or NET VIEW) on the network?
> > Simon
>
> Thanks for your response.
> @.@.servername returns the right value.
> I did forget to mention that the master server is sql server 2000 and
> target server, sql server 7.
> When the master server is pinged from the client it returns packets
> with no error.
> When originating_server is selected from sysjobs it returns 'local'
> I did notice that the target server name has been added as an alias
> when you open
> the client network utilities.Not sure if that will make any difference
> This is the exact error message
> Failed to make "serverName" a target server
> Enlist into Master Server "MasterServerName" Failed(Error 14262)
> Vincento

It sounds as if everything is OK - the only thing I can think of is that the
alias in the client network utilities might still have the old server name?
Also, can you create a working linked server from the SQL2000 server to the
SQL7 one? If not, then there is probably sort of name resolution issue. But
if you can, then I have no idea what the issue is - probably time to call
Microsoft.

Simon

Cannot make ODBC connection to SQL Express 05 Server from Win 2000 Server

I've got a web server running Windows 2000 Server that I need to make an
ODBC connection to a new SQL Express 2005 server running on Windows Server
2003. Using every logical combination I can think of I cannot make an ODBC
connection from this web server. I've tried this from another server on the
same subnet also running Windows Server 2003 and it connects fine. I can
even make an ODBC connection from my workstation located in a different
subnet. Just not the web server. I get the following error:
Connection failed:
SQLState: '01000'
SQL Server Error: 11004
[Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]ConnectionOpe
n
(gethostbyname()())
Connection failed:
SQLState: '08001'
SQL Server Error: 11
[Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]General netwo
rk error.
Check your network documentation.
I'm specifying the correct port and as far as the network I can connect from
either server to either server via My Network Places so I know the
IP/Subnet/gateway is correct. What's wrong here? Can anyone please provide
some insight on where to look for a solution?
Thanks!"Hiltie" <hiltie@.newasgroups.nospam> wrote in message
news:e1lV8pspGHA.4268@.TK2MSFTNGP04.phx.gbl...
> I've got a web server running Windows 2000 Server that I need to make an
> ODBC connection to a new SQL Express 2005 server running on Windows Server
> 2003. Using every logical combination I can think of I cannot make an ODBC
> connection from this web server. I've tried this from another server on
> the same subnet also running Windows Server 2003 and it connects fine. I
> can even make an ODBC connection from my workstation located in a
> different subnet. Just not the web server. I get the following error:
> Connection failed:
> SQLState: '01000'
> SQL Server Error: 11004
> [Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]ConnectionO
pen
> (gethostbyname()())
> Connection failed:
> SQLState: '08001'
> SQL Server Error: 11
> [Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]General net
work error.
> Check your network documentation.
> I'm specifying the correct port and as far as the network I can connect
> from either server to either server via My Network Places so I know the
> IP/Subnet/gateway is correct. What's wrong here? Can anyone please provide
> some insight on where to look for a solution?
BTW, I am able to make a successful telnet connection from the web server to
the SQL Express server, but I cannot make a successful ODBC connection using
the correct port.
Help!|||UPDATE:
I was able to resolve the problem. Thanks anyway.
"Hiltie" <hiltie@.newasgroups.nospam> wrote in message
news:eOW3MV0pGHA.4932@.TK2MSFTNGP05.phx.gbl...
> "Hiltie" <hiltie@.newasgroups.nospam> wrote in message
> news:e1lV8pspGHA.4268@.TK2MSFTNGP04.phx.gbl...
> BTW, I am able to make a successful telnet connection from the web server
> to the SQL Express server, but I cannot make a successful ODBC connection
> using the correct port.
> Help!
>