Categories
FORALL Linux oracle RAID Sharepoint Windows Server

It’s still working

Its been over two weeks now that I’ve had my Linux file server running and I am quite impressed with Linux. Its quite stable and reasonably quick. I don’t think anything can come close to FreeBSD however. I will miss BSD, but when it comes to stability vs. speed – stability wins every time.

I have thrown a lot at the server and nothing has broken the mirror. I only had two problems with the boot up process which I rectified as an incorrect configuration in the RAID. I had hard-coded in the partition names into the RAID startup file by accident. As anyone who uses Linux knows, the disk names can change occaisionally so it is not wise to refer to them in the fstab or mdadm.conf file directly. You have to refer to them by UUID.

Speed-wise it is significantly slower than FreeBSD. I suspect BSD can handle threads and DMA better. As well the device drivers are probably also better written. BSD is less fragmented development wise and thus I think there is more coordination and quality checks. Then again, FreeBSD couldn’t keep my SATA based RAID together whilst Linux can. I also discovered during this process that whilst SATA II is capable of 3Gbps transfer, each individual disk maxes out at either UDMA/100 or UDMA/133. Confusing to say the least.

I got my Windows Server 2008 going as well. Installation was dead easy – just pop the DVD in and follow the prompts. Setting the administrator password was tricky, as I did not realise that it needs to be a minimun 7 chars with a mix of letters upper and lowercase and numbers. Once in I was able to turn off that password policy. I don’t need it. SQL Server 2008 CTP went quite easily as well. But this is the CTP and I will need to re-install it at a later date, when SQL Server is released. This will be interesting as I have also installed Sharepoint 3 on the machine, and I wonder how the two will interact. I had some trouble getting Sharepoint to recognise my credentials from the other machines. I think I have it sorted, I am not running a domain and perhaps this is why? Any tips would be most welcome.

In other news I discovered the FORALL construct in Oracle. This is a fantastic operator and saved me from pulling my hair out. I needed to transfer 1M records from one database server to another – whilst consolidating the records through a map. I used a cursor with BULK INTO set at 1000 and a commit after inserting the 1000 records. This was done to help reduce Oracle undo as well as redo. Even on my fast servers this took ages to even get half-way through. Using FORALL cured my problem, reducing the transfer time to less than 10minutes! Fantastic.

Next time I have my first experience with mySQL and maybe some Linux tuning.

Categories
FreeBSD Linux RAID Ubuntu

A Switch for the better?

Previously I wrote about my problems with FreeBSD and one of my machines. Well the problem seemed to get worse and caused several system crashes and some data corruption. Much of the problem seemed to centre around copying large files on the single disk. This is not a good situation for a office file server. And the staff are less than impressed.

I still like FreeBSD however. It is light, its fast and relatively easy to setup and use. But it just wasn’t reliable on my hardware for some reason. Hopefully the BSD developers will figure out what the problem is and sort it out.

So, on Friday, I decided to drop BSD and go with linux. The difficult choice with linux is which distribution to go with. There are hundreds of them and dozens of server products – like SME Server – built on them. I chose to go with Ubuntu, well Xubuntu specifically, though choosing between OpenSUSE and Ubuntu is a toss up these days.

The install went very easy, getting the desktop up was easy. Next to get the 320Gig disks sorted out. I formatted on ext3 and mounted the other as a UFS2 read only partition. Copied the data over and then began to rebuild the RAID 1. There is plenty of info on software RAID in linux, but most examples deal with creating one from install. I had lost hope until I found http://www.linuxconfig.org/Linux_Software_Raid_1_Setup.

A bit of work with gparted, fdisk, sfdisk and viola! My RAID was back up. I don’t find the linux RAID as user friendly as the BSD one. Linux requires using the unfriendly tool mdadm and getting status and disk activity doesn’t appear to be as nice. So far my copying tests haven’t broken the I/O system and the RAID…we’ll see how it goes.

Overall Linux appears impressive. But I have had a couple of niggles. On one reboot the machine hung and dropped me into some system with a ‘(intramfs)’ prompt. Would like to know what that is. On another reboot the system hung on NFS restart. Clearly linux is not meant to be rebooted! Xubuntu also seems to use a lot more memory than BSD especially when running X. For that reason I have disabled the X login screen at boot.

Now to get the Samba/CIFS server back up and get my NFS back and working.

Then I have to get on to Windows 2008 Enterprise Server and Sharepoint 3. Wish me luck as I also intend to install SQL Server 2008 CTP on to it!

Categories
FreeBSD Linux RAID

Unhappy Fun with FreeBSD RAID

About one month ago I bought a second-hand PC from a charity with hopes to use it as a RAID server for my and my wife’s businesses. It was a older Celeron 800Mhz with 256M RAM, a 11Gig HD and a CDRW. Perfect! I thought.

I went out and bought two 320Gig SATA HD, a SATA PCI controller and 512MB DIMM. You would not believe what PC-133 memory costs these days!

Then the fun began. I started installing FreeBSD 7.0 which took a lot longer than what I had thought. The install is not as friendly as the new Linux distros I’ve used in the past. After two days I had got FreeBSD installed and then went on to setup the RAID 1.

This went pretty easy with gmirror. I was very impressed. And it worked, for a while. Then one day while I was copying a 1.8Gig zip file on to it from my Windows machine, one of the drives disconnected. So I had to restore the mirror, reboot the machine and then wait as it took 4hrs. to rebuild the mirror.

The next day I then had to use the zip file and extract it to my CentOS box to install Oracle. The same thing happened. This time I backed up all the files on the mirror and re-labelled and newfs’d the disks and made sure Soft-Updates is off. I then tested it by copying the zip file to another directory on the mirror. The drive failed again! This was getting ridiculous now.

I asked around on the forums and someone suggested the 235W PSU wasn’t big enough. I replaced it with a 380W PSU and tested again. Same result.

I’m not sure what’s going on here. I don’t know if its the drives, the way I’ve labelled them. The SATA card, it is a SiL 3512-based generic card. Or a bug in BSD, maybe my CPU isn’t powerful enough! Though I find that last thought hard to believe.

I’ve submited a problem report. In the meantime I’m not using gmirror and have to do with a single hard-drive with a cron job to copy the contents to the other hard-drive at night – as part of the periodic maintenence scripts. I’m also contemplating moving to a Debian or SUSE distro is stable with my hardware.