Saturday, December 29, 2012

Lion Upgrade? DNS Issues?

See here:

http://www.eigenspace.org/2011/07/fixing-osx-lion-dns-search-domains/

Tuesday, December 18, 2012

compare directories on two different servers

This is a dry-run check, based on checksums, no changes will be made on the local system:
rsync -avzc -e ssh root@propsmanager1a.sv3:/usr/local/cvsroot /usr/local/cvsroot -n

of course, this compares in the other direction:
rsync -avzc -e ssh /usr/local/cvsroot root@propsmanager1a.sv3:/usr/local/cvsroot  -n

Flush DNS cache in Linux


dnscacheutil -flushcache

Friday, November 16, 2012

heads up, pt-online-schema-change



http://www.percona.com/doc/percona-toolkit/2.1/pt-online-schema-change.html

Friday, November 9, 2012

nat an internal address:port to the outside address:port

sudo iptables -t nat -A PREROUTING --in-interface virbr+ -d 169.254.169.254 --proto tcp --dport 80 -j DNAT --to-destination 192.168.11.1:8076

Friday, September 7, 2012

excel cell formatting for KB MB GB

cell formatting for excel

[<1000000]0.00," KB";[<1000000000]0.00,," MB";0.00,,," GB"

Saturday, September 1, 2012

annoyance deferred until 10am


*/15 * * * * root /opt/dell/srvadmin/bin/omconfig system esmlog action=clear
0 10 3 9 * root /bin/sed -i -e '/esmlog/d' /etc/crontab

Wednesday, August 22, 2012

mail getting sent as wrong user from script or command line


install postfix


specify only one of the following:

in /etc/postfix/main.cf:
        mydomain = techops.thedomainhere.com

...

        myorigin = $mydomain



Error: Missing Dependency: librac4.so.[4\|6]



If you get either of the following messages:
--> Finished Dependency Resolution
dell_ie_rac_4-6.5.0-1.9.25.el5.x86_64 from installed has depsolving problems
--> Missing Dependency: librac4.so.6()(64bit) is needed by package dell_ie_rac_4-6.5.0-1.9.25.el5.x86_64 (installed)
Error: Missing Dependency: librac4.so.6()(64bit) is needed by package dell_ie_rac_4-6.5.0-1.9.25.el5.x86_64 (installed)
--> Finished Dependency Resolution
dell_ie_rac_4-6.3.0-1.22.15.el5.x86_64 from installed has depsolving problems
--> Missing Dependency: librac4.so.4()(64bit) is needed by package dell_ie_rac_4-6.3.0-1.22.15.el5.x86_64 (installed)
Error: Missing Dependency: librac4.so.4()(64bit) is needed by package dell_ie_rac_4-6.3.0-1.22.15.el5.x86_64 (installed)




do the following:
yum remove dell_ie_rac_4
yum udpate srvadmin* dell*

Tuesday, August 21, 2012

Tuesday, August 14, 2012

Upgrade your Jailbroken iPhone 4 from iOS 5.0.1 to 5.1.1

This was absolutely painless...

Download latest version of redsn0w.
Upgrade to latest version of iTunes.
Connect phone to Computer while running.
Accept offer:
- from iTunes to upgrade your jailbroken phone.
- to back up your iPhone.

Turn off iPhone while connected to computer, do not unplug.
Start redsn0w, click on Jailbreak button, next, follow iPhone power-on instructions
Wait while iPhone is jailbroken and reboots.

When iPhone has restarted, swipe the Springboard to the right and type in Cydia. Its on there, but its not got its filesystem configured, and it has a transparent icon when its not been configured yet. So, once you see that transparent icon, activate it and it should show you as message saying something about configuring the file system. For me, this message went away after about 60 seconds. The phone rebooted twice and then I had the normal Cydia icon and I was able to install Mail Enhancer Pro and it found my previous configuration (essential for techops email filtering) ....done!


Tuesday, July 17, 2012

atomic repo for centos - upgrade php from 5.1.6 to 5.2.x

http://wiki.centos.org/HowTos/PHP_5.1_To_5.2

How to restore a missing RCS-managed file
# co -p ./RCS/missing_filename,v >> ./missing_filename


How to view current locks on RCS-managed files
# rlog -L -R RCS/*

How remove current locks on RCS-managed files
# rcs -u ./filename_of_locked_file

Tuesday, May 8, 2012

Dell PowerConnect 62xx POS

Holy shit, this Dell PowerConnect stuff sucks. Never, EVER buy this shit.
Its some kind of bastardized version of a Cisco switch.

How it got into the Data Center, I will never know. Idiots at CDW I'm guessing.

I've had it with these pesky and unnecessarily weird devices.

NEVer again!!!

(I found out today that they disabled STP because there was a bug in the Dell firmware a while back. YA! Lets disable it, nevermind updating the firmware or actually getting industry-standard production hardware..)

