Thursday, August 4, 2016

Step By Step NLB Cluster Configuration in Multicast Mode

Need : NLB Cluster Configuration in Multicast Mode

Requirement : Windows Server Operating System
Windows Network Load Balancing Role

Process :

1. Add Network Load Balancing Role on all Servers which are participating in the NLB Cluster

2. Create New Cluster


3. Add 1st Server in the cluster.
4. Select appropriate NIC which is going to handle all network traffic of cluster











5. Add the cluster IP Address

6. Select Multicast



7.Finish the Configuration (I'm assuming that you will customize Port rules as per your requirement hence not covering here).

8. Make list of other IP Addresses which you want to add.
e.g. 172.21.21.1 to 172.21.21.10

9. Go to Cluster Properties

10. Add these IP Address in the "Cluster IP Addresses" Window

11. Goto "Cluster Parameter" Tab

12. Write all the MAC IDs of each IP Addresses
172.21.21.1     03-bf-ac-19-08-01
172.21.21.2     03-bf-ac-19-08-02
172.21.21.3     03-bf-ac-19-08-03
172.21.21.4     03-bf-ac-19-08-04
172.21.21.5     03-bf-ac-19-08-05
172.21.21.6     03-bf-ac-19-08-06
172.21.21.7     03-bf-ac-19-08-07
172.21.21.8     03-bf-ac-19-08-08
172.21.21.9     03-bf-ac-19-08-09
172.21.21.10   03-bf-ac-19-08-10

13. Do NOT Click OK

14. Cancel the Window

15. CRITICAL PART: Ask Network Team to make ARP Entries in the Network Switches for all those IP address with respect to the MAC ID

16. Ask them to Clear the ARP Cache from Network Switches

17. Again open Cluster Property

18. Add first IP Address in the "Cluster IP Addresses"

19.  Click OK.

20. Once the IP Address is reachable on network, go ahead for the second IP Address addition.

21. Repeat this step for all the IP Addresses.

22. By carefully following all the above steps, you will definitly able to configure Multicast Mode NLB Cluster.

23. All the best and Thanks for checking this out.

24. Do comment for any query.

Tuesday, May 10, 2016

Change EMC Storage Management IP Address without Storage Reboot

Issue : 
- How to Change EMC Storage Management IP Address without Reboot
- Customer needs to change the IP address, subnet mask , default gateway of a CLARiiON or VNX for Block storage processor (SP)without rebooting the Storage Processors (SP)

Scenario : EMC CLARiiON or VNX BLOCK Storage System

Solution :

1) Download and Install Naviseccli utility

 2)Run following command
Add Security Parameters
For SPA
naviseccli -User admin -Password password -Address 172.XX.XX.XX -Scope 0 -AddUserSecurity

For SPB
naviseccli -User admin -Password password -Address 172.XX.XX.XX -Scope 0 -AddUserSecurity

Get the info about existing SPs
For SPA
naviseccli -h 172.XX.XX.XX networkadmin -get
For SPB
naviseccli -h 172.XX.XX.XX networkadmin -get


Change the IP Address
For SPA
naviseccli -h 172.XX.XX.XX networkadmin -set -address 172.XX.XX.XX -subnetmask 255.255.255.0 -gateway 172.XX.XX.XX

naviseccli -h 172.XX.XX.XX networkadmin -set -address 172.XX.XX.XX -subnetmask 255.255.255.0 -gateway 172.XX.XX.XX



Congratulations! IP Address is changed!!!

Detailed Procedure from EMC Support :

 naviseccli commands will not cause SPs to reboot.
Using the CLARiiON/Block setup page in GUI causes a  reboot
Any name change requires SP reboot.

Instructions to update the SPs IP addresses, netmask and gateway IPs is below:

Before you begin:
Check to be sure the array is not part of a storage domain
Check that all hosts have dual-Fibre connectivity and that failover software is working correctly

In Unisphere, Under Domains-> Local - for the array he logged into.
Next, clicked on local, only one array  should show up - the array the IPs are being change on


Connect to the Array via the naviseccli
Verify the current settings and record them.
Command to check the current SP settings:
CMD:
 naviseccli -h <current SPaIP> networkadmin -get
SAMPLE OUTPIT:
Storage Processor:                  SP A
Storage Processor Network Name:     A-IMAGE
Storage Processor IP Address:       10.241.xx.xx
Storage Processor Subnet Mask:      255.255.xx.xx
Storage Processor Gateway Address:  10.241.xx.xx

Repeat for SPB

Verify the new information before hitting <enter>
Once the new ipaddresses are set, if any mistakes were made, it may be necessary to attach directly to the array to correct via the service or serial port
SAMPLE:
 naviseccli -h <current SPaIP> networkadmin -set -address <newSPaIP> -subnetmask <if changing-new IP> -gateway <if changing-newIP>

