Showing posts with label app. Show all posts
Showing posts with label app. Show all posts

Tuesday, March 20, 2012

Cannot Open default Database. Login Failed. Problem

I have created an app which use sqlserver exrpress and works fine. I have now craeted a authentication page login.aspx.

I have added users successfully to the asp.net configuartion via the web site admin tool.

When I go to login using my page I get the Cannot open default database.Login failed. Login failed for user servet\aspnet.

I have looked at the asonetdb in sql server management studio and the server\asp net is set up on the database.

Can anyone suggeste what I ma doing wrong or where I might see a work through of the problem.

Thanks

Frank

Please check the properties of 'server\asp net' login in SQL Server Management Studio again:

1. Find its default database in the General panel

2. In the User Mapping panel, make sure its default database has been selected and mapped to a valid user.

|||

The login seems to worjk fine when I run the app using visual web developer - when I try and logn after accessing the system conventially via a web page it doesn't let me login.

Any suggestions.

Frank

|||How do you infer the login works fine? Can you connect to the SQL Server with the login? Or you checked it in SQL logins?

Monday, March 19, 2012

Cannot open connection to Access Database.

I am very new to VB.Net but my goal is to build a web app that ineracts with an Access database. This is a very small scale app so I am not interested in using SQL server. I created my Access database and the udl file for connection information.

I created a class that opens a connection to the database when the webpage loads.

I get the following error though,

System.Data.OleDb.OleDbException was unhandled by user code
ErrorCode=-2147467259
Message="The Microsoft Jet database engine cannot open the file 'C:\Inetpub\wwwroot\Test1\RaceData.mdb'. It is already opened exclusively by another user, or you need permission to view its data."
Source="Microsoft JET Database Engine"
StackTrace:
at System.Data.OleDb.OleDbConnectionInternal..ctor(OleDbConnectionString constr, OleDbConnection connection)
at System.Data.OleDb.OleDbConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningObject)
at System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup)
at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection)
at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)
at System.Data.OleDb.OleDbConnection.Open()
at clsDBConn.Open_Connection() in c:\inetpub\wwwroot\Test1\App_Code\clsDBConn.vb:line 12
at Default2.Page_Load(Object sender, EventArgs e) in c:\inetpub\wwwroot\Test1\Default2.aspx.vb:line 8
at System.Web.UI.Control.OnLoad(EventArgs e)
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

The database is not open so I know it is a matter of security. I have configured IIS to use an admin account and the Access db does not have security turned on. In the UDL file I have selected read/write access and the test connection works.

Can anyone help me narrow down the root of this error,

Thanx in advance,

Chris

Topfuel5

Hi,

The Error is self descriptive that means either you don't have proper privilege or the file is either opened in Edit Mode refer below links for work around

http://support.microsoft.com/kb/174943 & http://www.xlinesoft.com/asprunner/docs/error_the_microsoft_jet_database_engine_cannot%20open%20the%20file%20(unknown).htm

Hemantgiri S. Goswami

Sunday, March 11, 2012

Cannot login to web app from local machine but can over RDP

See above. At first I thought it was a problem with SQL server, since I have just installed a new certificate. Now I am not so sure. Any suggestions??

Thanks,

kreid

When you say log in to web app do you mean a sql server database? First I would make sure remote connections to sql are enabledhttp://support.microsoft.com/kb/914277. Next, Is possible that port 1433 (default sql port) is blocked somewhere between your machine and the server? I would run a port scanner from your local machine and see if it is listening

|||

Hi,

Thanks for your reply.

Yes, I am using the default ASPNETDB membership/authentication database on SQL 2005 Workgroup edn. Here's some further info that I just discovered:

I can log into the web app fine from home, but not from the local domain. I suspected domains had something to do with it. We just got a new server with SBS 2003 (for reasons of economy). However, SBS assigned the server to be the domain controller of the domain: "MyCompanyName.local".

The old web server was not part of a domain. I don't really want to remove the server from the "local" domain, since the server uses this (I think!) for Exchange and Active Directory. I wouldn't even know how to do this in any case.

Anyway, back to your post:

It is very unlikely that the sql port is blocked, since SQL Server is on the same machine as the web app. This was also working fine on the old server, which was running 2003 Ent. Edn. It seems that the only difference between the two servers is the domain. Oh, there is also no error showing up in the web app - the password box just goes blank when I hit return.

