• Home
  • About Me

ukstokes.com

tech stuff from a tech bloke

Feed
  • Vista backup is stupid.

    Jan 6th 2008

    By: ben

    No comments

    I've been trying to get Vista to backup files to another computer on the network, and it's just not having it.

    The remote machine is a Linux computer on the network. If I click open the Vista menu, and then type \\servername\backups, it opens straight away and I can drop files in there and do whatever I like in the remote location.

    But, when I use "Backup status and configuration" to set up a new backup job and set the remote location to "\\servername\backups", first it asks for a password (which I enter - this is the Unix password for user Ben), then I get this message:

    Error Message
    Vista doesn't like Samba?

    But that's not the end of it. If I then go back to my remote backup location, I can see a new file in there called SDT97DB.tmp and a folder with a randomly generated name - so, it clearly can access that location as it has created folders and files there!!

    Not sure if this is a bug with Vista or a compatibility issue with Samba but it's damn annoying!

    Technorati Tags: Vista, Backup, Buggy Windows

    Windows Vista

  • Script to remotely backup multiple IIS metabases

    Aug 20th 2007

    By: ben

    No comments

    This is a script to backup IIS metabases to a network share. To run this script you need to create a file called iisservers.txt in the script's working directory and add the names of the IIS servers into it, one on each line. Substitute servername and sharename with the destination on your network. The forfiles statements will delete backups older than 7 days. The -7 variable can be changed to suit your needs.

    Some of the text has wrapped to the next line due to the formatting of this blog but when copied and pasted the unnecessary line breaks are removed.

    if exist o:\MetabaseBackup goto backup
    net use o: /delete /Y
    net use o: \\servername\sharename\London\Metabase

    :backup
    for /F %%i in (iisservers.txt) do cscript c:\windows\system32\iisback.vbs /backup /s %%i /b %%i_metabase /b %%i_metabase /overwrite
    for /F %%i in (iisservers.txt) do xcopy \\%%i\C$\windows\system32\inetsrv\metaback\*.* o: /y

    :cleanup
    o:
    forfiles /m *.MD* /D -7 /C "cmd /c del @file"
    forfiles /m *.SC* /D -7 /C "cmd /c del @file"
    c:
    net use o: /delete /Y

    The script can then be configured to run as a scheduled task, using an account with the appropriate permissions to your IIS Servers.

    For backing up SSL certificates there is a vbscript on Technet that can do all certs in a batch job, as appose to one site at a time as with IISCertDeploy.vbs in the IIS 6 Resource Kit.

    Technorati Tags: IIS, Metabase, Scripts, Backups, Windows 2003

    Windows Servers

  • How to repair a trashed IP stack on Windows 2003

    Aug 7th 2007

    By: ben

    No comments

    Last week I had a BSOD error on one of my MailSweeper servers. Afterwards when it booted into Windows it had disconnected itself from the network and the IPSec service would not start. I'm sure they were having a good laugh at Microsoft when they decided how to word this error message:

    Cannot start the IPSec Service
    What failed?

    The winsock stack can be reset from a command prompt using:

    netsh int ip reset resetlog.txt

    However in my case it was throwing up this error:

    Initialization Function InitHelperDll in IPMONTR.DLL failed to start with error code 10107
    The following helper DLL cannot be loaded: DHCPMON.DLL.
    The following helper DLL cannot be loaded: WINSMON.DLL.

    Thinking back to my NT4 days it used to be possible to reinstall the IP stack by simply removing and adding the TCP/IP protocol, but in Windows 2003 (and XP) it's a core component of Windows and the 'Uninstall' button is disabled. So, if you need to do this then this technet article can be followed. If you're not doing this work on a DC, then booting up into Safe Mode is fine - that's what I did and it worked like a charm.

    Technorati Tags: Winsock, TCP/IP, Windows 2003, Administration

    Windows Servers

  • Things that MIMESweeper can’t do

    Jul 24th 2007

    By: ben

    1 comment

    Question: What happens when a user sends a 1Mb e-mail to 2000 external recipients, and also requests delivery receipts?

    Answer: MailSweeper delivery service will die and mail will start to queue on your server. Messages will build up in the 'domains' folders and in 'holding' as your the policy server becomes unable to deliver any more mail.

    This happened to me today. It was noticed early as I use an spool watching utility (free on JMC's mswtools.org) which uses blat to send alerts when the number of files in the MSW spool directories go over certain thresholds.

    According to the ClearSwift engineer I spoke to, the problem is to do with the way the delivery service can only handle 50 threads at a time. One would imagine a policy server would cope with 2000 messages being dumped on it but apparently this will just keel it over. Multiple reboots did seem to give enough short bursts to clear the 'domains' queues apart from one internal domain containing around 800 delivery receipts and 100 business e-mails. The problem was, on most of these delivery receipts and delivery failures the original message was attached, and the queue was standing at around 900Mb. This would not clear and forcing a retry seemed to make the processing just freeze up. Unfortunately MailSweeper lacks controls on this part of the homepage to delete items in the delivery queue, so to purge all of the delivery receipts I had to delete the corresponding files in the file system on the PS. The problem to overcome then is, how do you make sure you only delete the delivery receipts when the folder is full of randomly named RCP files? I used the following commands within that domain folder to achieve this:

    findstr /S /M "Message relayed" *.RCP > output.txt
    FOR /F %I IN (output.txt) DO del %I

    Tomorrow I'll be implementing a much lower limit on the number of recipients per message that can be sent through Exchange, and of course suggesting a better method of delivering this PDF in the future. I'm thinking Morse code ...

    Edit: Just found the default in Exchange 2003 is a maximum of 64000 recipients per message!

    Technorati Tags: MailSweeper, MIMESweeper

    Messaging, Rants

  • Upgrade ESX from 3.0.0 to 3.0.1

    Jul 14th 2007

    By: ben

    No comments

    There seems to be some debate on whether in-place upgrades of ESX server are a good idea, or whether it's better to abandon old versions and go for clean installs. My opinion is that if your server is healthy and you don't have any issues or problems, then there's no need to be scared about upgrading your existing installation.

    First download it from vmware and untar it:

    tar zxfv 3.0.1-32039-full.tgz
    cd 32039
    ls

    You will the tarball contains a load of .rpm files. Updating from this directory should then be as easy as:

    /usr/sbin/esxupdate -n update

    However if you have already done some patching on your server you may receive the following error:

    INFO: 1 packages need to be downgraded.
    Please use the --force option and try again.

    Do not use the --force option in this situation as doing so will downgrade your previously installed patches. Instead, check your update log and see which packages are flagging the errors.

    grep -i downgrade /var/log/vmware/esxupdate.log

    Then use the -x switch to exclude those patches from the esxupdate.

    /usr/sbin/esxupdate -x VMware-esx-scripts.i386 -x krb5-libs.i386 -n update

    The -n switch supresses an automatic reboot so you can review the output of the command, but you will need to restart your server when the update has finished.

    Technorati Tags: ESX Server, Server Administration

    VMware

  • Patch ESX Server, the easy way

    Jul 14th 2007

    By: ben

    No comments

    I've discovered a really great tool for patching ESX servers from Windows: VMTS Patch Manager. It's a bit like WSUS in that all patches are downloaded once to a central repository and you select what you want pushed out from there. You don't need to log on to any ESX servers or spend any time at the command line, and it integrates with Virtual Centre which enables you to manage the patching of your whole virtual infrastructure by connecting to one place. All this is packaged in an easy-to-use GUI and available to download for free.

    ESX Patch Manager
    VMTS Patch Manager

    It's also clever enough to recognise patches that will downgrade your system or are not required, and it will not install them for you. It's not quite perfect and does have a few quirks and rough edges, but I would definitely recommend the download if you have an ESX deployment that needs patching. I've seen a few alternatives to VMTS Patch Manager that are basically perl scripts and http repositories, but nothing else I've seen is as good as this.

    Technorati Tags: ESX Server, Administration, ESX Patching

    VMware

  • Extending virtual disks in ESX Server 3.01

    Jul 3rd 2007

    By: ben

    4 comments

    Below is the procedure on how to extend the disk of a Windows 2003 virtual server.

    Before starting please note the following:

    • Microsoft's diskpart utility can only be used to extend dynamic disks. Before using this utility you will need to convert your disks to dynamic using the Disk Management utility in the Computer Management console.
    • System or boot volumes cannot be extended using diskpart.
    • GParted cannot manage dynamic disks. If you are resizing a system or boot disk, configure it as a dynamic disk after it has been resized. If you convert to dynamic first, you may not be able to convert it back to a basic disk.
    • Before making any changes ensure you have a backup of your server, or at the least a snapshot of your VM.

    1. Power down your VM gracefully
    2. SSH to the ESX Server hosting the VM
    3. cd to the directory containing your .vmdk disk file (you can check the name and location on the Hardware tab of your VM in Virtual Infrastructure Manager). e.g.

    cd /vmfs/volumes/vmStore

    4. Use vmkfstools to extend the disk using the following syntax: (Please use a double dash, not a single dash. WordPress automatically reformats this from a double to single dash)

    vmkfstools --extendvirtualdisk [size] [vmdk filename]

    Size can be in Mb, for example 5000m, or in Gb, for example 5g. e.g.

    vmkfstools --extendvirtualdisk 11g S05010094.vmdk

    If you are resizing your C: drive or system/boot partition, continue at step 9. Otherwise, continue below:

    5. Power up your VM
    6. In Computer Management ? Disk Management you should now see the unallocated space on the disk.
    7. Open a command prompt window and use the diskpart utility to extend the partition.

    Diskpart
    List volume
    Select volume z
    Extend size=x disk=y

    Where z = the volume number, x= the size in MB and y= the disk number in Disk Management

    8. Your server may need a restart for the changes to take effect.

    If you are resizing your C: drive , follow steps 1-4 above. Then:

    9. Obtain a copy of the GParted live CD iso, copy it to your ESX server and configure it as your CD ROM drive on your VM.

    Note: GParted will only recognize your disks if your VM's SCSI Controller is configured to emulate a BUS Logic SCSI controller. Changing type from LSI Logic to BUS Logic is dangerous. Make sure you know what you are doing or you could make your disk inaccessible to Windows.

    10. Change SCSI Controller type from BUS Logic to LSI Logic.
    11. Boot your VM from the ISO image.
    12. Use GParted to delete the extra space and extend your volume into the unallocated space.
    13. Power down VM. Change SCSI Controller type from LSI Logic to BUS Logic. Configure VM to boot from hard disk.
    14. Power on VM, chkdsk should run as part of the startup proces and your disk should then be extended.

    VMware

  • Implement an Exchange 2003 front end NLB cluster

    Jun 16th 2007

    By: ben

    No comments

    There are a few sites that explain how to implement this high availability solution:

    http://searchexchange.techtarget.com/origi...
    http://www.msexchange.org/tutorials/Imp...

    However when I tried this way I kept getting IP address conflicts. This is how I did it instead:

    • Configure OWA on both front end servers with the same certificate
    • Make sure Exchange patches are consistent on both cluster nodes
    • Create DNS A record for cluster IP address
    • If either server is created from an image (or vmware template), remove and reinstall network cards as per KB828258

    I then configured the cluster (including IP configuration on each node) using Network Load Balancing Manager from my workstation. If you use this tool to create clusters, you have to do it remotely as the cluster IP will have the same MAC Address across all nodes, and as this is configured it breaks the connectivity between the nodes.

    • Open Network Load Balancing Manager (Start - Administrative Tools - NLB Manager)
    • Cluster - New
    • Enter cluster IP address, subnet mask, and the DNS name you created earlier
    • Select Unicast mode, leave 'Enable remote control' unticked
    • Do not enter additional IP addresses or Port rules
    • On final step, add the server that will become the first node in the cluster

    When you click on Finish, NLB Manager will configure the NLB protocol and add the cluster IP address to the node. If this is successful you can then add further nodes by right-clicking the cluster name and selecting "Add node to cluster". You will notice that the NLB Manager automatically changes the priority of the new node as it is being added.

    NLB Manager
    Windows 2003 NLB Manager

    Final step is to then open IIS Manager on each cluster node and bind the cluster IP address to the OWA website.

    Technorati Tags: Exchange 2003, Network Load Balancing, NLB, Clustering

    Exchange, Windows Servers

  • Battling with BrightStor

    May 25th 2007

    By: ben

    No comments

    I really hate ARCserve products. It's not very often that I have to run an Exchange restore, but every time I do I just run into obsticles, cryptic and ambiguous error messages, and a complete lack of solutions on the ARCserve site and Google search results. What makes this worse is restores are normally required quite urgently, and when you're under pressure you don't want to spend hours faffing around getting simple things to work properly.

    On this weeks occasion after setting up my restore exactly as specified in this technote on the CA website, my restore kept failing with the following error:

    E3022
    No valid destination.

    Totals For................... Job
    Total Session(s)............. 0
    Total Databases(s)............ 0
    Total Skip(s)................ 0
    Total Size (Disk)............ 0 KB
    Total Size (DB).............. 0 KB
    Total Size (Media)........... 0 KB
    Elapsed Time................. 0s
    Average Throughput........... 0 KB/min
    Total Error(s)/Warning(s).... 1/0

    After a lot of wasted time Google searching and trying various configurations, I eventually found the solution to this problem. This is a known issue with ARCserve 11.5 SP2 and the solution is to upgrade to SP3. The upgrade files can be found here.

    Technorati Tags: ARCserve, Exchange 2003, Restores, BrightStor

    Windows Servers

  • Stuff Magazine previews the Blackberry Curve

    May 16th 2007

    By: ben

    No comments

    The Blackberry 8300 "Curve" was released on Monday. It's another full size keyboard jobbie and at first glance seems to be a redesigned Blackberry 8700 with a few extra features added. A short video preview from Stuff magazine is embedded below. RSS Subscribers may need to click on this permalink to see the embedded video.

    Technorati Tags: Blackberry, Blackberry Curve

    Blackberry

    • <
    • 1
    • ...
    • 3
    • 4
    • 5
    • 6
    • 7
    • ...
    • 9
    • >
  • Subscribe

  • Recent Posts

    • Script to list all local admins in your domain
    • Connect Skydrive as a Windows mapped drive
    • D-Link DWA-131 and Ubuntu
    • Configure a non-enterprise Blackberry handset for Exchange
    • Upgrading bugzilla from 3.0.x to 3.4.6
  • Spam Blocked

    14,695 spam comments blocked by
    Akismet
  • Recent Comments

    • deobfuscate on Deleting unwanted public folder stores
    • ben on D-Link DWA-131 and Ubuntu
    • Darryl on D-Link DWA-131 and Ubuntu
    • Andrew Montague on How to purge an orphaned mailbox
    • Orval Eske on Configure automatic login on OCS 2007
  • Categories

    • Android
    • Blackberry
    • Blogging
    • Desktop Linux
    • Enterprise Linux
    • Exchange
    • Messaging
    • Mobile
    • News
    • Nintendo
    • OCS
    • Random stuff
    • Rants
    • Scripting
    • Technology
    • VMware
    • Windows Servers
    • Windows Vista
  • Tags

    Active Directory Android Bash scripting BES Blackberry Bugzilla Cacti CentOS Citrix Desktop Linux DivX Dr DivX Enterprise Linux Google iptables K2 Wordpress 2.5 kickstart Linux Logical Volumes LVM Messaging Mobile N95 netfilter networking Open Source Performance Putty Random Rant Red Hat Red Hat Summit RHEL routing Scripting SSH thin client Ubuntu VBScript Video Encoding VMware Windows Windows Vista wireless
  • Tweets

    • Quite an interesting read. RT @engadgetmobile Apple's App Store Review Guidelines: 'we don't need any more fart apps' http://bit.ly/byrsHP 16 hours ago
    • @Jedipottsy I don't think you can unify 2 inboxes on 2 gmail accounts. Could be wrong on that though. 21 hours ago
    • RT @RogersMary: Hello!! HTC Magic+ Customers should expect HTC to start rolling out 2.1 OS today, OTA 2010/09/08
    • @Jedipottsy I use gmail for my domain (ukstokes.com). You just sign up and point your mx records to Google's servers. 2010/09/08
    • @tjralph I definitely fall into that camp. 2010/09/08

© Copyright ukstokes.com. All rights reserved.

Theme designed by Nischal Maniar