Showing posts with label linux. Show all posts
Showing posts with label linux. Show all posts

Thursday, April 10, 2008

Installing webmin on Ubuntu 7.10

Recently, I've discovered a very neat tool for administering some of my linux servers. It is called webmin, and it may be one of the more complete web based system administration tools I have seen for linux.

Admittedly, I was a bit apprehensive at first trusting a web interface to do administration. After all, I am not one to shy away from the command line. But the more I used the webmin console, the more I could really see the benefit of using such a tool. In particular, I found the custom commands, and scheduled monitoring two particularly useful features.

I had been configuring small single-application virtual machines lately with Ubuntu, and found webmin to be a very robust tool in which to write custom commands to administer the various function of that server. With webmin, it made each VM more like a virtual appliance -- something we just turn on and off -- rather than something we had to learn oodles of commands to maintain.

Now installatin of webmin on Ubuntu isn't quite as straight forward as just saying "apt-get install webmin", so I've written a small HOWTO guide on how to install on Ubuntu. If you find this useful, please do leave a comment. It's nice to know what people find useful, and what things people don't.

Step 1: Get the latest webmin debian package from webmin's site. Since the bare bones Ubuntu Server won't have a graphical browser, the easiest way to do this is to find the download link via another machine, then use wget to download it onto your server. For me, this was a close sourceforge mirror from which to obtain it. Therefore, I issued a command like this:

wget http://internap.dl.sourceforge.net/sourceforge/webadmin/webmin_1.410_all.deb

This was the response:

--12:57:12-- http://internap.dl.sourceforge.net/sourceforge/webadmin/webmin_1.410_all.deb
=> `webmin_1.410_all.deb'
Resolving internap.dl.sourceforge.net... 74.201.26.4
Connecting to internap.dl.sourceforge.net|74.201.26.4|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 13,140,062 (13M) [text/plain]

100%[====================================================================================================>] 13,140,062 417.00K/s ETA 00:00

12:57:44 (416.17 KB/s) - `webmin_1.410_all.deb' saved [13140062/13140062]

Step 2: Next, install the appropriate libraries (as a sudo user) to get webmin to run:

sudo apt-get install libnet-ssleay-perl libauthen-pam-perl libio-pty-perl libmd5-perl openssl
This was the response:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Suggested packages:
ca-certificates
The following NEW packages will be installed:
libauthen-pam-perl libio-pty-perl libmd5-perl libnet-ssleay-perl openssl
0 upgraded, 5 newly installed, 0 to remove and 39 not upgraded.
Need to get 1138kB of archives.
After unpacking 3555kB of additional disk space will be used.
Get:1 http://ca.archive.ubuntu.com gutsy/universe libauthen-pam-perl 0.16-1 [32.2kB]
Get:2 http://ca.archive.ubuntu.com gutsy/universe libio-pty-perl 1:1.07-1 [42.3kB]
Get:3 http://ca.archive.ubuntu.com gutsy/universe libmd5-perl 2.03-1 [5680B]
Get:4 http://ca.archive.ubuntu.com gutsy/main libnet-ssleay-perl 1.30-1 [186kB]
Get:5 http://ca.archive.ubuntu.com gutsy-updates/main openssl 0.9.8e-5ubuntu3.1 [872kB]
Fetched 1138kB in 9s (117kB/s)
Selecting previously deselected package libauthen-pam-perl.
(Reading database ... 33264 files and directories currently installed.)
Unpacking libauthen-pam-perl (from .../libauthen-pam-perl_0.16-1_i386.deb) ...
Selecting previously deselected package libio-pty-perl.
Unpacking libio-pty-perl (from .../libio-pty-perl_1%3a1.07-1_i386.deb) ...
Selecting previously deselected package libmd5-perl.
Unpacking libmd5-perl (from .../libmd5-perl_2.03-1_all.deb) ...
Selecting previously deselected package libnet-ssleay-perl.
Unpacking libnet-ssleay-perl (from .../libnet-ssleay-perl_1.30-1_i386.deb) ...
Selecting previously deselected package openssl.
Unpacking openssl (from .../openssl_0.9.8e-5ubuntu3.1_i386.deb) ...
Creating directory /etc/ssl
Setting up libauthen-pam-perl (0.16-1) ...
Setting up libio-pty-perl (1:1.07-1) ...
Setting up libmd5-perl (2.03-1) ...
Setting up libnet-ssleay-perl (1.30-1) ...
Setting up openssl (0.9.8e-5ubuntu3.1) ...


