Full text search for outlook

As you may know, we are using Exchange and Outlook for our Email and groupware needs. The thing just works and has some really useful groupware features while – in contrast to all those PHP-solutions – still being well integrated in the usual working area (read: has a windows client). And even better: Using Outlook / Exchange, even synchronizing the PDA works out of the box without that much of tweaking.

But with all this greatness, there are two problems: First, Outlook is not what I’d call a good email client, but it gets near. I still can’t use it for mailinglist consumption (bad threading, no qote highlighting,…), but for the rest it’s usable. The second problem is the search function. It’s so incredibly slow, even when you create a full text index on the Exchange-Server (without it’s even slower). And besides being slow, it looks like it’s searching forwards. When I enter some search term, it walks through the messages from the oldest to the nweset which is quite inpractical

So for reading mailinglists and for searching, I used Thunderbird

Then I found Lookout which was recently bought by Microsoft and released as freeware. This wonderful Outlook Add-In builds a fulltext index of all your Outlook folders and actually uses it (in contrast to outlook and the indexes on the exchange server). Additionally it has quite a powerful query language.

And with “fast” I mean fast: It takes just about 0.1 seconds to search my about 33’000 mails for this one message containing a certain word. This is great.

I’ve actually only two small problems with the tool:

  1. It uses the .NET Framework which must be loaded each time I start Outlook. This increases the already long startup time
  2. It uses it’s own window to display the search result. Outlook’s “Look for” function does this better and reuses the message list.

Besides that: Great tool!

Strange preconfiguration

Ever since I’ve updated our in-office Gentoo-Box to Samba 3, I had very bad performance (throughput wise). And with bad performance I mean at most 200 KBytes/s on a 100MBit network.

For quite some time I thought that it must be my client machine, so I rested the case. Till today, where someone else complained about really bad performance. So I began investigating.

At first I had one of our ultra-cheap switches in mind, so I tested the performance using FTP. Too bad: full speed there, so it must be a Samba problem.

What was really strange: Write performance to the server was great. It was just reading that took so incredibly long. So, armed with this information I did some googling and found … only vague stuff. While there are some people with the same problem as myself, they are always told that it must be a hardware or windows problem (the two easy solutions) and there was no further discussion in all cases.

Somewhere I found the tip to set the following in smb.conf for maximum performance:

socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192

I went and looked, but the setting was already there. Too bad. The next thing I did was to comment the line out and restart samba:

#socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192

And you will not believe it, but it helped. The server is back to its old performance with 8 Mbytes per second which is a good value considering the cheap equipement involved.

Problem solved. Culprit: Strange preconfiguration by Gentoo. Why this helped? No idea! Why the wrong setting in the first place? No idea either. Why the wrong tip to put this option into smb.conf? Don’t ask me. I’m just happy, it works again.

XP SP2, Delphi Debugger

This weekend, a pre-RC2-Release of Windows XP SP2 could be found on the net. Eager to learn whether the Delphi debugger now works again, I’ve downloaded and installed the thing.

I’m happy to report, that delphi indeed works again, so I’m keeping the build installed for now, as I really like the integrated bluetooth-support.

Cashpoint software for Geeks

I’m currently working on a WinCE based POS-System for unexpirienced users in low-profile stores (I took the liberty to black-out the logo at the top as it’s not official).

The Screen on this shot shows you the manual price entry screen. The problem: It seems like the values seem to get interpreted as HEX values… (see arrow). This is the optimal piece of software for geeky hardware stores ;-)

PS: Of course I fixed this. Actually it never even was a bug as it was wrong on purpose to give me reason for another blog entry

.Python

This Paper was featured on Slashdot today. It’s about an implementation of Python based on Microsofts CLR. The following quote speaks for itself:

I wanted to pinpoint the fatal flaw in the design of the CLR that made it so bad at implementing dynamic languages. My plan was to write a short pithy article called, “Why .NET is a terrible platform for dynamic languages”.

