Re: Installing WebDAV server
Piet van Oostrum p...@vanoostrum.org wrote in message news:m2mxefb8nd@cochabamba.vanoostrum.org... Fokke Nauta fnaut...@spamsolfon.nl writes: Piet van Oostrum p...@vanoostrum.org wrote in message news:m2zkigartn@cochabamba.vanoostrum.org... Fokke Nauta fnaut...@spamsolfon.nl writes: INFO:DAVServer.fshandler:get_data: d:\webdav not found XXX --- [07/Sep/2011 11:57:48] - Mozilla/5.0 UJindows NT 5.1; rv:6.0.1 Gecko/ 20100101 Firefox/6.0.1 - GET / HTTP/1.1 404 - XXX --- [07/Sep/2011 11:57:52] - Mozilla/5.0 Uindows NT 5.1; rv:6.0.1 Gecko/ 20100101 Firefox/6.0.1 - GET / HTTP/1.1 404 - From the log it looks like you are trying to access the server with the url: http://localhost:8008/ or something similar. Yes, I do. This won't work as you would try to access the root of your webdav directory in this way (i.e. D:/webdav). The webdav server can only serve files, not directories, so you would have to access http://localhost:8008/somefile.txt where somefile.txt is a file in D:/webdav. OK, thanks. I am not familiar to WebDAV. I tried. Got something different (at least something happened): Setuptools version 0.6c9 or greater has been installed. (Run ez_setup.py -U setuptools to reinstall or upgrade.) Wasn't able to find ez_setup.py yet. Google for it and install. I did. But I don't understand. You already had WebDav installed, so why do you need ez_setup.py? Well, that was my mistake. I entered in the browser http://10.0.0.140:8081/a.txt (one of the textfiles in the directory d:\webdav on the server) and got the message: Setuptools version 0.6c9 or greater has been installed. (Run ez_setup.py -U setuptools to reinstall or upgrade.) At first I thought this came from the webdav server. That's why I searched for the ez_setup.py script. Once it was there, I ran it. It took me some time before I realized it was the actual content of the document a.txt on the webdav server what I saw. So it worked! Different that I expected, but it works. This only applies to acces using a browser. If you access the server through a webdav-aware client (for example the Finder on Mac OS X, or probably the Windows Explorer) it can serve the contents of the directory. -- Thanks. I am just trying to use a calendar with a webdav server. I don't have any experience with that. Simply using my browser to try it out. Did you try the calendar with the WebDav server running? Not yet. The next step is the calendar. Dit you put a file in D:\webdav and try to get it with the browser? Yes, and that worked! I am able to see the contents of text files. In my unfamiliarity with WebDAV I expected to open the directory and see the files in there. Many thanks for your help. Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Fokke Nauta fnaut...@spamsolfon.nl wrote in message news:9c4trjfcf...@mid.individual.net... Hi all, I am completely new to Python, but I'm confronted with a problem I can't solve. This is my question: I'm running a PC with XP Pro32, which acts as a file server/print server/FTP server and web server. The web server is facilitated by the Aprelium Abyss X2 server, and has Perl and PHP support on http and https. It all works fine. To do some research with some calender systems and to share the Outlook calendar I need a WebDAV server. After googling I found the Python WebDAV server. I installed Python 3.2.1 and extracted the packages PyWebDAV and PyXML. Now I have a working Python app and 2 directories called PyWebDAV-0.9.4.1 and PyXML-0.8.4. In the PyWebDAV README it says: Installation and setup of server can be as easy as follows: $ easy_install PyWebDAV $ davserver -D /tmp -n -J But of course it doesn't work like that. When I start up Python GUI I see the prompt instead of the $ prompt. But where do I place the two directories? And there is no easy_install script in the PyXML-0.8.4 directory, only a setup.py and ez_setup.py script. I guess the latter is the one to use. But how? How do I proceed next? Any help will be appreciated. Thanks in advance. With regards, Fokke Nauta I have my webdav server up and running. Many thanks for all who contributed to solving this problem. With regards, Fokke Nauta -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Dennis Lee Bieber wlfr...@ix.netcom.com wrote in message news:mailman.823.1315377607.27778.python-l...@python.org... On Tue, 6 Sep 2011 21:26:12 +0200, Fokke Nauta fnaut...@spamsolfon.nl declaimed the following in gmane.comp.python.general: cut (here I try to login the WebDAV server with the local IE browser) INFO:fshandler :get_data: D:\Webdav not found At this point my best suggestion is to study the source code of fshandler to see what it is doing at this moment in time (offhand, is there any content IN the directory to be served?) There is a file indeed, in d:\Webdav server - - [06/Sep/2011 21:05:35] - Mozilla/4.0 (compatible; MSIE 8.0; Windows N T 5.1; Trident/4.0 - GET / HTTP/1.1 404 - server - - [06/Sep/2011 21:05:35] - Mozilla/4.0 (compatible; MSIE 8.0; Windows N T 5.1; Trident/4.0 - GET / HTTP/1.1 404 - That almost looks like something is trying to retrieve a default page for 404 (not found) page. To save you some time: -=-=-=- if os.path.exists(path): if os.path.isfile(path): file_size = os.path.getsize(path) if range == None: ## REST SNIPPED else: # also raise an error for collections # don't know what should happen then.. log.info('get_data: %s not found' % path) I have seen this part. Do I need to alter it? Note that at this point in the system, it is looking for a FILE, not a directory. -- I have re-installed Python and the setuptool, and tried the Python version of Active, but it did not make a difference. So now I use the old Python 2.7 again. Used easy_install to install PyWebDAV. I now run davserver.exe from the Script directory. Still the same problem. What I found, however, was that if I specify the directory from the command line (like davserver -D d:\Webdav -n) there is no error message as INFO:fshandler :get_data: D:\Webdav not found. The browser shows still the 404 error. The error INFO:fshandler :get_data: D:\Webdav not found only occurs when I specify the -c config.ini in the command line. I didn't expect it to be this so tricky. It looked easy to set up an experimental webdav server. Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
becky_lewis bex.le...@gmail.com wrote in message news:d26f81b2-f87e-46f1-bb4e-8ef1943df...@c29g2000yqd.googlegroups.com... I have re-installed Python and the setuptool, and tried the Python version of Active, but it did not make a difference. So now I use the old Python 2.7 again. Used easy_install to install PyWebDAV. I now run davserver.exe from the Script directory. Still the same problem. What I found, however, was that if I specify the directory from the command line (like davserver -D d:\Webdav -n) there is no error message as INFO:fshandler :get_data: D:\Webdav not found. The browser shows still the 404 error. The error INFO:fshandler :get_data: D:\Webdav not found only occurs when I specify the -c config.ini in the command line. I didn't expect it to be this so tricky. It looked easy to set up an experimental webdav server. Fokke How are you trying to access the webdav server? By IE 8 and Firefox, on the same system as well as on another system. Firefox doesn't show the 404 error but shows a blank screen. I bound the davserver to the local adress of the system where it's on (10.0.0.140). The port was 8081 but I changed it to 8008 as you said it's the default. No difference. I've been hacking on the server for several days now (unrelated reasons) and have found that it's a little unforgiving when it comes to configuration errors. You need to be accessing the webdav server via the correct port (I think it's 8008 by default). If you're not doing this and something else is running on port 80 (which is where a webdav client will go to by default) then this would explain the 404 errors. I certainly use the correct IP address and port number. Underneath is my command shell. The 1st time I specified the config file (davserver.ini), the 2nd time I specified on the command line. Here I logged in with Firefox from system XXX (replaced the name by XXX). (Here I started the server with the the config file (davserver.ini) D:Python27\Scriptsdavserver -m -c davserver.ini INFO:pywebdav:Starting up PyWebDAV server version 0.9.4-dev INFO:pywebdav:chunked_http_response feature ON INFO:pywebdav:http_request_use_iterator feature OFF INFO:pywebdav:http_response_use_iterator feature OFF INFO:DAVServer.fshandler:Initialized with d:\webdav-http://10.0.0.140:8081/ WARNING:pywebdav:Authentication disabled! INFO:pywebdav:Serving data from d:\webdav Listening on 10.0.0.140 8081 (browser logging in) INFO:DAVServer.fshandler:get_data: d:\webdav not found XXX --- [07/Sep/2011 11:57:48] - Mozilla/5.0 UJindows NT 5.1; rv:6.0.1 Gecko/ 20100101 Firefox/6.0.1 - GET / HTTP/1.1 404 - XXX --- [07/Sep/2011 11:57:52] - Mozilla/5.0 Uindows NT 5.1; rv:6.0.1 Gecko/ 20100101 Firefox/6.0.1 - GET / HTTP/1.1 404 - ^C D:\Python27\ScriptsINFO:pywebdav:Killed by user (Here I started the server with command line options) davserver -D d:\webdav -H 10.0.0.140 -P 8081 -n WARNING:pywebdav:Authentication disabled! Listening on 10.0.0.140 8081 XXX --- [07/Sep/2011 11:58:49] - Mozilla/5.0 Uindows NT 5.1; rv:6.0.1 Gecko/ 20100101 Firefox/6.0.1 - GET / HTTP/1.1 404 - XXX --- [07/Sep/2011 11:58:54] - Mozilla/5.0 Uindows NT 5.1; rv:6.0.1 Gecko/ 20100101 Firefox/6.0.1 - GET / HTTP/1.1 404 - ^C D:\Python27\ScriptsINFO:pywebdav:Killed by user -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Piet van Oostrum p...@vanoostrum.org wrote in message news:m2zkigartn@cochabamba.vanoostrum.org... Fokke Nauta fnaut...@spamsolfon.nl writes: INFO:DAVServer.fshandler:get_data: d:\webdav not found XXX --- [07/Sep/2011 11:57:48] - Mozilla/5.0 UJindows NT 5.1; rv:6.0.1 Gecko/ 20100101 Firefox/6.0.1 - GET / HTTP/1.1 404 - XXX --- [07/Sep/2011 11:57:52] - Mozilla/5.0 Uindows NT 5.1; rv:6.0.1 Gecko/ 20100101 Firefox/6.0.1 - GET / HTTP/1.1 404 - From the log it looks like you are trying to access the server with the url: http://localhost:8008/ or something similar. Yes, I do. This won't work as you would try to access the root of your webdav directory in this way (i.e. D:/webdav). The webdav server can only serve files, not directories, so you would have to access http://localhost:8008/somefile.txt where somefile.txt is a file in D:/webdav. OK, thanks. I am not familiar to WebDAV. I tried. Got something different (at least something happened): Setuptools version 0.6c9 or greater has been installed. (Run ez_setup.py -U setuptools to reinstall or upgrade.) Wasn't able to find ez_setup.py yet. This only applies to acces using a browser. If you access the server through a webdav-aware client (for example the Finder on Mac OS X, or probably the Windows Explorer) it can serve the contents of the directory. -- Thanks. I am just trying to use a calendar with a webdav server. I don't have any experience with that. Simply using my browser to try it out. Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
becky_lewis bex.le...@gmail.com wrote in message news:f5b9ec16-de9a-4365-81a8-860dc27a9...@d25g2000yqh.googlegroups.com... On Sep 5, 3:51 pm, Fokke Nauta fnaut...@spamsolfon.nl wrote: Hi Becky, I tried it straight away: directory=D:\Webdav\ directory=D:/Webdav/ Didn't work, in both cases the same error fshandler:get_data: \Webdav not found. I have the opinion that my WebDAV installation is at fault. The database is not created either. To have set up Python, I used python-2.7.2.msi. To install WebDAV, I used PyWebDAV-0.9.4.1 and PyXML-0.8.4 packages, both Unix/Linux. To install the, I used You dont install from Python GUI, use normal cmd, navigate to the folder you downloaded PyXML and PyWebDAV and run python setup.py install (python.exe has to be in your PATH). Then you have to find the startup-script davserver. Find your python installation directory and look intoInstall dir/Tools/Scripts, in my computer this is E:\python27\Tools\Scripts. PyXML and PyWebDAV get installed in the site-packages folder i.e. E:\python27\Lib/site-packages. You might have to look for davserver there... Shall I reïnstall the whole lot? Would it make a difference if in that case I would use ActivePython-2.7.2.5-win32-x86.msi instead of python-2.7.2.msi? Fokke You could try that but I'd imagine you'll end up with the same issue. My best guess is that something is preventing os.path.isdir from detecting the path as a directory under windows. I can't reproduce it on my Linux system but may have a working windows installation later. If I were you I'd fire up a python shell (execute python and get the prompt), import os.path and manually try os.path.isdir(path_name) to try and find out what the actualy problem is. I'm not familiar with Python, but I entered import os.path (nothing happened) and os.path.isdir(path_name) in the shell. I guess what I did was not correct. Underneath I copied what showed up in the shell. --- Python 2.7.2 (default, Jun 12 2011, 15:08:59) [MSC v.1500 32 bit (Intel)] on win32 Type copyright, credits or license() for more information. import os.path os.path.isdir(path_name) Traceback (most recent call last): File pyshell#1, line 1, in module os.path.isdir(path_name) NameError: name 'path_name' is not defined --- Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Dennis Lee Bieber wlfr...@ix.netcom.com wrote in message news:mailman.809.1315328739.27778.python-l...@python.org... On Tue, 6 Sep 2011 16:46:17 +0200, Fokke Nauta fnaut...@spamsolfon.nl declaimed the following in gmane.comp.python.general: --- Python 2.7.2 (default, Jun 12 2011, 15:08:59) [MSC v.1500 32 bit (Intel)] on win32 Type copyright, credits or license() for more information. import os.path os.path.isdir(path_name) Traceback (most recent call last): File pyshell#1, line 1, in module os.path.isdir(path_name) NameError: name 'path_name' is not defined --- path_name is a placeholder -- you're supposed to put in the exact string(s) you have been trying in the configuration file (wrap the string in quotes). import os.path os.path.isdir(e:\webdav) False os.mkdir(e:\webdav) os.path.isdir(e:\webdav) True os.path.isdir(e:\webdav\\) Traceback ( File interactive input, line 1 os.path.isdir(e:\webdav\) ^ SyntaxError: EOL while scanning single-quoted string os.path.isdir(e:\webdav\\) True os.path.isdir(e:\webdav/) True os.path.isdir(e:/webdav/) True os.path.isdir(e:/webdav) True os.rmdir(e:/webdav) os.path.isdir(e:\webdav) False Note that Python itself (and the C-runtime) doesn't care if the separator is \ or / or even mixed; it is just the Windows command line that uses \ for separator and / for options. (Python, however, uses \ as an escape and \ is treated first, hence the need for \\ to escape the \ itself) Thanks, this is clear. This is my Python shell: Python 2.7.2 (default, Jun 12 2011, 15:08:59) [MSC v.1500 32 bit (Intel)] on win32 Type copyright, credits or license() for more information. import os.path os.path.isdir(d:\webdav) True So Python recognizes the directory d:\webdav This is the command shell: D:\Python27\WebDAV\PyWebDAV\DAVServerserver.py -n -c config.ini INFO:pywebdav:Starting up PyWebDAV server version 0.9.4-dev INFO:pywebdav:chunked_http_response feature ON INFO:pywebdav:http_request_use_iterator feature OFF INFO:pywebdav :http_response_use_iterator feature OFF INFO:fshandler:Initialized with D:/Webdav-http://10.0.0.140:8081/ WARNING:pywebdav:Authentication disabled! INFO:pywebdav:Serving data from D:/Webdav Listening on 10.0.0.140 8081 (here I try to login the WebDAV server with the local IE browser) INFO:fshandler :get_data: D:\Webdav not found server - - [06/Sep/2011 21:05:35] - Mozilla/4.0 (compatible; MSIE 8.0; Windows N T 5.1; Trident/4.0 - GET / HTTP/1.1 404 - server - - [06/Sep/2011 21:05:35] - Mozilla/4.0 (compatible; MSIE 8.0; Windows N T 5.1; Trident/4.0 - GET / HTTP/1.1 404 - So - I'm a bit lost now. Thinking seriously that my webdav installation is at fault. Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
becky_lewis bex.le...@gmail.com wrote in message news:a7cd34d7-ed2b-4449-8edc-a6a45b59e...@hb5g2000vbb.googlegroups.com... Possibly. I tried this: server.py -n -c config.ini Once again, the server is up and running and when I am logging in with my browser (10.0.0.140:8081) I can see information showing up at the command prompt, showing somebody is logging is, but the same error: fshandler:get_data: \Webdav not found. During starting up the server mentioned: pywebdav:Serving data from \Webdav. In the config file it says: # main directory directory = \Webdav Perhaps my Python configuration is at fault. Fokke Is the path supposed to be absolute? In which case you'd need to have: directory=C:\path\to\Webdav instead of just directory=\Webdav I tried: directory=D:\Webdav directory=D:/Webdav To no avail. It didn.t make any difference. I surely believe my WebDAV installation is at fault. Fokke Interestingly, looking at the code that returns the fshandler:get_data: \Webdav not found message, it looks like it tests that the path given exists and then tries an os.path.isfile, then an os.path.isdir. If both fail you get the message that you see. This might be a bit of a shot in the dark but could you try the path with and without a trailing '/' or '\'? I don't currently have a windows box available to test on and figure out why it would be detected as existing but not test true for either a file or directory. Hi Becky, I tried it straight away: directory=D:\Webdav\ directory=D:/Webdav/ Didn't work, in both cases the same error fshandler:get_data: \Webdav not found. I have the opinion that my WebDAV installation is at fault. The database is not created either. To have set up Python, I used python-2.7.2.msi. To install WebDAV, I used PyWebDAV-0.9.4.1 and PyXML-0.8.4 packages, both Unix/Linux. To install the, I used You dont install from Python GUI, use normal cmd, navigate to the folder you downloaded PyXML and PyWebDAV and run python setup.py install (python.exe has to be in your PATH). Then you have to find the startup-script davserver. Find your python installation directory and look intoInstall dir/Tools/Scripts, in my computer this is E:\python27\Tools\Scripts. PyXML and PyWebDAV get installed in the site-packages folder i.e. E:\python27\Lib/site-packages. You might have to look for davserver there... Shall I reïnstall the whole lot? Would it make a difference if in that case I would use ActivePython-2.7.2.5-win32-x86.msi instead of python-2.7.2.msi? Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Thomas 'PointedEars' Lahn pointede...@web.de wrote in message news:109595831.vcn276c...@pointedears.de... cut If you don't have anything better to contribute, please stop answering. Es genügt schon. Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Dennis Lee Bieber wlfr...@ix.netcom.com wrote in message news:mailman.622.1314812583.27778.python-l...@python.org... On Wed, 31 Aug 2011 11:27:36 +0200, Fokke Nauta fnaut...@spamsolfon.nl declaimed the following in gmane.comp.python.general: Ofcourse I realized it was Unix/Linux. I already could tell that as the packages I downloaded were tar.gz files. So I unpacked them and expected to run a Python installer script from the Python command line. Hence my question How do I do that, but perhaps I did not make myself clear enough. NO Python package installer runs from the Python command line (ie; from a Python interactive session prompt). Typically you run them from the OS command interpreter. If the installer is a .py file and the associations are correct, the Python interpreter will be started to process the installer script. If the associations aren't set, you may have to enter python installer.py at the system prompt instead of installer.py Tried to run the Python installer script from the DOS command line but that resulted in an error. Okay -- so what was the error? -- Sorry - I didn't come back on your question. In the mean time I forgot what the error message was. But I installed it the way Paul Kölle mentioned: You dont install from Python GUI, use normal cmd, navigate to the folder you downloaded PyXML and PyWebDAV and run python setup.py install (python.exe has to be in your PATH). Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Dennis Lee Bieber wlfr...@ix.netcom.com wrote in message news:mailman.687.1314941410.27778.python-l...@python.org... On Thu, 1 Sep 2011 12:30:43 +0200, Fokke Nauta fnaut...@spamsolfon.nl declaimed the following in gmane.comp.python.general: Dennis Lee Bieber wlfr...@ix.netcom.com wrote in message news:mailman.643.1314851358.27778.python-l...@python.org... Next, if you'd read further and didn't take the comment as the instruction. set firstrun=1 I did to tell the server this is the first time it is being run - IT WILL create the database table (after the first start, reset the flag to 0 to speed up later runs). It didn't create the table. The database kept empty. Odd -- but then, I'm not running it myself, and wasn't up to reading all the code to see what path it takes. It's only for experimenting with calendar software, so authorization is not a point. So I forget about MySQL. Later in the config file set mysql_auth=1 to enable the use of MySQL, and set the admin user/password to what you plan to have it use. I did You probably want to set daemonize=1 (maybe after first run) I left this to 0. Oh, and don't forget to set the main data directory and any port/host changes. I left host and port as they were. The main directory is e:\wwwroot Start the server - it should connect to MySQL, create the table, and add the admin user to the table. I started the server with server.py (in D:\Python27\WebDAV\PyWebDAV\DAVServer) -D e:/wwwroot -m -c config.ini If the main directory is already in the config file, you probably don't need to specify it on the command line... OK And... could there be something in the code where overriding the directory by command line changes where it looks for the config file? (Just guessing at this point). Possibly. I tried this: server.py -n -c config.ini Once again, the server is up and running and when I am logging in with my browser (10.0.0.140:8081) I can see information showing up at the command prompt, showing somebody is logging is, but the same error: fshandler:get_data: \Webdav not found. During starting up the server mentioned: pywebdav:Serving data from \Webdav. In the config file it says: # main directory directory = \Webdav Perhaps my Python configuration is at fault. Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Dennis Lee Bieber wlfr...@ix.netcom.com wrote in message news:mailman.711.1314983727.27778.python-l...@python.org... On Fri, 2 Sep 2011 14:19:32 +0200, Fokke Nauta fnaut...@spamsolfon.nl declaimed the following in gmane.comp.python.general: In the config file it says: # main directory directory = \Webdav I think that's the line that should have your e:/wwwroot specification -- Sorry! It used to have. But as it did not work, with the same error message, it could not find E:\wwwroot, I changed it into \Webdav. Ofcourse, in the command line as well. Later on I left the D specification out in the command line. Perhaps another drive letter might cause the problem, so in this case I kept it on the same partition. But I still got the same error. Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
pyt...@bdurham.com wrote in message news:mailman.703.1314969082.27778.python-l...@python.org... Hi Fokke, Disclaimer: I have no experience with the Python WebDAV package you're using. But a thought: In the config file it says: # main directory directory = \Webdav Perhaps you should qualify your directory path with a drive letter? I would try this 2 ways: directory = E:\Webdav And if that doesn't work: directory = E:/Webdav My thinking about the 2nd example is that perhaps the \W is getting interpreted as a control character vs. backslash W. I tried: directory=D:\Webdav directory=D:/Webdav To no avail. It didn't make any difference. I surely believe my WebDAV installation is at fault. And D: is the same partition as where Python is, D:\Python27 Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
becky_lewis bex.le...@gmail.com wrote in message news:86b084e0-09a8-4997-9e0c-4526d7851...@s2g2000vby.googlegroups.com... On Sep 2, 1:19 pm, Fokke Nauta fnaut...@spamsolfon.nl wrote: Dennis Lee Bieber wlfr...@ix.netcom.com wrote in messagenews:mailman.687.1314941410.27778.python-l...@python.org... On Thu, 1 Sep 2011 12:30:43 +0200, Fokke Nauta fnaut...@spamsolfon.nl declaimed the following in gmane.comp.python.general: Dennis Lee Bieber wlfr...@ix.netcom.com wrote in message news:mailman.643.1314851358.27778.python-l...@python.org... Next, if you'd read further and didn't take the comment as the instruction. set firstrun=1 I did to tell the server this is the first time it is being run - IT WILL create the database table (after the first start, reset the flag to 0 to speed up later runs). It didn't create the table. The database kept empty. Odd -- but then, I'm not running it myself, and wasn't up to reading all the code to see what path it takes. It's only for experimenting with calendar software, so authorization is not a point. So I forget about MySQL. Later in the config file set mysql_auth=1 to enable the use of MySQL, and set the admin user/password to what you plan to have it use. I did You probably want to set daemonize=1 (maybe after first run) I left this to 0. Oh, and don't forget to set the main data directory and any port/host changes. I left host and port as they were. The main directory is e:\wwwroot Start the server - it should connect to MySQL, create the table, and add the admin user to the table. I started the server with server.py (in D:\Python27\WebDAV\PyWebDAV\DAVServer) -D e:/wwwroot -m -c config.ini If the main directory is already in the config file, you probably don't need to specify it on the command line... OK And... could there be something in the code where overriding the directory by command line changes where it looks for the config file? (Just guessing at this point). Possibly. I tried this: server.py -n -c config.ini Once again, the server is up and running and when I am logging in with my browser (10.0.0.140:8081) I can see information showing up at the command prompt, showing somebody is logging is, but the same error: fshandler:get_data: \Webdav not found. During starting up the server mentioned: pywebdav:Serving data from \Webdav. In the config file it says: # main directory directory = \Webdav Perhaps my Python configuration is at fault. Fokke Is the path supposed to be absolute? In which case you'd need to have: directory=C:\path\to\Webdav instead of just directory=\Webdav I tried: directory=D:\Webdav directory=D:/Webdav To no avail. It didn.t make any difference. I surely believe my WebDAV installation is at fault. Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Dennis Lee Bieber wlfr...@ix.netcom.com wrote in message news:mailman.643.1314851358.27778.python-l...@python.org... On Wed, 31 Aug 2011 14:18:00 +0200, Fokke Nauta fnaut...@spamsolfon.nl declaimed the following in gmane.comp.python.general: I also configured config.ini in D:\Python27\WebDAV\PyWebDAV\DAVServer In this file it says: # Auth Database Table, Must exists in database prior to firstrun dbtable=webDav # Create User Database Table and Insert system user I created in MySQL a database called webDav. I can create a table called User, but how many fields? After looking at the config file. I presume you have specified the MySQL username/password Sure (personally, and out of paranoia, I'd create a webDAV user/password that only has access rights to the specified webDAV database). Next, if you'd read further and didn't take the comment as the instruction. set firstrun=1 I did to tell the server this is the first time it is being run - IT WILL create the database table (after the first start, reset the flag to 0 to speed up later runs). It didn't create the table. The database kept empty. Later in the config file set mysql_auth=1 to enable the use of MySQL, and set the admin user/password to what you plan to have it use. I did You probably want to set daemonize=1 (maybe after first run) I left this to 0. Oh, and don't forget to set the main data directory and any port/host changes. I left host and port as they were. The main directory is e:\wwwroot Start the server - it should connect to MySQL, create the table, and add the admin user to the table. I started the server with server.py (in D:\Python27\WebDAV\PyWebDAV\DAVServer) -D e:/wwwroot -m -c config.ini The seems to work as I get a login screen in the browser. Later on I changed the ini file: # disable auth noauth = 1 # Enable mysql auth mysql_auth=0 No login screen anymore but I got an error message fshandler:get_data: e:\wwwroot not found Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Paul Kölle p...@subsignal.org wrote in message news:mailman.620.1314810894.27778.python-l...@python.org... Hi, answers below... Am 31.08.2011 14:18, schrieb Fokke Nauta: Paul Köllep...@subsignal.org wrote in message news:mailman.595.1314780791.27778.python-l...@python.org... Hi, Am 30.08.2011 22:00, schrieb Fokke Nauta: Hi all, I am completely new to Python, but I'm confronted with a problem I can't solve. Welcome to python. This is my question: [snip] I installed Python 3.2.1 and extracted the packages PyWebDAV and PyXML. Now I have a working Python app and 2 directories called PyWebDAV-0.9.4.1 and PyXML-0.8.4. In the PyWebDAV README it says: Installation and setup of server can be as easy as follows: $ easy_install PyWebDAV $ davserver -D /tmp -n -J But of course it doesn't work like that. When I start up Python GUI I see the prompt instead of the $ prompt. But where do I place the two directories? And there is no easy_install script in the PyXML-0.8.4 directory, only a setup.py and ez_setup.py script. I guess the latter is the one to use. But how? You dont install from Python GUI, use normal cmd, navigate to the folder you downloaded PyXML and PyWebDAV and run python setup.py install (python.exe has to be in your PATH). Then you have to find the startup-script davserver. Find your python installation directory and look intoInstall dir/Tools/Scripts, in my computer this is E:\python27\Tools\Scripts. PyXML and PyWebDAV get installed in the site-packages folder i.e. E:\python27\Lib/site-packages. You might have to look for davserver there... Thanks, Paul. I ran python setup.py install in both the PyXML and PyWebDAV directories. A lot of things happened and are added into those directories and I guess it will be OK. Next step, the startup-script davserver. There is no script as such, also not in \python27\tools\scripts. I found 2 similar scripts: 1. server.py in D:\Python27\WebDAV\PyWebDAV\DAVServer 2. WebDAVServer.py in D:\Python27\WebDAV\PyWebDAV\DAV Which one is the one to use? Your install locations look odd, but it might work nevertheless. The server is in DAVServer\server.py, you can look at the file and you will see: if __name__ == '__main__': run() at the bottom. This is the entry point of a python script if called from the command line. Yes, it was server.py. My install looks a bit different but I can start the server as follows: python.exe E:\Python27\Lib\site-packages\pywebdav-0.9.4.1-py2.7.egg\DAVServer\server.py -D c:\home -n WARNING:pywebdav:Authentication disabled! Listening on localhost (8008) I used server.py e:/wwwroot -m -c config.ini I also configured config.ini in D:\Python27\WebDAV\PyWebDAV\DAVServer I would use a config file outside the program directory and use the -c or --config switch, run server.py without arguments to see possible startup options. In this file it says: # Auth Database Table, Must exists in database prior to firstrun dbtable=webDav # Create User Database Table and Insert system user I created in MySQL a database called webDav. I can create a table called User, but how many fields? Don't know if that's documented somewhere but you can just look at the code in mysqlauth.py in the same directory as server.py. Seems it needs three columns, (Userstring,Passstring,can_write0|1) but I haven't tried. I have understood that the database will be configured with the first run, but in my case it didn't. In my congig.ini there was # Create User Database Table and Insert system user # Disable after the Table is created; for performance reasons firstrun=1 Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Thomas 'PointedEars' Lahn pointede...@web.de wrote in message news:4761603.ypau67u...@pointedears.de... Fokke Nauta wrote: Thomas 'PointedEars' Lahn pointede...@web.de wrote in message news:6545843.yvfaxzv...@pointedears.de... It's attribution _line_, not attribution novel. Your quotes are hardly legible, too ? http://insideoe.com/ Fokke Nauta wrote: I'm running a PC with XP Pro32, [.] [.] In the PyWebDAV README it says: Installation and setup of server can be as easy as follows: $ easy_install PyWebDAV $ davserver -D /tmp -n -J But of course it doesn't work like that. When I start up Python GUI That is really not a *G*raphical User Interface, but the (text-based) Python shell. Yes, I noticed. But the application has the name of Python GUI. ACK. Admittedly I cannot remember having used Python on Windows (XP) except via Cygwin. I see the prompt instead of the $ prompt. Doctor, my arm hurts when I move it. - Don't move it, then. I don't see the point here ... Do not run `python' or the Python GUI, then. The Python shell executes Python code. The above obviously is not Python code, but *system* shell commands. So let the *system* command shell execute them (as indicated by the `$' prompt, which is customary for a sh-based UNIX/Linux shell prompt). I know. I worked with SCO Unix and various sorts of Linux. But never with Python, so I hadn't got a clue about the prompt. Come on, with that experience you see a `$' and those commands and don't realize it is (ba)sh? Ofcourse I realized it was Unix/Linux. I already could tell that as the packages I downloaded were tar.gz files. So I unpacked them and expected to run a Python installer script from the Python command line. Hence my question How do I do that, but perhaps I did not make myself clear enough. Tried to run the Python installer script from the DOS command line but that resulted in an error. As I have Cygwin running as well, I could try to install it there instead of in Windows. Since you use Windows XP, type `cmd' to get the command shell (if you knew MS-DOS, which I doubt, you are at home now). I know MSDOS. I even worked with CP/M Good for you. However, you appear to have found the *UNIX/Linux* README (and the corresponding version?) of that server: the second command is usually how you would run a program as daemon on Unices (run through an init script), while on Windows NT (like XP) you would have a setup program install a service for you (maybe to execute that command when the service is started). Look for the Windows version. There is no other Windows version except the packages I mentioned, PyWebDAV and PyXML. The only Windows thing I got was the Python interpreter itself. Has it not occurred to you to STFW for easy_install first? What do you mean by STFW? I wasn't aware that easy_install was a utility. Downloaded and installed the Windows version and run easy_install pywebdav. It downloaded something, installed something and finished something. But, once again, don't know how to proceed. Otherwise I'll give it a try under Cygwin. And there is no easy_install script in the PyXML-0.8.4 directory, only a setup.py and ez_setup.py script. I guess the latter is the one to use. But how? RTFM. Which fucking manual? That of the server, on Windows-related information. Or that of easy_install. Or Python. Whichever comes first. It's my own server and I didn't write a manual for it. In the manual of Easy_install it says how to install packaged etc and I did sucessfully. There is no furter information as how to proceed. That's why I posted my question here. How do I proceed next? Look for the Windows version. If there is none, get easy_install and use it as described. I did and it worked. What's next? Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Paul Kölle p...@subsignal.org wrote in message news:mailman.595.1314780791.27778.python-l...@python.org... Hi, Am 30.08.2011 22:00, schrieb Fokke Nauta: Hi all, I am completely new to Python, but I'm confronted with a problem I can't solve. Welcome to python. This is my question: [snip] I installed Python 3.2.1 and extracted the packages PyWebDAV and PyXML. Now I have a working Python app and 2 directories called PyWebDAV-0.9.4.1 and PyXML-0.8.4. In the PyWebDAV README it says: Installation and setup of server can be as easy as follows: $ easy_install PyWebDAV $ davserver -D /tmp -n -J But of course it doesn't work like that. When I start up Python GUI I see the prompt instead of the $ prompt. But where do I place the two directories? And there is no easy_install script in the PyXML-0.8.4 directory, only a setup.py and ez_setup.py script. I guess the latter is the one to use. But how? You dont install from Python GUI, use normal cmd, navigate to the folder you downloaded PyXML and PyWebDAV and run python setup.py install (python.exe has to be in your PATH). Then you have to find the startup-script davserver. Find your python installation directory and look into Install dir/Tools/Scripts, in my computer this is E:\python27\Tools\Scripts. PyXML and PyWebDAV get installed in the site-packages folder i.e. E:\python27\Lib/site-packages. You might have to look for davserver there... Thanks, Paul. I ran python setup.py install in both the PyXML and PyWebDAV directories. A lot of things happened and are added into those directories and I guess it will be OK. Next step, the startup-script davserver. There is no script as such, also not in \python27\tools\scripts. I found 2 similar scripts: 1. server.py in D:\Python27\WebDAV\PyWebDAV\DAVServer 2. WebDAVServer.py in D:\Python27\WebDAV\PyWebDAV\DAV Which one is the one to use? I also configured config.ini in D:\Python27\WebDAV\PyWebDAV\DAVServer In this file it says: # Auth Database Table, Must exists in database prior to firstrun dbtable=webDav # Create User Database Table and Insert system user I created in MySQL a database called webDav. I can create a table called User, but how many fields? With regards, Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Laszlo Nagy gand...@shopzeus.com wrote in message news:mailman.597.1314791334.27778.python-l...@python.org... What do you mean by STFW? Search The Fucking Web ? OK, the modern version of RTFM. I wasn't aware that easy_install was a utility. Downloaded and installed the Windows version and run easy_install pywebdav. It downloaded something, installed something and finished something. Then it's installed! But, once again, don't know how to proceed. Is that so hard? I have never used pywebdav but the first page I hit through Google search is: http://code.google.com/p/pywebdav/ I've been there. Where it says: Installation and setup of server can be as easy as follows: $ easy_installPyWebDAV $ davserver-D/tmp-n-J Starting upPyWebDAV server(version0.9.2-dev) ATTENTION: Authentication disabled! Serving datafrom /tmp Listening on localhost(8008) Yes, but that's Unix/Linux again. But I'm in Windows, without experience with Python. So you successfully ran easy_install. Then I guess you will have to look for a program named davserver and start it up. I suspect that searching for davserver.* under your site-packages dir or Python installation dir will do. Fokke -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Laszlo Nagy gand...@shopzeus.com wrote in message news:mailman.603.1314797809.27778.python-l...@python.org... Where it says: Installation and setup of server can be as easy as follows: $ easy_installPyWebDAV $ davserver-D/tmp-n-J Starting upPyWebDAV server(version0.9.2-dev) ATTENTION: Authentication disabled! Serving datafrom /tmp Listening on localhost(8008) Yes, but that's Unix/Linux again. But I'm in Windows, without experience with Python. Not really... The easy_install command is the same on windows. Maybe the command prompt is different, but the command itself is the same. Same is true with the davserver command. If you can find a davserver.exe or davserver.py or davserver.pyw file under site-packages or tools/scripts, then that will be the program that you need to start up. No magic. Actually, I installed easy_install setuptools for Windows (setuptools-0.6c11.win32-py2.7.exe). Running easy_install generated an error message: Setuptools version 0.6c9 or greater has been installed. (Run ez_setup.py -U setuptools to reinstall or upgrade.) I did, quite something happened but the same error message came back when retrying. So, I installed it another way, indicated by Paul Kölle: navigate to the folder you downloaded PyXML and PyWebDAV and run python setup.py install (python.exe has to be in your PATH). That worked fine, but: There is no davserver script or executable. Please read my response to Paul Kölle. Fokke -- http://mail.python.org/mailman/listinfo/python-list
Installing WebDAV server
Hi all, I am completely new to Python, but I'm confronted with a problem I can't solve. This is my question: I'm running a PC with XP Pro32, which acts as a file server/print server/FTP server and web server. The web server is facilitated by the Aprelium Abyss X2 server, and has Perl and PHP support on http and https. It all works fine. To do some research with some calender systems and to share the Outlook calendar I need a WebDAV server. After googling I found the Python WebDAV server. I installed Python 3.2.1 and extracted the packages PyWebDAV and PyXML. Now I have a working Python app and 2 directories called PyWebDAV-0.9.4.1 and PyXML-0.8.4. In the PyWebDAV README it says: Installation and setup of server can be as easy as follows: $ easy_install PyWebDAV $ davserver -D /tmp -n -J But of course it doesn't work like that. When I start up Python GUI I see the prompt instead of the $ prompt. But where do I place the two directories? And there is no easy_install script in the PyXML-0.8.4 directory, only a setup.py and ez_setup.py script. I guess the latter is the one to use. But how? How do I proceed next? Any help will be appreciated. Thanks in advance. With regards, Fokke Nauta -- http://mail.python.org/mailman/listinfo/python-list
Re: Installing WebDAV server
Thomas 'PointedEars' Lahn pointede...@web.de wrote in message news:6545843.yvfaxzv...@pointedears.de... Fokke Nauta wrote: I'm running a PC with XP Pro32, [.] To do some research with some calender systems and to share the Outlook calendar I need a WebDAV server. After googling I found the Python WebDAV server. I installed Python 3.2.1 and extracted the packages PyWebDAV and PyXML. Now I have a working Python app and 2 directories called PyWebDAV-0.9.4.1 and PyXML-0.8.4. In the PyWebDAV README it says: Installation and setup of server can be as easy as follows: $ easy_install PyWebDAV $ davserver -D /tmp -n -J But of course it doesn't work like that. When I start up Python GUI That is really not a *G*raphical User Interface, but the (text-based) Python shell. Yes, I noticed. But the application has the name of Python GUI. I see the prompt instead of the $ prompt. Doctor, my arm hurts when I move it. - Don't move it, then. I don't see the point here ... The Python shell executes Python code. The above obviously is not Python code, but *system* shell commands. So let the *system* command shell execute them (as indicated by the `$' prompt, which is customary for a sh-based UNIX/Linux shell prompt). I know. I worked with SCO Unix and various sorts of Linux. But never with Python, so I hadn't got a clue about the prompt. Since you use Windows XP, type `cmd' to get the command shell (if you knew MS-DOS, which I doubt, you are at home now). I know MSDOS. I even worked with CP/M However, you appear to have found the *UNIX/Linux* README (and the corresponding version?) of that server: the second command is usually how you would run a program as daemon on Unices (run through an init script), while on Windows NT (like XP) you would have a setup program install a service for you (maybe to execute that command when the service is started). Look for the Windows version. There is no other Windows version except the packages I mentioned, PyWebDAV and PyXML. The only Windows thing I got was the Python interpreter itself. But where do I place the two directories? You do not; let easy_install place them in the correct packages directory (hence *easy* *install*). That is very likely what the setup.py and ez_setup.py scripts are for (spell ez in English). And there is no easy_install script in the PyXML-0.8.4 directory, only a setup.py and ez_setup.py script. I guess the latter is the one to use. But how? RTFM. Which fucking manual? How do I proceed next? Look for the Windows version. If there is none, get easy_install and use it as described. Thanks for your quick reply. This means Show over? Fokke -- http://mail.python.org/mailman/listinfo/python-list