At this point theCustomer's  network would need to be changed for the new array IP addresses.
Ping the new SP IP and be sure you are able to connect to it before proceeding to SPB.
Once the SPA is updated, contacted, and accessible, Complete changes on SPB




Wednesday, April 13, 2016

Solution | Windows event log service Error 5: Access is Denied

Error :

Windows event log service Error 5: Access is Denied

Error message when attempting to start the Windows Event Log Service: "Access denied


I went thru below articles with NO LUCK.

https://www.experts-exchange.com/questions/28046356/Windows-2008-Event-Viewer-service-won't-start-Error-5-Access-is-denied.html

Microsoft artical : https://support.microsoft.com/en-in/kb/971256
Error was still their.

Finally got below solution from https://social.technet.microsoft.com/Forums/office/en-US/94d02eef-72cd-458a-8275-abe9a341e9f7/windows-event-log-service-error-5-access-is-denied?forum=winservergen

Solution : 

1) Goto Folder C:\Windows\System32\winevt\Logs

2) Cut all the files and paste all of them somewhere else (e.g. C:\Temp)

3) Now start the Event Log Service. It will start. :)

Let me know your views in via comments.


Friday, February 26, 2016

Slow Web Based Java Applications | Solution

Hey All,

Another day for the issues and resolution. This time - JAVA Applications

Issue : JAVA Applications (e.g. Primavera Web Portal, EMC Unisphere Management Console, etc.) takes too long time to open / respond.

Scenario : Web Based Java Applications getting accessed from Client Machines having JAVA 7 Update 25+ and above

JAVA Based Intranet / Internet Applications

Resolution : 

Open Java Control Panel : Start ==> Configure Java

1) Enable client side Java Applet caching (If not enabled)
 
2) Disable Online Certification Check (Online Certificate Status Protocol)
 
3)  Click OK.

Restart your browser.

Open the application. It may take time for the 1st time. Subsequent loads should be faster.

Cheers!!!

Let me know if this solution worked for you.



 

Friday, February 12, 2016

Script to attach multiple databases in 1 Click | SQL Server | Migration

Dear All,

Scenario :
Source Server : SQL Server 2008 R2, Windows Server 2008 ,
Destination Server : SQL Server 2014, Windows Server 2012 R2
We are in process of SQL Server Migration from 2008 R2 to 2014

We faced situation that we had to attach 600+ databases to newly created setup, which would require 10+ Hrs.

Then i decided to create script for it.

