Apache :: 2.4 Cannot Change Documentroot - Get Error
Sep 25, 2014
I run windows 8.1
Installed Apache 2.4.10 into c:apache24
Apache is run as service
I tried to change documentroot and directory to e:xxx....
When I test localhost/test_apache.html (my own html) I get error
"Forbidden You don't have permission to access / on this server."
Have I changed all needed parameter or is it a real permission problem?
RewriteEngine On RewriteCond %{HTTP_REFERER} !^[url] [NC] RewriteCond %{HTTP_REFERER} !^$ RewriteRule .*.(jpg|jpeg|gif|bmp|png|swf)$ - [F] sounds good so far? ok. i put this file in the root of where all my html files go.
According to what plesk created for me, it is: /var/www/vhosts/mydomain.com/httpdocs
but that just wont work! it just wont!
So i pulled up the /etc/httpd/httpd.conf file and found out that theres two reference to DocumentRoot.
The first one reads:
DocumentRoot "/var/www/html"
and then again a few lines below it
<Directory "/var/www/html">
ok that just doesnt sound right. Because in that directory, /var/www/html is this:
Code: [root@mydomain html]# pwd /var/www/html [root@mydoamin html]# ls -la total 16 drwxr-xr-x 3 root root 4096 Sep 9 04:43 . drwxr-xr-x 9 root root 4096 Jun 26 19:28 .. -rw-r--r-- 1 root root 316 Sep 9 04:43 .htaccess drwxr-xr-x 4 root root 4096 Sep 6 21:24 awstats ya. theres no symlink to /var/www/vhosts/mydomain.com/httpdocs or any reference in the httpd.conf file whatsoever!
So i put the .htaccess file in /var/www/html and the .htaccess hotlinking worked! (as in no one can hotlink from me now)
(I've attached a copy of my httpd.conf file for review)
Lets say you own the .com and .net of a domain name. Are there any consequences to pointing your DocumentRoot of two domains to the same directory? I'm thinking this could mess up your logs, passwords, or general configuration. Let me know if you've had any experience with this.
I'm doing some work for a friend of mine, and he's requested that he be able to have multiple domains refer to the same DocumentRoot (have all the domains load the same pages).
PRODUCT, VERSION, MICROUPDATE, OPERATING SYSTEM, ARCHITECTURE plesk parrells ,12.0.18 ,Update #26 ,centos 7 , 64 bit PROBLEM DESCRIPTION file in documenRoot folder eg httpdocs wont display properly STEPS TO REPRODUCE create a new sLTubscriptions , then ftp files into document root folder using filezilla
[Code] ....
The weird thing is when I put the files into a subdirectory (eg www.example.com/home /) the site itself shows correctly. But when I put the files back into the document root folder(eg httpdocs) it doesn't show correctly. Also no css or javascript error messages show up in the chrome debug window?
i have a problem i have dedicated server with direct admin panel so i was trying to change the skin to see how it looked but what a surprise it kick me out and now its blank and i cant get in to the directadmin panel anymore with this error msg "Error: document not found"
I've been on vacation w/ no internet for only 2 days, just got back today, and my website now has an internal server error. It worked right before I left and now it doesn't, and nothing was added....
Usually everything has been working fine with this .htaccess-file until today. There hasn't been any change on the system.
If you click on the hyperlink to the restricted area the login window appears where you need to type in your username and a password. After typing in these data the following message appears in the browser:
500 Internal Server Error
The server encountered an internal error or misconfigruation and was unable to complete your request. (…)
The apache error log file contains the following message:
Request exceeded the limit of 10 sub request nesting levels due to probable configuration error.
Use 'LimitInternalRecursion' to increase the limit if necessary. Use 'LogLevel debug' to get a backtrace.
The increase of the LimitInternalRecursion does not solve the problem. So I switched the LogLevel in the httpd.conf file from warn to debug and looked again on the entries of the error log.
The following appeared (I have replaced ip addresses, usernames and URL by xyz or <URL>) :
Code:
[error] [client xyz] mod_digest_apple: Client is using a nonce not issued by this server for this context:/rb/Vorlesung/WS12/Downloads/, referer: http:<URL>
One of my customers wants me to change the ownership to nobody and group to apache in a directory created in the home directory of his website. I want to know whether doing so will pose any security problem. Also is there any advantage of changing the owner to nobody and group to apache?
I am trying to change permissions on my perl and CGI files to execute them for my website.
I have a laptop I am using as my server. It has Windows Server 2003. I have Apache, and Active Perl. IIS is disabled. My website loads just fine.. I just cant change the permissions or find out how.
How do I change the permissions on my perl and cgi files?
We have a SAP portal and Apache server in our environment. The URL which users see is like http://portal:50000/irj/portal in some cases after login, from a program we are calling the url http://portal:50000/irj/portal/alias1 in the same window. In this case the URL changes in explorer.
I am trying to find out if I can mask the url and keep it the same as http://portal:50000/irj/portal, but Apache to send calls to SAP server as http://portal:50000/irj/portal/alias1, so the end user cannot see the URL change.
When trying to change the hosting type of a subscription, from website to forwarding or none, that was created before I removed tomcat from the server, I get the error: "Error: tomcatmng failed:".
For subscriptions that where created after I removed the tomcat package (with the updates and upgrades manager/product installer) hosting type changing is no problem.
APache is running under the "nobody" user/group as default in CPanel servers as a suggestion I should change it to another user/group to improve security!
But in CPanel servers its hard to do that because you must edit some scripts and files to prevent the backing to nobody when running some scripts such
And I think everything is working. When openingen 127.0.0.1 I see the apache message that the server is running and when executing phpinfo() it displays the PHP info.
My problem is that I'm trying to change the document root.
After this I did a reboot of the apache server using the CMD httpd -k restart. I even tried restarting using the apachemonitor and rebooted the whole server. But apache still loads the files from c:/Apache24/htdocs
I can't find any more entries with htdocs to change. What am I missing?
Recently I moved my WordPress website to another server, After moving my site I see that my all files permission set to 664, for that I getting many error, now I want change all files permission 644, but problem is I have many subdomain with this site, is there any way to make change all files permission to 644 with SSH or any other way?
I'm running Apache 2.4.7 on a RHEL 6.4 server. I'm using the Oracle WebLogic Proxy Plugin ver 12.c to connect to a back end server.What's happening is that Apache answers URL.. and proxies the request via the WebLogic Proxy Plugin to internal.blah.com. Unfortunately, the downstream system encounters a problem and issues an http 302 redirect to internal.blah.com/whathappened. I would like to have Apache intercept this http 302 and redirect the client to URL...
I'm new to Apache. I'm using a version 2.4 for Windows 7. It didn't come in as an .msi so I had to configure the appropriate web-server name via the httpd text document.
Each time I go to http://localhost, I am present with a page with the content "It works." I tried adding a different .html file into the directory to see if I could access that also, but I was not able to navigate to it via the address bar. So I edited the content of index.html from 'It works!' to "It works?!!!" but sadly, the actual page is still showing 'It works!' for its content (Rather ironic, huh?).
So, for whatever reason, the actual 'localhost' page isn't updating or even noticing any of my edits in what I presume to be the correct directory.
I have a client on a dedicated IP, today we needed to downgrade the web hosting plan. As the web hosting plan puts users on a default shared IP, this plan change also changed the dedicated IP to the shared one causing some propagation issues for a small period of time.
I have contacted WHMCS about this asking if they had a way of changing the clients plan but keeping the IP address intact as this could lead to some very undesirable outcomes. They explained that it is not their fault and to contact Parallels.
I know I can change the plan directly in Plesk however by initiating the plan change via WHMCS, everything is automated.
Has anyone helped clients transition from one domain to another? Maybe dissolving a partnership or renaming their company... so a new domain name has been registered and a new website created.
2 Issues:
#1 Using .htaccess 301 redirect We used the following command line in their old website's htaccess file
Redirect 301 / [url]
The goal was to get people try to visit any page of their old website (i.e. OldWebsite.com/contact.html) redirected to their new website (i.e. NewWebsite.com/contact.html). Isn't that supposed to change the address bar's URL, too? For some reason, I visit their old site and I seem to be redirected to their new website but the address bar still has their old domain name? Something is going on???
#2 Having their new company name for 2 years now. People can enter her new company name in Google, MSN or Yahoo. Her new company name appears in the search results but has the old domain name associated with it. We are trying to get rid of any reference to that old domain name? What's the easiest way to do this? So what people see in search engines is:
New Company Short Meta Description www.OldDomain.com
What steps did I miss in this transition?
What steps do I have to take on their old website/old web server to control it's appearance on search engines and make sure people get to the new website?
I have a few sites that I point to my nameservers, but the accounts aren't set up yet for them.... quite a few actually... and while they might only be on this page for a day or two at most, a few of the sites get quite a bit of traffic.
Can someone please tell me where I can find this HTML file so I can edit and brand my own custom page in place of this "Great Success!" Apache / cPanel default error page?