Showing posts with label Tools. Show all posts
Showing posts with label Tools. Show all posts

Monday, 22 June 2009

Webmin 1.480

I run webmin to manage my servers. To upgrade I usually download the latest package from the webmin website and install using dpkg.

Today I saw a notification on the System Information page. Following the link upgrades to 1.480. This is the first time upgrading from within webmin worked on my servers.

If you need web based server administration, I can recommend webmin.

Monday, 4 May 2009

Backup with Clonezilla

On my server I use LVM to manage my disks. My physical volume group has two disks containing one logical volume. Up till now I had trouble backing up my server as all the backup tools did not recognize the LVM.

This time I used Clonezilla 1.2.1.48. It's release notes state that it recognizes and honours logical volumes.

And it does.

Just to let you know.

Sunday, 15 February 2009

Adding Code Intelligence to Komodo

Writing programs in Python using PyGTK can be hard as the documentation is not consistent and somewhat outdated.

Adding Code Intelligence to the Komodo IDE is a matter of adding a specific XML-File to the IDE. Here is the link to the CIX-Files that do the trick:
http://community.activestate.com/files/gtk._gtk.cix_.gz
http://community.activestate.com/files/gtk_v2.cix_.gz
Extract the files to a directory. Add the two under Edit/Preferences/CodeIntelligence "Add an API Catalog...".

Viola. You have code completion.

Sunday, 8 February 2009

Awn Window Navigator

I follow development of the awn window navigator closely ever since it was first announced on Launchpad.




Awn window navigator is an Apple dock mimic. Under Gnome it acts a a panel on steriods. It lets you collect your favorite apps in a dock, supports drag-and-drop and gives nice visual feedback about the state of the application - Apple like.

Is it pretty? Yes,

Is it usefull? I'm not quite sure any more.

A shortcut collection of items makes sense if:
  • the set of common applications remains static most of the time
  • the set of apps is limited to a few (10 - 15 apps). Otherwise the dock will be overloaded and at the most exceed screen limits
  • the main screen is big enough for the extra space used by the dock
  • applications are hidden behind a cumbersome access path (like menues on Windows or folders on Macs)
Technically speaking, awn is working fine. It allows for customization, adding applications is straightforward, the tool is sufficiently responsive and graphically appealing.

So why do I doubt the usefullness of it?

Basically Ubuntu comes with some shortcuts in the main panel. This dock-like panel can be populated with additional apps. It does not provide visual feedback like awn. On the other hand, it does not use extra screen space (the dock is there anyway).

Ubuntu is reduced to some essential applications. The main menu is organized in logical compartments and can be adjusted to personal preferences using the menu editor. All of this makes Ubuntu easy to use and navigate.

It is because of the combination of just providing the essential applications and the option to add ones favorite applications as shortcuts to the top panel that makes awn redundant on Ubuntu (at least in my eyes).

My recommendation: If you want to mimic Apple, use awn. If you want to work, use the panel instead.

Tuesday, 28 October 2008

Open Source tool to migrate Outlook calendar

When I moved from Windows to Ubuntu, I faced one mayor hinderance: Outlook.

In particular, migrating calendar entries from Outlook was near impossible.
  • OL2003 lets one export one single calendar item to iCal format (and you have to use a trick to even get there).
  • OL2007 lets you export more than one entry at once, if the entries are less than 1000 and do not span more than a 10 year periode (earliest to latest entry).
The last limit is particularly nasty, as birthdays will not migrate and if you have more than 1000 entries (which I had), you have to partition the export (which means you have to switch to list view, which also shows canceled and updated calendar entries).

FreeMiCal

Cut a long story short, I wrote a little program, available on SourceForge that exports all calendar items at once, regardlessly.

FreeMiCal comes as a source zip-package or just the executables (for easy use). It is written in C# and requires nothing more than a Windows machine with Outlook 2003/2007 and .NET 2.0 installed.

FreeMiCal was downloaded over 11.000 times in the last year. It seems to do the job and helps obliviate Outlooks calendar lock-in.

