apache

Can I rely on session availability after redirect to & from another server?

Hi, the question's in the title really. I have an online form where, after a series of stages, the user is sent off to a payment gateway on another server, then back again after completing their details there (no card or personal info is sent, just encrypted tokens, that's the point). So can I rely on the session data still being avail...

Need help converting apache .htaccess code to lighttpd url_rewrite code

Hi All, I have this custom written CMS built on XAMPP. I'm trying to test the same on lighttpd to benchmark the so-called performance gains... but am stuck at the rewrite rules. I use the default rewrite rules of WordPress in my .htaccess which hands all url parsing over to my script as long as there aren't any files or directories sa...

Why does my CGI header print as part of the body?

Hello, I am having a strange problem, maybe something to do with Apache more than Perl. In my code when I write: print "content-type: text/html\n\n"; it prints that along with the code. But when I type: $c = new CGI; $c->header(); it works fine and displays the HTML rendered output. What could the problem be? Thank you ...

Permissions to PHP session files

Hi I have a domain domain.com and subdomain sub.domain.com Those two domains have different ftp users (user1, user2) belonging to the same group (usergroup) on linux environment. Finally I have the same PHP application that uses sessions on both domains (one is live and other is testing environment). When I go to domain.com without go...

How do I configure Apache to forward some URLs to my servlet container regardless if the file exists.

How do I configure Apache to forward a URLa of a certain extension, say *.htm to my Servlet container, in this case, Resin, without first checking for the file's existence. Currently, if Apache can not find the requested file in the directory structure, it serves a 404, even though my web.xml Servlet mapping would handle the request if ...

apache prefork/mod_wsgi spawned process count seemingly past configuration

in a production environment running nginx reversing back to apache mpm-prefork/mod_wsgi, im seeing 90 apache child processes, when i would expect that 40 would be the maximum, as configured below. the configuration/setup is nothing exciting: nginx is reverse proxying to apache via proxy_pass, and serving static media apache only serves...

Stress testing a server and VPS's vs. Dedicated servers

We used to have a dedicated server (1&1) and very infrequently ran into problems with the server having issues. Recently, we migrated to a VPS (Wiredtree.com) with similar specs to our old dedicated server, but notice frequent problems running out of memory, mysql having to restart, etc... both when knowingly running intensive scrips an...

how to change the default encoding to UTF-8 for server

i am using a hosting company and it will list the files in a directory if an index.html is not there. However, it will use iso-8859-1 as the default encoding. if the server is apache, is there a way to change it to use UTF-8 as a default instead? Update: actually, i found that it is actually using a DOCTYPE of HTML 3.2 and then there ...

mod_rewrite vs symlink: the browser is not fooled.

I have a file foo.bar.1 on my server and when I try to access it from a browser (firefox) I get a popup that says "You have chosen to open foo.bar.1 which is a: 1 file ... What should Firefox do with this file...". If I create a symlink to it, foo.dat, I can access it just fine; the contents display in the browser as I expect. My probl...

Apache httpd cluster logging

I have a cluster of Apache httpd servers. It's a load balanced cluster where all nodes serve the same, shared, content. The content itself is located on a shared storage. I would like to setup all nodes to log (server access logs) to the same log file (again on the same shared storage), but I am concerned that this would create concurre...

Uploading a file to an apache server

I've got a java function that generates digital signatures for xml files. Here's an excerpt that is giving me some trouble: String boundary = MultiPartFormOutputStream.createBoundary(); HttpURLConnection urlConn = (HttpURLConnection)MultiPartFormOutputStream.createConnection(new URL(url + "/sign")); urlConn.setRequestProperty("Accept",...

Strip specific parameteters when redirecting with Mod-Rewrite

I have a pretty complex RewriteRule where I need to check if certain parameters are present in QueryString and then redirect to the same URL but with those parameters stripped. How can I remove some parameters and preserve the rest? RewriteCond %{QUERY_STRING} color=red RewriteCond %{QUERY_STRING} status=contiue RewriteRule ^(.*)$ /$1?...

jQuery firefox issue with different servers

Hi. I'm developing a simple voting system for my site with jQuery. When I tested it on my local (own PC server), it all worked fine (on IE, Firefox and Chrome). When I uploaded to my main server, Firefox gave me an error. Considering that Firefox works fine on my local server, it has to do with the difference in servers... This is the ...

mod_rewrite - point css/images/js files to specific directory

On my hosted server, the files are located here: /usr/home/user1/public_html I have to access the files using something like this: http://server1.example.com/user1/ However, all my files use absolute paths to reference CSS / Images / JS files. So, my requests for these assets look like this: http://server1.example.com/images/homepag...

php as apache input filter

Can the php5apache_filter be used as an input filter? Haven't found much documentation for php's filter sapi. ...

How can I set up a reverse proxy with mod_proxy without redirecting?

How can I set up a reverse proxy with mod_proxy without redirecting to another server or IP? This will be a virtual host environment. The reason I want to do this is so that mod_proxy handles the communication with the client's browser thereby freeing up web server processes to serve the next request instead of feeding the client's brow...

EC2onRails + SSL + Apache: No response on port 443

Hi, I'm trying to configure SSL on EC2onrails with no luck. At present I am unable to even telnet into my server at port 443, it simply says "trying MY.IP.ADDRESS..." and stays there indefinitely. Telnet into 80 works fine. This was my starting point: groups.google.com/group/ec2-on-rails-discuss/browse_thread/thread/79b60bf683b2365b (a...

Search and replace in apache htaccess a RewriteRule

I'd basically like to get /path/file+name+with+plusses.mp3 to rewrite to /path/file name with plusses.mp3 In my case wordpress is intercepting the request and giving a 404. But the file does indeed exist. Given the constraints of the regex in mod_rewrite implementation, I haven't yet seen a straightforward way of doing this. ...

running 2 websites with mono

I have 2 websites : myDomain1.com & myDomain2.com Both run on the same apache server with Mono. However my issue is that i cannot get them working at the same time. When i go to myDomain2.com it shows the aspx content of myDomain1.com. Occassiononly this is inversed. So that myDomain1.com shows the content for myDomain2.com. I think th...

Why does Apache Content Negotiation not with files that have a hyphen in the extension?

I am trying to use Apache Content negotiation for localizing my site. I have the files index.htm.en, index.htm.es, index.htm.zh-ch and index.htm.en-GB. Apache content negotiation is not working in the third and fourth case. So is this because of the hyphen(-) in the extension? ...