Tech Blog

Internet Explorer cannot download file

Posted At : February 28, 2011 11:51 PM

I had a report recently from a client that they couldn't download a file from one of our servers using Internet Explorer 7:

The message they got was:

Internet Explorer cannot download [filename] from [sitename]

Internet Explorer was not able to open this Internet site. The requested site is either unavailable or cannot be found. Please try again later.

I knew that the site and file were both available and a bit of hunting around I was reminded that IE used to have issues with Gzip encoding in the past - but I presumed that it was a thing of the past.

I also noticed that when downloading the file Firefox would not show a progress bar but would instead show a "indeterminate progress" bar.

Looking at the headers the it turned out that there was no Content-Length header but there was a header as follows:

Transfer-Encoding: chunked
The transfer encoding chunked allows the server so start sending the file before if has completely compressed it - but was not playing nice with IE7.

To fix this I added some more exclusions to my mod_gzip rules to not zip some particular file types.

#Compress eveything that is not already well compressed
SetOutputFilter DEFLATE
SetEnvIfNoCase Request_URI \
   \.(?:gif|jpe?g|png|mp3|air|exe|zip)$ no-gzip dont-vary

Now its working a treat. It would also be possible to do this only for IE - but most of the files we use on this are already well compressed to gzip compression doesn't help too much anyway.

Cheers, Mark

Learnosity are looking for Junior to Mid level Web Application Developers x2

Posted At : October 20, 2010 4:36 AM

Learnosity develop cutting edge tools for teachers and educators. Our flagship product Learnosity Voice uses the telephone to enable language students and teachers to interact on a one to one level. Our service:
  • Makes it practical for students to practice Oral and Aural skills
  • Is efficient and effective for teachers, as they can listen to each student individually at a time to suit them
  • Can be used for homework assignments or “High Stakes Assessments”

Learnosity are creating the next generation of language and assessment technology for use in schools and education worldwide. The current product portfolio includes:

  • High availability web based systems
  • Cross platform software (Windows, Mac and Linux)
  • iPhone/Android native applications
  • Telephony/VOIP and SMS applications

We need someone who can:

  • Use Javascript or Actionscript to create great user interfaces
  • Develop highly scalable web applications using ColdFusion, PHP or similar
  • Cut code with the best in the world

You will also need to be:

  • keen to continue learning new technologies
  • able to have a conversation with non technical people
  • enthusiastic and ready to push the boundaries

You'll need:

  • 1-3 years of programming experience
  • Experience in at least one Client side language (Actionscript or Javascript/jQuery)
  • Experience in at least one Server side language (eg PHP, Java, ColdFusion, etc)
  • Understanding of Object Oriented design
  • Understanding of XHTML and CSS

It would be good if you have:

  • A degree in Computer Science, Engineering or similar.
  • been working with open source tools
  • Experience with Adobe AIR or Flex
  • been playing around with iPhone/Android applications
  • experience with some of Linux/VOIP/SIP/Asterisk/Jabber/XMPP

This is a full time role and you will be working in a casual workplace with flexible hours in the Sydney CBD. Salary commensurate with experience.

If this sounds like the job for you, email a covering letter explaining why you'll be great and your resume to mark@learnosity.com - no agencies please.

Lego Digital Designer on Ubuntu

Posted At : August 28, 2010 7:48 AM 3 Comments

Having seen the Lego Digital Designer I wanted to see if I could get it to run on Ubuntu, as there is a distinct lack of windows machines at home for my son to use.

It was all relatively painless and it's quite amazing how far Wine has come.

Installing Lego Digital Designer

Go to the Lego Digital Designer site and download the Windows version.

I got LDD 3.1.3 which was the latest version available at the time.

Now - to make it all work you need to install Wine and I used the latest version from the wine PPA team.

Add the wine ppa:

sudo add-apt-repository ppa:ubuntu-wine/ppa
[sudo] password for markl:

You'll then see:

Executing: gpg --ignore-time-conflict --no-options --no-default-keyring --secret-keyring /etc/apt/secring.gpg --trustdb-name /etc/apt/trustdb.gpg --keyring /etc/apt/trusted.gpg --primary-keyring /etc/apt/trusted.gpg --keyserver keyserver.ubuntu.com --recv 883E8688397576B6C509DF495A9A06AEF9CB8DB0
gpg: requesting key F9CB8DB0 from hkp server keyserver.ubuntu.com
gpg: key F9CB8DB0: public key "Launchpad PPA for Ubuntu Wine Team" imported
gpg: Total number processed: 1
gpg: imported: 1 (RSA: 1)