Saturday, 4 October 2008

Easy system backup tool

Before upgrading 8.04 to 8.10 I did a full backup of my harddisk. There are several tools around but I found CloneZilla to be well suited and easy to use.

CloneZilla comes in two flavours:
  • LiveCD (for on the fly backups)
  • SE (Server Edition for workgroup or corporate backup)
There is another source that offers an added feature:

CloneZilla - SystemRescueCD - SuperGrub

This is a compound bootable CD that offers both CloneZilla and SysResCD in one package. The latest version can be downloaded here. Additionally to CloneZilla this CD offers a system recovery CD and a tool that allows to repair the grub boot loader.

Sunday, 21 October 2007

11 most useful console tools

Here are the most essential command line tools:

> filename
Redirect output of commands into a text file, so that you can attach it to emails.
$ uname -a > mypc.log
man command
This gives a brief online description of the command. man always requires a parameter.
$ man uname
sudo command
Run a command with full access rights. You will be asked to enter your password again. The command then executes.
$ sudo chown root:root /etc/init.d/networking
Attention: You turn off Ubuntu's protection features, so double check what you enter!

uname
Provides general system information. Usually called like:
$ uname -a
less filename
If you need to view configuration- or logfiles, less allows you to view them on the console. less always requires a parameter.
$ less /etc/X11/xorg.conf
tail (-f) filename
To view just the most recent part of logfiles, tail shows the last 10 lines of the file. The parameter -f will show new lines as they come in.
$ tail -f /var/log/syslog
lspci
Lists all devices attached to the PCI bus. You can analyze hardware problems with this.
$ lspci
lsusb
If you have trouble with USB devices, this lists all attached USB ports.
$ lsusb
lsmod
Lists kernel modules and their dependencies. You may want to find out, if kernel modules are loaded at all and which modules depend on others.
$ lsmod
dmesg
To read what was printed on the boot screen, this command preserves the messages even when you are in X-Windows.
$ dmesg
sysctl kernel.parameter
If you ever need to display or set any kernel parameter, you can use this.
$ sysctl kernel.hostname
To start a console window, from the main menu select Applications -> Accessories -> Terminal. At the prompt ($) you can enter your command. The output will be shown in the same window.

Monday, 14 May 2007

First steps in Python

In my blog Python demystified I reflected on some thoughts about computer programming and the language in particular.

Ever since then I was aware and interested in this language. Remember I said:
Without any decent IDE (like Netbeans for Java) that allows for graphical programming and UI-design, I strongly doubt that Python will ever gain momentum.
Well, I found a decent IDE: ActiveState Komodo IDE.

Except for GUI it has everything, a decent IDE needs: Syntax highlighting, code completion and code folding, integration into version control (subversion), debugging and profiling.

So just as I was to change my attitude and general opinion on Python the snakes ugly head rose from the depth of my notebooks core:

(Briefly): Python allows for object oriented programming. Objects can be created and instanciated. When going out of scope they are subjected to the garbage collector for destruction. So far so good.

I tried on example program from a popular python book - it worked.

I tried to extend the program (for better understanding) - it crashed.

Well, it terminated with an exception.

Further investigation revealed:
Python stores class definition and object instances in a globally accessible list. When program flow exits the current scope, all objects within scope are subjected to garbage collection according to this global list (and in the exact order of appearance within it).

So there is the possibility that an instance "wol" may be destructed before the class definition "Person". Changing the object name to "wolf" brings it after the "Person" identifier in the globals list and thus there is an object still in memory and valid, where the class definition is destroyed. Any following destructor of the objects instance cannot be called. The code is not there any more.

Is it just me that I find these things on my first day with the language?

Other than that I am fascinated by this elegant and slim language. Worth a try.

Tuesday, 27 March 2007

Finger weg from Eclipse

We have this ongoing argument about not enough Java/Oracle programmers available. I took this to brush up on my Java know-how.

A friend suggested Eclipse to use as an IDE. So I listened and tried it.

