Plesk and WebDav

Need to get WebDav running on a directory within a domain hosted on Plesk 8.4 for Linux (Fedora 8).

These URLs were helpful:

Created the following files: /var/www/vhost/ and /var/www/vhost/

And populated them with:

# vhost.conf
Alias /webdav_directory /var/www/vhosts/
<Location /managementdocs>
Options +Indexes


# vhost_ssl.conf
Alias /webdav_directory /var/www/vhosts/
<Location /managementdocs>
Options +Indexes

Obviously you don’t need both as you may just want it accessible via HTTPs.

Then, rebuilt the Plesk webserver configuration file with the following command:  /usr/local/psa/admin/sbin/websrvmng –reconfigure-vhost –

This appeared to work and allowed adding the URL via windows “Add new network place”.

Other commands we issued (allowing read/write from the apache/psacln user – could possibly do this with chmod 2775?):

 chmod 777 /var/www/vhosts/

Also, you probably don’t want it accessible from anyone and everyone.  You can add password authentication via the Plesk interface using protected directories.

PHP 4 apache module, Fedora 8 and Plesk 9

Some sites still require PHP 4 and for some reason do not work with PHP 5 and may not have the time to upgrade the scripts.

Useful links:

Download the latest PHP 4 source code from PHP.NET.

  • Make the directory: mkdir -p /opt/php-4.4.9
  • wget
  • tar -zxvf php-4.4.9.tar.gz
  • mv php-4.4.9 source
  • The configure statement used in this case was:
    ./configure –prefix=/opt/php-4.4.9/ –enable-versioning –with-layout=GNU –enable-libxml –with-libxml-dir=/usr/ –enable-reflection –enable-fastcgi –with-apxs2=/usr/sbin/apxs –with-regex=php –with-zend-vm=CALL –with-mysql=/usr –with-imap –enable-ftp –with-gd=/usr –with-pcre-regex=/usr –with-kerberos –with-imap-ssl –enable-memory-limit=yes –with-pear –with-zlib –enable-calendar –with-expat –with-png-dir=/usr –with-jpeg-dir=/usr –with-zlib-dir=/usr –with-freetype-dir=/usr –enable-sysvsem –enable-sysvshm –enable-exif –with-curl –enable-mbstring –enable-zend-multibyte –with-tiff-dir=/usr –with-gettext –enable-xml –with-ssl –with-mcrypt=../libmcrypt –with-mhash=../libmhash
  • If there were no problems: make && make install
  • Then, comment out the following line in: /etc/httpd/conf/httpd.conf
    #LoadModule php4_module        /usr/lib/httpd/modules/
  • In /etc/httpd/conf.d/php.conf comment out the PHP5 module and enable the PHP4 module:
    ##LoadModule php5_module modules/
    LoadModule php4_module        /usr/lib/httpd/modules/
  • The restart apache and check the websites: service httpd restart

This allows PHP4 to be ran as a module, however, if you want to use PHP5 you can use it via CGI in the Plesk 9 domain setting.