Unfortunately, as I carried out my experiments I found the CLR to be a surprisingly good target for dynamic languages, or at least for the highly dynamic specific case of Python. This was unfortunate because it meant that instead of writing a short pithy paper I had to build a full Python implementation for this new platform […]

This is very interesting. Imagine having access to all the Tools, Components around .NET from a wonderful language like Python. But it does not end here: As your Python code in the end gets compiled to MSIL, you can even create libraries in Python and share them with users of languages like C#. This is nice!

Too bad I don’t speek Python. But then again: If it’s working with python: What about Perl? PHP? Unix Shell [;-)]?

A programmers Editor…

… doesn’t have to take that much care of usability. And the installation routine of EditPlus certainly doesn’t.

edp.png

Besides the fact that this dialog appears when it’s already too late (after the installation has completed) and that it contains redundancy (the “Send To” entry and the additional context menu entry do practically the same), the marked wording is very ridiculous or can you imagine a mouse button with an attached (?) editor?

As usability would not matter (remember: programmer’s editor) that much, a more useful and less ridiculous wording would be “Add EditPlus to the Context Menu of Explorer”.

The wording is one of the things that are very often very wrong in software by semi-professional companies (not excluding my own software) and this usually gets even worse in the installers as they are often not very well tested (or not at all). Those InstallShield things are the worst as many developers just click together the installation, then click through the dialogs and put the thing on the web.

This is the reason why my parents still have not succeeded in installing software on their own while nearly everything else went quite well the last year.

Another unobvious Windows problem

I have quite a lax administration policy concerning our network which is possible as long as we don’t have that many machines and employees: I for myself do not place many restrictions in choice of hardware and OS on our employees. They should work with whatever they want. Only restriction: The OS must be multi-user capable (means: no Windows 9x) and if the employee wants access to our file-server it must somehow support the SMB protocol.

Lukas, on the other hand, adds another requirement to the list above: The system must somehow provide support for our exchange based groupware. This can be native access or via the web interface.