End of rant, thanks in advance for any help!

|||

Hi,

Solved the problem, was due to my incorrect keyboard mapping - d'oh!

cannot locally telnet to 1433 but Mgt Studio ok ?

Hi,
I have a hosted server running win2003, sql express and an app I need to
connect to 1433.
In a cmd prompt I enter "telnet 99.99.99.99 1433" and I cannot connect.
(this works on every other server I have tested).
I CAN open sql mgt studio an connect ok (again on 1433 I guess by default)
and connect to the correct DB using the user my app uses.
My app throws an error as it cannot connect, I think I need to get this
telnet test working before my app will work. (app passes user + pass + IP +
DB).
What would block telnet on 1433 but still allow SQL Mgt Studio to connect on
1433 ?
My server IP is public, and telnet test uses public IP. Is it possible
telnet test is not routed locally and the Mgt Studio connection is routed
locally ?
I tried telnet on ip loop back but that did not work i.e "telnet 127.0.0.1
1433"
Thanks for any advice.
Scottsorry failed to mention Mgt Studio uses netbios name ... when i enter IP i
does not work ... so i guess its the way traffic is routed. must be a
filtered somewhere in security policy or routers. both win + sql
authenrtication work using netbios name but neither with ip.
can someone confirm how traffic in these situations is routed ?|||"Scott" <scott@.> wrote in message
news:eiCIekDIHHA.4688@.TK2MSFTNGP04.phx.gbl...
> sorry failed to mention Mgt Studio uses netbios name ... when i enter IP i
> does not work ... so i guess its the way traffic is routed. must be a
> filtered somewhere in security policy or routers. both win + sql
> authenrtication work using netbios name but neither with ip.
> can someone confirm how traffic in these situations is routed ?
>
SQL Server supports multiple network libraries, TCP/IP is one, but Named
Pipes and Shared Memory are two others. Locally on the box you will often
be using the Shared Memory library.
It sounds like TCP/IP is just not enabled. Check the SQL SErver log to be
sure. IT will tell you on startup all the listener endpoints it starts.
Here's my log
12/15/2006 08:44:40,Server,Unknown,SQL Server is now ready for client
connections. This is an . ..
12/15/2006 08:44:40,Server,Unknown,Server is listening on [ 127.0.0.1 <ipv4>
1434].
12/15/2006 08:44:40,Server,Unknown,Server is listening on [ ::1 <ipv6>
1434].
12/15/2006 08:44:40,Server,Unknown,Server local connection provider is ready
to accept connection on [ \\.\pipe\sql\query ].
12/15/2006 08:44:40,Server,Unknown,Server local connection provider is ready
to accept connection on [ \\.\pipe\SQLLocal\MSSQLSERVER ].
12/15/2006 08:44:40,Server,Unknown,Server is listening on [ 'any' <ipv4>
1433].
12/15/2006 08:44:40,Server,Unknown,Server is listening on [ 'any' <ipv6>
1433].
You can change the protocols used by your server using the SQL Server
Configuration Manager.
David|||many thanks for reply.
i think you are right about this.
Cheers
Scott

cannot locally telnet to 1433 but Mgt Studio ok ?

