Friday, December 10, 2010

Extending partitions in Windows using DiskPart

This article provides steps to expand a virtual disk (VMDK) and then extend a partition using DiskPart in Microsoft Windows. Refer to VMware KB

Wednesday, December 8, 2010

Windows Shortcut Keys

To open properties of the selected item press-------------Alt+Enter
To switch between running applications press-------------Alt+Tab
To minimizes all windows press---------------------------Windows+M
To open File Explorer press------------------------------Windows+E
To Find Files press---------------------------------------Windows+F
To open System Properties Dialog Box press-------------Windows+Pause
To openTask Manager press-----------------------------CTRL+Shift+ESC
To open start menu press---------------------------------CTRL+Esc
To open The Run Dialog Box-----------------------------Windows+R
Instantly Locks your Computer --------------------------Windows+L

Command prompts for Windows

Here is a list of commands you can use under Microsoft Windows.

Answer Available Here

Tuesday, December 7, 2010

Windows Installer CleanUp Utility fails to install on Windows

When trying to install Windows Installer CleanUp Utility and it fails with error message of:

Script: C:\DOCUME~1\fzi\LOCALS~1\Temp\StartMs i.vbs


Line: 2
Char: 1
Error:
Code:
Source: (null)

Answer Available Here

When I run a script in Windows Script, I receive an error message: "Library not registered

When you try to run a script in Windows Script, you receive the following error message:


Error: Library not registered.

Code: 8002801D

Source: (null)
 
Refer to Microsoft KB 949140 for more details

Monday, December 6, 2010

How to Reset CentOS or RHEL root password

In order to reset the root password for GRUB users, follow these steps:

1) Reboot Machine and when the GRUB menu appears.

2) Press letter "e'' on the keyboard to enter edit mode.

3) Use arrow keys to select the kernel line for kernel to be booted and then press "e" to edit and go to end of line and type "single" (without quotes) as a separate word,

           append "single" to ro root=LABEL=/ single

4) Press ESC key to exit the edit mode.

5) Press "b" to boot into single user mode

6) Enter passwd at cmd prompt and reset the root password a prefered password.

In order to reset the root password for LILO users, follow these steps:

1) If you are using LILO, at the LILO boot prompt press Ctrl-x to exit the graphical screen and go to the boot prompt, and then enter:

        linux single

Once you enter linux single, this will make you the "root" user without asking for a password. Once the system has booted, you can change the root password using the password command:

         passwd

Wednesday, December 1, 2010

Outlook 2007 using MS Exchange 2007 free busy does not show

Open the registry and explore to:

HKEY_CURRENT_USER\Software\Microsoft\Office\12.0\Outlook\Options\Calendar

Click edit and create a new DWORD Value

Give the value name “UseLegacyFB” and change the value data to 1

Internet Explorer 8 and png images appears a red cross sign

It's a known issue with IE8 and in order to fix this issue, import below in registry by saving it as .reg file and double click on it.

Using Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\MIME\Database\Content Type\image/png]

"Extension"=".png"

"Image Filter CLSID"="{A3CCEDF7-2DE2-11D0-86F4-00A0C913F750}"

[HKEY_CLASSES_ROOT\MIME\Database\Content Type\image/png\Bits]

"0"=hex:08,00,00,00,ff,ff,ff,ff,ff,ff,ff,ff,89,50,4e,47,0d,0a,1a,0a

Tuesday, November 30, 2010

Tuesday, November 9, 2010

Your message wasn’t delivered because of security policies in Exchange 2007

When you’re trying to send an email to a distribution group, the following error may be returned:


Delivery has failed to these recipients or distribution lists
Your message wasn’t delivered because of security policies in Exchange 2007. Microsoft Exchange will     not try to redeliver this message for you. Please provide the following diagnostic text to your system administrator.

In most cases, this error appears because you’re trying to send email from outside your organisation to an internal distribution list. By default, only authenticated users are allowed to email to a distiribution group.

Answer Available Here

Credit to Christian Gude from itexperiencenet.

Tuesday, August 3, 2010

Upgrade from ESX to ESXi

We have just recently finalised the migration of our vmware infrastructure from vCneter 2 and ESX 3.5 to vSphere 4. If you reference the vmware web site, they already talking about migration path to vSphere 4.1 and more prefered path of ESXi.

So, now once again I have to plan for upgarde and complete all the business requirements and formalities to migrate to ESXi. I have started looking for information and reading on ESXi and durning this process, if I find any useful information which can assist me with graceful migration process to ESXi, I"ll add the info to my blog for my future references.

