LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   cant access second hard drive with apache on my Ubuntu 14.04 server (https://www.linuxquestions.org/questions/linux-newbie-8/cant-access-second-hard-drive-with-apache-on-my-ubuntu-14-04-server-4175523159/)

Galahad 10-23-2014 03:38 PM

cant access second hard drive with apache on my Ubuntu 14.04 server
 
I installed a 3TB storage drive on my Ubuntu 14.04 as im using this as a media server and serving some large files I ran out of space I have mounted it at /media/root/"uuid"/ the issue im having is its restricted access I get the "You don't have permission to access / on this server" msg I have tried to change permissions but this seems to have no effect I think because you cant give public permissions to the media folder.
Q should this be mounted in a diff way or spot for this?
I simply need to server web pages from the /var/www/ of the second storage drive please let me know what you think or if you want more info
thanks

yancek 10-23-2014 06:27 PM

I'm not sure what you are doing. You say you have /var/www on the storage drive and that you have files under /media/root/uuid. What do you have your document root set to in the apache configuration file and who is the owner:group for the /media sub-directory? Did you create the /root sub-directory there? On my Ubuntu, I have sub-directories for users but none for root.

Galahad 10-23-2014 07:58 PM

thanks for the reply
so I created the /var/www/ directory on the second hdd I guess this is not set as the document root in apache however I did not think it needed to be if using symlinks but this seemed to not work as well (im new here but I would think I should be able to serve documents from more than one place) I certainly can try to change the apache root if needed as far as owner and permissions I have changed this around a bit a few times never seems to make a diff I have tried chmod with 777 just to test and also set the drive/directory with group www-data, nogroup and other sugestions ive seen on forums I have also unmounted and mounted the drive sevral times in diff spots same affect im sure this is just simple misconfiguration on my part, as far as the question of what im trying to do I simply need to serve my content from a drive that is not the os drive if a document root change is somehow needed im good with that

thanks again for the reply and any advice or support you offer.

Galahad 10-23-2014 10:16 PM

resolved
 
ok so I seem to have resolved this issue I know feel kind of dumb but this is what worked for me
I edited fstab to place my new drive mount point as
/dev/sdc1 /var/www/c84ef2b5-9636-42a0-9470-9c3315942a67 ext4 nosuid,uhelper=udisks2,nodev 0 0 I listed this as nobody nogroup for permissions
I then edited apache to document root accordingly and it seemed to serve my pages fine
not sure why it took me 2 months to do this again thank you for your help
I can only assume it was the actual mount point that caused the issue.


All times are GMT -5. The time now is 05:36 PM.