TOW (Trac On Windows) Blog

January 7, 2008

How to fix “Cannot load … mod_python.so into server:” in startup?

Filed under: Trouble Shooting — Tags: , , , — yeoupooh @ 4:49 am

If you have a problem like below in starting TOW, there isn’t a msvcr71.dll file at C:\Windows\System32.


[TOW] TOW Launched.
[TOW] Now, you can test Trac in http://localhost:8080/projects/HelloTOW
[TOW] And you can test Subversion in http://localhost:8080/svn/HelloTOW
httpd: Syntax error on line 493 of C:/TOW/Apache/conf/httpd.conf: Cannot load C:/TOW/Apache/modules/mod_python.so into server: blah blah.

You can find that file from web searching or another PCs.

Thanks for reporting Park YoungSeob.

7 Comments »

  1. 8080포트를 80으로 변경 가능한지요?

    Comment by 일초리 — January 16, 2008 @ 8:42 am

  2. C:\TOW\Apache\conf\httpd.conf 파일을 고치시면 가능할거 같습니다. 자세한 내용은 http://httpd.apache.org/http://www.apache.or.kr/ 를 참고하세요.

    Comment by yeoupooh — January 17, 2008 @ 9:00 am

  3. 이것 msvcr71.dll system32에 카피해 넣어도 마찬가지입니다.
    오히려 아래… mod의 버전문제인듯합니다만 ?
    Hi..

    I just can repeat something I wrote some days ago…

    The Windows binaries I d/l from sourceforge had a link to python 2.2 even when they are announced for python 2.3 (only).
    So it was using my python22.dll… and my own apache-extension modules (in 2.3 dir of python) where not found.

    – Hans

    Comment by MOOJI — March 4, 2008 @ 1:58 pm

  4. 혹시 TOW 설치이전에 Python이나 Subversion를 설치하지는 않으셨는지요? 확인바랍니다. 설치하지 않았는데도 발생한다면…음..어떻게 해야 될려나..

    Comment by yeoupooh — March 7, 2008 @ 11:44 am

  5. 이거참 설치후에 테스트 프로젝트 인 HelloTOW 도 모두 잘되는데…
    왜 새 프로젝트를 생성하면 trac 메인페이지에서 아래와 같은 오류가 발생하는지 모르겠습니다.

    Oops…
    Trac detected an internal error:
    If you think this really should work and you can reproduce it, you should consider reporting this problem to the Trac team.

    Go to http://trac.edgewall.org/ and create a new ticket where you describe the problem, how to reproduce it. Don’t forget to include the Python traceback found below.

    TracGuide — Trac의 사용자와 관리자 가이드

    Python Traceback
    Traceback (most recent call last):
    File “D:\TOW\Python\lib\site-packages\trac\web\main.py”, line 406, in dispatch_request
    dispatcher.dispatch(req)
    File “D:\TOW\Python\lib\site-packages\trac\web\main.py”, line 191, in dispatch
    chosen_handler = self._pre_process_request(req, chosen_handler)
    File “D:\TOW\Python\lib\site-packages\trac\web\main.py”, line 263, in _pre_process_request
    chosen_handler = f.pre_process_request(req, chosen_handler)
    File “D:\TOW\Python\lib\site-packages\trac\versioncontrol\api.py”, line 73, in pre_process_request
    self.get_repository(req.authname).sync()
    File “D:\TOW\Python\lib\site-packages\trac\versioncontrol\api.py”, line 104, in get_repository
    repos = self._connector.get_repository(rtype, rdir, authname)
    File “D:\TOW\Python\lib\site-packages\trac\versioncontrol\svn_fs.py”, line 234, in get_repository
    repos = SubversionRepository(dir, None, self.log)
    File “D:\TOW\Python\lib\site-packages\trac\versioncontrol\svn_fs.py”, line 264, in __init__
    raise TracError(“%s does not appear to be a Subversion repository.” \
    TracError: C:/TOW/SvnRepo/Projects/ProjectBBG does not appear to be a Subversion repository.

    Comment by MOOJI — March 7, 2008 @ 12:47 pm

  6. 그리고 , 그전에는 다른PC에 설치하여 막 테스트 하던 중이었는데…
    잘 되더니만 새로운 working copy를 새 프로젝트의 저장소에 임포트 하는 중에 trac 페이지를 호출하여 봤더니…
    그뒤부터…

    500 internal server error 가 발생되어 모두 삭제하고 다시해도 여전히 아래와 같은 오류만 발생되는데.. 이건 대체 뭐가 원인일까요 ?? ㅜㅜ

    23 2008] [error] [client 127.0.0.1] mod_python (pid=4544, interpreter=’tow.localhost’, phase=’PythonHandler’, handler=’trac.web.modpython_frontend’): Application error
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] ServerName: ‘tow.localhost’
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] DocumentRoot: ‘C:/TOW/Apache/htdocs’
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] URI: ‘/projects/ProjectBBG’
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] Location: ‘/projects’
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] Directory: None
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] Filename: ‘C:/TOW/Apache/cgi-bin/trac.cgi’
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] PathInfo: ‘/ProjectBBG’
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] Traceback (most recent call last):
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\Lib\\site-packages\\mod_python\\importer.py”, line 1537, in HandlerDispatch\n default=default_handler, arg=req, silent=hlist.silent)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\Lib\\site-packages\\mod_python\\importer.py”, line 1229, in _process_target\n result = _execute_target(config, req, object, arg)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\Lib\\site-packages\\mod_python\\importer.py”, line 1128, in _execute_target\n result = object(arg)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\Lib\\site-packages\\trac\\web\\modpython_frontend.py”, line 87, in handler\n gateway.run(dispatch_request)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\Lib\\site-packages\\trac\\web\\wsgi.py”, line 87, in run\n response = application(self.environ, self._start_response)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\Lib\\site-packages\\trac\\web\\main.py”, line 391, in dispatch_request\n env = _open_environment(env_path, run_once=run_once)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\Lib\\site-packages\\trac\\web\\main.py”, line 58, in _open_environment\n env_cache[env_path] = open_environment(env_path)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\Lib\\site-packages\\trac\\env.py”, line 462, in open_environment\n env = Environment(env_path)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\Lib\\site-packages\\trac\\env.py”, line 142, in __init__\n load_components(self)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\Lib\\site-packages\\trac\\loader.py”, line 95, in load_components\n egg.location)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\lib\\logging\\__init__.py”, line 955, in debug\n apply(self._log, (DEBUG, msg, args), kwargs)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\lib\\logging\\__init__.py”, line 1079, in _log\n self.handle(record)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\lib\\logging\\__init__.py”, line 1089, in handle\n self.callHandlers(record)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\lib\\logging\\__init__.py”, line 1126, in callHandlers\n hdlr.handle(record)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\lib\\logging\\__init__.py”, line 642, in handle\n self.emit(record)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\Lib\\logging\\handlers.py”, line 819, in emit\n self.handleError(record)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\lib\\logging\\__init__.py”, line 693, in handleError\n traceback.print_exception(ei[0], ei[1], ei[2], None, sys.stderr)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\lib\\traceback.py”, line 129, in print_exception\n _print(file, lines[-1], ”)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] File “C:\\TOW\\Python\\lib\\traceback.py”, line 13, in _print\n file.write(str+terminator)
    [Fri Mar 07 14:18:23 2008] [error] [client 127.0.0.1] IOError: [Errno 9] Bad file descriptor

    Comment by MOOJI — March 7, 2008 @ 12:49 pm

  7. MOOJI님 답변 드리자면..

    첫번째 trac 메인페이지의 에러는, 제가 보기엔 Subversion 저장소의 설정에 문제인 듯 합니다.

    해당 프로젝트의 trac.ini 파일(C:\TOW\TracRepo\Projects\프로젝트명\conf 에 위치)안의 [trac] 밑에
    repository_dir = C:\\TOW\\SvnRepo\\Projects\\프로젝트명 이 부분이 있을텐데요. 실제와 일치하는지 확인하시구요.

    그리고, TOW를 복사해서 다른 곳에 설치하셨다면, trac-admin resync 도 한번 하시구요.

    두번째의 에러는 마지막에 보시면 Bad File descriptor 에러가 나는데, 특별한 이유는 잘 모르겠습니다. Trac쪽에 문의해보셔야 할 거 같네요. 아님 구글링이나…

    Comment by yeoupooh — March 10, 2008 @ 1:45 am


RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Create a free website or blog at WordPress.com.

%d bloggers like this: