Found a search add-on for Firefox if you are into electronics – Octopart has a search plugin written for Firefox which can be installed here. Very handy if you are constantly looking up datasheets or part numbers.
This question stumped me for awhile several years back, at the time I was working from home and my ISP would block SMTP relaying to any host other then their own (as most typically do). I already had a free Dynamic DNS account with DynDNS and decided to add their inexpensive Mailhop Outbound service which worked great and solved all my problems for a whole $15/year*. Thinking about it more I figured it would be make sense to utilize it further and have my Linux server relay any emails to my cellphone/Blackberry, especially any mdadm monitoring alerts for my RAID-5 array. However I was having difficulting locating quality documentation configuring relayhost SMTP authentication in sendmail. It’s a simple setup now with Postfix (and probably sendmail too), but at the time I was running Fedora Core and just switched to the brand-new Warty release (I wasn’t kidding when I said some time ago).
Here are some basic configuration steps. We will be using mail.myrelayhost.com and testing delivery to bob@aol.com as an example. I have not tested this with DynDNS relaying in some time now but I see no reason that would prevent it from working if you use their service. Note: These commands must be run with root permissions via sudo.
I was taking a mid-afternoon nap (yes at 3 am, I work nights) and I came back to my PC to see CPU usage on my server hovering around 15% – not at idle like usual. Doing a quick check revealed md0_raid5 and md0_resync running which is normally not a good sign.
mdadm –detail /dev/md0 showed the following:
Update Time : Sun Oct 5 03:22:19 2008 State : clean, recovering Active Devices : 4 Working Devices : 4 Failed Devices : 0 Spare Devices : 0 Layout : left-symmetric Chunk Size : 64K Rebuild Status : 85% complete
Uh oh. Why was the array rebuilding itself? All drives were listed as active and working … but did we experience a drive momentarily dropping from the array or a SATA device reset? Was this a sign of impending hardware failure? Tailing /var/log/messages displayed this useful piece of information:
Oct 5 01:06:01 rigel md: data-check of RAID array md0
Ok, so “data-check” doesn’t sound so worrysome. A quick Google search revealed this nice gem:
root@rigel:~# tail /etc/cron.d/mdadm # By default, run at 01:06 on every Sunday, but do nothing unless the day of # the month is less than or equal to 7. Thus, only run on the first Sunday of # each month. crontab(5) sucks, unfortunately, in this regard; therefore this # hack (see #380425). 6 1 * * 0 root [ -x /usr/share/mdadm/checkarray ] && [ $(date +\%d) -le 7 ] && /usr/share/mdadm/checkarray --cron --all --quiet
Ah, so this is the first Sunday of the month and the check kicked off at 1:06 AM. You trixies Ubuntu. Apparently a bug has been filed causing performance issues on some boxes. Good idea to verify data integrity, although slightly more obvious notice would be nice.
When I originally build my NFS/NAS server I decided to go for a software-based RAID 1 array for the OS install itself. The storage drive was RAID-5 based but that is a different story. I can’t recall the specifics exactly but I do remember a few times having difficulty booting off of the second drive and during the rebuild thought a slightly different design would be worth a try. Since I had two identical drives from the array I figured the mirroring was a good idea, it was just the mdadm driver that I wanted to avoid. Instead a manual mirror with rsync was in order.
I did base my design upon some very good backup reference information. Plus with this way it would be easy to boot from if ever needed and take tar archives of the data without dealing with file consistency or modification issues.
Here’s how it works: