apache2

Safari browser won't display Error 401 page.

I'm using Apache 2 and have a custom 401 page, in httpd.conf ErrorDocument 401 /error/unauthorized.html When I access a protected resource, all browsers show the basic http authentication dialog. If I click "cancel", all browsers but Safari (v3 and v4) will display the custom 401 page. Safari just displays the current page. Is there ...

Page anchor with mod_rewrite?

I'm trying to set up page anchors on a website that uses mod_rewrite (Apache2 running on Ubuntu Server 9.04). My htaccess file looks like this: RewriteEngine On RewriteRule ^information.php/([A-Za-z0-9-]+)/?$ information.php?display=$1 [NC,NE] If I was using regular URL's the query would look something like this: http://mydomain/info...

Apache 2 authentication error

Attempting to implement client authentication with an SSL cert, according to this HOWTO, I receive the following errors. Apache: Re-negotiation handshake failed: Not accepted by client!? Firefox: ssl_error_handshake_failure_alert I assume it is a configuration error, but have not been able to locate it. Additional info: Com...

Mercurial push, abort: authorization failed.

I'm having problems with pushing to mercurial repository: $ hg push pushing to https://user:***@hg.domain.com/X_repo searching for changes abort: authorization failed The same URL (with the same credentials) is accessible through the web browser. Also, I tried it without embedding usr+pass into the URL. HTTPS is correctly configured,...

PHP 5.2 and PHP 5.3 side-by-side in vHosts on the same Apache (Debian)?

Possible Duplicate How can one run multiple versions of php5.x on a development lamp server Is there a chance to have various versions of PHP (right now I'd like to have 5.2 and 5.3 side by side) running on the same machine just within different vHosts? I'm running a Debian server and the PHP packages come from dotdeb.org - is ...

HOWTO transfer a request made to an Apache server to an IIS server without using a URL redirect?

My Apache 2.2.9 runs on Debian Lenny 5.0.1 with 2 network interfaces, one interface has a public IP and hostname, the other is not configured. This machine caters to services that run on the LAMP stack. There is a Windows Server 2008 SP2 machine running IIS 7 that serves our ASP.net needs. The box can be configured to be either on a loc...

move_uploaded_file hangs?

I seem to have a bizarre error I just can't quite figure out. My website was working on one server, but when I transferred it to a new one it stopped working. I believe I've narrowed the error down to this line of code: $ret = move_uploaded_file($tmp_name, $orig_path); This is executed through an AJAX call so it's a little bit tricky ...

Apache2 displaying root index.html instead of virtualhost's index.html

I've just set up a new apache 2 install and I'm adding my first virtualhost. I'm seeing some odd behaviour. The virtualhost seems to work, in that if I browse to a URL under the root of my virtualhost in a web browser I get what I expect to see, however if I just go to www.$myhost.com, I get the default apache "It works!" page, which is ...

Throttle download traffic in apache for all users

Hi, Lets say I subdomain called largefiles.domain.com This is on a dedicated server and I can change any configuration. Server runs Apache/2.2.3 (CentOS) How do i restrict all file downloads to just 10Kbps for every file downloaded from the webserver? What is the easiest solution to implement this for the entire subdomain? ...

Mac Leopard - Can't start Apache2 after building SVN1.6.2 from source

Last Thursday I built SVN from source on my Mac running Leopard 10.5.7 so that I could get svn+ssh capability. (For some reason that functionality wasn't available using the binary from Collabnet.) The build was successful and I was able to use SVN afterwords, but apache stopped launching. When I tracked down the error, this is what I'...

Apache2 access restricted to local LAN

Until recently, I had a bunch of virtual sites set up like so: <VirtualHost 127.0.0.1:1234> ... This works fine for testing on my local machine, where I use a Linux desktop. In order to test how MS and explorer displays my pages from my Windows laptop, I changed this to <VirtualHost *:1234> ... Which also works fine, calli...

How do I use Microsoft AD and php single sign on web app?

I'm vaguely aware that on a computer joined to a domain IE can be asked to send some extra headers that I could use to automatically sign on to an application. I've got apache running on a windows server with mod php. I'd like to be able to avoid the user having to log in if necessary. I've found some links talking about kebros and apach...

Apache Reverse Caching Proxy - why isn't it caching?

I am attempting to set up a reverse caching proxy for ad graphics (gif, jpg, swf) serving. The proxying is working fine and sending the request on to the origin server, but I can't seem to figure out why the content isn't being cached. My current config is below. The goal is to cache all requests that match the /ca/ URI prefix. The origi...

Why are Rails and Passenger eating up my memory?

I'm on a 256 slice of Slicehost and running Apache and Passenger to host my Rails app. I've had to do the Hard-Reboot often. When I looked at this Passenger memory stat. --------- Passenger processes --------- ** [out :: welcometonewnepal.com] PID Threads VMSize Private Name ** [out :: welcometonewnepal.com] ------------------...

ImageMagick: convert png fail via PHP and works via bash shell

I've got a very weird bug which I've yet to find a solution. UPDATE see solution below What I am trying to do is convert a full size picture into a 160x120 thumbnail. It works great with jpg and jpeg files of any size, but not with png. ImageMagick command: /opt/local/bin/convert '/WEBSERVER/images/img_0003-192-10.png' -thumbnail x32...

500 Server Error: Infinite rewrite loop in Apache 2.2.x with mod_vhost_alias, VirtualDocumentRoot, and mod_rewrite for routing / "pretty" URLs

I'm running into a problem using Apache's mod_vhost_alias directives and mod_rewrite for routing "pretty URLs" with a local development machine. I know that it's possible to do so, because my hosting provider uses a similar configuration and has no problems. However, whenever I try on my local machine, Apache returns a 500 Internal Serve...

Apache: Block all directories except for listed ones

I want to block people from accessing every directory except for /sandbox, /WebDev and /Projects I tried this: <Directory ^/(?<!sandbox|Projects|WebDev)+(/.*)> Order Deny,Allow Deny from all </Directory> but it gave a 500 error. ...

Exception Errno::EPIPE in Passenger RequestHandler (Broken pipe)

Hi, Upgraded to Rails 2.3.2 and Passenger 2.2.4 on Ubuntu hardy slice at slicehost with Apache2 I'm getting this same above discussed error in my Apache error.log of system /var/logs/apache2/ [ pid=4249 file=ext/apache2/Hooks.cpp:638 time=2009-07-04 11:47:32.752 ]: No data received from the backend application (process 4383) within ...

Is there a practical HTTP Header length limit?

I have a web application that adds contextual information to XmlHttpRequest objects using the setRequestHeader API. I am using a custom header name (e.g. X-Foo) and a JSON structured value. It isn't part of the URL QueryString or POST body because it is meta information about the request. Is there a practical size limit to the header ...

Why doesn't my Perl script start under FastCGI?

I am getting this error in error_log one of my Perl CGI application. I am pretty sure I haven't changed my script at all and all of a sudden i have started getting this error. This is what I see in error_log: [Wed Jul 8 15:18:20 2009] [warn] FastCGI: server "/local/web/test/cgi-bin/test.pl" (pid 17033) terminated by calling exit ...