Web Sharing and vhosts

Hi all
Can some one help with regards to setting up web sharing and vhosts under 10.8.
I have started apache (sudo apachectl start).
I've enabled php and mysql.
I have de hashed (#) Include /private/etc/apache2/extra/httpd-vhosts.conf
I have added my vhost :
127.0.0.1      www.myvhosts.dev
127.0.0.1     myvhost.dev
to the file     /private/etc/hosts
I have also edited the http-vhost.conf file by adding
<VirtualHost *:80>
        DocumentRoot "/Volumes/MacPro RAID/Web Development/myvhost"
        ServerName www.myvhosts.dev
</VirtualHost>
<VirtualHost *:80>
        DocumentRoot "/Volumes/MacPro RAID/Web Development/myvhost"
        ServerName myvhosts.dev
</VirtualHost>
But typing in www.myvhosts.dev or myvhosts.dev takes me straight to google.
Further more http://localhost and http://localhost/~username
both kick out access errors that I have tried to fix with a user.conf file with
<Directory "/Volumes/MacPro\ RAID/stevenwhiteley/Sites">
    Options Indexes MultiViews
    AllowOverride None
    Order allow,deny
    Allow from all
</Directory>
But nothing works.
Any assistance would be most apprecated.
Cheers
Steve

Either move the content to the /Library/WebServer/Documents
directory or create aliases in that directory for the real files.
Dave

Similar Messages

  • Personal Web Sharing and Filemaker Server Advanced

    After migrating from FileMaker Server-7 Advanced and installing version-8 Advanced web components (w/Easy Install) and restarting the Mac, Personal Web Sharing refuses to activate. I also cannot access the Filemaker Admin Console to create the FMSA account to register it with the database server.
    OSX Console log listed this error below when trying to start Apace with Personal Web Sharing:
    Syntax error on line 1 of /Library/FileMaker Server/Web Publishing/web-configuration/WEB-INF/conf/mod_jk.conf:
    Cannot load /usr/libexec/httpd/modjkfm.so into server: (reason unknown)
    /usr/sbin/apachectl start: httpd could not be started
    Line 1 of the mod_jk.file reads:
    LoadModule jkfmmodule libexec/httpd/modjkfm.so
    What needs to be corrected so I can start web sharing and access the FileMaker Web Publishing Engine in the browser?
    Using Mac OSX 10.4.6 on Mac Mini w/Intel dual core

    Apache is trying to load modjkfm.so which should be stored in /usr/libexec/httpd, but it isn't.
    This file should be installed by the Filemaker Server installer. If it wasn't installed by the Easy Install option, check the other install options to see if it's there.

  • Web Sharing and Apache losing connection?

    ok so i just did a fresh install of 10.4 on my server (PowerMac G4 - 350 Mhz) i have set up my web sharing with a few tweaks like turned mod_ssl and installed MySQL. Other than that it's a pretty basic config.
    My problem is that i when i start or restart apache everything works and stays that way for hours as I am updating and testing. I go home at night and come back in the morning and i can not access any of my sites nor the local ip of the server (192.168.0.100) or 127.0.0.1
    so i restart apache and its back up...
    i do have a static IP so I know its not my IP Changing
    any ideas on keeping apache alive?

    What do the logs have to say about it?
    There's nothing anyone here can tell you about why it's stopping - there are just too many posibilities. The server logs, though, might provide some clues.
    Check specifically /var/log/httpd/error_log and /var/log/system.log

  • Issue on Web sharing and XSL files

    Hi all,
    What are the things to be taken care while we are doing websharing. I have an issue with one of my xMII projects. Everything is working fine on that server except xsl files. It is not getting transformed into HTML at run time. It is showing in XML format instead. I really doubt the problem is with my web sharing, because the same set of files(<b>including XSL file</b>) are working on a different server without any issue.
    I have done websharing by right clicking on the folder name, selecting the websharing tab and giving Alias name. Is that ok or anything more as to be done?
    Can anyone please trace out the issue.
    Thanks in advance
    Muzammil P.T

    Hi,
    Webroot is still in c:\inetpub\wwwroot, but i set up a new virtual directory to <b>c:\Lighthammer</b> and accessing xMII using the URL http://*...*/Lighthammer
    and my project contects using http://*...*/Lh/CompApps/MyProj/HomePage.html
    (I have given Lh as the Alias name).
    Here, My xMII homepage is working and myProj Homepage is also working fine. Once i calls the HTML pages which contains XSL files, the problem is coming.
    Please Note: The same contents is working on our different server without any change.
    Regards
    Muzammil

  • Web sharing and apache server down

    Hi all
    Sorry for this noobie question but it's the first time I have this strange behavior
    Today I tried to use my MBP (under Lion 10.7.4) outside of my home in a location where web connection was not permitted.
    I thought I could continue to work on my web project which is at the moment on a localhost server.
    But it was impossible as the web sharing was down and it was impossible to relaunch it through preferences panes.
    did I missed something in my Apache config or somewhere else as I am pretty sure that this behavior should be the correct one it should be possible to have the apache server running even if not connected to the web.?
    Obviously once returned at home and reconnected to the web all going back at normal.
    Thanks in advance for your help
    BR
    BKantique

    Finally I found by myself, apparently I my apache server pointed on the port 80 which once disconnected of the web cause to Apache to be down.
    Changed the port into 8080 and then no issue anymore the Apache server still on once disconnected of the web

  • Web sharing and pop mail access

    I use a mac mini running 10.4 as a wireless router for my macbook pro. I can access the web alright, but I can't seem to access my pop mail account. i.e. mail won't download or send mail. How can I fix this?
    Thanks,
    Chris

    Thanks very much Duane
    That's great. I can now download all my emails, but now can't send any via the smtp server that the mac mini uses happily. Is there a setting I need to change in services or somewhere else?
    Also, Is it safe to have turned off the firewall on the mac mini?
    Thanks again,
    Chris

  • Web Sharing with Leopard 10.5.2 and Airport Extreme Base Station HELP!!!

    Ok...I want to set up web sharing on my computer but so far my attempts have failed.
    I have an intel iMac with Leopard 10.5.2 installed and I have the latest Airport extreme base station (With draft n).
    I turn on web sharing, and of course it works locally but not when trying to be accessed over the internet.
    Now I realize that by default my routers address wont let anyone connect to my computer over the internet.
    My router has an ip of 10.0.1.1, and I assigned my computer a static ip address of 10.0.1.200.
    Now in the network preferences pane and the airport category, i set my computers IP (the 10.0.1.200), I put the gateway as 255.255.255.0, the router as 10.0.1.1 and the DNS as 10.0.1.1
    Now going over to the airport utility I added a new entry in the port mapping section, with port 80 (both public and private) and the IP of my machine, 10.0.1.200.
    Now in theory this should work but NOOOOO.
    Does anyone have the same setup? a wireless network with the new airport extreme base station and has successfully configured Web Sharing?
    Thanks in advance.
    Felipe

    Well here is an update.
    I saw an entry in apple support that said I had to change some setting in the apache folder /etc/apache2 in order to avoid getting the 403 forbidden error. I tried this and it did not work, i checked my user configuration file as well and the path to my home site directory was correct
    Anyone here have a similar setup and has it working? It shouldnt be too hard to set up web sharing through a router. It has to be possible or else a lot of people would not buy a router because of this.
    thanks in advance to anyone kind enough to help
    Bye.

  • Wake on Demand and "Web Sharing"

    Does anyone know if the new Wake on Demand feature is supposed to work with the "web sharing"? It doesn't seem to be working for me. The iMac does wake fine, however, with SSH, file sharing, screen sharing, and printer sharing.

    Hi mcewen. The Wake on Demand feature works with any service being advertised with Bonjour. The caveat with Web Sharing is that it only advertises itself with Bonjour if you've modified one of the default web pages. So all you have to do is go into the Sites folder in your Home directory, and make a change to the index.html file, and then turn off Web Sharing and turn it back on. That should get it to be advertised with Bonjour (you can verify this by going to the Bonjour bookmarks section in Safari to make sure your web page shows up). After that it will support Wake on Demand using Web Sharing.

  • Web Sharing Help

    Hi All
    I have created a website and have uploaded it into /Library/WebServer/Documents/.
    I have turned on web sharing and then opened up safari and directed it to my computer name which is
    {apple.local} wothout the brackets, instead of it bringing up the web page automatically it brings up the Index of page and lists all the folders and files there.
    To make it display the web page i have to type http://apple.local/index.htm
    is there a way to make it automatically open the page instead of typing it in with the extension after it?
    I have about 5 macs in my place and want to be able to allow all to see the page but not everyone know's about html code and dont know about putting /index.htm after the address ?
    Thanks

    Solved the problem now, for some reason the files were called default.htm instead of index.htm
    Apple must have some filter to only search for index.htm
    i changed the main page to index.htm and tried the page name and worked fine
    Cheers anyway

  • Web sharing suddenly stops working

    Hello there!
    I'm using web sharing all the time to stream content from my mac to my ps3. It was always working flawlessly with no issues whatsoever. Today there's no way I can connect to from my ps3 and any other device as well. It's not a password error message I'm just getting a "could not connect to the server" error.
    I opened up the apache 2 server log and I'm getting a variety of errors. I'm not really sure though what they mean.
    If anyone has any ideas please let me know!!
    Here's the log
    "[Sat Dec 05 22:33:07 2009] [notice] caught SIGTERM, shutting down
    [Sat Dec 05 22:33:32 2009] [warn] Init: Session Cache is not configured [hint: SSLSessionCache]
    mod_bonjour: Skipping user 'dk79' - cannot read index file '/Users/dk79/Sites/index.html'.
    [Sat Dec 05 22:33:32 2009] [notice] Digest: generating secret for digest authentication ...
    [Sat Dec 05 22:33:32 2009] [notice] Digest: done
    [Sat Dec 05 22:33:32 2009] [notice] Apache/2.2.13 (Unix) mod_ssl/2.2.13 OpenSSL/0.9.8k DAV/2 PHP/5.3.0 configured -- resuming normal operations
    [Sat Dec 05 22:36:20 2009] [error] [client 192.168.1.3] File does not exist: /Library/WebServer/Documents/favicon.ico, referer: http://192.168.1.3/~dk79/PS3/
    [Sat Dec 05 22:36:21 2009] [error] [client 192.168.1.3] File does not exist: /Library/WebServer/Documents/favicon.ico, referer: http://192.168.1.3/~dk79/PS3/
    [Sat Dec 05 22:36:51 2009] [notice] caught SIGTERM, shutting down
    [Sat Dec 05 22:37:25 2009] [warn] Init: Session Cache is not configured [hint: SSLSessionCache]
    httpd: aprsockaddr_infoget() failed for dk79.local
    httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
    mod_bonjour: Skipping user 'dk79' - cannot read index file '/Users/dk79/Sites/index.html'.
    [Sat Dec 05 22:37:25 2009] [notice] Digest: generating secret for digest authentication ...
    [Sat Dec 05 22:37:25 2009] [notice] Digest: done
    [Sat Dec 05 22:37:25 2009] [notice] Apache/2.2.13 (Unix) mod_ssl/2.2.13 OpenSSL/0.9.8k DAV/2 PHP/5.3.0 configured -- resuming normal operations

    I too am getting the same problem. Web Sharing WAS fine now I get the following message:
    NOTE ~myusername has been substituted to avoid confusion.
    Error!
    Could not connect to remote server
    You tried to access the address http://192.168.1.253/~myusername/, which is currently unavailable. Please make sure that the Web address (URL) is correctly spelled and punctuated, then try reloading the page.
    Using Terminal I get:
    /usr/sbin/apachectl configtest
    Syntax OK
    ls -l /usr/sbin/apachectl
    -rwxr-xr-x 1 root wheel 3640 24 sep 2007 /usr/sbin/apachectl
    which apachectl
    /usr/sbin/apachectl
    -bash: /private/etc/apache2/users/myusername.conf: Permission denied
    NOTE (this test is being run from user a/c quentin
    NOTE (this test seems to be picking up a website in "Sites" directory called Q-website_NEW this website is currently running live on the www)
    tail /var/log/apache2/error_log
    [Mon Dec 14 22:05:10 2009] [warn] Init: Session Cache is not configured [hint: SSLSessionCache]
    mod_bonjour: Skipping user 'myusername' - cannot read index file '/Users/myusername/Sites/index.html'.
    [Mon Dec 14 22:05:10 2009] [notice] Digest: generating secret for digest authentication ...
    [Mon Dec 14 22:05:10 2009] [notice] Digest: done
    [Mon Dec 14 22:05:10 2009] [notice] Apache/2.2.13 (Unix) mod_ssl/2.2.13 OpenSSL/0.9.7l DAV/2 configured -- resuming normal operations
    [Mon Dec 14 22:05:42 2009] [error] [client 192.168.1.253] File does not exist: /Library/WebServer/Documents/favicon.ico, referer: http://192.168.1.253/~myusername/
    [Mon Dec 14 22:07:13 2009] [error] [client 192.168.1.253] File does not exist: /Users/myusername/Sites/Q-websiteNEW/siteassets/Bgnd.png, referer: http://192.168.1.253/~myusername/Q-website_NEW/index.htm
    [Mon Dec 14 22:07:33 2009] [error] [client 192.168.1.253] File does not exist: /Users/myusername/Sites/Q-websiteNEW/siteassets/Bgnd.png, referer: http://192.168.1.253/~myusername/Q-websiteNEW/indexes.htm
    [Mon Dec 14 22:07:43 2009] [error] [client 192.168.1.253] File does not exist: /Users/myusername/Sites/Q-websiteNEW/siteassets/Bgnd.png, referer: http://192.168.1.253/~myusername/Q-websiteNEW/indexfi.htm
    [Mon Dec 14 22:10:26 2009] [notice] caught SIGTERM, shutting down
    quentin:~ myusername$
    quentin:~ myusername$ tail -f /var/log/apache2/error_log
    [Mon Dec 14 22:05:10 2009] [warn] Init: Session Cache is not configured [hint: SSLSessionCache]
    mod_bonjour: Skipping user 'myusername' - cannot read index file '/Users/myusername/Sites/index.html'.
    [Mon Dec 14 22:05:10 2009] [notice] Digest: generating secret for digest authentication ...
    [Mon Dec 14 22:05:10 2009] [notice] Digest: done
    [Mon Dec 14 22:05:10 2009] [notice] Apache/2.2.13 (Unix) mod_ssl/2.2.13 OpenSSL/0.9.7l DAV/2 configured -- resuming normal operations
    [Mon Dec 14 22:05:42 2009] [error] [client 192.168.1.253] File does not exist: /Library/WebServer/Documents/favicon.ico, referer: http://192.168.1.253/~myusername/
    [Mon Dec 14 22:07:13 2009] [error] [client 192.168.1.253] File does not exist: /Users/myusername/Sites/Q-websiteNEW/siteassets/Bgnd.png, referer: http://192.168.1.253/~myusername/Q-website_NEW/index.htm
    [Mon Dec 14 22:07:33 2009] [error] [client 192.168.1.253] File does not exist: /Users/myusername/Sites/Q-websiteNEW/siteassets/Bgnd.png, referer: http://192.168.1.253/~myusername/Q-websiteNEW/indexes.htm
    [Mon Dec 14 22:07:43 2009] [error] [client 192.168.1.253] File does not exist: /Users/myusername/Sites/Q-websiteNEW/siteassets/Bgnd.png, referer: http://192.168.1.253/~myusername/Q-websiteNEW/indexfi.htm
    [Mon Dec 14 22:10:26 2009] [notice] caught SIGTERM, shutting down
    I have tried re-editing the myusername.conf file thus:
    <Directory "/Users/myusername/Sites/">
    Options Indexes MultiViews
    AllowOverride None
    Order allow,deny
    Allow from all
    </Directory>
    and have replaced it in the directory
    /etc/apache2/users/
    then I ran the command
    sudo chown root:wheel /etc/apache2/users/shortname.conf
    with this result
    quentin:~ myusername$ sudo chown root:wheel /etc/apache2/users/shortname.conf
    Password:
    chown: /etc/apache2/users/shortname.conf: No such file or directory
    quentin:~ myusername$
    NOTE please remember "myusername" has been substituted to avoid confusion.
    I am still unable to access my web sharing and am still getting the error message quoted at the start of this post.
    I would greatly appreciate any advice as I am currently trying to implement php and MySQL on this machine.

  • Web Sharing broke

    I've been using Web Sharing with php enabled to work on my webpage. Lately my macbook lost power and when I booted it back up the server seems to have stopped working. I've tried restarting, turning off web sharing and turning it back on. typing "sudo apachectl restart" in the terminal. It looks like everything is ok until I actually go to view the page. Chrome says that it could not connect to the IP. I can't access any of the files in my "Sites" folder.
    Is there any way to reset the apache server? or even find some kind of info on what the error is?

    Figured it out. silly mistake. My local IP had changed when I restarted.

  • Web Sharing starting up....

    Hi all
    I'm a newbie that would like to learn the basics of PHP and web applications.
    I've followed instructions and upgraded the current php on my system. I used the terminal and followed step by step instructions as i have no idea what i'm doing with that application, and coding. I tried to test a simple php file (that tells you the current date/time) in dreamweaver (soon after) and it didn't work. =(
    Well, After following more and more instructions i find my machine with a new oracle user, some sw folder with an application called fink inside it, and all sorts of little files and stuffed folders that seemed to do nothing positive for my current goal.
    I found out shortly after that i probably, simply didn't have apache up and running so once again i've folowed instruction but i've got the following issue: I'm trying to get the apache to start up by clicking the Personal Web Sharing 'start' button in the Sharing area in the System Preferences. The button works, it all goes grey which tells me that it's doing something... but unfortuantely nothing seems to be happenning. I've been through the forums and followed many terminal instructions that have been given to people with the same issues but nothing seems to be working.
    I've gone to work with all the most recent instructions and simply by using the terminal to get rid of a few #'s to get its native php kick started, and pressing that start up web sharing button in the preferences, seems to have worked fine. I haven't tested that .php file to test if its worked or not, but the Web Sharing started with no issues.
    I guess i'm a little worried that with all this tweaking and upgrading of my system that i may have i killed my chances at getting this php working on my imac, and probably injured it in other ways too.
    Can anyone give me any hints as to what i've managed to do to my machine and how i may be able to fix anything that i may have broken.
    If my novice terminology isn't helping much, i do apologise and if anyone out there is willing to help me out i'll do my best to make this all make sense.
    Nev
    imac   Mac OS X (10.4.7)  

    Hi Rick
    right.. I've been on php.net
    Gone into the intro section... copied the script from http://uk3.php.net/manual/en/introduction.php into a blank dreamweaver file. saved it as index.php and previewed the file in my safari window staright from dreamweaver (which has a root of file:///Users/.......htm)
    I get a blank screen (so i guess that means its not reading the php)
    I tried testing it locally from my works ftp area... same deal (root was like www...../test/Index.php)
    I've also tried just typing in http://192/168/0/19/~Byron/ and that isn't even showing the normal file that used to show up as standard (from the sites folder)
    which is why i'm thinking i've done something bad...
    My firewall's off =)
    It's not starting up the Personal Web Sharing (and i reckon thats the problem)
    When im just doing normal html static sites in DW its fine.. no problems with viewing locally at all. Its as soon as i introduce server technology (php) that it becomes un-viewable. (well it loads the file... it just doesn't read anything thats on it).
    Yeah its just in the Local area. I'm just trying to view pages locally, on the machine that created the files. Then upload them to the ftp server later on, once i've got it all running properly.
    Php wouldn't have NEEDED upgrading, it was just one of the things that php.net said would have been a good idea for me to do. (so i followed the advice from their site) Now i think about it, i actually upgraded php (from that site) before i found out how to unlock the native php from the system.
    Would that effect anything?
    imac   Mac OS X (10.4.7)  

  • Web Sharing + Remote mysql Access

    Hey! I just had a quick question.
    I'm a developer and I was wondering how to enable Web Sharing to allow my PHP code to access mysql databases remotely.
    Currently, my web sharing and php and stuff like that work great, but I get the following error whenever I try to connect to a database.
    "Warning: mysql_connect() [function.mysql-connect]: Can't connect to local MySQL server through socket '/private/tmp/mysql.sock' (2) in /Users/matt/Sites/bio/web/dbconnect.php on line 2
    Could not connect: Can't connect to local MySQL server through socket '/private/tmp/mysql.sock' (2)"
    I'm pretty saavy with software, but anything dealing with firmware or hardware, I am very much humbled. Can someone please help with enabling access to connect to a remote mysql database?
    Thanks so much.

    Nah I haven't actually physically installed it on my computer. I didn't think I had to install it, since I already actually have the database built that I want to connect to.
    Should I install it, then?

  • Web Sharing Issues... No PHP support

    Good morning all, I guess it's fair to say that we are having problems with PHP, but I'm curious to see if anyone is having the same issues that I am... here is the story:
    I have two Mac's, a powerbook G4, and a powermac G5. I decide to wipe the hard-drive and start fresh with my G4 so when I got leopard I got my chance.
    The install went pretty smoothy, and I'm enjoying the OS quite a lot and look forward to when I have a better Idea as to what I'm doing. On this device I was able to get MySQL server running (after I installed the wrong bit - G4 is not 64bit... do'h) but I got it up and running and can connect to my web server's database.
    With my G5 I did the standard upgrade, but here is where I wish I would have held off on that upgrade for a few weeks. When I turn on Web Sharing, and try to navigate out to http://computername.home/~Brian/ I get the message that says that I do not have permissions to access this Server...
    I do the same thing on the G4 and it works just fine, as I can't install PHP on it yet... Anyway, I've called Apple and made them aware of the issue, and I think I'm going to try some things in the terminal to perhaps turn off PHP or turn it on (apple's version of it) to see if that will let me access my web-server as now when I'm working on my website it won't let me access my MySQL etc...
    Anyway, did anyone else run into this same issue?
    Thank you,
    Brian
    http://www.comicearth.com

    I had the same/similar problems to start with.
    If your issues are the same as mine it is because Apache has been upgraded from 1.3 to 2.2.
    The thread with the details (and solution) is:-
    http://discussions.apple.com/message.jspa?messageID=5649480#5649480

  • Web sharing starts but will not turn off

    I have enabled web sharing and been running successfully for a long time, recently upgraded to Lion.
    The problem I have now is that I can turn Apache on through the Web Sharing prefs but it will not turn off, technically that not true as the instance is killed off but something is restarting the httpd processes (new pid's). As far as the Pref pane is concerned Apache is off (un checked box), though in reality, a new instance is running.
    The only way to turn it off is by su apachectl stop.
    Any ideas?
    Thanks,
    Adam.

    Have you tried to hold down the sleep and home keys for about 20 seconds or so, until you see a silver apple. See if you can get it to reboot.

Maybe you are looking for