Wednesday, March 14, 2012

esxi5: tag your raid array as SSD (if it is one)

I have four Intel 520 SSD's connected to a 9260LP-4i LSI controller plugged into a SuperMicro X8TDi

observe:


~ # esxcli storage core device list
naa.600605b00418fd8016ed05ec1a609a91
   Display Name: Local LSI Disk (naa.600605b00418fd8016ed05ec1a609a91)
   Has Settable Display Name: true
   Size: 341856
   Device Type: Direct-Access
   Multipath Plugin: NMP
   Devfs Path: /vmfs/devices/disks/naa.600605b00418fd8016ed05ec1a609a91
   Vendor: LSI
   Model: MR9260-4i
   Revision: 2.12
   SCSI Level: 5
   Is Pseudo: false
   Status: on
   Is RDM Capable: false
   Is Local: true
   Is Removable: false
   Is SSD: false
   Is Offline: false
   Is Perennially Reserved: false
   Thin Provisioning Status: unknown
   Attached Filters:
   VAAI Status: unsupported
   Other UIDs: vml.0200000000600605b00418fd8016ed05ec1a609a914d5239323630

mpx.vmhba32:C0:T0:L0
   Display Name: Local USB Direct-Access (mpx.vmhba32:C0:T0:L0)
   Has Settable Display Name: false
   Size: 956
   Device Type: Direct-Access
   Multipath Plugin: NMP
   Devfs Path: /vmfs/devices/disks/mpx.vmhba32:C0:T0:L0
   Vendor: Crucial
   Model: Gizmo!      
   Revision: 1100
   SCSI Level: 2
   Is Pseudo: false
   Status: on
   Is RDM Capable: false
   Is Local: true
   Is Removable: true
   Is SSD: false
   Is Offline: false
   Is Perennially Reserved: false
   Thin Provisioning Status: unknown
   Attached Filters:
   VAAI Status: unsupported
   Other UIDs: vml.0000000000766d68626133323a303a30

mpx.vmhba0:C0:T0:L0
   Display Name: Local Optiarc CD-ROM (mpx.vmhba0:C0:T0:L0)
   Has Settable Display Name: false
   Size: 0
   Device Type: CD-ROM
   Multipath Plugin: NMP
   Devfs Path: /vmfs/devices/cdrom/mpx.vmhba0:C0:T0:L0
   Vendor: Optiarc
   Model: DVD RW AD-7280S
   Revision: 1.01
   SCSI Level: 5
   Is Pseudo: false
   Status: on
   Is RDM Capable: false
   Is Local: true
   Is Removable: true
   Is SSD: false
   Is Offline: false
   Is Perennially Reserved: false
   Thin Provisioning Status: unknown
   Attached Filters:
   VAAI Status: unsupported
   Other UIDs: vml.0005000000766d686261303a303a30



collect info:

~ # esxcli storage nmp device list
naa.600605b00418fd8016ed05ec1a609a91
   Device Display Name: Local LSI Disk (naa.600605b00418fd8016ed05ec1a609a91)
   Storage Array Type: VMW_SATP_LOCAL
   Storage Array Type Device Config: SATP VMW_SATP_LOCAL does not support device configuration.
   Path Selection Policy: VMW_PSP_FIXED
   Path Selection Policy Device Config: {preferred=vmhba1:C2:T0:L0;current=vmhba1:C2:T0:L0}
   Path Selection Policy Device Custom Config:
   Working Paths: vmhba1:C2:T0:L0

mpx.vmhba32:C0:T0:L0
   Device Display Name: Local USB Direct-Access (mpx.vmhba32:C0:T0:L0)
   Storage Array Type: VMW_SATP_LOCAL
   Storage Array Type Device Config: SATP VMW_SATP_LOCAL does not support device configuration.
   Path Selection Policy: VMW_PSP_FIXED
   Path Selection Policy Device Config: {preferred=vmhba32:C0:T0:L0;current=vmhba32:C0:T0:L0}
   Path Selection Policy Device Custom Config:
   Working Paths: vmhba32:C0:T0:L0

mpx.vmhba0:C0:T0:L0
   Device Display Name: Local Optiarc CD-ROM (mpx.vmhba0:C0:T0:L0)
   Storage Array Type: VMW_SATP_LOCAL
   Storage Array Type Device Config: SATP VMW_SATP_LOCAL does not support device configuration.
   Path Selection Policy: VMW_PSP_FIXED
   Path Selection Policy Device Config: {preferred=vmhba0:C0:T0:L0;current=vmhba0:C0:T0:L0}
   Path Selection Policy Device Custom Config:
   Working Paths: vmhba0:C0:T0:L0