My starting point for gathering information VMware ESXi and ESX Infor Center

Tuesday, July 20, 2010

How to Remove old hardware after performing P2V in Windows environment

When performing P2V action on a Windows machines, the virtual machine still holds a lot of hardware components of physical machine. These components might be hidden, but still they are there and drivers are loaded for them. They might comsume resources or create issues on your virtual machine.

Which is generally not a good thing. So, how to detect those unused hardware components and drivers. All you need to do is to open the command prompt:

Enter set devmgr_show_nonpresent_devices=1

Then, open the device manager by entering the command of:

devmgmt.msc

Finally, Select View ----> Show hidden devices

You should delete all the grayed-out hardware which is not in use anymore.

Wednesday, July 14, 2010

vSphere Compatibility Matrixes

vSphere Compatibility Matrixes

VMware vSphere Online Library ESX 4.0 and vCenter Server 4.0

I found VMware online library very handy when you need to find out any information related to VMware, you can view VMware product documentation, search across all books in a product documentation set, and print or bookmark topics.

VMware vSphere Online Library

Monday, June 28, 2010

Migrating to vSphere 4

Very handy information, if you are planing to migrate from VI3 to vSphere 4. You can check out the step-by-step vSphere migration videos. For more details on the migration from VI 3 to vSphere 4. click on vSphere Update Center

Vmware Resolution Path

I found these are very handy when I'm trying to troubleshoot VM, vCenter, or any ESX issues. All you just need to do is to identify the path for the issue and read the vmware KBs to resolve the issue.

Many common tech support issues in VMware products can be solved using Resolution Paths. Resolution Paths are collections of modular steps that can be used to solve tech support issues.Resolution Paths Published

How to enable Web Access on vSphere ESX 4

During our migration to vSpher 4, I noticed that for some reason the Web Access on the new hosts were not working. and I'm not sure why the Web Access to ESX 4 is disabled by default.


To enable this, all you need to do is, you need to ssh to the service console and log in as root.

[root@testone]# chkconfig --level 345 vmware-webAccess on

Once the above command is initiated. then you need to verify if it has been enabled for run level 3, 4, and 5 by executing the below command:

[root@testone]# chkconfig --list vmware-webAccess

vmware-webAccess 0:off 1:off 2:off 3:on 4:on 5:on 6:off

finally, you need to start the service:

[root@testone]# service vmware-webAccess start

Starting VMware Virtual Infrastructure Web Access:

VMware Virtual Infrastructure Web Access [ OK ]

For more details, refer to: vSphere Web Access Administrator's Guide

Tuesday, June 1, 2010

ESX Server is Disconnected or Not Responding in VirtualCenter

This morning when I try to log in to my vCenter Server using vSphere Client to verify my virtual farm. The vSphere Client show one of the ESX host had been disconnected from the virtual center by itself. The ESX host itself should be running in critical mode as production and had HA and DRS enable on the cluster.


The first thing I did is to verify that the entire VM’s and ESX host itself is still in production without any issues. Which was the case, all the VM were up and running as normal while the status is disconnected.

After that I had to resolve the issue by reconfigure my ESX host and rejoin it back to the HA and DRS cluster in my production farm.

These are the steps I had to go through to resolve the issus:

1) Disable the HA and DRS features from the cluster

2) SSH to the host in question and then path your way to the /etc/init.d and look for the services "mgmt-vmware status" command.

Then you need to issue the command "services mgmt-vmware restart". This process usually takes a minute or so to get the service fully restarted.

Once the services restarted, you can easily add host to the virtual center and reconfigure the HA and DRS cluster mode again. The ESX host is back to normal and status of all the VM's running on that host should change back to normal and should work perfectly as usual.

In some instances by just restarting the mgmt-vmware might not resolve the issues, and you might need to restart the vmware-vpxa services as well. To restart the vmware-vpxa, all you nedd to do is to initiate the "services vmware-vpxa restart" at the CLI.

For more details, refer to VMware KB

Tuesday, May 18, 2010

Configuring networking from the ESX service console command line

This VMware KB article provides steps to configure networking for an ESX host when you only have access to the service console.

Monday, May 17, 2010

How to modify the ESX Login Message

Logon directly to ESX Host and edit the motd file


1.Enter in the prompt nano /etc/motd
2.Create a message or some welcome banner
3.Press Ctrl o
4.Press Enter
5.Press Ctlr x

