-
Hide sqlldr Oracle Password in PS Command
Our internal audit team has raised an issue on some scripts exposing database user, password and tns. You see, all you need is an access to unix shell and run ps command and you’ll be able to get the user id and password of the database. On the otherhand, there’s not a lot of people…
-
How to Get The First File in Unix
In case you are looking files using ls or find command and only want to get the first file found, the command would be like. ls -l /any/path/filename*|sed -e ‘s///,/g’|awk -F “,” ‘{print $NF}’|head -1 Of course, you can also use it in find command. find /any/path/ -name “filename*” -type f|sed -e ‘s///,/g’|awk -F “,”…
-
How to Display Seconds in Unix File Timestamp
Apparently, there’s no native shell command to show the seconds portion of a unix file timestamp. The nearest to this functionality is stat. However, it’s not always available in unix systems. I’m using HP-UX and it’s not installed on our server. Instead, I needed to use a one-line perl program shown below. perl -e .foreach(@ARGV){$t…
-
SpotVPS First Impressions
After the unfortunate incident last week with NordicVPS, I decided to look for a new VPS host. As usual, I went to lowendbox and get the reviews in webhostingtalk. It’s there where I stumbled upon a promo from SpotVPS. As it turns out, SpotVPS is a low-cost VPS offering of ComfortHost.NET. And who are they?…
-
Apache Cannot Allocate Memory Problem
For the past month, I have been encountering some problems with my WordPress installation. I keep getting the Error 500. I checked the log files and here’s what I found. (12)Cannot allocate memory: couldn’t create child process: /opt/suphp/sbin/suphp for
-
Recursive setacl command on Linux/Unix
Setting access control list(acl) recursively is not as straigthforward in HP/UX. I believe the same is true for other Unix flavors. In case you are wondering how, the command is shown below.
Recent Comments