Monday, June 22, 2015

Removing a file from VMFS volume fails with the error: Resource temporarily unavailable (2063629)

http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=2063629

Removing a file from VMFS volume fails with the error: Resource temporarily unavailable (2063629)

  • Deleting a file from a VMFS datastore in the vSphere Client or the vSphere CLI fails.
  • You see the error:

    Resource temporarily unavailable
  • When you attempt to delete a file from a VMFS datastore, the vmkernel.log file reports an error similar to:  
cpu6:5455056)FS3: 1393: vol 'datastore_name', lock at 173475840: [Req mode: 1] Not free:
cpu6:5455056)[type 10c00004 offset 173475840 v 158, hb offset 3338752gen 4307, mode 1, owner 51b23791-f35c96e9-44ed-3c4a92f61680 mtime 2278287
cpu6:5455056)Res3: 5696: Rank violation threshold reached: cid 0xc1d0000c, resType 3, cnum 1410
cpu6:5455056)Fil3: 15247: Max retries (10) exceeded for caller Fil3RemoveCore (status 'Lock rank violation detected')

Note: The location of the vmkernel.log file:
  • ESXi 5.5, 5.1 and 5.0: /var/log/
  • ESXi 3.5 and 4.x: /var/log/messages/

This issue occurs if an ESXi host on the vCenter Server holds a lock on the file you are trying to delete.   

To resolve this issue:

Tuesday, June 16, 2015

FileMaker 14 Offline Installation - Since FM can't write decent documentation

Purpose:  To assist installing FileMaker 14 offline as it the server doesn’t have access to the internet.


