Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Beginning Dreamweaver MX/MX 2004 MX ISBN: 978-0-7645-4404-0; MX 2004 ISBN: 978-0-7645-5524-4
This is the forum to discuss the Wrox book Beginning Dreamweaver MX by Charles E. Brown, Imar Spaanjaars, Todd Marks; ISBN: 9780764544040
Please indicate which version of the book you are using when posting questions.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning Dreamweaver MX/MX 2004 MX ISBN: 978-0-7645-4404-0; MX 2004 ISBN: 978-0-7645-5524-4 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old April 13th, 2005, 04:35 PM
Authorized User
 
Join Date: Mar 2005
Location: , , .
Posts: 35
Thanks: 0
Thanked 0 Times in 0 Posts
Default MX2004 webpage using opened database

When I try to open the webpage while the database is open, this error message shows up:

Technical Information (for support personnel)

Error Type:
Microsoft JET Database Engine (0x80004005)
The Microsoft Jet database engine cannot open the file 'X:\FilePath\File.mdb'. It is already opened exclusively by another user, or you need permission to view its data.
/website/home.asp, line 15


This doesn't make sense to me because the whole point of having webpage access to a database is so that multiple users can update and access the data, right?

If anyone can help, please reply. Thanks.

d.t.
  #2 (permalink)  
Old April 14th, 2005, 01:48 AM
Imar's Avatar
Wrox Author
Points: 72,055, Level: 100
Points: 72,055, Level: 100 Points: 72,055, Level: 100 Points: 72,055, Level: 100
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,086
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Hi there,

Check out the following FAQs:

http://imar.spaanjaars.com/QuickDocId.aspx?QUICKDOC=263
http://imar.spaanjaars.com/QuickDocId.aspx?QUICKDOC=290

As for your second question; I am not sure what you're asking. If there is no point, then don't put the pages online. But I think that's not what you're asking.... Or does this have to do with the error message of "already opened exclusively by another user"?

If that's the case, then there's no need to worry. You'll get that error when someone has opened the database and is, say, adding or changing a table. In normal operations, multiple users can access the database without this error...

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
  #3 (permalink)  
Old April 14th, 2005, 12:24 PM
Authorized User
 
Join Date: Mar 2005
Location: , , .
Posts: 35
Thanks: 0
Thanked 0 Times in 0 Posts
Default

The computer parent computer name has been added to the Database Properties Security permission. Interestingly, the "IUSR_" for the computer is not included, nor can it be added. However, the computer name itself is and has been added.

There is still the same error, however, of not having permissions or that the database is opened exclusively by another user.

My previous comment ("2nd question") had to do with this exclusivity access. I probably misunderstood that a website cannot simultaneously allow multiple users to edit data in a database, reading what the error message is saying. I'm glad to hear otherwise.

But alas, I'm still stuck, after having added the permission setting. Any assistance would be appreciated. Thanks.

d.t.
  #4 (permalink)  
Old April 14th, 2005, 01:20 PM
Imar's Avatar
Wrox Author
Points: 72,055, Level: 100
Points: 72,055, Level: 100 Points: 72,055, Level: 100 Points: 72,055, Level: 100
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,086
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

From your description, it seems your computer is on a domain. By default, IIS runs under a local account called IUSR_MachineName which is not available on the domain.

To add a local account, click the Add button on the Security tab and then on the Select Users and Groups dialog click the Locations button. That allows you to switch from the domain to your local machine. Once you switched, you should be able to add IUSR_MachineName....

HtH,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
  #5 (permalink)  
Old April 14th, 2005, 01:33 PM
Authorized User
 
Join Date: Mar 2005
Location: , , .
Posts: 35
Thanks: 0
Thanked 0 Times in 0 Posts
Default

If the database file, accessed by multiple users is not on my local machine but on the server, as part of a Network, are you saying that I must run the website from the server itself? Is there any way otherwise? Meanwhile, I will have to look into setting up the local/remote/test servers on the network server itself from DW. If you think there are alternatives, please do assist. Thanks.

d.t.
  #6 (permalink)  
Old April 14th, 2005, 02:06 PM
Authorized User
 
Join Date: Mar 2005
Location: , , .
Posts: 35
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Quote:
quote:Originally posted by DellTah
 Meanwhile, I will have to look into setting up the local/remote/test servers on the network server itself from DW.


I don't think setting up the local/remote/test server differently will affect access into the database files. The problem seems to be coming from the database security settings itself.

  #7 (permalink)  