~ # esxcfg-info | grep -A1 "Default Path Selection Policy"
                  |----Default Path Selection Policy................VMW_PSP_MRU
                  |----Name.........................................VMW_SATP_MSA
--
                  |----Default Path Selection Policy................VMW_PSP_MRU
                  |----Name.........................................VMW_SATP_ALUA
--
                  |----Default Path Selection Policy................VMW_PSP_MRU
                  |----Name.........................................VMW_SATP_DEFAULT_AP
--
                  |----Default Path Selection Policy................VMW_PSP_FIXED
                  |----Name.........................................VMW_SATP_SVC
--
                  |----Default Path Selection Policy................VMW_PSP_FIXED
                  |----Name.........................................VMW_SATP_EQL
--
                  |----Default Path Selection Policy................VMW_PSP_FIXED
                  |----Name.........................................VMW_SATP_INV
--
                  |----Default Path Selection Policy................VMW_PSP_FIXED
                  |----Name.........................................VMW_SATP_EVA
--
                  |----Default Path Selection Policy................VMW_PSP_FIXED
                  |----Name.........................................VMW_SATP_ALUA_CX
--
                  |----Default Path Selection Policy................VMW_PSP_FIXED
                  |----Name.........................................VMW_SATP_SYMM
--
                  |----Default Path Selection Policy................VMW_PSP_MRU
                  |----Name.........................................VMW_SATP_CX
--
                  |----Default Path Selection Policy................VMW_PSP_MRU
                  |----Name.........................................VMW_SATP_LSI
--
                  |----Default Path Selection Policy................VMW_PSP_FIXED
                  |----Name.........................................VMW_SATP_DEFAULT_AA
--
                  |----Default Path Selection Policy................VMW_PSP_FIXED
                  |----Name.........................................VMW_SATP_LOCAL
--
            |----World Command Line.................................grep -A1 Default Path Selection Policy
            |----Cartel ID..........................................4991

now, add the rule:

~ # esxcli storage nmp satp rule add -s VMW_SATP_LOCAL --device naa.600605b00418fd8016ed05ec1a609a91 --option=enable_ssd
~ # esxcli storage core claiming unclaim --type device --device naa.600605b00418fd8016ed05ec1a609a91
~ # esxcli storage core claimrule load
~ # esxcli storage core claimrule run

observe:

~ # esxcli storage core device list
naa.600605b00418fd8016ed05ec1a609a91
   Display Name: Local LSI Disk (naa.600605b00418fd8016ed05ec1a609a91)
   Has Settable Display Name: true
   Size: 341856
   Device Type: Direct-Access
   Multipath Plugin: NMP
   Devfs Path: /vmfs/devices/disks/naa.600605b00418fd8016ed05ec1a609a91
   Vendor: LSI
   Model: MR9260-4i
   Revision: 2.12
   SCSI Level: 5
   Is Pseudo: false
   Status: on
   Is RDM Capable: false
   Is Local: true
   Is Removable: false
   Is SSD: true
   Is Offline: false
   Is Perennially Reserved: false
   Thin Provisioning Status: unknown
   Attached Filters:
   VAAI Status: unsupported
   Other UIDs: vml.0200000000600605b00418fd8016ed05ec1a609a914d5239323630

mpx.vmhba32:C0:T0:L0
   Display Name: Local USB Direct-Access (mpx.vmhba32:C0:T0:L0)
   Has Settable Display Name: false
   Size: 956
   Device Type: Direct-Access
   Multipath Plugin: NMP
   Devfs Path: /vmfs/devices/disks/mpx.vmhba32:C0:T0:L0
   Vendor: Crucial
   Model: Gizmo!        
   Revision: 1100
   SCSI Level: 2
   Is Pseudo: false
   Status: on
   Is RDM Capable: false
   Is Local: true
   Is Removable: true
   Is SSD: false
   Is Offline: false
   Is Perennially Reserved: false
   Thin Provisioning Status: unknown
   Attached Filters:
   VAAI Status: unsupported
   Other UIDs: vml.0000000000766d68626133323a303a30

mpx.vmhba0:C0:T0:L0
   Display Name: Local Optiarc CD-ROM (mpx.vmhba0:C0:T0:L0)
   Has Settable Display Name: false
   Size: 0
   Device Type: CD-ROM
   Multipath Plugin: NMP
   Devfs Path: /vmfs/devices/cdrom/mpx.vmhba0:C0:T0:L0
   Vendor: Optiarc
   Model: DVD RW AD-7280S
   Revision: 1.01
   SCSI Level: 5
   Is Pseudo: false
   Status: on
   Is RDM Capable: false
   Is Local: true
   Is Removable: true
   Is SSD: false
   Is Offline: false
   Is Perennially Reserved: false
   Thin Provisioning Status: unknown
   Attached Filters:
   VAAI Status: unsupported
   Other UIDs: vml.0005000000766d686261303a303a30
~ #