Let me put it this way: I have not used such a bad piece of software in a while.

OK, it's free of charge but that's about all that speaks for it.
  • It's slow. Dead slow. A simple "Hello world" took 5 minutes to set up, 2 minutes to debug and more than a minute to launch from the IDE
  • It's complicated: To set up a project you need to go from Window to Window to set up projects, packages, classes, hierarchies and outlines
  • It's slow (did I mention that already?): The code completion takes for ages and even blocks text entry (System - hang - .out. - hang - println - hang ...)
  • It's confusing: Try to debug, does nothing. You have to select which type of project it should be (Can a Java class be debugged as C/C++?)
  • It's broken: I tried to update the IDE (I used 3.2). There were some updated modules. The update mechanism asked over and over which Download center I wanted to use (the automatic selection ended in a disaster). And after another 15 minutes of downloading, the IDE told me, I had not enough rights to install the update. Thanks for telling me so soon
  • It's cumbersome: Creating a SWT app is not straight forward. I gave up working on this one
  • It's slow (deja vu): You can add plug-ins easily (if you have root privilege, that is). With each plug-in, the IDE becomes slower and more unusable
Conclusion: If I have to write programs in Java, I use Netbeans (free of charge) or IntelliJ ($ 599,- incl. TeamCity).

Tuesday, 16 January 2007

Python demystified?

Four years ago I was asked to troubleshoot a project under tight schedule and budget. The team had committed itself to finish an ASP application within 2 years. When I was called, there were only 4 month to the deadline.

I agreed to manage the team under the condition that 2 out of 3 parts be substituted by standard OTS componenten (who needs to develop their own database or browser) and efforts being concentrated on the core functionality.

My proposal was rejected. The project team was confident that using Python programming language would give them an advantage to finish on time and budget.

Later I learned that the project failed and the company went out of business.

My argument then was that Python was not to be compared to C# or Java in efficiency. More so, no real libraries exist.

I was right about the potential of Python as a tool to finish in time.

However I was wrong about the true reason why Python has not gained momentum and probably will not in the future as Java and C# had.

Recent occupation with the subject led me to a different opinion.

1. C# is easy to use and convenient for writing software. However, C#'s strong typing requires programmers to define in advance what to do. Even with refactoring tools and support for generics changes in structure and data definition can cause headache.

Python (as JavaScript) offer weak typing. Objects can be of any type, programmers don't have to worry in advance what they have to handle. Python as opposed to JavaScript has a tight syntax an object declaration (var i, I know its var, so why do I have to state it?)
There are many more advantages to the Python language. Some of them are:
  • everything is an object,
  • strong string operations,
  • plethora of external modules,
  • integration into host operating systems,
  • integration with other programming languages,
  • etc. ...
These make Python a powerful programming tool.

Going from here, I would prefer Python to any language any day.

2. In the early days of Java, everyone wrote their own IDE. This was possible because Java offered AWT a platform independent graphics subsystem. That allowed for many programmers to adopt Java. C# is hosted in the Visual Studio IDE (with a free Express edition available). Even Mono has two prominent IDE's: MonoDevelop and SharpDevelop.

Python offers an outdated IDLE (basically a specialised shell with no charm), ERIC (a bloated QT based environment with an older version of python interpreter), PyDev, a slugish Eclipse plugin, and many more alpha and pre-alpha Editors.

Without any decent IDE (like Netbeans for Java) that allows for graphical programming and UI-design, I strongly doubt that Python will ever gain momentum.

3. There is plenty of introductory books about Java, C# or VB. There are some books around introducing Python. None of the books I reviewed showed how to set up a working python development environment. Maybe its the selection, maybe I am used to skipping chapters on how to get started with other languages. With Python I wasted hours installing, testing and deinstalling IDE's and development tools.

Without a cross platform native or Python based IDE I am pretty sure that Python will be something like Modula 2 in the 70s, ADA in the 80s and LiveScript in the 90s.

Looking back, finishing the project on time was absolutely impossible. Not because of missing power in the language but lack of a powerful IDE.