Dell Console Redirection fails with Login Failed - Error "Channel in use"

First of all simply clear the cache on your browser. In most cases this should resolve the issue.But if this fails then perform the following steps:


  1. Close all your IE sessions (In some case you might need to reboot your machine if the session veiw is locked by anther sessions).
  2. Go to c:\WINDOWS\Downloaded Program Files
  3. Right click on 'session viewer' and click remove
  4. Right click on 'rac5vm control' and click remove
  5. Finally, Clear out your browsing cache again.
This should resolve your "channed in use" error with Dell Console Redirection issue.

How to run Remote Desktop Console using CLi

You can use mstsc to create connections to terminal servers or other remote computers.
For example, to connect to the console session of a server, type:

mstsc /v:servername /console

For addition help, run mstsc /? on cli, whic will provide you all the addtional switches and syntax:

/v:ServerName[:Port] - Specifies the remote computer to which you want to connect and optionally, the port number to which you want to connect.

/console - Connects to the console session of the specified Windows Serve.

/f - Starts Remote Desktop connection in full-screen mode.

/w: - Specifies the width of the Remote Desktop window.

/h: - Specifies the height of the Remote Desktop window.

/public - Runs Remote Desktop in public mode.

How to create an "Offer Remote Assistance" shortcut

Being part of IT infrastructure team, occasionally I need to provide support to end users when the desktop support guys are not available. This is when I found the remote assistance feature very handy, providing support to end users without moving from your workstation.

I found the quickest and the easiest way to launch the “Offer Remote Assistance" is to create a shortcut on your desktop:

To do this, simply create a shortcut that points to following url:

%windir%\explorer.exe "hcp://CN=Microsoft%20Corporation,L=Redmond,S=Washington,C=US/Remote%20Assistance/Escalation/Unsolicited/Unsolicitedrcui.htm"

Wednesday, May 12, 2010

How to Configure ssh for root user in VMWare ESX

Logon directly to ESX Host and edit the configuration file for ssh

  1. Enter in the prompt nano /etc/ssh/sshd_config
  2. Find the line PermitRootLogin and change the value of PermitRootLogin no to yes
  3. Press Ctrl o
  4. Press Enter
  5. Press Ctlr x
Finally, you need to restart the ssh service by entering the following command:
  1. service sshd restart
  2. Press Enter
Once you completed the above steps, simple use putty to test that changes you made is working fine by allowing you to logon via service console with the root privileges.

     
 

Tuesday, May 11, 2010

Permissions to Manage Mailbox Servers

So here is the command that you use to add mailbox permissions:


Add-MailboxPermission -Identity "Some User" -User fawad -Accessright Fullaccess -InheritanceType all

Here are some more parameters for -Accessright, which is actually the most important part of the command that can be used to control the permission:

FullAccess
DeleteItem
ReadPermission
ChangePermission
ChangeOwner
ExternalAccount
SendAs

MS Reference article: Answer Available Here


 

Thursday, May 6, 2010

How to Unblock Attachments in Microsoft Outlook

In order to unblock attachments in MS outlook, you need to follow few simple registry modification. But it is recommended to backup your registry before you start editing it.


Go command prompt (cmd) then regedit (press enter) and then go to:

HKEY_CURRENT_USER\Software\Microsoft\Office\12.0\Outlook\Security

1. Backup your registry by right clicking and select Export.

2. Add a new String Value called: Level1Remove

Once you added the string value then you need to edit it and save the value data to the extension you wish to allow but makesure you add a semi colon delimiter after each extensions.

For Example: .mdb or .mdb;.exe;.scr;.bat and so on

3. Finally, you need to restart outlook without rebooting you pc.

Please refer to MS KB for further details

Tuesday, April 27, 2010

Windows Server 2008 RDP and Widows Firewall

This can be an issue when you have some sort of GP in your domain to stop the Windows firewall services. If the windows firewall service is stopped for Windows Server 2008, then the traffic to the server will be blocked. This means when the clients try to establish an RDP session will have issue connecting to the server.


Use the following commands to enable or disable the Windows firewall:

Netsh advfirewall set allprofiles state on or Netsh advfirewall set allprofiles state off

Useful AIX commands

Answere Available Here

AIX FAQ

I found the below wesite very useful:
Click Here

How to check the AIX version

Putty to AIX server and use the following below command:

Use "oslevel -g"

Friday, April 23, 2010

How to clean up the metadata of deleted domain controllers

