Pio’s work related musings

Pio’s work related musings

David  //  

Feb 12 / 6:53am

Dell iSCSI Tape Library devices not appearing

The Dell TL2000 and TL4000 tape libraries both have the option to be used with iSCSI.  This comes in the form of a SAS to iSCSI bridge which installs in the unit.  The SAS ports are then connected to the Bridge card with an adapter cable (supplied) and the network ports on the card  are connected to your iSCSI network.

The microsoft iSCSI initiator is used to connect to the iSCSI bridge which presents the tape library hardware as a series of targets.

At first glance the first target appears to be duplicated but do not be fooled (like I was).  These are actually the first tape drive *and* the robotic library itself.

Once all the devices are logged on, you should see the Robotic library and all the drives in your changer in backup exec although you may need to rerun the device detection wizard in BE first.


     
Click here to download:
Dell_iSCSI_Tape_Library_device.zip (131 KB)

Loading mentions Retweet
Filed under  //  TL2000   TL4000  

Comments (0)

Nov 5 / 11:54pm

Removing old hidden devices

Usually this is an issue when you change a network card and want to reuse the original IP.  The old driver and device is still registered in windows even though it's gone from device manager even if you select show hidden devices, so windows winges about duplicate IPs.  It'll still work mind, but it's not the neatest way to keep your windows.

The answer, in a command prompt, run the command set devmgr_show_nonpresent_devices=1 then start the device manage snap-in devmgmt.msc.  Then when you show hidden devices it'll also show devices that are no longer in the system.

Loading mentions Retweet
Filed under  //  windows  

Comments (0)

Oct 21 / 4:26am

Monitoring VMware vSphere ESX4 with Dell ITAssistant with SNMP

This is a howto for setting up SNMP on VMware vSphere ESX4 to work with ITAssistant, written because there's precious little documentation on the matter and what documentation exists is quite often misleading or plain wrong!  Vmware in their wisdom have completely changed the way SNMP is configured in vSphere ESX4 (note not ESX4i which is a completely different kettle of fish and covered elsewhere).  This means (young padawan) you have to unlearn everything you knew and any documentation for pre-vSphere can be pretty much thrown out of the window.  The version used was 4.0.0 but should apply to future versions too.

Install Openmanage 6.1.x or higher

This is done the same way as on older vmware servers or linux systems.

1) download and unzip the Openmanage redhat package (OM_6.1.0_ManNode_A00.tar.gz) from the dell website to someone on in your vmware service console.

gzip -d OM_6.1.0_ManNode_A00.tar.gz
tar -xvf OM_6.1.0_ManNode_A00.tar

This will give the following files/volders:
COPYRIGHT.txt
docs/
license.txt
linux/
setup.sh

2) Run setup (as root) and select the first 3 options
sh setup.sh

##############################################

Server Administrator Custom Install Utility

##############################################

 

  Components for Server Administrator Managed Node Software:

 

    [x] 1. Server Administrator Web Server

    [x] 2. Server Instrumentation

    [x] 3. Storage Management

    [ ] 4. Remote Access Core Components

    [ ] 5. Remote Access SA Plugin Components

    [ ] 6. All

 

  Enter the number to select a component from the above list.

  Enter q to quit.

 

Then select i to install

3) start the Openmanage services
srvadmin-services.sh  start

4) Open the vmware firewall to allo access to the openmanage web interface

/usr/sbin/esxcfg-firewall -o 1311,tcp,in,OpenManage

Make sure you test it so you know openmanage is working and can see your hardware.  If you can see the disk systems, memory, cpus etc, then fix openmanage first.

Setup passive polling from ITAssistant

Passive monitoring is where the ITAssistant polls the server at a regular interval.  Supported methods in ITAssistant are CIM, SNMP and IPMI.  SNMP with the "get" string is the usual method and what this howto covers.  The ITAssistant documentation recommends creating a new readonly string for use with ITAssistant.

1) Edit the snmp conf file
/etc/snmp/snmpd.conf

2) Locate line 41 which should contain this string:
com2sec notConfigUser  default       public

3) Change the value from public to your string used with discovery in ITAssistant.

4) Append the following to the bottom of the file
smuxpeer .1.3.6.1.4.1.674.10892.1

This allows the snmp service to also serve out the Dell MIB information.

5) Restart the SNMPD service
/sbin/service snmpd restart
It often shows "failed" for the stop part but you can ignore that.

6) Restart the Dell Openmanage services for good measure
srvadmin-services.sh restart

7) Open up the SNMP service on the vmware firewall:
/usr/sbin/esxcfg-firewall -e snmpd