Hi,
I have a hosted server running win2003, sql express and an app I need to
connect to 1433.
In a cmd prompt I enter "telnet 99.99.99.99 1433" and I cannot connect.
(this works on every other server I have tested).
I CAN open sql mgt studio an connect ok (again on 1433 I guess by default)
and connect to the correct DB using the user my app uses.
My app throws an error as it cannot connect, I think I need to get this
telnet test working before my app will work. (app passes user + pass + IP +
DB).
What would block telnet on 1433 but still allow SQL Mgt Studio to connect on
1433 ?
My server IP is public, and telnet test uses public IP. Is it possible
telnet test is not routed locally and the Mgt Studio connection is routed
locally ?
I tried telnet on ip loop back but that did not work i.e "telnet 127.0.0.1
1433"
Thanks for any advice.
Scott
sorry failed to mention Mgt Studio uses netbios name ... when i enter IP i
does not work ... so i guess its the way traffic is routed. must be a
filtered somewhere in security policy or routers. both win + sql
authenrtication work using netbios name but neither with ip.
can someone confirm how traffic in these situations is routed ?
|||"Scott" <scott@.> wrote in message
news:eiCIekDIHHA.4688@.TK2MSFTNGP04.phx.gbl...
> sorry failed to mention Mgt Studio uses netbios name ... when i enter IP i
> does not work ... so i guess its the way traffic is routed. must be a
> filtered somewhere in security policy or routers. both win + sql
> authenrtication work using netbios name but neither with ip.
> can someone confirm how traffic in these situations is routed ?
>
SQL Server supports multiple network libraries, TCP/IP is one, but Named
Pipes and Shared Memory are two others. Locally on the box you will often
be using the Shared Memory library.
It sounds like TCP/IP is just not enabled. Check the SQL SErver log to be
sure. IT will tell you on startup all the listener endpoints it starts.
Here's my log
12/15/2006 08:44:40,Server,Unknown,SQL Server is now ready for client
connections. This is an . ..
12/15/2006 08:44:40,Server,Unknown,Server is listening on [ 127.0.0.1 <ipv4>
1434].
12/15/2006 08:44:40,Server,Unknown,Server is listening on [ ::1 <ipv6>
1434].
12/15/2006 08:44:40,Server,Unknown,Server local connection provider is ready
to accept connection on [ \\.\pipe\sql\query ].
12/15/2006 08:44:40,Server,Unknown,Server local connection provider is ready
to accept connection on [ \\.\pipe\SQLLocal\MSSQLSERVER ].
12/15/2006 08:44:40,Server,Unknown,Server is listening on [ 'any' <ipv4>
1433].
12/15/2006 08:44:40,Server,Unknown,Server is listening on [ 'any' <ipv6>
1433].
You can change the protocols used by your server using the SQL Server
Configuration Manager.
David
|||many thanks for reply.
i think you are right about this.
Cheers
Scott

cannot locally telnet to 1433 but Mgt Studio ok ?

Hi,
I have a hosted server running win2003, sql express and an app I need to
connect to 1433.
In a cmd prompt I enter "telnet 99.99.99.99 1433" and I cannot connect.
(this works on every other server I have tested).
I CAN open sql mgt studio an connect ok (again on 1433 I guess by default)
and connect to the correct DB using the user my app uses.
My app throws an error as it cannot connect, I think I need to get this
telnet test working before my app will work. (app passes user + pass + IP +
DB).
What would block telnet on 1433 but still allow SQL Mgt Studio to connect on
1433 ?
My server IP is public, and telnet test uses public IP. Is it possible
telnet test is not routed locally and the Mgt Studio connection is routed
locally ?
I tried telnet on ip loop back but that did not work i.e "telnet 127.0.0.1
1433"
Thanks for any advice.
Scottsorry failed to mention Mgt Studio uses netbios name ... when i enter IP i
does not work ... so i guess its the way traffic is routed. must be a
filtered somewhere in security policy or routers. both win + sql
authenrtication work using netbios name but neither with ip.
can someone confirm how traffic in these situations is routed ?|||"Scott" <scott@.> wrote in message
news:eiCIekDIHHA.4688@.TK2MSFTNGP04.phx.gbl...
> sorry failed to mention Mgt Studio uses netbios name ... when i enter IP i
> does not work ... so i guess its the way traffic is routed. must be a
> filtered somewhere in security policy or routers. both win + sql
> authenrtication work using netbios name but neither with ip.
> can someone confirm how traffic in these situations is routed ?
>
SQL Server supports multiple network libraries, TCP/IP is one, but Named
Pipes and Shared Memory are two others. Locally on the box you will often
be using the Shared Memory library.
It sounds like TCP/IP is just not enabled. Check the SQL SErver log to be
sure. IT will tell you on startup all the listener endpoints it starts.
Here's my log
12/15/2006 08:44:40,Server,Unknown,SQL Server is now ready for client
connections. This is an . ..
12/15/2006 08:44:40,Server,Unknown,Server is listening on [ 127.0.0.1 <i
pv4>
1434].
12/15/2006 08:44:40,Server,Unknown,Server is listening on [ ::1 <ipv6>
1434].
12/15/2006 08:44:40,Server,Unknown,Server local connection provider is ready
to accept connection on [ \\.\pipe\sql\query ].
12/15/2006 08:44:40,Server,Unknown,Server local connection provider is ready
to accept connection on [ \\.\pipe\SQLLocal\MSSQLSERVER ].
12/15/2006 08:44:40,Server,Unknown,Server is listening on [ 'any' <ipv4>
1433].
12/15/2006 08:44:40,Server,Unknown,Server is listening on [ 'any' <ipv6>
1433].
You can change the protocols used by your server using the SQL Server
Configuration Manager.
David|||many thanks for reply.
i think you are right about this.
Cheers
Scott