Thanks to google, I got ready made information from Michelle Gutzait (https://www.mssqltips.com/sqlservertip/1786/auto-generate-sql-server-database-attach-and-detach-scripts/#comments)

And comment from James E. Satterthwaite helped me for my requirement.

Hope that this helps for you too.

================
Solution
================

Goto SQL Server Management Studio on the Source Server and Run this query on the required instance.

-- *******************************************************
-- Script for attaching multiple Databases at a time
-- Do following if you want to relocate DB and log files elsewhere
-- FIND    H:\MSSQL10_50.APP\MSSQL\DATA\    and Replace with     E:\MSSQL12.SQL2014NEW\MSSQL\DATA\
-- FIND     I:\MSSQL10_50.APP\MSSQL\Data\     and Replace with     F:\MSSQL12.SQL2014NEW\MSSQL\Log\
-- *******************************************************
                          
SET NOCOUNT ON
DECLARE     @cmd        VARCHAR(MAX),
            @dbname     VARCHAR(200),
            @prevdbname VARCHAR(200)

SELECT @cmd = '', @dbname = ';', @prevdbname = ''

CREATE TABLE #Attach
    (Seq        INT IDENTITY(1,1) PRIMARY KEY,
     dbname     SYSNAME NULL,
     fileid     INT NULL,
     filename   VARCHAR(1000) NULL,
     TxtAttach  VARCHAR(MAX) NULL
)

INSERT INTO #Attach
SELECT DISTINCT DB_NAME(dbid) AS dbname, fileid, filename, CONVERT(VARCHAR(MAX),'') AS TxtAttach
FROM master.dbo.sysaltfiles
WHERE dbid IN (SELECT dbid FROM master.dbo.sysaltfiles
            WHERE FileID = 1
            AND DATABASEPROPERTYEX(DB_NAME(dbid), 'Status') = 'ONLINE'
            AND DB_NAME(dbid) NOT IN ('master','tempdb','msdb','model'))
ORDER BY DB_NAME(dbid), fileid, filename

UPDATE #Attach
SET @cmd = TxtAttach = 
            CASE WHEN dbname <> @prevdbname
            THEN CONVERT(VARCHAR(200),'exec sp_attach_db @dbname = N''' + dbname + '''')
            ELSE @cmd
            END +',@filename' + CONVERT(VARCHAR(10),fileid) + '=N''' + filename +'''',
    @prevdbname = CASE WHEN dbname <> @prevdbname THEN dbname ELSE @prevdbname END,
    @dbname = dbname
FROM #Attach  WITH (INDEX(0),TABLOCKX)
 OPTION (MAXDOP 1)

SELECT TxtAttach
FROM
(SELECT dbname, MAX(TxtAttach) AS TxtAttach FROM #Attach
 GROUP BY dbname) AS x

DROP TABLE #Attach
GO 


================
Script End
================

Wednesday, January 13, 2016

VB Script to List Local Administrators Membership

VB Script to List Local Administrators Membership

Script Credit : Brian Desmond

'==========================================================================
' NAME: Dump Local Administrators Membership
'
' AUTHOR: Brian Desmond,
' DATE  : 4/16/2007
'==========================================================================


Option Explicit

Const LogFile = "LocalAdmins.log"
Const resultFile = "LocalAdministratorsMembership.csv"
Const inputFile = "c:\scripts\workstations.txt"


Dim fso
Set fso = CreateObject("Scripting.FileSystemObject")

Dim shl
Set shl = WScript.CreateObject("WScript.Shell")

Dim fil
Set fil = fso.OpenTextFile(inputFile)

Dim results
Set results = fso.CreateTextFile(resultFile, True)

WriteToLog "Beginning Pass of " & inputFile & " at " & Now()
'WScript.Echo "Beginning Pass of " & inputFile & " at " & Now()
On Error Resume Next

Dim grp
Dim line
Dim exec
Dim pingResults
Dim member

While Not fil.AtEndOfStream
    line = fil.ReadLine
   
    Set exec = shl.Exec("ping -n 2 -w 1000 " & line)
       pingResults = LCase(exec.StdOut.ReadAll)
    
    'pingResults ="reply from"
     If InStr(pingResults, "reply from") Then
         WriteToLog line & " responded to ping"
         'WScript.Echo line & " responded to ping"
        
         On Error Resume Next

        Set grp = GetObject("WinNT://" & line & "/Administrators")
       
        'WScript.Echo line & ", Administrators"
        results.WriteLine line & ",Administrators,"
       
        For Each member In grp.Members
            'WScript.Echo     "Administrators: " & member.Name
            WriteToLog line & ": Administrators - " & member.Name
            results.WriteLine ",," & member.Name
        Next
    Else
        WriteToLog line & " did not respond to ping"
        'WScript.Echo line & " did not respond to ping"
    End If
Wend

results.Close
WScript.Echo "Operation Finished"

Sub WriteToLog(LogData)
    On Error Resume Next

    Dim fil   
    '8 = ForAppending
    Set fil = fso.OpenTextFile(LogFile, 8, True)
       
    fil.WriteLine(LogData)   

    fil.Close
    Set fil = Nothing
End Sub

Wednesday, December 30, 2015

VBA Script for Automatic Excel Link Update

Issue : 
We migrated our file server. End users started complaining that hyperlinks are not working in excel file. 

Observation : When excel link gets created, it does not store Drive name. It either stores Computer Name/IP Address or relative path of the folder.

If you have migrated file server with different IP Address and Computer name, then Hyperlinks which are having old entries will not work.

Solution : 
Here is a small VB Script which you can configure in your PERSONAL.XLSB Macro and save your valuable time.

'*******************************************
Sub Correct_Hyperlink()
    Dim wks As Worksheet
    Dim hl As HyperLink
    Dim sOld As String
    Dim sNew As String
    Dim ChangeCount As Integer
    ChangeCount = 0
    Dim Change As Integer
    Change = 0
    Set wks = ActiveSheet
    sOld = "\\172.241.17.234\"
    sNew = "\\172.241.17.123\"
    For Each hl In wks.Hyperlinks
   
        If InStr(hl.Address, sOld) > 0 Then
            ChangeCount = ChangeCount + 1
            Change = 1
        End If
       
        hl.Address = Replace(hl.Address, sOld, sNew)

    Next hl
   
If Change = 1 Then
    MsgBox "Macro Updated " & ChangeCount & " Links"
Else
    MsgBox "All links are already updated or old links are not present"
End If

End Sub


'*******************************************

Solved : The user profile failed to attach. The process cannot access the file becase it is being used by another process

Issue :  The user profile failed to attach. Please contact Support. Status : 0x0000000B, Message: Cannot open virtual disk Error Code: 0x000...