7) Test SNMP with the troubleshooting tool in ITAssistant (tools->troubleshooting tool).  Select the SNMP connectivity test and click the configure button to change the get string to your string (if you're not using

Alternatively use snmpwalk on the Dell MIB Tree
snmpwalk -v2c -c <your-string> 127.0.0.1 .1.3.6.1.4.1.674.10892.1
This should produce alot of scrolling text as it prints all the snmp output.

I'm still ironing out the quirks with active alerts (SNMP traps) and hope to have a definitive guide soon!

Loading mentions Retweet
Filed under  //  itassistant   vmware  

Comments (2)

Aug 12 / 1:35am

Restarting a list of servers

Windows 2003 has an enhanced shutdown command which allows shutdown of
multiple servers.
Running shutdown -i brings up a dialog box where you can enter the
list of servers.
Remember it's always good practice to put shutdown comments the mean
something so looking back in the future you'll know what was done.
Loading mentions Retweet

Comments (0)

Aug 8 / 10:13am

Resolving port conflicts

If you ever need to find out which process is holding a port open use:
netstat -b
Loading mentions Retweet

Comments (0)

Aug 8 / 6:37am

Posterous

Just found a new blogging site called posterous.  It's main feature is making blogging easy by having entries all sent via email.  While some people are used to having a web connection all the time, I find often I'm out and about and just want to do something quick and simple on my phone so being able to upload posts, photos, videos somewhere just by sending an email from the gmail client on my phone sounds great.

The only downside is it posts signatures too :)

Lets see if this works then...

Loading mentions Retweet

Comments (0)

May 13 / 8:14pm

Using ESEUTIL to recover and repair exchange databases with dirty shutdown state


There are plenty of guides on using eseutil but getting the parameters right always seems to be a case of trial an error, so here's a quick howto:

1) Copy all the original database and log files to somewhere safe. Then also copy them into a working directory. Eseutil will modify the files in situ so if it goes wrong you don't want your original files modified.

You need to have a copy of the database files (*.edb and *.stm) plus the transaction logs (Exx*.log where xx is a number relating to the information store). The location of the files is available from exchange system manager, but you really should know where they all are anyway.

I'm going to assume the temp directory for the database files is e:\temp\data and they're called exchdb.edb, exchdb.stm. If they reside in the 1st storage group, the transaction logs will be called E00.log (this is the most recent base file) and E00xxxx.log etc (these are the old logs). Lets assume these are copied to e:\temp\logs. You need to replace these with your own paths/filenames of course.

2) Check the database state and expected log files with

eseutil.exe /mh e:\temp\data\exchdb.edb

The output will show a line State: which will be either clean or dirty shutdown. If it's clean, then you don't need this article :)

It will also show which logs are required e.g. which hadn't yet been played into the database when the dirty shutdown occured. If you have any missing then you will have lost email. This generally only occurs if you lost a log drive and have replicated copies of the logs you can use.

3) "Recover" the database. This replays missing transaction logs into the database file - run:

eseutil.exe /r E00 /d"e:\temp\data\exchdb.edb"

You might receive an error that there is an outstanding database attachment. In this case use the /i switch in the command

eseutil.exe /r E00 /d"e:\temp\data\exchdb.edb" /i

4) recheck the database state with the command in 2). If it still shows dirty shutdown you need to repair the database with:

eseutil /p e:\temp\data\exchdb.edb

5) Recheck the database once more and it should show clean shutdown. At this point you should defrag the database

eseutil /d e:\temp\data\exchdb.edb

6) The file is now in a clean state and is ready to be put back into exchange so copy it back to the original location on your exchange server but don't yet mount the file. The last step before mounting the file is to get rid of any remaining errors using isinteg.exe. This tool requires the database to be in the original location on the original exchange server. It needs to be run several times until it no longer reports any errors.

7) Once the database file has no more errors you can now remount it in exchange.

Loading mentions Retweet
Filed under  //  eseutil   exchange  

Comments (0)

Feb 10 / 6:00pm

Verifying that bulk file copy

If you copy a bunch of files/folders from one disk to another and want to verify they have all copied correctly without corrupting, you can use cygwin and md5sum to verify them.

In cygwin run the following commands:

cd /cygdrive/[drive letter]/
[path]
e.g. cd /cygdrive/c/test. This is the source path to generate the MD5 hashes from.

find . -type f 2>/dev/null -exec md5sum {} \; >/cygdrive/c/temp/test.md5
This generates the md5 file which is a plain text file containing the MD5 hashes. Depending on the size of files to verify this might take a while. There may also be issues with files over 2GB in size (I haven’t tested this).