Step 3: Install the webmin package as root using dpkg.

sudo dpkg -i webmin_1.410_all.deb
This was the response:

Selecting previously deselected package webmin.
(Reading database ... 33791 files and directories currently installed.)
Unpacking webmin (from webmin_1.410_all.deb) ...
Setting up webmin (1.410) ...
Webmin install complete. You can now login to https://myserver:10000/
as root with your root password, or as any user who can use sudo
to run commands as root.

Step 4: You're done! Login to the server using your web browser and point it to the address it indicates.

Sunday, March 23, 2008

The best things in life are free

Ever had one of those weird moments when you check out what's stuck in your wallet and compare it with that of your buddies? I'm not talking about how much money you have, but all of the other things - receipts, drivers license, club cards, gym memberships, packs of sugar, ...? (Think George in that old episode of Seinfeld...)

Well, this post is all about what's stuck in your development environment. Perhaps one of the biggest lessons I have learned over the past few years is that some of the best development and I.T. tools out there don't have to cost you an arm and a leg. There was once upon a time when we subscribed to a different model: the pay-as-you-go model, where every time we ran into a problem, we'd call up our favourite vendor and "discover" what next big purchase we would need to make to solve the problem.

No longer. Now, thanks to a plethora of good open-source or economical commercial software, one no longer has to pay big bucks to develop good software.

Here's what I have installed:
  • Eclipse Europa -- this is my main integrated development environment. Within Eclipse, I use a variety of plugins and environments. I develop using Java 6, unit test with JUnit, manage my configuration using Subversion and Subclipse, integrate using Ant, and task manage using Mylyn.
  • Mozilla Firefox -- this is my main browser. I enjoy using this browser immensely because it is cross-platform, and because it is not tied to my operating system, is relatively secure.
  • GVIM - for all editing tasks I don't use Eclipse for. It is a trusty, albeit expert-friendly friend (vi) ported over to Windows. It is free and even does colour syntax highlighting.
  • Beyond Compare - about the best diff/compare/merge tool out there for Windows. It is not free, but the $30 license fee isn't going to kill you either. I highly recommend this tool as it does not only file comparisons, but does wonderful directory comparisons which is great for synchronizing directories.

Now for some of the back office stuff:
  • Bugzilla Bug Tracking System - tracks our defects and bugs and integrates nicely into Eclipse thanks to a nifty Mylyn connector plugin.
  • Subversion - handles all of our source control and configuration management
  • Bugzilla uses PHP, and MySQL extensively while both use the Apache Web Server which Ubuntu Server (based on the very versatile Debian linux distribution) does a nice job of pre-installing for you.
  • Almost all of these servers run as virtual machines on VMServer - a commercial but free product from VMWare that allows you to run more than one virtual machine on a given server. Great for lab testing products and hosting virtual servers.
  • The remaining stuff such as our Java Web Start deployment server runs on an instance of Apache Tomcat.
  • Apache ActiveMQ acts as our messaging server.

We have made similar utilizations in everything from our networking to even the on-hold music on our telephone system. It's not that we don't run commercial products. But, with the availability of open-source, community driven, community debugged programs available, IT professionals and developers are offered a much greater choice. The focus shifts from product-driven focus (and trying to find which product fits the budget) to a problem solving focus where real problems can be solved by expertise, experience and knowledge of how best to integrate the available open-sourced or commercial products together to make a working environment. Best of all, you can keep most of that big fat wallet of yours in your back pocket because you won't have to take it out very often. :-)



Those are my two bits. What about yours? What are the pros and cons of open source software in your environment? Hit me up in the comments.