Enabling WebDAV On Fedora 16

Logo for the Apache HTTPD Server Project .

Image via Wikipedia

Here is how I enabled WebDAV on Fedora 16 (before starting, you need to know how to use a terminal/shell and change into root account from terminal/shell):

  1. I opened up ports 80 and 443 for the firewall
  2. I disabled SELinux
    1. Open up the file vi /etc/sysconfig/selinux by typing in the command vi /etc/sysconfig/selinux as root inside a terminal
    2. Change the line that says SELINUX=enforcing to SELINUX=disabled
    3. Save the /etc/sysconfig/selinux file and get out of vi
    4. Reboot the machine
  3. I installed Apache Web Server
    1. Inside a terminal as root, type in the command yum -y install httpd
    2. Edit the file vi /etc/httpd/conf/httpd.conf by typing in the command vi /etc/httpd/conf/httpd.conf inside a terminal as root user
    3. Change line #43 to ServerTokens Prod
    4. Change line #75 to KeepAlive On
    5. Change line #261 to root@localhost
    6. Change line #275 to ServerName localhost:80
    7. Change line #337 to AllowOverride All
    8. Change line #401 to DirectoryIndex index.html index.php
    9. Change line #535 to ServerSignature Off
    10. Comment out the line #758 to something like this #AdDefaultCharset UTF-8
    11. Save the file /etc/httpd/conf/httpd.conf and get out of vi
    12. Type the command systemctl start httpd.service inside the terminal as root user to start Apache web server
    13. Type the command systemctl enable httpd.service to enable the starting of Apache web server on each fresh boot
    14. Install PHP by typing command yum -y install php php-mbstring php-pear inside a terminal as root user
    15. Type the command systemctl restart httpd.service inside a terminal as root user to restart Apache web server
    16. Configuring SSL for Apache to serve websites in SSL mode (i.e., HTTPS) by installing mod_ssl, so type the command yum -y install mod_ssl inside a terminal as root user
    17. Edit the file vi /etc/httpd/conf.d/ssl.conf by typing in the command vi /etc/httpd/conf.d/ssl.conf inside a terminal as root user
    18. Uncomment the line #78 to DocumentRoot “/var/www/html”
    19. Uncomment the line #79 to ServerName localhost:443
    20. Uncomment line #112 if it’s not yet uncommented, so the line should look like this SSLCertificateFile /etc/pki/tls/certs/localhost.crt
    21. Uncomment the line #119 if it’s not yet uncommented, so the line should look like this SSLCertificateKeyFile /etc/pki/tls/private/localhost.key
    22. Save the file /etc/httpd/conf.d/ssl.conf and get out of vi
    23. Type the command systemctl restart httpd.service to restart the Apache web server
  4. Create WebDAV server/protocol
    1. Inside a terminal as root user, type in the command mkdir /home/WebDAV to create a directory named WebDAV
    2. Change the owner for directory WebDAV by typing in the command chown apache. /home/WebDAV inside a terminal as root user
    3. Change permission for WebDAV directory to 770 by typing in the command chmod 770 /home/WebDAV inside a terminal as root user
    4. Make a webdav.conf file to configure WebDAV server by typing in the command vi /etc/httpd/conf.d/webdav.conf inside a terminal as root user
    5. Type the lines below into the file /etc/httpd/conf.d/webdav.conf using vi editor:
    6. Alias /share /home/WebDAV
    7. <location /share>
    8. DAV On
    9. SSLRequireSSL
    10. Options None
    11. AuthType Basic
    12. AuthName WebDAV
    13. AuthUserFile /etc/httpd/conf/.htpasswd
    14. <LimitExcept GET OPTIONS>
    15. Order allow,deny
    16. Allow from 192.168.1.
    17. Require valid-user
    18. </LimitExcept>
    19. </Location>
    20. Stop typing the stuffs into the file /etc/httpd/conf.d/webdav.conf and save it and get out of vi
    21. Type the command htpasswd -c /etc/httpd/conf/.htpasswd fedora inside a terminal as root user to add password for fedora user to use WebDAV server
    22. You will be asked to create a password and confirm password, so type in the same password twice
    23. Now you need to restart the Apache server by typing in the command systemctl restart httpd.service inside a terminal as root user

Log into the WebDAV server by using https://192.168.1.(enter the last bit of number for your server IP address here)/share.  You will be asked to enter username and password.  The username should be fedora, and the password is the password that you had created earlier.

Troubleshooting:  You should check to see if you can ping your Apache server. Check to see if Apache server has a daemon running (i.e., ps aux | grep httpd).  Check to make sure firewall ports 80 and 443 are opened.  Check to make sure SELinux is disabled.  Check to see the configuration file for httpd.conf is correctly configured.  Check to see the configuration file for webdav.conf is correctly configured.  If permission 770 for /home/WebDAV isn’t working, try to change it to 755 or 777.  Make sure you had enabled SSL for Apache correctly.  If all failed, you might want to reboot Apache and to see if problems could be resolved this way.

Installing Virtualmin On Ubuntu 10.04

New php developers and web designers who are wanting to develop their codes in a test environment, they need to learn how to set up a local server or a local server environment on their laptops and desktops.  It’s a dreaded thing for them to learn even more before they can have a test environment going so they can frequently upload their php scripts and related html codes.  It’s a lot of work!  Not to worry, I know an easier way for you to get a test server environment going!  I’m sure there are even easier ways than mine, but if you haven’t found out a better way yet, why not try my method, right?  So how?  One word, Virtualmin!

What’s Virtualmin?  It’s a control panel of sort that helps you manage your server using LAMP configuration.  For your information, LAMP stands for the combination of technologies involves with Linux, Apache, MySQL, and PHP.  Why is it easy to manage your test server or production server with Virtualmin?  For an example, you can create a new virtualhost account that has FTP access, SSH access, email account, SSL protocol for securing website, and a lot more by just filling out a single web page where you can enter new username and password for the new virtualhost account, check necessary boxes of features that you want your virtualhost account to have, and then accept the creation of your newly virtualhost account with one single last click on the create account button.  It’s simple as that!  It saves you time to open up a terminal, editing various configuration files of Apache, Bind, FTP, MySQL, and so on.  Just like any powerful control panel in the market, Virtualmin has many ways for you to manage your server either in the test environment or in the production environment with ease.

I have created a video which shows you how to install Virtualmin.  Also, in this video, I show you how to create a simple virtualhost account.  Check it out after the break!  Have any feedback or comment for me?  Don’t hesitate to write a feedback or a comment on my video.  I don’t mind if it’s a negative comment, because the more critical you’re, the more that I know you care!

Drupal’s Taxonomy

Not everyone knows how to use Taxonomy in Drupal.  Simply put, Taxonomy is how Drupal allows you create categories.  Watch the video below to see how you can create a category in Drupal using Taxonomy!  My apology on the watermark appears across the video since I’m only using the free version of the ScreenFlow screen recorder software.