Now to update the list of available software:

sudo apt-get update

And then install wine and winetricks

sudo apt-get install wine winetricks

Wine lets you run Windows software on other operating systems, in this case Ubuntu.

Wine tricks provides a simple way to install native versions of some of the libraries that are not 100% compatible - by looking at the Wine App DB I discovered that it had problems with missing font's (Tahoma) and scrolling which was fixed by installing Quartz.

winetricks tahoma quartz

Then install double click on the install file for LDD and it should be up an running in no time.

If you get a warning about it not being Executable you may need to right click on the application and select Properties - and then from the Permissions tab select "Allow executing file as program"

Son is now very happy with Lego Digital Designer :-)

proxy_http vs proxy_ajp benchmark

Posted At : March 18, 2010 1:20 AM 2 Comments

After I posted a previous blog entry about configuring railo & tomcat with apache and mod_proxy_http, Paul Kukiel and Gary Gilbert suggested that I should be using mod_proxy_ajp.

This has been something I've been looking at, but haven't found a compelling reason for one over the other.

Proxy AJP is claimed to be faster as it is a "Wire protocol" but I couldn't find any benchmarks around this.

So I decided to do a very quick and dirty benchmark to satisfy my curiosity. This is not a scientific process, I just ran a simple railo testpage on the same machine with 50 threads of jmeter requests hitting it.

First I enabled proxy_http and ran it four times, then enabled proxy_ajp and repeated. The config is below:

# Proxy HTTP config
<IfModule mod_proxy_http.c>
   <Proxy *>
   Order deny,allow
   Allow from all
   </Proxy>
   ProxyPassMatch ^/(.*\.cfm)$ http://testsite.railo:8080/$1
   ProxyPassReverse / http://testsite.railo:8080/
</IfModule>

# Proxy AJP config
<IfModule mod_proxy_ajp.c>
   <Proxy *>
   Order deny,allow
   Allow from all
   </Proxy>
   ProxyPassMatch ^/(.*\.cfm)$ ajp://testsite.railo:8009/$1
   ProxyPassReverse / ajp://testsite.railo:8009/
</IfModule>

Results:

RunHTTP Requests/secAJP Requests/sec
Run 1206.9181.4
Run 2203.9143.6
Run 3194.6189.2
Run 4204.6191.4
Average202.5176.4

The results showed that the proxy_http module was faster - i.e. more requests per second could be pushed through.

I'm putting this down to the fact that proxy_ajp has to convert the http request into it's binary format, while proxy_http really just has to pass it along.

In different scenarios and network configurations the results may be different, but for now I'm going to stick with the http proxy.

Proxy AJP has one other benefit, in that is passes along some extra flags such as whether the request is https or not, but for our purposes we don't need this.

Cheers, Mark

Split first name and last name with Openoffice/Excel

Posted At : February 23, 2010 10:21 AM

I've been dealing with a lot of spreadsheets of usernames recently and sometimes you get firstname and lastname in seperate columns, and sometimes in the same column.

If you get them in the same column but need them in two columns here are two little formulae to do it:

FullName | FirstName | Lastname |
Mark Lynch | =MID(A2,1,FIND(" ",A2,1)) | =MID(A2,FIND(" ",A2,1)+1,100) |
Which will look like:
FullName | FirstName | Lastname |
Mark Lynch | Mark | Lynch |
This basically seperates the string on the space between the names and puts it into each column

Cheers, Mark

Jmeter over SSH Socks proxy

Posted At : January 6, 2010 11:25 PM

I've been doing some testing recently where I need to connect via SSH server to a remote network to run some load testing.

To do this I used a SSH sock proxy like I have previously blogged about.

So I fired this up so that I could review the site I wanted to look at. It worked a charm through firefox but there is no where to set up the proxy in jmeter.

To make it work you need to let the JVM know what proxy to use like so:

java -DsocksProxyHost=localhost -DsocksProxyPort=8080 -jar ApacheJMeter.jar

No jmeter will use the socks proxy on port 8080 on my local machine. Nice.

Job Vacancy Sydney AU - QA Test Lead - Learnosity

Posted At : September 2, 2009 5:44 AM

2 September 2009, Learnosity are looking for a QA Test Lead in Sydney.

About Learnosity

Learnosity develop cutting edge tools for teachers and educators. Our flagship product Learnosity Voice uses the telephone to enable language students and teachers to interact on a one to one level.

