Dynamically change title of FreeBSD terminal windows in SSH sessions

For a while I have been working on a FreeBSD 10 desktop, and one thing I missed from my Mac OS X Terminal was the ability to have the title bar of my terminal window change when I connect via SSH to a remote host. With a lot of SSH session in different windows opened at the same time, it becomes difficult to know what server you are sending commands to. Thus I solved this little annoyance by creating this alias in the .cshrc script:

alias remote 'printf \\033]0\;\%s\\007 "\!^" && ssh "\!*"'

I’m using the urxvt terminal, but I guess the solution can works well on any other UNIX terminal emulator for X11 out there.

At the same time, I found useful to have replicated in the title bar the same info I have in the prompt, thus I added the following lines to same configuration file, under the section that (in the default FreeBSD setup) checks if this is an interactive shell:

if ($?prompt) then
  ...
  if ( $?TERM ) then
   set prompt="%{\033]0;%N@%m:%~\007%}%N@%m:%c3 %# "
   endif
endif

(In bold the code I added).

Migration to VirtualBox hypervisor on FreeBSD

It’s a step on which I thought a lot. Our primary virtualization server was feeling a bit “outdated”… it has been started almost six years ago with Microsoft Virtual Server 2005 and then upgraded to the “R2” release, looking forward the (at that time) promising code-name Viridian technology (now called “Hyper-V“). After Microsoft’s fall, I evaluated CITRIX XenServer and VMware ESXi hypervisors, but the first one, based on Xen, was not able to virtualize Windows without the support for Intel-VT or AMD-V in the host’s CPU, and our server was bought just a few month before these technologies come out. ESXi seemed the right choice for us, but I wasn’t able to get a test machine which complies with all ESXi hardware requirements in a timely fashion. In the meanwhile I started looking at VirtualBox on FreeBSD… until a couple of weeks ago I did not consider it a viable solution to operate as a server-side headless emulator, but after some days of studying and testing I realized that it is actually a strong choice if you need a simple yet reliable hypervisor to consolidate a few non-FreeBSD servers!

Now we have a good virtualization host, on which both Windows guests and FreeBSD jails can run at the same time. With this move the last Windows Server host has gone from our server farm! 🙂

I’ll post some technical details about this migration as soon as possible.

CommuniGate upcoming

Today I officially began the path towards the migration from Microsoft Exchange to the Stalker’s CommuniGate Pro platform. A lot of time has past since I discovered this piece of software, but what I learned about it in the past months has convinced me to put it in production. CommuniGate has a lot of strenght points which make it a good alternative (even better on many aspects) to the Microsoft’s mail server. I can’t obviously write them all now, but the reliability gained by this software’s architecture (which comes from simplicity) can be enough to persuade a lot of Exchange2k7-sceptic sysadmins to give a look at it.

I’m currently running CommuniGate 5.2.6 on a FreeBSD 7.0/amd64 jail. By now on, all SMTP traffic flow from/to my corporate domains is routed by this server. As soon as I go on the migration process, all contents from Exchange private and public stores will be gradually moved to CGP, until the Exchange host will be left emptied and will be decommissioned. Corporate users whose mailbox has been migrated can already use the new Pronto! web interface by using the URL https://mail.valsania.it/Pronto.

Corporate redirection web site

I’ve finally migrated my corporate URL redirection service from an handwritten MSFT-IIS-ASP solution to a new BSD jailed system running a Drupal instance. The new solution empowers the Front Page, the Path Redirect and Web file Manager modules, and enables all authorized users to both maintain all the official URL redirects and manage a dedicated WebFM file repository, from anywhere their are working.

The base URL of the new service is http://go.valsania.it.

CommuniGate Pro

I had been spending some free-time to research a good  groupware server far less featured than an enterprise product (such as Microsoft Exchange, with whom I’ve some experience 😉 ). What I was looking for was a product which is able to:

  • run on at least one type of BSD server platform;
  • give a user experience similar to that of an Exchange system (e-mail, personal and shared contacts, calendar and tasks);
  • be accessed using different types of desktop clients (such as Microsoft Outlook, Mac OS X Mail, web browsers or other free/open-sourced  products) over the web in a secure way (using SSL/TLS);
  • integrate with an existing corporate directory service (Active Directory, Mac and authenticate using secure protocols, such as kerberos.

I’ve spent a lot of time looking for that solution and, until now, it seemed that the only way to accomplish these goals was to build it using a few stand-alone products (SMTP and IMAP server for e-mail, web collaboration for groupware tasks, external authentication services, etc.). That was not what i was looking for, since one of my requirements was to maintain the administration cost as low as possible.

Same days ago I rediscovered the Communigate Pro platform, which seems to fit completely what are my needs: I’m giving it a try by creating a new service subdomain (see the CGP web interface at http://mail.bsd.valsania.it) and running it on a FreeBSD jail. It’s too early to say something sharp about it, but I feel that’s a great piece of software, built to perform and scale very well even in an enterprise or service provider environment, and I surely be glad to get deeper into that solution.

Asterisk

Few days have past from when I began to play with the most famous and feature-rich open sourced IP PBX. Obviously, I’m running it on my FreeBSD testing systems and, even if I’m in the beginnings, I can say that my impression about this software is very good: I feel like it was the “Sendmail” in the IP PBXes field, and that makes it very friendly to me! 😀

I’ve also discovered many ways to give it a user-friendly graphic interface; I gave them a try, but they are too simple to be effectively useful in the environments I wish to make Asterisk working. I’ll go further and mybe I’ll tell you again as soon I’ll have a sharper vision about that.

At the time I’m writing, the dialplan I’ve wrote is enabling me to place calls between two offices in different locations, manage incorrectly typed extension numbers and support remote SIP and IAX connections to the central office system. I wish to complete the configuration of the voicemail module and implement call parking, conferencing and dial-by-name directory as soon as possible.