Change timezone on Ubuntu server (CLI only)
Using the command line, you can use dpkg-reconfigure tzdata.
Follow the instructions to reconfigure the timezone. This was taken from the ubuntu wiki article
Cheers, Mark
Using the command line, you can use dpkg-reconfigure tzdata.
Follow the instructions to reconfigure the timezone. This was taken from the ubuntu wiki article
Cheers, Mark
I was returning a query with some bit fields into my class but the it was not returning true or false when I switched the data.
A bit of hunting and it turned out the that it was being returned as a binary type and after a few failed attempts to convert it to an integer or boolean on the PHP side I found this bug report on it.
So the moral of the story is if you are selecting BIT types from a mysql DB in PHP don't do this:
Instead cast the bit to an integer in MySQL like so:
Voila, it works like expected.
Cheers, Mark Lynch
There was lots of free space on the drives as the root partition was only using a small portion of the disk. After running fdisk to partition it and mkfs.ext3 on the partitions to format them I couldn't see them in /dev/disk/by-uuid.
A quick google presented the solution:
According to the man page this makes udev request the kernel device uevents, which in essence makes it read the disk info again and show it all up so you can mount it happily.
Cheers, Mark
NOTE the example from the adobe site has the quotes in the wrong place. Note you also need to change [cf_webapp_root] to match the location on your machine.
After I enabled Datasource security I began to receive the following error, a bit of digging reminded me that the MySQL connector tries to do some autoconfiguration for coldfusion to optimise it.
It was failing to load the configuration file which is inside the mysql connector jar file /com/mysql/jdbc/configs/coldFusion.properties
I haven't gotten to the bottom of why it couldn't be loaded but adding the following to the datasource query string fixed it up:
I would suggest adding some of the settings from this file as paramaters in your datasource settings as per previous post
Note: This was using the following:
Hope it helps. Cheers, Mark
So you need something like Flash Media Server or Red5 to record it.
However, once you record it to the server it is an flv and the audio codec is stored as a NellyMoser encoded audio portion. This codec is not supported by many applications and after a quick google found the nelly2pcm project on google code.
This will convert a flv sound file to a raw pcm file - which you can then do useful stuff with. So here's how to do it on a Ubuntu machine.
You can run it as follows:
This will create a raw sound file with no headers and output the line above which you'll need for the next part.
To play this file back you can use sox (apt-get install sox)
If you've got all the options correct then this will play the file back. Once you got it correct you can then use sox to create a wav file which is essentially the same except that it has a header which contains all the settings (eg bitrate etc)
From a wav you can convert to whatever you like. I'm looking forward to the Flash Player 10 release as this messing will no longer be necessary as it will support encoding with the free Speex codec.
Cheers, Mark
We weren't intentionally doing these queries but they were coming from somewhere. A bit of detective work via google found a very enlightening article about this problem.
A quick read of this explained:
It turns out ColdFusion was asking Connector/J for the metadata on every field, which in turn triggered a SHOW FULL COLUMNS query for every varchar and text column returned.
It also went on to say that is had been fixed as of Connector/J 5.07.
On reading the release notes it mentions that the
Driver detects when it is running in a ColdFusion MX server (tested with version 7), and uses the configuration bundle coldFusion, which sets useDynamicCharsetInfo to false (see previous entry), and sets useLocalSessionState and autoReconnect to true.
However, from my testing it wasn't doing it as we were still seeing the problem. However, we are running the MultiServer version of ColdFusion which sits atop Jrun4.
So I added the parameter directly to the querystring:
This has stopped the problem, and given a significant performance gain. On one of the sites I was load testing it gave a 12% throughput increase and on another one which had less queries it gave a 4% increase.
Hope it helps.
Cheers, Mark
It does exactly what is says on the tin and makes it very easy to copy dvd's. Initially I used it from my Mac and it worked flawlessly.
I also tried the Linux version on Ubuntu Hardy (8.04) which has no GUI but it is pretty simple when you get the hang of it.
Here's a typical command line:
This reads from /dev/cdrom and uses the handy "iPod Low-Rez" preset which fixes it all up nicely for the iPod.
And here's one that takes the second title:
The wiki has more information on command line usage.
Happy iPodding.
Cheers, Mark
I've been using them for a project and all was going well until we hit a limitation in the libraries. We can do rich formatting and we can do automatic line wrapping and pagination, but we can't do the both together.
This would have been an enormous problem if this was a piece of commercial software as we would be completely at the mercy of the creators. However, as it is Open Source we have access to the code and we can extend it as we see fit.
And that's exactly what we did. I've added a new version of the writeText() method called very imaginatively writeText2().
It takes the same parameters but instead of taking a standard string it will render a string that has html markup. I.e. you can put a <b> tag in and your text will be bold. Eg:
For the curious you can download a sample document generated by it.
It currently supports the following tags:
The code still needs a some cleanup and more testing but it seems to be reliable now.
The two files that were changed are available for download. Or alternatively you can download the full version with changes included. Give it a try and let me know what you think.
Cheers, Mark Lynch
It also mentioned the swfdump tool which looked interesting
I downloaded it and went to the bin directory to try swddump but it didn't work straight away complaining about a missing jar file.
I thought this would mean a lot of pain to get it all compiling but I was very surprised. Here were the steps to get it working on Ubuntu 8.04 Hardy Heron.
This will check out the code to a directory called flex4 under your current directory. I'm assuming you have Subversion installed but if you don't you'll need to run this first.
Some couple of minutes later you should get the following message
Now you have a build of Flex4. Next step is to figure out how to configure Flex Builder to use the new compiler.
NOTE: This is not a finished version of Flex4 yet. Just the work in progress.
Cheers, Mark
A bit of googling turned up this Technote from Adobe which mentioned the same problem on RedHat Linux.
The redhat solution is also documented on Talking Tree but it doesn't cover Ubuntu.
For Ubuntu it's very simple - you need to install 3 libraries and you are good to go - one single line.
This will install a dozen or so packages - then restart ColdFusion and you have a shiny working install.
Cheers, Mark Lynch