RSS

How to package Firefox extensions for Global installs

Firefox extensions are distributed in XPI packages (pronounced zippy).
XPI packages are in reality just a ZIP file with a standard file and folder structure in it.
Two types of add-on installations can be performed : Per-user, and per-workstation (Global). Typically, extensions are installed per-user, especially if the user is not a local administrator on his workstation.
However, there may be cases where a global installation is preferred: a standard extension would need to be installed multiple times for every user of a shared workstation. It would also be harder to push extensions out to users instead of machines.
Here is how to create install a firefox extension globally in a way that can easily be packaged  with anything that allows running batch files. The same information can easily be used to create clean MSI packages as well, using WiX or anything else, just put the files in the right location and set the proper registry keys. It would probably be more reliable to do it with an MSI than batch files.
1) Obtain the XPI package

2) Unzip the XPI package

3) Open the install.rdf file in the package.

We need to identify the “ID” of the package. Look for something similar to this:
<em:id>Blah blah</em:id>
The ID contained in the EM:ID anchors may be a name or a GUID. Note it down.
4) Create a registry import file
Create a .reg file.
This will be used to tell Firefox where to look for the new globally installed extension. This can be anywhere you want as long as the user that will open firefox has read access to it.
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Mozilla\Firefox\Extensions]
“em-id-of-extension”=”C:\\Program Files\\Mozilla Firefox\\PathToExtension”
5) Create a registry import file for uninstallation
This file needs to be identicaly to the above, but with a minus instead of the path to the extension. This simply deletes the string we created before.
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Mozilla\Firefox\Extensions]
“em-id-of-extension”=-
6) Create a batch file for installation

This batch file simply needs to copy the files to the location you specified in your .reg file, and then run regedit /s regfile.reg to import the registry changes.
7) Create a batch file for uninstallation
This batch file simply deletes the directory containing your extension and runs regedit /s on the uninstallation regfile.
No Comments | Tags: , , , ,

Online Payment | SAAQ

Online Payment | SAAQ.

Did I wake up in 1995, or is the SAAQ restricting my choices to two banks in Quebec?

I can renew my license plates online with a credit card, but for some reason, they seem to want to force me to either waste paper and a stamp, or to go to their location to pay.

And yes, paying at their location will cost you an extra $3 on top of that $86/year driver’s license.

No Comments | Tags: , ,

Lacie Tech Support doesn’t know what a share is

I recently got a Lacie D2 network drive. It has been working pretty well, I’m using it for SMB share, AFP share, time machine and to share movies and music to my ps3.

I own a copy of Office that is the download-able version. It is basically a selft-extracting exe that then runs a setup.

I had it stored in a SMB share on the Lacie drive. I ran it. The setup crashed. Then, AFP crashed on my NAS. Rebooting it made things worse. AFP wouldn’t start. Bonjour wouldn’t start. Not long after, SMB wouldn’t start.
Logfiles seemed to indicate that the system’s drive was full. I presume the system is stored on Flash storage in the NAS itself.

I contacted Lacie support. They could only instruct me to reset the unit to factory settings. At least, no data was lost.
I then asked if it could be related in any way to me running a setup file directly from the share, expecting them to tell me there is a known issue when reading a file and writing a lot at the same time or something similar..
Instead, I got this reply:

Tech Support dude.

Makes no sense
Posted: September 3, 2009 @ 7:23 AM

It was related to running the .exe file on the drive.  The file is proprietary to an OS such as XP, Vista, or Mac OS X.  Running the file on a non-conforming OS is going to create severe havoc and other issues.  I am glad the reset resolved the issue.

Regards,

Tech support dude

3 Comments | Tags: , , , ,

Companies I hate and love.

This is a post that will get updated as I get shafted by incredibly poor service from companies, or stellar service.

1) Bell… ok now you know the first section is the NEGATIVE one.

Throttling, DNS Hijacking, Saying they are coming to fix my dry-loop DSL between 5 and 9pm and not showing up (I have an ADSL through Teksavvy).