Old April 14th, 2005, 03:33 PM
Imar's Avatar
Wrox Author
Points: 72,055, Level: 100
Points: 72,055, Level: 100 Points: 72,055, Level: 100 Points: 72,055, Level: 100
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,086
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Yeah, the Dreamweaver settings have nothing to do with this.

What happens is this:

1. You request a page on your web server. Let's call this machine WebServer (at this point, it doesn't really matter whether that's a remote host or your local development machine; it's the webserver serving web pages). It also doesn't really matter if you access pages on this machine directly (e.g. http://localhost) or remotely (e.g. http://Webserver)

2. The request is handled by IIS under a specific user account. By default, this is a local machine account, thus IUSR_WebServer in this example.
If both the database and IIS reside on the same machine (which is probably the easiest and fastest and safest and smartest thing to do anyway), it's this IUSR_WebServer account that needs permissions to the *local* folder with the database on the Webserver's hard disk.

So, a webserver with a local database is easy to set up; just grant the IUSR_Webserver account modify permissions on the Database folder.

If you're trying to access a database on a different machine (that is, the website at WebServer is trying to access an .mdb on another machine called FileServer) you'll have a bit of problem.

By default, the FileServer machine doesn't recognize the IUSR_WebServer account, as that account is local to the WebServer machine (still with me??). There are a few ways around this problem.

My FAQ How Do I Setup IIS to Allow it to Use Network Resources? describes your options in more detail.

HtH,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
While typing this post, I was listening to: Spitfire by The Prodigy (Track 1 from the album: Always Outnumbered Never Outgunned) What's This?
  #8 (permalink)  
Old April 14th, 2005, 05:31 PM
Authorized User
 
Join Date: Mar 2005
Location: , , .
Posts: 35
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I've tried the first option, but was unsuccessful:
Using the Integrated Security option, I'm prompted to enter a password, but the database file is still not accessible.

However, if I try to directly open the database file (even with the *.ldb while it's open), I AM able to open it. The webpage, however, cannot.

I'm curious, if the file is openable by myself would it not also be by the webpage (using the same authentication protocol).

As for the 2nd option, I'm out of luck either because my team firmly holds that it's not a good idea (sensitive data).

I'll try the third. If in the meanwhile you have insights, please help.

d..t

  #9 (permalink)  
Old April 14th, 2005, 05:45 PM
Imar's Avatar
Wrox Author
Points: 72,055, Level: 100
Points: 72,055, Level: 100 Points: 72,055, Level: 100 Points: 72,055, Level: 100
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,086
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

I think you'll need to provide more information about your setup. What machines are involved? How do they interact? What OSs are they running? What machine calls what on the other? Where is the database stored and how do you try to access it? Are you running Active Directory? If so, are all machines part of the same domain? Etc etc etc

Option 2 is not as insecure as it sounds; no password is passed around; only a hashed credential will be passed. However, it can be troublesome to set up or maintain.


Cheers,

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
While typing this post, I was listening to: .Xerox and Freeman by Eternal March What's This?
  #10 (permalink)  
Old April 14th, 2005, 06:15 PM
Authorized User
 
Join Date: Mar 2005
Location: , , .
Posts: 35
Thanks: 0
Thanked 0 Times in 0 Posts
Default

What machines are involved? various (PCs)
How do they interact? within Network Server
What OSs are they running? Windows 2000
What machine calls what on the other? Web_Server (computer name) calls on Domain Controllers
Where is the database stored and how do you try to access it?
Database is stored in one of the Domain Controllers
Are you running Active Directory? If so, are all machines part of the same domain? Yes, Active Directory, with multiple domain controllers

The issue is sensitvity of the data itself; making it available and vulnerable. I do understand where they're coming from even if extremely (and prohibitively) cautious. Don't know if the above helps, but that's as detailed as probably they're comfortable with anyways...

 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Quick Webpage access with large data in database madhusrp ASP.NET 1.0 and 1.1 Professional 2 March 14th, 2006 04:11 AM
Default settings MX2004 ouzodave Dreamweaver (all versions) 2 April 13th, 2005 02:33 PM
MX2004 Stored Procedure Problem Kframbro Dreamweaver (all versions) 1 March 1st, 2005 07:43 PM
How to close database opened by adodc aa_azadeh Pro VB Databases 1 September 28th, 2004 08:04 AM
CSS MX2004 firestorm77 Dreamweaver (all versions) 2 December 21st, 2003 09:54 PM



All times are GMT -4. The time now is 03:37 AM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.