Aug 28

Last night I finally finished cutting all my server services to their new residence on Pukwudgie (my spectacular CentOS 5.3 based server VM). I turned off my old Thinkpad server, which has been doing the job reliably for over 2 years, rebooted pukwudgie just to make sure everything starts up correctly unattended and that was that. My first impressions are that everything seems to run faster. I really expected that, though, because there are a lot more resources available to Pukwudgie than there were to the old server. I am loving it so far and it sure is nice to have an up-to-date server. The old server was running Ubuntu 6.10, which was so old I couldn’t even get security patches for it anymore and this new CentOS server is completely current.

Hopefully this is a move for the better, and I can probably offer the old lappy/server on FreeLinuxBox.org too!

Aug 26

new-servers
Lately, I have been slowly migrating my server services from my ancient Thinkpad server to a VM on some real server hardware. This has been an arduous process, mostly because this is my own personal server, which means I am #1 strapped for time, #2 deprived of ambition when home and #3 insanely paranoid about screwing up any of my data.

I mentioned recently about how to set up a fakie mail server, which is what I have used for a long time. Well, oddly enough, the *new* portion of the server setup is quick, easy and works great. The hard part of that, which I didn’t mention on the previous post was data migration. You see, on the old server I used UW-IMAP and on the new one am using Dovecot IMAP. They both are set to use Maildir, so I just copied the folders from one machine to the other. Somewhere in there there is something funny in how each uses the folder structure. I noticed the problem immediately when using Alpine to get email from the server that it couldn’t find the previously configured folders. It turns out that I had to rename them to INBOX.foldername on the new system instead of just foldername and then things would mostly jive. I still had to make a few mail client tweaks, which were irritating, but hey, I got mail!

Once mail was running, I set out to get my webdav share working. That’s a pretty easy process and you can find a good instructable at http://www.cyberciti.biz/faq/rhel-fedora-linux-apache-enable-webdav/. I have used webdav fileshares for quite some time now and really dig them despite the fact that it’s a crap shoot if such-and-such version of nautilus will work with them (/me grates teeth at nautilus). It still makes for good document portability.

I set up subversion (dav) as well. This is a must have for any coder of any kind and a great tutorial for this is at http://wiki.centos.org/HowTos/Subversion. Once again, I pretty much copied my repo files from one machine to the other, and I even renamed the base repo on the way. Everything just worked and retained my logs and revision history, etc. Good stuff!

I installed LAMP on the server and moved over my intranet php code and databases and set up ntpd (a time server).

Lastly I installed bind on the new server so I can keep my dns going. That was a little bit more of a pain as the installs are *way* different between Ubuntu (old server) and CentOS (new one). CentOS uses a jailed instance, a different directory structure and a slightly different config setup as well. The tutorial at http://www.sanhom.com/?p=83 was invaluable at getting things going.

Whew, we are almost there! The only things I have left to do is setup my music server (GnuMP3d) and dhcp server, bothl of which are pretty much a piece of cake. After that I am ready for the momentous unplugging of the old machine :-)

I wonder how Dann managed all this in just one night?! :-)

Aug 20

What is a personal IMAP mail server and why would you want one? Well, such a server is, like it sounds, your very own mail server that you can access via IMAP. You might want such a thing because, like me, you have a lot of different email accounts in different places and you want to collect them all into one central and easy to manage location. I also like having more direct control over my access to my email. For example, if your email account at somewhere.com stops working because their server is down and you need to reference an email stored there, you are out of luck, unless you store your somewhere.com email on your own email server where you can still access it even though their server is inaccessible.

Since I am doing some personal server upgrades and migration, I thought it would be great to share just how to get this kind of server up and running with the most minimal hassle.

For starters, my new mail server is going to be a 32 bit server install of CentOS 5.3. This OS is not at all difficult to install at all and it’s enterprise ready, so it’s plenty reliable.

When you have a machine ready with CentOS running on it, you will need to install Dovecot to handle your IMAP mail access. This is just an yum install away:

yum -y install dovecot

You will need to configure Dovecot after the install. Edit the /etc/dovecot.conf file and make sure the following is set and uncommented:

protocols = imap imaps
mail_location = maildir:~/Maildir

CentOS uses a sendmail/procmail mail combo by default, so in order to make sure your server and IMAP are both using Maildir (so your email gets delivered to you locally) you’ll need to create a file called /etc/procmailrc and in it put:

DEFAULT=$HOME/Maildir/

And then restart your mail service (just to make sure):

service sendmail restart

Once that is set, you will need to turn on Dovecot!

chkconfig dovecot on
service dovecot start

At this point, you should be able to (firewall issues not withstanding) connect to your new mail server via IMAP and see that you have no mail. I am assuming that you have set up mail clients before, the only difference now is you will point to “YourNewMailServerName” and set it up for IMAP mail and use your account name and password from “YourNewMailServerName”.

For example, I created a new server called “Pukwudgie.linc.lan” and created an account on it called linc and made a supersecret password. When I set up my mail client to test the mailserver setup, I set it up to point to Pukwudgie.linc.lan using my username of linc and my password of supersecret via the IMAP protocol. I was able to log directly into my new mail account, which was completely empty.