2) Micro-Boutique (at dix30)
Some of the worst service I’ve ever seen in a computer store. I’d rather get a Mac at Futureshop than there. Took over 30minutes of arguing over a 35$ rubber iPod case that plain didn’t fit properly. They didn’t want to take it back because I had used the screen protector (which you have to install before you put the case on). They couldn’t replace it as the WHOLE BATCH was messed up (iSkin), yet refused to reimburse me for about 30minutes.
When I informed the employee that the case was badly molded, and that I had read on some forums that other people had issues with it, I was told that “This is plain FALSE, we sold a lot of them and they’re FINE”.
Thanks for saying I’m a liar before even checking it out.

Oh, also, when the iPhone 3g was released, they told me, 3 times in a row, that they would ABSOLUTELY have cases for it TOMORROW.

Just bought a Macbook ..from the Apple store.

3) Mobilia
Great furniture, crappy service. My couch has been late for about 2 weeks now, which is not that bad of an issue. What’s bad is I went there two times, to told that the manager would call me the next day. He never did.

Oh, and apparently they ordered only 2 couches but sold 3, so someone is getting the shaft.

http://www.bbb.org/kitchener/business-reviews/furniture-retail/mobilia-thomasville-in-pointe-claire-qc-1034196#ratingdetails

Their awesome BBB rating seems to show I’m not the only one having issues with them.

I was going to get more furniture to match the couch I got from there if I ever receive it, but it’ll have to be somewhere else.

Now, the good ones!

1) Teksavvy
Even though they have to go through Bell’s ADSL network to provide customers with service, they always answer prompty and try their best to fix your problem. It’s sad Bell’s bad service is hurting them, and I hope Bell is forced into playing fair.

2) Zaino Canada
The best products to polish a car, and it ships out so fast I got the stuff the second day after I ordered. Twice.

More to come…

No Comments | Tags: , , ,

OS X 10.5.8 Problems with Firefox

I have just upgraded my Macbook pro to 10.5.8.

I didn’t use the combo update for two reasons:

1) My ADSL is totally messed up, waiting for Bell to fix it, so 700+megs is insane for an update
2) I figured that since my OS X install was about a WEEK OLD that it could handle updates easily.

The install went fine, I rebooted.. and now I can’t even launch Firefox 3.5 !

Update: I rebooted a second time, and now Firefox seems to work fine. My spotlight index appears to be wiped, which I assume is normal.

Weird.

No Comments | Tags: , , , ,

Weird book themes

How can people be looking for so many Unix books yet… The first one here isn’t unix related at all!

1 Comment | Tags: , , ,

Useful error messages. Or not

No Comments | Tags: , , ,

Funny Graffiti

Why would someone write “Wood Killer” …on a plywood board? Perhaps because they have to cut down trees to build the condos?

 

photo

No Comments | Tags: ,

How to sync Outlook on your PC, iCal, Pocket Informant on the iPhone and still get alarms

Pocket Informant is a wonderful tool on Windows Mobile, and an iPhone version was just released. It doesn’t have all the same bells and whistles (yet), and suffers from the heavy restrictions and lack of functionality in the iPhone OS version 2.

Two particularily annoying restrictions are the fact that it can’t sync with the iPhone’s calendar, which would’ve made it easy to sync with your desktop, and it can’t ring alarms if the app isn’t on. And to think that a decade ago, Pilot 1000s could ring even while the device was off…

To be able to sync my iPhone Pocket Informant to my work Calendar (Outlook) and home Calendar (iCal), and to retain alarms, I use this scheme:

image

Here is what you will need to do, and in what order.

1. Open a Google Calendar account. It should be noted that this is stored on Google’s servers, so this solution may not be the best if you treat your calendar info as super private or if it contains confidential information. It might also be a very bad idea if you schedule crimes using your iPhone. Read the privacy policy.

2. Backup your iCal and Outlook calendars, or really any other application you will sync with Google Calendar. The calendar will get wiped from your iPhone so make sure that the info is already somewhere else.

3. Download and install the Google Calendar Sync tool. The options are very straightforward:

image

Enter your Google credentials, and set the sync to 2 way. Test the synchronisation, verify that your Google Calendar now reflects what is in your Outlook calendar.

4. Download and install the Google Calaboration Utility to Configure Google Calendar as CalDAV Calendars in iCal . Again, the options are pretty straightforward, though the first sync will get the data from Google to your iCal in a new calendar. You will to create new appointments in the proper calendar. I’m no big iCal user, I barely use it in fact, so you may know a way of merging your calendars. Test creating an appointment, see if it got created on the Google Calendar, and then force a sync in Outlook and see if it made it there.

