2

How do I properly address disk partitions Server 11.04 and Apache2 I have not found any information (must be looking in the wrong places) from the terminal window.

Example: say define a directory path to another partion and directory as DocumentRoot in VirtualHost.

  • Could you refine your example a bit more to make it clearer what you are trying to do? – Brian Jul 10 '11 at 4:01
  • Brian Hello I wish to define a path to another partition and Directory – Gordon McIntosh Jul 10 '11 at 4:33
1

I'm still not sure I understand, but each virtualhost can only have one document root. You can either create another virtualhost, or you can do something like create a symbolic link in the current root to the new one.. (for example, symbolically link the directory /var/www/html/pics/ to /pictures/)

  • Ok thanks Brian lets see if this is better two partitions /dev/sdb3 and /dev/sdb4 the O/S is on 3 and I wish to get to a directory /home/public_html on 4 and a file name index.html on 4 in public_html how should I code the path? – Gordon McIntosh Jul 10 '11 at 10:49
  • Partitions in linux are a very different concept than windows. You can mount a partition anywhere, for instance, to /home/public_html, or to /web/html/ or wherever you want. You would use the mount command (and possibly /etc/fstab) to setup where you wanted to mount up to, and then just copy your files there. It is not good to address files by the partitons, (for example, /dev/sdb4/index.html is bad.. mounting it to and then accessing from /home/public_html/index.html is good) You would just set the document root in the virtual directory of your httpd.conf – Brian Jul 12 '11 at 2:39
  • Thanks Brian that has answered my question much appreciated – Gordon McIntosh Jul 13 '11 at 5:31

Not the answer you're looking for? Browse other questions tagged or ask your own question.