Advertisement Header

Showing posts with label Windows. Show all posts
Showing posts with label Windows. Show all posts

Tuesday, 21 March 2017

HandsON! Review: AWS EC2Rescue for Windows instances

When it comes to troubleshooting Windows server issues, it is not easy to get all required logs at same time with single tool. Systems Administrators will spend their valuable time on collecting logs when troubleshooting below issues:

  • Boot Issues
  • Restore
  • Disk issues
  • Generate OS logs
  • Generate Memory dumps
  • Export Registry entries
  • Windows Update Logs
  • Export Event Logs

We will spend time on lot of multiple tools/utilities to generate or export above logs/dumps when it comes to cloud environment expectation to resolve the issues is much higher at the same time we need to equip with right tools to achieve the same supporting the cause Amazon had recently released EC2Rescue GUI based troubleshooting tool to help us to resolve operations system issues to generate logs faster.


The following are a few common issues that are addressed by EC2Rescue:

  • Instance connectivity issues due to:
    • Firewall configuration
    • RDP service configuration
    • Network interface configuration
  • Operating system (OS) boot issues due to:
    • Blue screen or stop error
    • Boot loop
    • Corrupted registry
  • Any issues that might require advanced log analysis and troubleshooting

Here are the System Requirements to install EC2Rescue which can be downloaded

  • Windows Server 2008 R2 or later
  • NET Framework 3.5 SP1 or later installed
  • Is accessible from a Remote Desktop Protocol (RDP) connection
Note: EC2Rescue can only be run on Windows Server 2008 R2 or later, but it can also analyze the offline volumes of Windows Server 2008 or later.

How to USE:

Note: Here are the few things where this tool cannot help:
  • Windows Update logs are not captured on Windows Server 2016 instances.
  • Offline instance refers to a stopped instance whose root volume has been detached and then attached to another instance as a secondary volume for troubleshooting with EC2Rescue.
  • Run this tool with the account which have local administrator access.

Step 1: One we downloaded tool from here 



Step 2: Unzip the download zip file



Step 3: Double click on EC2Rescue.exe to open and click on next to begin.


Step 4: Now we can select mode Current Instance / Offline instance

Current Instance Mode
This mode analyzes the instance on which EC2Rescue is currently running. It is read-only and does not modify the current instance, and therefore it does not directly fix any issues. Use this mode to gather system information and logs for analysis or for submission to system administrators or AWS Support.



When we select Current instance mode, we will get option to capture logs:


Here EC2Rescue tool will give us more options to select which ever logs we need to generate based on kind of issue we can select type of logs we need.


Once we select required logs click on Collect and it will prompt information dialog box (Note: Read it very carefully when you are sharing logs with any third party vendors).



Once you accept by clicking yes it will be prompted to select the filename and file location to store. Give appropriate filename and location as required.


It will generate above selected logs and place @ your mentioned location, once you extract selected logs will be available as below:

We can share this logs with third party as required or we can use ourself to troubleshoot.

Now lets see what we can perform using Offline Instance Mode:

Offline Instance Mode
This mode allows you to select the volume of the offline system. EC2Rescue analyzes the volume and presents a number of automated rescue and restore options. Also included is the same log collection feature as the Current Instance Mode.

Note: Offline instance refers to a stopped instance whose root volume has been detached and then attached to another instance as a secondary volume for troubleshooting with EC2Rescue.

Once we attach the volume which we need to troubleshoot to the instance where we can run Ec2Rescue Tool. we can select offline instance as above.

Now we should be able to see newly attached volume in Computer Management panel:


Make it disk Online by right clicking (In my case it is Disk 1 your disk number may change based on number of existing disks you may have)


Open Ec2Rescue tool by double clicking on Ec2Rescue.exe as mentioned above.

This time we have to select Offline Instance


Now we will get the additional Volume which is Disk 1 in my case will be visible to select.


It will be prompter the warning whether we selected appropriate volume and we can agree the same by clicking yes


Volume Successfully loaded


Now we will have Offline instance troubleshooting options a follows:
  • Diagnose and Rescue
  • Restore
  • Capture Logs


Lets Explore "Diagnose and Rescue"


Now it will display summary of possible issues:


We can select Next to proceed to issue selection


Select appropriate option as required to fix the issue. In my case I tried to set Ec2 Password to Rescue.


Lets Explore "Restore"



We will have below restore options:

Select appropriate restore option in my case restore registry and then click on restore.

Lets Explore "Capture Logs" this as like as which we perform for Current instance option.



Select appropriate logs to collect



Once we are done with troubleshooting for additional volume which we attached can be detached and add back to original instance to boot as usual.


Final Verdict 

As we can see Ec2Rescue tool will be very handy for troubleshooting windows instance (Online/offline) related issues, So I would definitely encourage others to use and make benefit out of it.