5. Buy, download and install Pocket Informant on your iPhone. Under Settings / Sync / Google Calendar, set the Sync to Active, enter your credentials, and force a sync. See if everything is now in Pocket Informant.

6. Disable calendar sync in iTunes. 

7. On  your iPhone, follow these instructions that explain how to setup your Google Calendar to sync over the ActiveSync (Exchange) protocol. This will wipe any calendar info from your iphone. Force a Sync, check if your iPhone calendar got updated. This will give you alarms !

8. Bonus option for jailbroken phones: Install Lock Calendar , available in Cydia, to display calendar info on the lock screen.

From Outlook..

From Google Calendar...

image image

You now have a decent calendaring solution for your iPhone, hopefully, some of these steps will be redundant with version 3 of the OS and future Pocket Informant release.

Known issues:

There is obviously a pretty long delay until all parts are up to date. I set the sync on my iPhone to 30minutes (I don’t use push), and to my outlook to 30 minutes, so if I’m not lucky it can take quite a while to be everywhere.

Items added from Pocket Informant with “Alerts” don’t seem to sync properly to Google, and therefore doesn’t get synched back into the iPhone calendar properly. So for now, until a workaround is found (there are quite a few different alert types in PI, maybe one of them works), you’re better off creating items that need alerts somewhere else.

Pocket Informant’s sync is not super reliable right now, should be improved soon.

ToDo:

You can use the same process with a ToodleDo account. I myself simply use Toodledo with the Firefox sidebar, and sync my Toodledo account to Pocket Informant and the Toodledo app for iPhone (Great value, by the way).

No Comments | Tags: , , ,

Home NAS Project: Part 1

If you’re like me, you have multiple computers at home, multiple laptops in the family, and at least one video game console with Video/Music playback capability connected to your TV and sound system.

 

Synching music and picture databases is a pain, and having central storage that can be accessed by all of these would definitely make things easier, as all the devices would either

  • Read directly from that device (if it’s a “Stay at home” computer or data considered “Stay at home”)
  • Synchronize only with the central storage (i.e.: Laptop1 to NAS, NAS to Laptop2, never Laptop 1 to Laptop2).

 

Requirements

  1. Storage: At least 500gigs usable storage
  2. Redundancy: At least a mirror
  3. Power: As low as possible (No full blown PC!)
  4. Speed: No hard numbers, but “fast enough to be able to stream HD Xvid rips and bluray rips”, which should be using 6000 to 8000kbps. (Kilobits per second)
  5. Protocols:
    1. It absolutely has to support CIFS for Windows and Mac OS X Access to shares.
    2. Obviously, FTP access, to enable any device to transfer to it and from it, especially over the VPN when you forgot to sync something and CIFS is too unstable at low bandwidth.
    3. DLNA ( Digital Living Network Alliance ) support would be great, simply because I intend to use my ps3 to play movies on the TV. My XBMC powered Xbox can mount SMB/CIFS shares but the ps3 can’t. Also, the Xbox supports many more codecs, hopefully, DLNA with transcoding will help the ps3 (though I am not expecting to end up with a machine able to transcode, since it won’t be powerful enough. Oh well, I’ll make sure to download supported media).
    4. Some kind of “Sync” protocol needs to be supported, such as rsync, Unison, etc.
  6. Noise: Not too noisy please !
  7. Encryption: Ability to encrypt the drives would be great, as this device will also store unencrypted backups of laptops. I use full drive encryption on my hard drives, and I want to be able to easily back them up and restore single files. But at the same time, I don’t want someone stealing my NAS and having my complete computers available.
  8. Fun option: Torrent client. If I’m going to leave it on all the time, it might as well handle the torrents by itself too.

Option #1: DNS-323

After researching SOHO hardware, the only one that was cheap enough and looked “hackable” enough, with a decent reputation to go, was the

2-Bay Network Storage Enclosure – DNS-323 by D-Link  . It costs 150 to 200$ depending on your retailer, without drives.

