Browsed by
Author: utdream

Methods to address a slow Tomcat/Railo/Lucee startup

Methods to address a slow Tomcat/Railo/Lucee startup

Recently my technicians and I encountered an issue with a hosting customer who had an interesting situation between two VPS Accounts that he owns. The first VPS had a relatively quick startup time (under a minute), and the second VPS had an extremely slow startup time (above 5 minutes). Both VM’s were relatively similar, and both served a great number of sites. The following are the two options that corrected the issue: OPTION 1 Set property in TOMCAT_HOME/conf/catalina.properties: org.apache.catalina.startup.ContextConfig.jarsToSkip=*.jar This…

Read More Read More

Railo/Lucee CGI remote_addr/remote_host says 127.0.0.1

Railo/Lucee CGI remote_addr/remote_host says 127.0.0.1

When installed on to a Linux/Apache machine, the Railo installers will install mod_proxy_http as the default connector for Apache to Tomcat/Railo. The result is the same as you’d get with any other proxy, where the remote host is replaced with the address of the proxy (in this case 127.0.0.1) and the original requester’s IP address is placed in the “X-Forward-For” header. If you need to find the original requestors IP address you can accomplish this in one of two easy…

Read More Read More

Apache 2.4 – 403 Forbidden (AH01630: client denied by server configuration)

Apache 2.4 – 403 Forbidden (AH01630: client denied by server configuration)

I recently updated one of my development machines to Ubuntu 13.10 which now uses Apache 2.4 by default. In my case, I had updated a machine that was previously running Ubuntu version 13.04 and had been running Apache 2.2. After the upgrade, I was disturbed to find that none of my sites worked! I kept getting Apache 403 (Forbidden) error messages. I figured the upgrade had changed my configurations or something… but after fruitlessly messing with the config files (and…

Read More Read More

Resetting Pulseaudio on Ubuntu 13.04 (new sound card)

Resetting Pulseaudio on Ubuntu 13.04 (new sound card)

I’ve been having a huge number of issues with both my sound and my video drivers since upgrading to Ubuntu 13.04. The problem is that my hardware is getting older, and the drivers aren’t always “up to snuff” with the latest builds. I understand that hardware evolves and in order to remain current with the latest hardware, backwards compatibility isn’t always on the top of everyone’s priority list. I’m not mad at anyone about this, but it means that I…

Read More Read More

Howto: Mass Rename File Extensions in Linux/BASH

Howto: Mass Rename File Extensions in Linux/BASH

Just recently I had a bunch of HTML files (files with a .html extension) that I wanted to rename to .cfm so that they would be interpreted by a CFML engine. To do this, I created a quick BASH loop and ran it directly in the command line: for i in *.html; do mv $i `basename $i html`cfm; done The semi-colons at the end of the first two lines will tell bash that you want to enter more commands, and…

Read More Read More

BASH Execute a Command in a Variable – with Quotes!

BASH Execute a Command in a Variable – with Quotes!

Just recently I encountered a situation where I was using a BASH script to evaluate some input and then pass a boat-load of parameters to another executable. It just so happened that one of the parameters I was pasisng was a variable that had a space in it. So… –myvar “my spacey attribute”. This command would work great when I ran the command myself, but as soon as I tried to execute the command in my BASH script, the blasted…

Read More Read More

scp “command not found” CentOS 6 / Ubuntu 12

scp “command not found” CentOS 6 / Ubuntu 12

I run Ubuntu 12.04 64-bit as my local Desktop OS. I’ve run the “SCP” command multiple times to multiple machines from my own PC when I’m moving files around, but for some reason when I tried to SCP, I got the following error: dream@dream-C32A-H9:~/Downloads$ scp myfile.zip root@myserver.viviotech.net:/root root@myserver.viviotech.net’s password: bash: scp: command not found lost connection Okay… so that doesn’t make any sense. I use SCP all the time. What is *really* going on here? To find out, I ran…

Read More Read More

yum “Couldn’t resolve host ‘mirrorlist.centos.org'” in CentOS

yum “Couldn’t resolve host ‘mirrorlist.centos.org'” in CentOS

I ran into an issue recently where I could ping URL’s just fine, but when I ran the “yum update” command yum could not resolve anything. I would get error messages like the following: [root@viviotech ~]# yum -y update Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile Could not retrieve mirrorlist http://mirrorlist.centos.org/?release=6&arch=x86_64&repo=os error was 14: PYCURL ERROR 6 – “Couldn’t resolve host ‘mirrorlist.centos.org'” Error: Cannot find a valid baseurl for repo: base After a bit of digging, and absolutely…

Read More Read More

How To Fix Windows Java Error 1723

How To Fix Windows Java Error 1723

Just recently I experienced a problem with both installing or uninstalling Java (the JRE) on a Windows 2003 system. I had to research this quite a bit and there were no clear answers anywhere, so I though I’d post here on how I was able to fix it. In my case, I was using Windows Server 2003 64-bit, but this should apply to other Windows versions as well. The error I was getting was as follows: “Error 1723. There is…

Read More Read More

BASH – Generate a Random String

BASH – Generate a Random String

In a recent project, I needed a function that would generate a random string for me. In my case, I was creating a random file name to store some data, but there are other uses as well, so I am posting the BASH code here in the hope that it will help others out there on the net writing BASH scripts and need a good random string function: Save this to a script file (I called mine rand.sh) using the…

Read More Read More