My Blog

contains PHP and other web related content. (Sometimes there are some off topic things - don't freak out!)

Archive for the ‘apache’ Category

mod_unique_id error after installing mod_security

Thursday, November 5th, 2009

After installing my mod_security module for apache, I could not restart my apache server. I kept getting the following error:

[alert] (EAI 2)Name or service not known: mod_unique_id: unable to find IPv4 address of "mn-ws"

In this case, mn-ws was the host name of my computer.

This is a pretty simple fix, but I’ll document it anyway. The issue was that my host name was not looking up to my server.

First, I executed the hostname command. This reported back ‘mn-ws’ properly. Then, I tried to ping mn-ws with no reply. I finally put an entry in the /etc/hosts file with the following content:

127.0.0.1 mn-ws

This solved the issue and mod_security would now allow the server to start. Pretty simple.

Eclipse PDT: Integrating Apache Bench for load testing

Friday, January 23rd, 2009

When I use an IDE, I expect for it to do everything I need for my project, from start to finish. As you may have read in earlier entries, I enjoy using Eclipse PDT. I think its time to include load testing into my arsenal of tools inside of eclipse. I’m going to focus on apache’s AB for this article.

(more…)

Cross Domain AJAX – A quick anatomy of a mashup

Wednesday, September 19th, 2007

So after searching the Internet for some cross domain AJAX stuff, I noticed two interesting articles. The first was the specifics of writing these queries (located here). Then, the next gave a breakdown of how this might be useful in a mash-up collaborative sense (here).

The one missing point was how the collaboration should occur. There is talk about same parent domain but I think everyone’s forgetting about the DNS/webserver changes that need to happen.

In order to prove my concept on my windows box, I set up the examples. In that previous example, domain D had a subdomain of D_s which pointed to E.

I determined what the IP address of E was and entered that into my hosts file (I don’t have access to a DNS server at the moment) followed by the subdomain D_s.

Next, using apache, I found the virtual host for E, and put in ‘ServerAlias D_s’. This will make sure that the incoming connection to that IP will also respond to that sub domain.

I just wanted to jot this down to help fill in the hole I noticed. :)

Pass PHP session to a new script using fsockopen

Thursday, September 6th, 2007

I was working on a script that opened up a new connection to the same server with fsockopen to process a php script. It passed the variables needed through GET and then gathered the output. Finally, it displayed the output on the screen under the current context.

I ran into an issue where now I needed to set a session variable in my calling script, but make the same session information available to the called script (the called script starts its own session too).

This is how I did it:

(more…)

Security Issue with Subversion Deployment?

Wednesday, July 4th, 2007

I use Subversion (SVN) for source control and deployment both for JEMDiary and at (“the triangle”). While working on my local copy of one of the websites, I got to thinking about the .svn folder and all of its files. The .svn folder is a local cache/db of the file changes in order to support diffs, reverts, and to give cues about file changes and the need to commit. I started poking around inside of the folder – and discovered the text-base folder. Inside of there, every one of my recently changed files were in there with an extension of .svn-base. Could this be a security issue – was I showing my code to the whole world? Lets figure this out:

(more…)

  • twitter loader

Follow me on twitter: @aaronsaray

The views on this website are my own and do not reflect the opinions of my employer or clients.
Creative Commons License Home | Open Source | Book | Music | Art | Bio | Resume | Contact
My Baby