Let’s see how it scores against my requirements..

  1. Storage: It has two available SATA slots, and according to this page , it has been tested with drives up to 1TB .
  2. Redundancy:  It supports RAID 1 .
  3. Power:  According to TechDigs.net , the device uses 24 to 26 watts when in use, and 14 to 16 watts when drives are parked. Other anecdotal data suggests that it uses around to 25 watts when in use, too. We will average this to 20 watts.
  4. Speed: The same TechDigs review has tested the DNS-323 with speeds of 14.5 to 16 MB/s.
  5. Protocols
    1. It does support SMB/CIFS.
    2. It does support FTP.
    3. It does not seem to support DLNA out of the box. However, a software called TwonkyMedia could be purchased and added to it.
    4. It could be synched relatively easily with rsync on client computers by mounting it as a smb or nfs share. NFS not included, but can be added.
  6. Noise: According to the same article, the machine generates approximately 40decibles at 2 feet, and 50decibels at 2 feet under maximum usage. Maximum usage is less of a concern as it won’t be in the room where I watch movies, but the minimum noise is important as I will often work near the machine. Sounds like it’s pretty quiet. We will average this to 45decibels.
  7. Encryption: The DNS-323 doesn’t seem to support full drive encryption. I could probably manage to recompile the Linux kernel for it, or I could use something such as duplicity to encrypt the actual backups. Meh.
  8. Fun option: Torrent client. Multiple torrent clients seem available for the DNS-323, plus command line ones could probably easily be compiled and used along with ssh and screen.

Option #2: FreeNas on a MSI Wind Desktop

After finding that FreeNas looked like a really promising distribution, the MSI Wind PC was the machine I decided was the best hardware fit for my project.

It is available on NewEgg for approximately 170$, so there is not much price difference with the DNS-323. This could be a bit more expensive since a bit of RAM will need to be added to it. (It looks like it comes with no RAM).

Let’s see how it scores against my requirements..

  1. Storage: It has two available SATA slots. I did not find much about the biggest type of drive supported but it shouldn’t have any type of hard limit (especially not under 1TB!)
  2. Redundancy:  The board has no RAID support, however, FreeNas supports multiple types of raid, including 1 and 5.
  3. Power:  The unit comes with a 65watt power supply, and anecdotal evidence seems to point at a 20watt “idle” power usage, and 30 to 35 watt peak usage. I do not know if this includes two hard drives, so let’s go with 35 to be safe. 35 and 20 average to 27.5 (even though it will be idle more often,I use this very simple average for the chart below. It’s not scientific at all.)
  4. Speed: I have no idea. Quite simply, I haven’t seen benchmarks of people running FreeNas on that machine, as it is pretty new. It does have a Gigabit Ethernet port, so the bottleneck will definitely not be the network adapter, and I do own a MSI Wind netbook which performs rather well overall. 
  5. Protocols: According to the FreeNas manual ..
    1. It does support SMB/CIFS.
    2. It does support FTP.
    3. DLNA support is not fully documented yet, but is available. It uses uShare 
    4. It includes Rsync, Unison, NFS, AFP… synching to it as an rsync server or a mapped share should be easy.
  6. Noise: Anecdotal data suggests a 30decibel volume rating, so with two drives, it should be similar to the DNS-323. We will average this to 40decibels.
  7. Encryption: The manual explains encryption support for plain and RAID volumes. It supports multiple algorithms, including AES.
  8. Fun option: Torrent client. There is a built-in t
    orrent client, and since it runs on FreeBSD, installing any command line client should be straightforward.

Chart and conclusion of Part1

I scored the criteria for each devices. “Better when lower” criteria such as Watts were scored in a “100 minus Power usage” way, so higher scores are better.

Scoring for non-numeric points is 100% for fully functional and supported.90% for minor inconvenience (included but not supported, not fully implemented but usable), 75% for “some hacking required”, and 50% for “Could work, but would be a bit annoying to setup.”

image

Totally unscientific chart, I may sound biased, you might not agree… but it looks like while they are both good machines. However, easy full-disk encryption, free DLNA support and better rsync support make the FreeNas combo a winner to me. It might use a tiny bit more power, and performance is unknown.

I will write Part 2 as soon as I have bought and received my Wind PC. Part 2 will cover HD selection and installation. I will also write about my experience with DLNA and the ps3, as well as about how I will backup a Windows machine and a Mac machine to the NAS.

 

Thanks for reading, and if you have any comments or questions, be sure to post them, I’m usually close enough to my iPhone to approve them right away !

5 Comments |