# Apache + webdav = fehlschlag. [solved]

## root_tux_linux

Hi

Hab ein kleines Problem und zwar würde ich gerne webdav betreiben nur funktioniert es nicht.

Ich bin dieser Anleitung gefolgt: http://gentoo-wiki.com/HOWTO_WebDav

Jedoch benutz ich als Pfad /var/www/uploads und der Ordner gehört apache und gruppe apache.

Sobald ich aber über konqueror und webdavs://localhost/uploads oder webdav://localhost/uploads verbinden will heisst es uploads würde nicht existieren.

Code aus /etc/apache2/vhost.d/00_vhost.d.conf

```
<IfModule mod_dav.c>

    Alias /uploads /var/www/uploads

    DavMinTimeout 600

        <Location /uploads>

                Options None

                Dav On

                <Limit GET PUT POST DELETE PROPFIND PROPPATCH MKCOL COPY MOVE LOCK UNLOCK>

                        AuthType Basic

                        AuthName "WebDav Restricted Repository"

                        AuthUserFile /var/www/uploads/.davpasswd

                        Require valid-user

                </Limit>

        </Location>

</IfModule>

```

die .davpasswd existiert auch.

----------

## root_tux_linux

Habs hinbekommen  :Smile: 

----------

## schotter

 *root_tux_linux wrote:*   

> Habs hinbekommen 

 und wie?

----------

## root_tux_linux

 *schotter wrote:*   

>  *root_tux_linux wrote:*   Habs hinbekommen  und wie?

 

```
gentoo64 ~ # cd /etc/apache2/modules.d/ 
```

```
gentoo64 modules.d # mv 45_mod_dav.conf 45_mod_dav.bak  
```

```
gentoo64 apache2 # cat httpd.conf | grep dav

LoadModule dav_module modules/mod_dav.so

LoadModule dav_fs_module modules/mod_dav_fs.so

LoadModule dav_lock_module modules/mod_dav_lock.so

gentoo64 apache2 #       
```

```
gentoo64 vhosts.d # cat default_vhost.include

# ServerAdmin E-Mail

ServerAdmin root@systemerror.homelinux.org

# ServerName

#ServerName www.example.com:80

ServerName 192.168.1.2

# DocumentRoot

DocumentRoot "/var/www/localhost/htdocs"

# Options for DocumentRoot

<Directory "/var/www/localhost/htdocs">

        Options Indexes FollowSymLinks

        IndexOptions NameWidth=*

        IndexOptions SuppressDescription

        IndexOptions SuppressLastModified

        #IndexOptions SuppressSize

        IndexOptions FancyIndexing

        #IndexOptions HTMLTable

        IndexOptions SuppressColumnsorting

        #IndexOptions IconsAreLinks

        AllowOverride All

        Order allow,deny

        Allow from all

</Directory>

# Alias for cgi-bin

<IfModule alias_module>

        ScriptAlias /cgi-bin/ "/var/www/localhost/cgi-bin/"

</IfModule>

# Option für ScriptAlias cgi-bin

<Directory "/var/www/localhost/cgi-bin">

        AllowOverride None

        Options None

        Order allow,deny

        Allow from all

</Directory>

# Error Messages Alias

Alias  /error  /var/www/localhost/error

# Error Messages Alias Options

<Directory "/var/www/localhost/error">

        AllowOverride none

        Options MultiViews IncludesNoExec FollowSymLinks

        AddType text/html .html

        AddHandler server-parsed .html

        Allow from all

</Directory>

#       "400 Bad Request"

  ErrorDocument  400  /error/400

#       "401 Authorization Required"

  ErrorDocument  401  /error/401

#       "403 Forbidden"

  ErrorDocument  403  /error/403

#        "404 Not Found"

  ErrorDocument  404  /error/404

#       "500 Internal Server Error"

  ErrorDocument  500  /error/500

## BandWidthModule

BandwidthModule On

ForceBandWidthModule On

BandWidth all 80000

## Webdav

<IfModule mod_dav.c>

<IfModule dav_fs_module>

DavLockDB "/var/lib/dav/lockdb"

  <Directory /var/www/localhost/htdocs/webdav>

                Options Indexes MultiViews

                AllowOverride None

                Order allow,deny

                allow from all

        </Directory>

    Alias /uploads /var/www/localhost/htdocs/webdav

    DavMinTimeout 600

        <Location /uploads>

                Options None

                Dav On

                <Limit GET PUT POST DELETE PROPFIND PROPPATCH MKCOL COPY MOVE LOCK UNLOCK>

                        AuthType Basic

                        AuthName "WebDav Restricted Repository"

                        AuthUserFile /var/www/localhost/htdocs/webdav/.davpasswd

                        Require valid-user

                </Limit>

        </Location>

</IfModule>

</IfModule>

gentoo64 vhosts.d #                              
```

```
mkdir /var/www/localhost/htdocs/webdav
```

```
chown apache:apache /var/www/localhost/htdocs/webdav
```

```
htpasswd2 -c /var/www/localhost/htdocs/webdav/.davpasswd USERNAME
```

Irgendwie mochte er die Pfade nicht  :Smile: 

Naja jetzt gehts...

----------