At some point, you will want to SEND some mail from this account. Since this personal IMAP server is just a place to HOLD your emails, you will need to configure your email client to use your ISP’s smtp address to send through. Follow their instructions for doing this. Most ISP’s do not allow you to use any smtp server other than their own these days.

Now for the fun part. You wan to collect your mail from other places and store it here. This is accomplished through the use of fetchmail. You will need to place a “~/.fetchmailrc” file in your home directory. Please refer to the fetchmailrc man page for full details, but in essence mine looks a lot like this:

poll lincisgreat.org user "linc" there with password "itsasecret"

And you can have as many of those lines in that file as you have email accounts. After creating the rc file, you can run fetchmail to get your mail and have it delivered locally on your new server, where you can access it via IMAP. There are several methods of running fetchmail. You can run it by itself and watch the output as it goes each time, you can run it in daemon mode by starting it with the -d command line switch and specifying a time interval:

fetchmail -d 60

Will check for and grab your email every 60 seconds. Or you could put fetchmail in your crontab and have cron manage getting your mail like so:

*/5 * * * * /usr/bin/fetchmail &> /dev/null

Which would check your email every 5 minutes.

Aug 19

As previously mentioned, the Planet TLLTS website at http://tllts.org/planet is now up. Please adjust your rss feeds settings if necessary.

Aug 18

Linux Mint

Linux Mint


Just a quick note on how to get Firefox 3.5 running on Linux Mint 7.


sudo apt-get install firefox-3.5
sudo rm /usr/bin/firefox
sudo ln -s /usr/bin/firefox-3.5 /usr/bin/firefox

Pretty easy a?

Aug 15

In between bouts of making Linc’s World Famous Potato Soup, I had a few minutes to do some catch-up coding today on FreeLinuxBox. It desperately needed an rss feed, so that is what I coded up. How else are you supposed to know there is new stuff there right? Well, all finished and added the feed to LinuxPlanet.org, which you should be subscribing to if you aren’t already :-) If you are just looking for the FLB feed, you can find it at http://freelinuxbox.org/rss/rss.php.

Speaking of Free Linux Boxes, Russ, The Techie Geek, was the latest person to put a box up on FLB and he has a GREAT idea. He wants local pickup (because of weight no doubt), but he said he’d be wiling of delivering to the Ohio Linux Fest. Outstanding idea. If you, like me, have some boxes you are putting off giving out because of the hassle in shipping, perhaps following Russ’ example could be the answer!

Aug 14

ptl
A while back I wrote a little bash script called IdentiBash, which, oddly enough, let me post and read to/from my lacomica account via the bash command line. Well, as of late I decided that that script really didn’t work very well with the xml/rss style feeds. It needed updating. Instead of turning to bash again it occurred to me that php5 has simplexml built in now. Well, that makes things really easy! In just a few minutes I cranked out a command line php script that will let me grab posts from Twitter, Identica, and Laconica servers. It works like a top too. The script is not complete yet as I am not sure quite yet what else I really want it to do and how I want it to handle those things, but it is a great start to any such project and I thought I would share. Especially for those people still using IdentiBash, this reader works much better and it’s really easy to expand upon if you are at all familiar with php. So here you have it, “ptil.sh”..

By the way, if you do anything wonderful with it, let me know, I’d like to see!


#!/usr/bin/php
$user="your_user_name";
$passwd="your_password";
#$puburl="http://stream.tllts.org/identica/api/statuses/friends_timeline/$user.rss";
$puburl="http://twitter.com/statuses/friends_timeline/60602470.rss";
system("curl -s -u $user:$passwd $puburl > /tmp/tweet.tmp");
$rss = simplexml_load_file("/tmp/tweet.tmp");
foreach ($rss->channel->item as $item)
{
echo "---------------------------------\n";
echo $item->pubDate."\n";
echo $item->title."\n";
}
?>

You’ll notice 2 puburl lines in there. The first is how I access my account in laconica/identica and the second is for twitter. They are given as examples and you’ll have to replace with your own urls. Simply put your info on the appropriate spots, make it executable and run it from the command line.

Aug 13

With the help of RFQuerin, the internet’s own Open Source graphics master, I have updated the logo merchandise stores for The Linux Link Tech Show, Free Linux Box, and Linux Planet. It’s all great stuff so check them out and support a project by flying it’s colors on a T-shirt or maybe even a coffee mug. We don’t make a dime off this stuff, strictly publicity and it’s real nice to see someone at a conference wearing a T with a logo of a project your are involved with too!

http://cafepress.com/tllts
http://cafepress.com/freelinuxbox
http://cafepress.com/linuxplanetorg

Aug 10

Here’s your notice. If you subscribe to the TLLTS Planet feed, I will be shortly changing the software from it’s current Planet Planet to WordPress (a la LinuxPlanet) feed aggregator. This will help ease some server migrations here at the house. Sorry for any inconvenience.

preload preload preload