Sunday, February 12, 2012

Cannot generate SSPI context

I'm getting this error from my SQL client. I'm developing a web app that
connects to a SQL Server, but after some time I get that error. I have to
restart and it works again. It only happens in my laptop. Other computers
from the intranet are working normally. I use windows authentication -I'm in
a windows 2003 domain-
Regards,
Diego F.This happens when your machinr can't access the DC to obtain an SSPI context
= Trusted Connection = Validated Logon.
Trying pinging the DC's when this happens - I think you will find a network
failure.
"Diego F." <diegofrNO@.terra.es> wrote in message
news:O2GnrF0aFHA.2968@.TK2MSFTNGP10.phx.gbl...
> I'm getting this error from my SQL client. I'm developing a web app that
> connects to a SQL Server, but after some time I get that error. I have to
> restart and it works again. It only happens in my laptop. Other computers
> from the intranet are working normally. I use windows authentication -I'm
> in a windows 2003 domain-
> --
> Regards,
> Diego F.
>
>|||Sorry for that, but what do you mean y DC?
Regards,
Diego F.
"Mercury" <me@.spam.com> escribi en el mensaje
news:d8432l$4ac$1@.lust.ihug.co.nz...
> This happens when your machinr can't access the DC to obtain an SSPI
> context = Trusted Connection = Validated Logon.
> Trying pinging the DC's when this happens - I think you will find a
> network failure.
>
>
> "Diego F." <diegofrNO@.terra.es> wrote in message
> news:O2GnrF0aFHA.2968@.TK2MSFTNGP10.phx.gbl...
>|||BTW, if you mean domain controler, I can access the server normally. I must
say that from once to once I lose the connection with the network, but not
so often as the SQL error.
Regards,
Diego F.
"Mercury" <me@.spam.com> escribi en el mensaje
news:d8432l$4ac$1@.lust.ihug.co.nz...
> This happens when your machinr can't access the DC to obtain an SSPI
> context = Trusted Connection = Validated Logon.
> Trying pinging the DC's when this happens - I think you will find a
> network failure.
>
>
> "Diego F." <diegofrNO@.terra.es> wrote in message
> news:O2GnrF0aFHA.2968@.TK2MSFTNGP10.phx.gbl...
>|||DC = domain controller here.
Depending on how the program is written, it could be connecting to the DC
much more often than it should. If your network connection really is flakey
then that would explain it.
To test this out, try and recreate the problem with a ping -t
dc-machine-ip-address running in the background. The -t switch means 'run
continously'.
- Tim
"Diego F." <diegofrNO@.terra.es> wrote in message
news:eKVkWK3aFHA.2664@.TK2MSFTNGP15.phx.gbl...
> BTW, if you mean domain controler, I can access the server normally. I
> must say that from once to once I lose the connection with the network,
> but not so often as the SQL error.
> --
> Regards,
> Diego F.
>
> "Mercury" <me@.spam.com> escribi en el mensaje
> news:d8432l$4ac$1@.lust.ihug.co.nz...
>

Friday, February 10, 2012

Cannot find PInvoke DLL SqlCeMe30.dll

I create a smll app that should created a database in the hand held, it compiles without problem but when I debugg it

I ge the error message: Cannot find PInvoke DLL SqlCeMe30.dll

I found such dll to be located in:C:\Program Files\Microsoft SQL Server 2005 Mobile Edition\Device\Mobile\v3.0\wce500\x86 among other folders.

Why then is "not found"?

Soft reset your device, reinstall the SQL Mobile CAB(s) and try again. I have seen issues on WM5 devices where it appears that SQL Mobile cannot find DLLs that are actually there. I've seen it under low memory situations on the device and immediately following errors during replication or RDA.

Darren

|||

hi, i have found this issue very frequencly happened on the WM5 devices.

I believe softreset and reinstall is a better way but it is cause by the programming behaviour which is not apply logically. For example create a lot of object and did not dispose properly. Is there anyother way to avoid the low memory occur by clear off the prvious undispose object or thread that are still runnning in the background?

Please advise.

Thanks

|||