cd /cygdrive/[drive letter]/[path]
e.g. cd /cygdrive/d/destination. This is the destination where you copied the files to.

md5sum –c /cygdrive/c/temp/test.md5 | grep –i failed >/cygdrive/c/temp/test-result.log
This checks the copied files against the md5 hashes and filters the output through grep to only include failed files. c:\temp\test-result.log will contain the results of the verify.
The result is either “ok” or “failed” but you’re probably only interested in the failed files.

Loading mentions Retweet
Filed under  //  checksum  

Comments (0)

Sep 29 / 11:33pm

Wake on LAN problems - Dell 2950 servers and Broadcom NICS

Although I've been using vmware for over 3 years through various incarnations, I've only just been in a position to exploit the power-saving features in v3.5. 

At first glance it looks pretty straight forward - click the "enter standby" option and sit back and watch. No.

First off, you need to have Wake on LAN (WOL) supported on your vmotion NIC.   This isn't necessarily something you think of when setting up the patching of the virtual server - Intel PT1000 Quad Port NICs only support WOL on the first port (Dual ports also).  Others in the range might be different, but the VT1000 NICs have their own issues in vmware depending on the version of vmware installed.

Most of the servers I work on are Dell x9xx series which have Broadcom 5708 onboard NICs.  Looking in Virtual Center at the NIC configuration shows whether VMware thinks WOL is available.  I was a bit confused when I found for some servers it was available and for others it wasn't.  Dell support went through the usual steps - update the firmware, update the NIC firmware, etc. - to no avail.

I tested the WOL feature anyway with the AMD Magic Packet utility and the MAC address of the NIC and lo! it woke up.  Curiouser and curiouser.

After more research by Dell, one of their engineers discovered source of the issue (hurrah!) in the version of the Ethernet Controller Hardware.  an lspci command (run as root) reveals the version number:

05:00.0 Ethernet controller: Broadcom Corporation Broadcom NetXtreme II BCM5708 1000Base-T (rev 11)

Rev 11 is the culprit and Rev 12 servers correctly show WOL available in vmware.  Dell have escalated the issue to vmware so hopefully there will be some kind of resolution soon.

So in summary:

  1. Make sure vmotion is enabled on a NIC that supports WOL
  2. Check your broadcom NICs are Rev12 and above.
  3. Put your Host in a Cluster
  4. At least one other Host in the Cluster must be on (this does the wakeup on the others that are in standby)
  5. Enable WOL in the NIC boot bios

Blogged with the Flock Browser
Loading mentions Retweet
Filed under  //  2950   broadcom  

Comments (0)

Jun 30 / 6:12pm

Setting up wildcards with Exim4 and virtual domain

This is a quick howto for setting up Exim4 with:
1) several incoming (virtual) domains
2) some local users
3) wildcard catchall accounts to collect the emails not matching the local users
  • Setup the virtual domains in the dc_other_hostnames variable in /etc/exim4/update-exim4.conf.conf. These are the domains considered local by this installation of Exim4. Any other domains will be routed as remote mail either through the IP defined by dc_smarthost, or direct delivery through DNS lookup of the MX records, or a hubbed_hosts definition file if it exists which overrides the DNS lookups.
  • Create the local users with adduser
  • If required, create the local user sending addresses (for the From: header) in /etc/email-addresses (otherwise the local user will be stamped with the mail hostname defined in /etc/mailname)
  • Define the catchall accounts in a new a wildcard aliases file /etc/aliases_wildcards
    • # /etc/aliases_wildcards
    • #*@domain1.com: domain1-catchall-user
    • #*@domain2.net: domain1-catchall-user
  • Create a new router directive to process the wildcard aliases - the first 3 digits of the filename define which order routers are processed by Exim4. This needs to be after the local_user router which is by default 900 so any value higher than 900 will work. I've chosen 999. /etc/exim4/conf.d/router/999_exim4-config_system_aliases_wildcard
    • # This router handles wildcard aliasing using a /etc/aliases_wildcards file
    • # /etc/aliases_wildcards must exist as it is a non-standard file
    • system_aliases_wildcards:
    • debug_print = "R: system_aliases_wildcards for $local_part@$domain"
    • driver = redirect
    • domains = +local_domains
    • allow_fail
    • allow_defer
    • data = ${lookup{*@$domain}lsearch*{/etc/aliases_wildcards}}
    • file_transport = address_file
  • Check the routing works as expected
A good source of information on which config file does what in Exim4 can be found here
Loading mentions Retweet
Filed under  //  exim  

Comments (0)