Hope this review post help you.

Tuesday, 23 November 2010

How to use ADPlus to troubleshoot "hangs" and "crashes"

ADPlus is a tool from Microsoft Product Support Services (PSS) that can troubleshoot any process or application that stops responding (hangs) or fails (crashes). Frequently, you can use ADPlus (ADPlus.vbs) as a replacement tool for the Microsoft Internet Information Server (IIS) Exception Monitor (6.1/7.1) and User Mode Process Dump. These are two separate tools that PSS frequently uses to isolate what causes a process to stop responding (hang) or quit unexpectedly (crash) in a Microsoft Windows DNA environment.

Click Here to Download ADPlus

Thursday, 12 August 2010

Run Commands Remotely in Windows

rsh and rexec commands (inbuilt) and we can use PsExec.exe

RSH:
---
Runs commands on remote hosts running the RSH service.

RSH host [-l username] [-n] command

host Specifies the remote host on which to run command.
-l username Specifies the user name to use on the remote host. If
omitted, the logged on user name is used.
-n Redirects the input of RSH to NULL.
command Specifies the command to run.

Rexex:
------
Runs commands on remote hosts running the REXEC service. Rexec
authenticates the user name on the remote host before executing the
specified command.

REXEC host [-l username] [-n] command

host Specifies the remote host on which to run command.
-l username Specifies the user name on the remote host.
-n Redirects the input of REXEC to NULL.
command Specifies the command to run.

Wednesday, 10 February 2010

Disabling The Shutdown Event Tracker

A new feature in Windows Server 2003 is the "Shutdown Event Tracker" which requires you to provide a reason for each manually-requested shutdown. This information then gets written into the event log.
If your server is not mission-critical, you may want to turn this feature off.

To turn off the Shutdown Event Tracker, navigate to the following key in your registry:

HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Reliability
(You may need to create the Reliability key)

Insert or change a value with the following:

Data Type: DWORD
Value Name: ShutdownReasonOn
Value: 0

The change will take place immediately

Disable Printer Events In The Event Log

If you don't want to see a printer notification event in the event log you can disable that..

Start regedit and find the key "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Providers".
Add "Eventlog" and set the value "Reg_DWORD" at "0".

Monday, 11 January 2010

FTP Automation

Make a text file that contains your ftp instructions...

OPEN my.ftp.com
mylogin
mypassword
binary
MPUT mylog.rar
BYE

Make a bat file that executes it...

ftp -i -s:C:\script_daily.txt

Saturday, 9 January 2010

Fix for Login failed for user “. The user is not associated with a trusted SQL Server Connection:

To set the DisableLoopbackCheck registry key yourself, follow these steps:
  1. Click Start, click Run, type regedit, and then click OK.
  2. In Registry Editor, locate and then click the following registry key:
    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Lsa
  3. Right-click Lsa, point to New, and then click DWORD Value.
  4. Type DisableLoopbackCheck, and then press ENTER.
  5. Right-click DisableLoopbackCheck, and then click Modify.
  6. In the Value data box, type 1, and then click OK.
  7. Quit Registry Editor, and then restart your computer.
--------------------------------------

Wehould now find that the connection will complete successfully. Another place to check is in event viewer. For this particular error we had 3 events logged in event viewer:

1. Failure Audit :: Login Failed for user ‘\’. (CLIENT 127.0.0.1)

2. Error :: SSPI handshake failed with error code 0×8009030C while establishing a connection with integrated security; the connection has been closed. (CLIENT 127.0.0.1)

3. Failure Audit :: Login Failed for user “. (CLIENT 127.0.0.1)

--------------------------------------

Wednesday, 21 October 2009

Saturday, 5 September 2009

Files required to use Windows Update are no longer registered or installed on your computer

Solution:
This problem can be corrected by re-registering the various dll files that Windows Update requires to run.

To do this firstly click on the “Start” button then “Run” and enter the following command into the “Run” dialog box

· regsvr32 wuapi.dll

You should then receive a message to say it was successful. The above process then needs to be done for each of the following commands:-

· regsvr32 wups.dll
· regsvr32 wuaueng.dll
· regsvr32 wucltui.dll
· regsvr32 atl.dll
· regsvr32 msxml3.dll

Monday, 2 February 2009

Show Desktop Icon Missing:

open notepad and pass the below text and save it Show Desktop.scf file name that all you will get ShowDesktop Icon:
===========

[Shell]
Command=2
IconFile=explorer.exe,3
[Taskbar]
Command=ToggleDesktop

===========

Thanks
Sravan Kumar E

Sunday, 1 February 2009

To unlock the Bulk AD accounts using Batch file:

Download unlock.exe and save it in your local computer and save the below commnads in batch file:
===============================
unlock . * -view > Unlock-Status.txt
unlock . *
===============================

Thanks
Sravan Kumar E