Maybe this will be helpful: (LoadLibrary) - http://forums.microsoft.com/msdn/showpost.aspx?postid=1349826&siteid=1&sb=0&d=1&at=7&ft=11&tf=0&pageid=1

Cannot find PInvoke DLL SqlCeMe30.dll

I create a smll app that should created a database in the hand held, it compiles without problem but when I debugg it

I ge the error message: Cannot find PInvoke DLL SqlCeMe30.dll

I found such dll to be located in:C:\Program Files\Microsoft SQL Server 2005 Mobile Edition\Device\Mobile\v3.0\wce500\x86 among other folders.

Why then is "not found"?

Soft reset your device, reinstall the SQL Mobile CAB(s) and try again. I have seen issues on WM5 devices where it appears that SQL Mobile cannot find DLLs that are actually there. I've seen it under low memory situations on the device and immediately following errors during replication or RDA.

Darren

|||

hi, i have found this issue very frequencly happened on the WM5 devices.

I believe softreset and reinstall is a better way but it is cause by the programming behaviour which is not apply logically. For example create a lot of object and did not dispose properly. Is there anyother way to avoid the low memory occur by clear off the prvious undispose object or thread that are still runnning in the background?

Please advise.

Thanks

|||

Maybe this will be helpful: (LoadLibrary) - http://forums.microsoft.com/msdn/showpost.aspx?postid=1349826&siteid=1&sb=0&d=1&at=7&ft=11&tf=0&pageid=1

cannot find info on 'event id 17052' in Microsoft Knowledge base

I have a repeatitive error of event id 17052 in my App log. It fills up the
log in about 4 hours. The description is error 99001, severity 10, state 1.
Can someone help me with this. I can't find anything in the Knowledge Base
or anywhere else. Thank you.
Event ID 17052 is a generic event recorded for various
issues. Error numbers over 50000 are user defined messages.
On the server where you are seeing this, you can create the
same entry in the app log yourself by executing the
following in Query analyzer:
raiserror(99001, 10, 1)
So you probably have a stored procedure or an application
raising this error.
-Sue
On Fri, 11 Mar 2005 16:11:03 -0800, Jeff Delk <Jeff
Delk@.discussions.microsoft.com> wrote:

>I have a repeatitive error of event id 17052 in my App log. It fills up the
>log in about 4 hours. The description is error 99001, severity 10, state 1.
>Can someone help me with this. I can't find anything in the Knowledge Base
>or anywhere else. Thank you.

cannot find info on 'event id 17052' in Microsoft Knowledge base

I have a repeatitive error of event id 17052 in my App log. It fills up the
log in about 4 hours. The description is error 99001, severity 10, state 1.
Can someone help me with this. I can't find anything in the Knowledge Base
or anywhere else. Thank you.Event ID 17052 is a generic event recorded for various
issues. Error numbers over 50000 are user defined messages.
On the server where you are seeing this, you can create the
same entry in the app log yourself by executing the
following in Query analyzer:
raiserror(99001, 10, 1)
So you probably have a stored procedure or an application
raising this error.
-Sue
On Fri, 11 Mar 2005 16:11:03 -0800, Jeff Delk <Jeff
Delk@.discussions.microsoft.com> wrote:

>I have a repeatitive error of event id 17052 in my App log. It fills up th
e
>log in about 4 hours. The description is error 99001, severity 10, state 1
.
>Can someone help me with this. I can't find anything in the Knowledge Base
>or anywhere else. Thank you.

cannot find info on 'event id 17052' in Microsoft Knowledge base

I have a repeatitive error of event id 17052 in my App log. It fills up the
log in about 4 hours. The description is error 99001, severity 10, state 1.
Can someone help me with this. I can't find anything in the Knowledge Base
or anywhere else. Thank you.Event ID 17052 is a generic event recorded for various
issues. Error numbers over 50000 are user defined messages.
On the server where you are seeing this, you can create the
same entry in the app log yourself by executing the
following in Query analyzer:
raiserror(99001, 10, 1)
So you probably have a stored procedure or an application
raising this error.
-Sue
On Fri, 11 Mar 2005 16:11:03 -0800, Jeff Delk <Jeff
Delk@.discussions.microsoft.com> wrote:
>I have a repeatitive error of event id 17052 in my App log. It fills up the
>log in about 4 hours. The description is error 99001, severity 10, state 1.
>Can someone help me with this. I can't find anything in the Knowledge Base
>or anywhere else. Thank you.