So yesterday, someone wanted to add his computer to our network. It’s a IBM Thinkpad running Windows 2000 in a highly tweaked installation which should be preserved at all costs. Every other administrator would insist that at least the corporate configuration would be enforced, but I don’t care and put the users satisfaction above all easement for my task, so I let him keep his setup, but suggested him to join our Windows domain to make his life easier (no logging in to our fileserver, better exchange-support (remember: Lukas’ condition).

After some initial problems with the installed personal firewall (have I told you that I hate them? Yes I have), I went on and tried to join our Windows 2003 domain. After quite a long waiting time, the only thing I got was “Access Denied”. A quick look to the server’s event log showed nothing but success-messages.

Googling did not help (much), but told me about a certain netsetup.log windows is supposed to create on the client (it’s in %windir%Debug. Here’s the log I got:

03/30 16:19:28 -----------------------------------------------------------------
03/30 16:19:28 NetpDoDomainJoin
03/30 16:19:28 NetpMachineValidToJoin: 'THINKPAD'
03/30 16:19:28 NetpGetLsaPrimaryDomain: status: 0x0
03/30 16:19:28 NetpMachineValidToJoin: status: 0x0
03/30 16:19:28 NetpJoinDomain
03/30 16:19:28 	Machine: THINKPAD
03/30 16:19:28 	Domain: office.sensational.ch
03/30 16:19:28 	MachineAccountOU: (NULL)
03/30 16:19:28 	Account: office.sensational.chpilif
03/30 16:19:28 	Options: 0x3
03/30 16:19:28 	OS Version: 5.0
03/30 16:19:28 	Build number: 2195
03/30 16:19:28 	ServicePack: Service Pack 4
03/30 16:19:28 NetpValidateName: checking to see if 'office.sensational.ch' is valid as type 3 name
03/30 16:19:28 NetpValidateName: 'office.sensational.ch' is not a valid NetBIOS domain name: 0x7b
03/30 16:19:28 NetpCheckDomainNameIsValid [ Exists ] for 'office.sensational.ch' returned 0x0
03/30 16:19:28 NetpValidateName: name 'office.sensational.ch' is valid for type 3
03/30 16:19:28 NetpDsGetDcName: trying to find DC in domain 'office.sensational.ch', flags: 0x1020
03/30 16:19:43 NetpDsGetDcName: failed to find a DC having account 'THINKPAD$': 0x525
03/30 16:19:43 NetpDsGetDcName: found DC '\durin.office.sensational.ch' in the specified domain
03/30 16:19:43 NetUseAdd to \durin.office.sensational.chIPC$ returned 5
03/30 16:19:43 NetpJoinDomain: status of connecting to dc '\durin.office.sensational.ch': 0x5
03/30 16:19:43 NetpDoDomainJoin: status: 0x5

Not so useful besides: NetUseAdd to \durin.office.sensational.chIPC$ returned 5

As the last entry was something about a status 0x5 and the error was “Access Denied”, I figured that this “returned 5” must mean “Access Denied” too.

A quick try to access the server showed me that I was right: I could not access any share – my password was not accepted (besides the server’s security log telling me otherwise).

Finally the guy owning the noteook had an idea: He has disabled Windows 2000’s packet signing and encryption via Administrative Tools/Local Security Policy. Enabling it and rebooting finally did the trick. When asked why he did so he said that it would greatly speed up access from a PC running Windows 98…

What did I learn: Maybe my policy is a bit too lax and if keep it, I should at least not try to fix problems I’m getting with it (it would have worked perfectly well without joining the domain)
What do you learn: If you have the same problem, here’s the solution. And this is what this blog is for.

The best bittorrent client

I have been looking for a decent Bittorrent-Client.

While the official one is quite nice for not-that-large files, its disadvantage of not being able to limit the upstream-bandwidth becomes deadly with large files: All connections I currently have access to for running bittorrent have a much smaller upstream than downstream and a saturated upstream will eventually kill off the downstream (as you most likely already know)

So I went looking and here’s what I found so far:

  • BitTorrent EXPERIMENTAL download client: quite similar to the official client, but with the desired upload-limiting-feature. Unfortunatly quite out of date. I haven’t tried it out because of that.
  • ABC [ Yet Another Bittorrent Client ]: written in Python – supports more than one torrent in one application window. While it has quite a decent feature set, it has a terribly geeky user interface (not necessarily a bad thing) ande it crashed on me about four times in just 12 hours, so I can’t really recommend it
  • Azureus: Written in Java, but nice-looking (thanks to SWT), fast and with an extremely comprehensive feature-set. I can’t just say a lot about its stability – the featureset (especially the cool graphs) have amazed me so much that I deceided to post this entry here…

Azureus is now about the third Java-Application I know of that not only works, but works so well that I recommend it over native counterparts (the other ones being jEdit and Eclipse).

I really think it’s time to rethink the “java-is-crap-for-the-desktop” saying that was so incredibly popular the old days. Actually I do think that Java slowly begins to become a real alternative.

I mean: If you just stop thinking about the difficult (for end users) installation of the JRE and the (till now) slow speed, Java indeed has some advantages which make it the tool for desktop developement: It’s platform independent (ok… nearly – at least the major ones are supported), it’s (quite) easy to work with (I don’t like it very much myself, but it’s definitely much easier to work with than C, for example) and it has a very convinient memory management which makes it a bit more secure than your standard C-application (speaking of Buffer Overflows for example).

In short: It’s the optimal toolset to build applications for the desktop where a lot of features, fast developement and high security (unconcerned users, not admins are working with the software) are the key to success.

I really think that the big time for Java is just coming, not fading away.

Today’s little PC-Problems

Today, I deceided to track the daily PC-problems I have to solve, just because I wondered why I generally think that PC’s suck and to learn how much time I lose just for fixing things that should work.

Today’s list of software-stupidity I’ve had to learn:

  • floAt’s Mobile Agent has a feature to react when the connected BT phone comes out of range. I’ve configured fma to lock the workstation as soon as I leave it. Quite nice. Every time the BT connection now drops, the screen is locked. Unfortunatly, it does not check for the cause of the connection drop: If it’s because I’m just quitting fma, it locks the screen anyway. This stupid thing happend to me just one time too many, so I decided to post this whole entry here.
  • I’ve 1 GB of RAM in my Thinkpad which, I think should be enough for the machine to swap only very rarely. Then: Why is my system virtually unusable because of swapping if I bring Firefox in the forground after is lied in the background for an hour or so? I’m not blaming Firefox for this. I’m blaming windows for it’s less-than-optimum memory handling. Why swap if it’s not needed? Why has the system to stop responding when it’s swapping?
  • On the Exchange Server, I’ve set up a daily backup-task using Microsoft Backup. It never run and did not provide any error-message at all. Why? Because the command-line created from MS-Backup’s planning assistant was too long to be executed by windows. Why is such invalid command line created? Why is there no error message?
  • I had to support one computer where surfing to any website immediatly created a 404-error. I’ve double checked – the pages where there, the websited did in fact work. Cleaning the browser-cache (the supported person insists on using IE) helped. Why? What was the problem?

Stupid, Stupid, Stupid.

I mean: I’m writing software myself and I really check not to do such stupid things. They happen. They happen all the time when programming. Your mind is thinking completly differently when you are buried deep in program code. But then: Why don’t the people take some time to actually test theiur products? Why do such stupid things happen? Why can’t we live in a world without bugs? Without software-stupidity?

Apple, you are coming closer and closer…

T610/Z600, Outlook, MobileAgent and Bluetooth

If you own either a T610 or Z600 mobile phone, you may know of floAt’s Mobile Agent a not-so-stable but even more powerful tool for accessing the phone from your PC. Sending SMSes, Managing contacts, even getting a popup windows when somebody calls you – everything is possbible.

Everything but synchronizing with outlook. There’s just some kind of CVS export for your contacts, but this is very uncomfortable to handle. The bluetooth sync-profile the Widcomm software provides would do the trick, but I’ve many more contacts in outlook than there’s space on the phone. So I need a way to specify which contacts to synchronize.

The software that comes from ericsson, XTNDConnect PC, has support for filters (I’ve created a category T610 and I’m syncing only contacts whithin this category), so would be doing the job.

Unfortunatly, this Ericsson PhoneMonitor-thing which XTNDConnect relies on is slightly incompatible to MobileAgent – either the phone is not detected or MobileAgent loses its connection (which locks my workstation because I’m using the proximity detection). I’ve never succeded in finding a way to reproducibly use both programs concurrently.

Not ’till now.

(BT-Driver is Widcomm 1.4.x but it should work with 1.3 too)

  1. Open the Advanced Bluetooth configuration.
  2. Client Applications Tab.
  3. Add COM Port
  4. OK to everything
  5. Double click the BT-Icon in the Tray
  6. “View devices in range”
  7. Double click your phone
  8. Right-click “Serial Port 2” and create a shortcut.
  9. go up two levels.
  10. right click the created shortcut, properties.
  11. Select the newly created port
  12. OK everything
  13. In the control panel open the Ericsson Phone Monitor
  14. In COM Ports, select the newly created port, chose “Reserve” and “Enable”
  15. OK

Before synchronizing, double click the newly created shortcut in your “bluetooth places”. The phone will not immediatly be detected, but as soon as you start XTNDConnect and hit “synchronize”, it will be.

What you did with this steps is creating two virtual com-ports for the phone that can be concurrently used. That way you can use XTNDConnect to synchronize with outlook and MobileAgent for the rest. Very nice.