August 2005 Archives

31.08.2005 02:26

Java on Mandriva 10.2 KDE 3.4

Well I found out the hard way tonight the short falls of java on Mandriva 2005 KDE 3.4 version. I had it installed but it wasn't the VM wasn't working in my browsers 9Konqueror, Firefox and Opera). I created the symlink Firefox needs, still no go. I found java needs to in your path for the VM to work so I got the working by adding to my ~/.bashrc script the java bin folder to my PATH with:
I then found this didnt solve the problem. Why you ask ?? Well I was very much wondering the same thing. I decided to run java_vm from console and got the error message that JAVA_HOME and PLUGIN_HOME were not set. Never knowing I had to set them I googled to find most were setting them to the dir above the java bin, like so:
	export JAVA_HOME=/usr/java/jre1.5/
	export PLUGIN_HOME=/usr/java/jre1.5/
This finally got it working. Strange for a newly installed Distro to not have have Java working -----

Posted by DaveQB | Permanent Link | Categories: IT

24.08.2005 13:59

Interactive or non-interactive

Vectorlinux nicely prints to the screen info about who you are, and what commands you have at your disposal. Screenshot of Vectorlinux terminal login This is nice but can halt programs that do non-interactive logins, like scp. So off I go finding where Vector does this and how to make the script test for interactivity before printing to the terminal. After a bit of googling I found this handy link. So now to apply this info to Vector. I searched through and found:
  • /etc/profile.d/
This file was responsible for printing that info to the terminal. So basicly I applied that if statement found on the link above around all the info in the file. Also, I pulled out the non-interactive part of the file and put it outside the now interactive executed section so it would be ran if it was an interactive or non-interactive login. Here's the files, now altered to work with scp.

Posted by DaveQB | Permanent Link | Categories: IT

17.08.2005 20:44

WARNING Will Robinson

I use the great application called GKrellm. Its a system monitoring tool; it monitors CPU and case temp's, disk usage, network usage, memory and swap status and uptime to name a few. Well this morning I accidently found there is a GKrellmd package. A little probing find you can connect remotely to a GKrellmd with a GKrellm client. So I urpmi'd GKrellmd on my server and launched it with:
	gkrellmd -a -m 1 -d
And then launched a seperate instance of GKrellm on my desktop with the command:
	gkrellm -s
And up she popped with all my servers information. Beut! Didn't have temps though. So I checked and didnt have lm_sensors package installed. So urpmi'd that and ran what it suggested "sensors-detect". It asked about scanning my system and found 2 sensors. One was my motherboard one and the other was a riva named chip. Must be the VGA. Thought I would say yes to installing a module for that as well and WHAMO! Whole system to a halt. There goes my 82 day uptime :( GKrellm running on my desktop monitoring my servers actions -----

Posted by DaveQB | Permanent Link | Categories: IT

15.08.2005 16:30

CSS beginnings

Well I have dabbled in CSS (Cascading Style Sheets) before for little bits of sites I have built, but never gave it a full go.....until now. What an amazing piece of work CSS is. Makes laying out a site so much easier and updating is a breeze later on. I got it a little bother and asked a few guys in #css on Here's a few links I have gathered so far that I dont want to lose:
  • -- humous intro to css
I'll add more when I can recall them :) -----

Posted by DaveQB | Permanent Link | Categories: IT

09.08.2005 11:54

PHP fun (solution)

Well I found the solution on #php on substr($ret , -5) was returning html when being the last 5 char is should of returned .html. I did notice this, but having never used the substr function before I didnt think much of it. So it turns out I was returning html\n (\n is 1 char). So it needed the trim function applied: trim(substr($ret, -4);
Its just like Perls chop function, servers same purpose. There easy solution like I said. -----

Posted by DaveQB | Permanent Link | Categories: IT

08.08.2005 23:01

PHP fun

Well I have been putting together a site using php has a front end to a shell script. Well it all done and works well accept when I tried to add a little validation and error checking. I wanted to make sure the shell script ran fine and returns a file name (teamnames.html). Well validating that has become a nightmare. Here's my problem: echo $ret; // prints VikingsVChiefs.html
$ext = substr($ret, -5);
echo $ext; // prints html
$name = pathinfo("/var/www/html/dbnfl/$ret");
echo $name['extension'], "\n"; // prints html
if ( $name['extension'] == "html" ) {
echo "String found to have html extension"; }
else { echo "string not found to have html"; } // prints "string not found to have html"
Can you see this strange dilema ?? I have tried several different ways with the syntax, yet always results the same. I will hopefully have the answer to this soon. -----

Posted by DaveQB | Permanent Link | Categories: IT

03.08.2005 12:31

Slapt-get working on Vectorlinux

Well I have had the problem of slapt-get not working on some fresh installs of Vector that I do. I would re-install and it would work, for no apparent reason. Today I think I found the reason why. I think I uncommented too many sources in the slaptgetrc file. I have been using Australian mirrors as well as the default one. So this time I only uncommented 1 sources per section, that being the default one. This corrected the problem of slapt-get trying to install from a local source (file:///mnt/somewhere) that was never uncommented in the slaptgetrc [made troubleshooting very confusing]. -----

Posted by DaveQB | Permanent Link | Categories: IT