With Windows Server 2008, when you delete a DC from the Active Directory Sites and Services MMC snap-in, and all the DC's associated metadata is also deleted. However, on earlier versions of Windows Server the metadata is left around if a DC is improperly demoted.

Please refer to MS KB: How to remove data in Active Directory after an unsuccessful domain controller demotion 

Microsoft also provides a script (Remove Active Directory Domain Controller Metadata Script) with a GUI to delete DCs. The script currently support the following platforms: Windows Server 2008/R2, Windows Server 2003, Windows XP and Windows 2000.

Revive Deleted AD Objects with Active Directory Recycle Bin

Answer Available Here

Friday, April 9, 2010

How to reboot/shutdown Windows Servers remotely using PsShutdown utility

You need to copy the PsShutdown file on Windows server in a folder. Say I saved the file under a folder called C:\downloadss. Next open windows command prompt, go to  (Start > Run > cmd) and schedule the  reboot:


c:> at 12:00am c:\downloads\psshutdown.exe -r -f -c -t 10 -accepteula

Above command will reboot the system at 12am. If you want to shutdown system:

c:> at 12:00am c:\downloads\psshutdown.exe -s -f -c -t 10 -accepteula

Where:
  • -s: Shutdown specified server
  • -r: Reboot specified server
  • -f: Forces all running application to exit
  • -c: Allow the shutdown to by cancel by user
  • -t: Specifies the countdown in seconds until the reboot or shutdow process
  • -accepteula (you need to add -accepteula to the psshutdown command, otherwise the task will hang, indicating a “running” state in Scheduled Tasks)

Tuesday, March 16, 2010

How find out a User Login Name

You can use this window server 2003 native command to find out users login details:

DSQUERY USER -name *LastNameOrFirstNameQuestionedUser* | DSGET USER -samid -display

For Example, if we want to find out fawad's login details then the command would be:

DSQUERY USER -name *fawad* | DSGET USER -samid -display

Output Screen from above command:

samid       display

FZI          Fawad Zikria
dsget succeeded

Who is Logged on to a Computer

You can use WMIC command on Window xp pro or later version of OS to find out who is logged on to a computer.

WMIC /Node:RemoteComputerName ComputerSystem Get UserName

For Example:

>WMIC /Node:replicator ComputerSystem Get UserName
UserName
fzk
ske
tet
tue

Above are 4 users who are currently logged on to replicator.

Also, you can use the PSTools to find out who is logged on to a computer remotely by executing the following command:

PSLOGGEDON -L \\Remote ComputerName or PSEXEC file://remotecomputername/ NET NAME

How to List all Domain Controllers on your Domain

Open the CLI and type to following Window Server 2003 native commands:

DSQUERY Server

Otput Screen:

"CN=testserver,CN=Servers,CN=sydney,CN=Sites,CN=Configuration,DC=test,DC=com,DC=au"

"CN=DC1,CN=Servers,CN=Campbelltown,CN=Sites,CN=Configuration,DC=test,DC=com,DC=au"
"CN=DC2,CN=Servers,CN=Campbelltown,CN=Sites,CN=Configuration,DC=test,DC=com,DC=au"
"CN=SDC1,CN=Servers,CN=City,CN=Sites,CN=Configuration,DC=test,DC=com,DC=au"
"CN=SDC2,CN=Servers,CN=City,CN=Sites,CN=Configuration,DC=test,DC=com,DC=au"

or, if you prefer the host names only then type:

DSQUERY Server -o rdn

Output Screen:
testserver

DC1
DC2
SDC1
SDC2

You can also use the below command on window server 2003:

           nltest /dclist:DomainName

For example:

       nltest /dclist:test.com.au


Useful Commands for Windows Administrator

Answer Available Here

Monday, March 1, 2010

How to Change Windows Local Administrator’s Password Remotely via CLI

In order to change a local user’s password in the computer being used, we can run this command:

           net user username newpassword

But to change a local user’s password in another computer, first of all you need to have a administrator privileges and then need to make connection to the IPC$ of the computer.

Use this command to establish a IPC connection:

           net use \\computer_name\ipc$ /user:administrator

Press Enter and then enter the administrator’s password when prompted.

For Example : To change the administrator’s password of the computer called vmcitrix04:

            net use \\vmcitrix04\ipc$ /user:administrator


Local name
Remote name \\vmcitrix04\ipc$
Resource type IPC
Status Disconnected
# Opens 0
# Connections 1

The command completed successfully.