This document assumes the following:
1.      You are attempting to install with the extracted files placed in C:\Filemaker Server 14v2 (see below for instructions)
2.      You have modified Assisted Install.txt (see below for instructions)
3.      You have modified the setup.ini file (see below for instructions)
4.      You have installed the required Application Request Routing Package ref: Application Request Routing 3.0 Stand-alone package (IExpress) x64 (http://www.microsoft.com/en-us/download/details.aspx?id=47332)

Installing the application from the command line

1.      Open the command prompt
2.      Type cd “C:\Filemaker Server 14v2\files” and press ENTER 
3.      Type setup.exe /V”/log %temp%\FM14InstallLog.log ARRINSTALLED=1” and press ENTER
4.      Click NEXT through the installer and adjust as needed.  Refer to product installation documents as it is outside the scope of this document.
5.      At the completion continue with configuring FileMaker as necessary

How to extract the installation files

1.      Double-Click the installation file assuming fms_14.0.2.226 (version 14v2)
2.      It will extract automatically to a subdirectory of the version name you launched it from I.E. C:\FileMaker Server 14v2
3.      Click Cancel to break the install routine

How to modify the Assisted Install.txt file

               Assuming the directory name C:\FileMaker Server 14v2
1.      Open the file C:\FileMaker Server 14v2\Files\Assisted Install.txt in Notepad
2.      Enter the License information as indicated Name/Organization/License Key
3.      Save and Exit Notepad

How to modify the setup.in file to prevent the download prerequisite

               Assuming the directory name C:\FileMaker Server 14v2
               Assuming the pre-requisite line is PreReq0

1.      Open the file C:\FileMaker Server 14v2\Files\Setup.ini in Notepad
2.      Scroll to the [ISSetupPrerequisites] section
3.      Delete the line that indicates PreReq0=Application Request Routing 3.0 (Download).prq
4.      Delete the line that indicates PreReq0=Common
5.      Save and Exit Notepad


Tuesday, May 5, 2015

PVSCSI Processor Utilization

I find the CPU utilization interesting when using PVSCSI driver

Test Parameters:

1 GB File
10 Second duration
No write activity only read performance
Randomized
8KB
1 thread
Latency info captured
no hardware/software caching

Luns are presented in both datacenter

Intel-r1:
Datastore A6

SCSI Controller: LSI Logic SAS
VMXNET3


Intel-r2:
        Remote Datacenter
Datastore A0

SCSI Controller: ParaVirtual
VMXNET3

Server-r1

Local on SX1
Run 1, 15836.69 iops, 123.72 MB/sec, 0.626 ms, 20.20% CPU
Run 2, 14622.15 iops, 114.24 MB/sec, 0.679 ms, 18.53% CPU
Run 3, 17374.64 iops, 135.74 MB/sec, 0.570 ms, 22.66% CPU
Run 4, 15767.63 iops, 123.18 MB/sec, 0.629 ms, 18.20% CPU
Run 5, 19634.08 iops, 153.39 MB/sec, 0.504 ms, 23.16% CPU
Run 6, 20334.63 iops, 158.86 MB/sec, 0.487 ms, 23.40% CPU
Run 7, 20507.43 iops, 160.21 MB/sec, 0.483 ms, 22.73% CPU
Run 8, 20918.63 iops, 163.43 MB/sec, 0.473 ms, 22.77% CPU

Remote Read from Server-r2 on remote SXC1 server

Run 1, 4190.29 iops, 32.74 MB/sec, 2.386 ms, 21.61% CPU
Run 2, 3957.42 iops, 30.92 MB/sec, 2.522 ms, 20.91% CPU
Run 3, 3675.10 iops, 28.71 MB/sec, 2.717 ms, 19.26% CPU
Run 4, 3423.77 iops, 26.75 MB/sec, 2.913 ms, 26.76% CPU
Run 5, 3605.29 iops, 28.17 MB/sec, 2.769 ms, 19.37% CPU
Run 6, 3338.81 iops, 26.08 MB/sec, 2.991 ms, 17.77% CPU
Run 7, 2382.91 iops, 18.62 MB/sec, 4.192 ms, 12.85% CPU
Run 8, 2764.14 iops, 21.59 MB/sec, 3.613 ms, 15.66% CPU

Server-R2

local on SXC1
Run 1, 4624.96 iops, 36.13 MB/sec, 2.158 ms, 4.24% CPU
Run 2, 3652.52 iops, 28.54 MB/sec, 2.735 ms, 1.85% CPU
Run 3, 8326.79 iops, 65.05 MB/sec, 1.198 ms, 4.21% CPU
Run 4, 6511.88 iops, 50.87 MB/sec, 1.532 ms, 3.08% CPU
Run 5, 7673.32 iops, 59.95 MB/sec, 1.299 ms, 5.37% CPU
Run 6, 8512.71 iops, 66.51 MB/sec, 1.171 ms, 4.01% CPU
Run 7, 9639.73 iops, 75.31 MB/sec, 1.034 ms, 4.56% CPU
Run 8, 9401.47 iops, 73.45 MB/sec, 1.060 ms, 4.36% CPU

Remote Read from Server-r1 on SX1

Run 1, 4906.13 iops, 38.33 MB/sec, 2.034 ms, 17.31% CPU
Run 2, 4437.13 iops, 34.67 MB/sec, 2.249 ms, 14.33% CPU
Run 3, 4556.07 iops, 35.59 MB/sec, 2.191 ms, 12.64% CPU
Run 4, 4862.19 iops, 37.99 MB/sec, 2.053 ms, 14.76% CPU
Run 5, 4789.36 iops, 37.42 MB/sec, 2.085 ms, 16.89% CPU
Run 6, 4696.56 iops, 36.69 MB/sec, 2.125 ms, 14.51% CPU
Run 7, 5259.87 iops, 41.09 MB/sec, 1.897 ms, 16.53% CPU
Run 8, 4713.28 iops, 36.82 MB/sec, 2.117 ms, 15.63% CPU

Tuesday, April 21, 2015

sample prompt

title = "Continue?"
$message = "If the settings are correct, Press Y to Continue?"
$yes = New-Object System.Management.Automation.Host.ChoiceDescription "&Yes", "Yes"
$no = New-Object System.Management.Automation.Host.ChoiceDescription "&No", "No"
$options = [System.Management.Automation.Host.ChoiceDescription[]]($yes, $no)
$choice=$host.ui.PromptForChoice($title, $message, $options, 1)

if ($choice -eq 1){Write-Warning "You pressed no.  Exiting script routine.";break}
Else { 'Do something Special }

Use User Credentials in MDT 2013 to Run Powershell Script

#UserName
$tmpuser=$tsenv:UserID
$tmpuser=[System.Text.Encoding]::Default.GetString([System.Convert]::FromBase64String($tmpuser))

#DomainName
$tmpdomain=$tsenv:UserDomain
$tmpdomain=[System.Text.Encoding]::Default.GetString([System.Convert]::FromBase64String($tmpdomain))

#set password to variable
$tmppassword=$tsenv:UserPassword

#Decode Password
[string]$tmppassword=[System.Text.Encoding]::Default.GetString([System.Convert]::FromBase64String($tmppassword))

#Convert to secure string
$mypassword=ConvertTo-SecureString -String $tmppassword -AsPlainText -Force

#format domainname\username for PSCredential object
[string]$tmpFQusername=$tmpdomain + "\" + $tmpuser

$creds = new-object System.Management.Automation.PSCredential($tmpFQusername,$mypassword)


Place the above code into your custom scripts to use PScredentials

Monday, April 13, 2015

Living List of Hotfixes for various components at Microsoft.

List of Failover Cluster related hotfixes post RTM for Windows Server 2012 R2 RTM



Wednesday, March 25, 2015

All about kerberos the three headed dog with respect to iis and sql

http://blogs.msdn.com/b/chiranth/archive/2013/09/20/all-about-kerberos-the-three-headed-dog-with-respect-to-iis-and-sql.aspx

Wednesday, February 25, 2015

Using PSEXEC to execute powershell scripts remotely

I ran into an issue where I found myself having to hit the any key to complete a psexec call to a batch file that launches powershell. The workaround was to add -inputformat none to my launch parameters for powershell.

example: powershell -inputformat none -file C:\scripts\StampBackups.ps1 -executionpolicy bypass 

ref http://stackoverflow.com/questions/4238192/running-powershell-from-msdeploy-runcommand-does-not-exit/4239192#4239192

ref https://connect.microsoft.com/PowerShell/feedback/details/572313/powershell-exe-can-hang-if-stdin-is-redirected

Monday, February 9, 2015

Migrate tons of groups and users

So I had to create a bunch of local groups and populate them with accounts from active directory as determined by a query on the server I was migrating from. There was probably a hundred groups defined, with tons of users in each. 2 scripts to get this done, sure I could spend more time to consolidate into one but time was of the essence. Please test, I'm not responsible for your environment. Script 1. I used this to collect the info. I found this out on the web, I forgot who created it otherwise I'd give them credit. I did modify it further suit my needs. Trap {"Error: $_"; Break;} Function EnumLocalGroup($LocalGroup) { $Group = [ADSI]"WinNT://$strComputer/$LocalGroup,group" "Group: $LocalGroup" # Invoke the Members method and convert to an array of member objects. if (($LocalGroup -ne "HelpServicesGroup" -or $localgroup -ne "Guests")){ $Members= @($Group.psbase.Invoke("Members")) $Collection = @() ForEach ($Member In $Members) { $path = $Member.GetType().InvokeMember("Parent", 'GetProperty', $Null, $Member, $Null) $Name = $Member.GetType().InvokeMember("Name", 'GetProperty', $Null, $Member, $Null) $collection += "$LocalGroup;$path/$Name" } $collection|Out-File -FilePath $filepath -Append } } # Specify the computer. $strComputer = (Read-Host "What Computer") "Computer: $strComputer" #specify the file path $filepath = (Read-Host "File path to export results to" $computer = [adsi]"WinNT://$strComputer" $objCount = ($computer.psbase.children | measure-object).count $i=0 foreach($adsiObj in $computer.psbase.children) { switch -regex($adsiObj.psbase.SchemaClassName) { "group" { $group = $adsiObj.name EnumLocalGroup $group } } #end switch $i++ } #end foreach Script 2. Reads CSV and breaks it out $PATH = (read-host "Please type the file path to your semi-colon delimited file") $groupsNusers = Import-Csv -Path $PATH -Delimiter ';' $remotecomputer = (read-host "Please enter the computername"") foreach ($strCollection in ($groupsNusers)){ $localgroup = $strCollection.group $aduser=$strCollection.user.ToString().Replace("\","/") try { $user = [ADSI]("WinNT://$aduser") $New = [ADSI]"WinNT://$remotecomputer" #create groups $NEWgroup = $NEW.Create("Group","$LocalGroup") $NEWgroup.setinfo() $objGroup = [ADSI]"WinNT://$remotecomputer/$LocalGroup,group" $objGroup.PSBase.Invoke("Add",$User.PSBase.Path) } Catch [System.Management.Automation.MethodInvocationException] { if ($_.Exception.HResult -eq "-2146233087") {write-host "$aduser is already in $localgroup";continue} else {Write-Error "Unhandled error:" + $_.exception;Break} } Catch {Write-Error $_} } $PATH = "" $groupsNusers = "" $aduser="" $localgroup=""