Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I'm working on a system that needs to manage databases for 1000 users (at maximum). I used Apache server, and MySQL for this task.

Since I'm new to the whole thing my question is:

  1. Is it possible to configure Apache server so it locks writing on a record whenever a user is updating that record?
  2. Is it the right choice? I mean is it better for me to implement my own server or just use Apache?

I'm using python 2.6 and Windows x64, pyqt4 for the interface.

I would really appreciate it if you guys could give me any advise related to this (like: Don't use python, use C++).

share|improve this question
    
and by the way , this system will be to handle all the tasks progress inside the company , manage assets and file versions , and organize work overall . –  Moayyad yaghi Sep 25 '10 at 19:21

3 Answers 3

up vote 3 down vote accepted

httpd doesn't handle the database itself. You need to ask these questions of the language/framework you will be using, rather than the web server.

share|improve this answer
    
can you please explain more ,( sooo sorry for my noobie question ) iv'e been programming GPUs and writing AI for games only . that's all my back ground :( ) –  Moayyad yaghi Sep 25 '10 at 19:29
    
The web server only handles the HTTP connection part. If you want to run an actual program then it needs to hand off control to the program itself, which can be written in pretty much any language. Most languages have web frameworks that are used in order to handle common operations more easily. wiki.python.org/moin/WebFrameworks –  Ignacio Vazquez-Abrams Sep 25 '10 at 19:34
    
@lgnacio , thank you very much , i think i'll start learning django now :) .sorry cant give +1 because of my reputation on this site ^^. –  Moayyad yaghi Sep 25 '10 at 19:49

i'm working on a system that needs to manage the data bases of 1000 user...

1000 total 'users/week' or 1000 online at a single time?

1- Already answered: Apache doesn't lock database tables, MySQL can handle that part.

2- Is Apache the right choice?

IMO, you can have 3+ years of experience and still debate the answer.

  • Apache is easy to learn the basics, but generally uses a lot of resources.

  • The right choice is to use something lightweight upfront (i.e. lighttpd or nginx / google 'caching server' or 'reverse proxy server'.) with Apache handling the rest (as little as possible)

share|improve this answer

It's hard to answer such a confused question but here are some key points:

Apache doesn't deal with the database at any level. Thats handed by the web application and the locking is handled by MySQL itself.

Questions regarding the choice of programming language are out of place here, as that has nothing to do with system administration. Further, it has no direct bearing on the issue of a web server and database server.

If you feel confident that you can write your own web server and thereby eliminate Apache that's entirely up to you. Knowing nothing at all about your level of competency as a programmer we cannot say whether that's a good or bad decision, although being aware of the time and effort it has taken to bring any web server to a production ready state does give us some clues as to the likely outcome of writing your own.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.