But if we want to automate the service to change the local administrator’s password or to schedule the task for later, then we need to find out the time on the computer. So, we need the current time on the computer by using this command :

      net time \\vmcitrix04

Current time at \\vmcitrix04 is 3/1/2010 4:19 PM
The command completed successfully.

Finally, use the below cmd format to schedule the task at 4:22 using this command:

    at \\vmcitrix04 4:22 cmd /c net user administrator testing

Added a new job with job ID = 1

The job is scheduled to run on vmcitrix04 at 4:22 by changing the local administrator password to testing.

Thursday, February 11, 2010

How to Renew or Replace Self-Signed Certificate in Exchange Server 2007

Answer Available Here

Example, how i renewed our SSL in Exchnage 2007 environment when the Certificate expired

[PS] C:\Windows\System32>New-ExchangeCertificate -domainname "scatest01.com.au", "SCATEST01" -Services "SMTP

Confirm
Overwrite existing default SMTP certificate,
'E73B30FE933569AD8411D39ED9B70C27921C5DDA' (expires 11/02/2010 2:12:25 PM),
with certificate 'C674BA0B5A3478B8055E172CD87796CBC16EF411' (expires 12/02/2011
9:27:19 AM)?
[Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help
(default is "Y"):y

Thumbprint Services Subject
---------- -------- -------
C674BA0B5A3478B8055E172CD87796CBC16EF411 ..... CN=scatest01.com.au

[PS] C:\Windows\System32>Enable-ExchangeCertificate C674BA0B5A3478B8055E172CD877
96CBC16EF411 -services SMTP

Tuesday, February 9, 2010

Free Virtualization E-Learning Collection Available

Collection 6333: Exploring Microsoft Virtualization Technologies

Overview
This collection of two 2-hour online clinics and an 1-hour online clinic provides IT Professionals experienced in Windows 2000 Server or Windows Server 2003 with the knowledge and skills to implement and manage virtualization technologies.

Topics covered in the clinic within the collection include:
Introduction to Microsoft System Center Virtual Machine Manager 2008
Overview of Microsoft Application Virtualization
Overview of Terminal Services in Windows Server 2008
Overview of Hyper-V

Student Prerequisites:
Experience in planning, implementing, and supporting Windows Server–based networks, operating systems and platform infrastructure. This may include experience in Windows 2000 Server, Windows Server 2003, and Windows Server 2008.
Knowledge of server virtualization and Hyper-V.

How to Slipstream Updates for Office 2007

Answer Available Here

MS Office 2007 Customisation Install

To customise MS Office 2007 for deployment, copy all the content of MS Office to location where you can access it locally or on the network, in this example we will copy the content to a testpc's, local C drive under a folder called depleysw. Then follow the below steps:
1) cmd to the location where you saved the MS Office contents

2) Type setup.exe /admin

This Command Guide You For Create one Silent Install For MS Office 2007 , the guide generate a .MSP file, which can be used setup.exe /adminfile filename.msp.

If you require more help then you need to Type setup.exe /help for more info.

3) Create a Install batch file and save it to same location as MSP and the Setup.exe files.

eg:- \\testpc\c$\deploysw\office2007\setup.exe /adminfile install.msp

or
if you like to create a silent cd, then copy all files from cd for temp dir, create a .bat file, eg called "setup.bat" and add in the bat file "setup.exe /adminfile filename.msp", Edit autorun.ini to modify;

[autorun]
OPEN=SETUP.EXE
FOR
[autorun]
OPEN=SETUP.bat

Finally, burn all files onto a midia or create an .ISO file.

Using Group Policy to deploy software to select computers

Answer Available Here

How to Apply Patches (.msp) to Group Policy Deployed Software (.msi)

Answer Available Here

Wednesday, January 13, 2010

How to Create Local User Account on an ESX Server

1. Log into the ESX Server Service Console with root account.

2. Type useradd username at the command prompt.

3. Type passwd username to set an initial password.

4. Type the password twice.

5. Finally, open a new ssh session and test the user account and password to see if it works.

How to Rescan vmhba1 from a Service Console Command Line

1. Log on to a console session as a nonroot user.


2. Type su - and then click Enter.
3. Type the root password and then click Enter
4. Type esxcfg-rescan vmhba1 at the # prompt

How to Display a List of available LUNs with their associated Path, Device Names and UUIDs

1. Log on to a console session as a nonroot user.

2. Type su - and then click Enter.

3. Type the root password and then click Enter

4. Type esxcfg-vmhbadevs -m at the # prompt