# apache /Webdav setup problems

## Wallsandfences

Hi,

I try to get apache/webdav working. I installed it with:

USE="ssl -debug -doc -ldap (-selinux) -static -suexec -threads" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation proxy rewrite setenvif speling status unique_id userdir usertrack vhost_alias -asis -auth_digest -authn_dbd -cern_meta -cgi -cgid -charset_lite -dbd -dumpio -ident -imagemap -log_forensic -proxy_ajp -proxy_balancer -proxy_connect -proxy_ftp -proxy_http -substitute -version" APACHE2_MPMS="-event -itk -peruser -prefork -worker" 0 kB

If I now start apache, I get:

/etc/conf.d/apache2: line 13: DAV: command not found

 * apache2 has detected an error in your setup:

Syntax error on line 90 of /etc/apache2/modules.d/00_default_settings.conf:

Invalid command 'Order', perhaps misspelled or defined by a module not included in the server configuration

Line 13 is: DAV          Enables mod_dav, line 90 is: Order deny,allow

For now, I just want to know if my USE-flags set up properly for apache to run with webdav and ssl.

Thanks!

Rüdiger

----------

## Mousee

Take a look at this guide:  http://en.gentoo-wiki.com/wiki/WebDav

Basically, you'll want to add the following to /etc/conf.d/apache2

```

APACHE2_OPTS="${APACHE2_OPTS} -D DAV -D DAV_FS"

```

(You can simply add that to a new line under the original "APACHE2_OPTS" line, as it will simply "add on" the options from there as well).

----------

## Wallsandfences

Thanks Moussee,

I already (tried to) follow the wiki, and have /etc/conf.d/apache2 already altered. The error sitll persists.

Thanks,

Rüdiger

----------

## Mousee

Hmmm, interesting. Have you run a "dispatch-conf" to determine if there's any config files for apache that need to be updated?

I ask as several module lines were changed in Apache-2.2 and, judging from your error, it sounds like mod_access is currently not enabled (which is why you're getting that "Invalid command 'Order'..." bit).

After running dispatch-conf, if it doesn't return any config files to be updated for Apache, I would suggest checking your /etc/apache2/httpd.conf file and see if mod_access, at the very least, is being loaded properly.

----------

## Wallsandfences

afaik, mod_access is no longer in use, and now authz_host is used.

The USE flags I posted above where taken from the wiki, btw. But it seems that it doesn't match my setup.

Rüdiger

----------

## Wallsandfences

trying to follow the wiki further I run into new errors:

```

/etc/ssl/misc/CA.pl -newca

CA certificate filename (or enter to create)

Making CA certificate ...

3075229320:error:0E079065:configuration file routines:DEF_LOAD_BIO:missing equal sign:conf_def.c:362:line 356

3075094152:error:0E079065:configuration file routines:DEF_LOAD_BIO:missing equal sign:conf_def.c:362:line 356

```

There is definitly something unexpected going on. But where to look at?

Rüdiger

----------

## Wallsandfences

Good morning....

at least, I was successful to get apache up and running via unmerge/emerge. However, webdav still fails to work, and the wiki is far too lean for my skill-level.

I followed all the steps thoroughly without the ssl-part and I still get an error message from davfs2 running on the other computer.

So, what to check and how to debug the apache/webdav install?

Rüdiger

----------

## Wallsandfences

A bit of progress:

I can connect to my webdav server and execute the 'ls' - command. And that's it. If I try to cp a file, apache's error_log states:

```
Could not LOCK /example.wav due to a failed precondition (e.g. other locks).  [423, #0]

[Sat Jan 08 12:29:16 2011] [error] [client 192.168.0.136] (2)No such file or directory: Existing lock(s) on the requested resource prevent an exclusive lock.  [423, #0]
```

I have set all permissions I could poosibly trace down to be relevant to 777, and a lockfile exists and seems to work.

I'm seriously running out of ideas what to try!

Thanks,

Rüdiger[/code]

----------