Our service:

  • Makes it practical for students to practice Oral and Aural skills
  • Is efficient and effective for teachers, as they can listen to each student individually at a time to suit them
  • Can be used for homework assignments or “High Stakes Assessments”

About the role:

Working as an integral part of the Learnosity development team you will ensure delivery of high quality products through the development of a formalised testing framework, documentation of releases, and management of the UAT component of all software projects.

  • Create and implement test plans for each project
  • Conduct functional and non-functional testing including UAT, Load and regression testing
  • Review and sign off test reports
  • Track, allocate and prioritise areas to be tested
  • Manage the release process from development through staging and production
  • Report and manage defect analysis process including logging, tracking and testing
  • Produce high quality documentation and release notes
  • Implement automated testing and build processes

Who we looking for:

Qualifications & Attributes

  • Self motivated person willing to continually learn and improve themselves and processes around them.
  • Tertiary qualifications at associate diploma level or equivalent in computing or a related discipline or an equivalent combination of training and experience.
  • Minimum of 2 years work experience within a dot com or software development environment.

Knowledge & experience

  • Ability to translate requirements and functional specifications into test cases
  • Hands on experience across multiple applications of end-user technologies
  • Understanding of Project Management concepts
  • Strong skills and history working in a test and release management position in a dot com or software development environment
  • Testing methodologies and procedures, including load testing
  • Knowledge and/or experience of testing tools and techniques
  • Release management procedures
  • Highly developed written skills
  • Excellent proven communication and people skills including client liaison and documentation
  • Demonstrated ability to organise and plan work with care and attention to detail while meeting deadlines
  • Ability to work independently and as part of a team

This is a full time role and you will be working in a casual workplace with flexible hours in the centre of Sydney.

If this sounds like the job for you, email your resume and covering letter to mark@learnosity.com - no agencies please.

Two quick server tips

Posted At : August 14, 2009 10:12 PM 1 Comments

Here are two quick tips that I've recently found for server admins:

  • Automatically fixing file system errors
  • Ignoring directories from updatedb

Automatically fixing file system errors

If you have a remote server, i.e. at a data center 10km or 1000km away this should prevent some panic when rebooting the server remotely.

Ext2/3 will do a filesystem check after a certain number of reboots or time. Most of the time any errors are fixed automatically, but certain errors by default require the root shell and the administrator to fix them. I've seen a few of these happen, but I have always replied yes to the prompts as I don't know enough about file systems to fix it I said no.

So, to prevent the need to rush to a data center and plug in a keyboard and mouse just to press the "Y" key there is and option to automatically assume yes.

On Ubuntu in the file /etc/default/rcS you need to change the following:

FSCKFIX=no
to
FSCKFIX=yes

Ignoring directories from updatedb

If you have a backup server you may not want it to update the locate db for all your backup files, as it can take a very long time.

To tell locate to ignore a directory you need to add it to the PRUNEPATHS line in the /etc/updatedb.conf file like so:

PRUNE_BIND_MOUNTS="yes"
PRUNEPATHS="/tmp /var/spool /media /srv"
PRUNEFS="NFS nfs nfs4 afs binfmt_misc proc smbfs autofs iso9660 ncpfs coda devpts ftpfs devfs mfs shfs sysfs cifs lustre_lite tmpfs usbfs udf rpc_pipefs"

In the above code I have added the /srv entry to make it ignore all my backups which are held under the /srv directory.

Note: These tips were tested on Ubuntu linux, other distributions will have similar functionality but the file locations may vary.

Cheers, Mark

HOWTO generate diff files from subversion

Posted At : March 3, 2009 12:46 AM

Here's a nice and quick way to generate a diff file from subversion and store it on your local machine.

svn diff filepath/myFile.ext > saveDirPath/myFile.ext.diff

Where filePath is the local path to your working directory in which your file is located. And saveDirPath is the path where you want to save your diff file.

Diff files can be very useful when contributing to open source projects.

You can also get a list of files changed between revisions.

Marko

SVN - Get list of files changed between revisions

Posted At : January 16, 2009 2:18 AM

For my own reference, here is how to get the list of files that have changed between any two subversion revisions.

svn diff --summarize -r5:10 http://svn.example.com/trunk

This will give something like:

If you want to get the revisions from a revision to the latest then you can change the 10 to HEAD - eg:

svn diff --summarize -r5:HEAD http://svn.example.com/trunk

Cheers, Mark