Monday, March 30, 2015

Creating Disks and Volumes Using the DiskPart Command

डिस्कपार्ट के द्वारा डिस्क और वोल्यूम बनाना




The following examples show how to create basic and dynamic disks using the DiskPart command.

Example 1: Creating basic disks using the DiskPart command.

Select a disk, whether it is Raw or dynamic disk, and convert it to basic storage type.

X:\windows\system32\DR>diskpart



Display existing disks.

DISKPART>list disk

DISKPART>list volume



Create the boot and system volume on disk 0

DISKPART>select disk 0



(Optional) Convert to GPT style, if needed

DISKPART>convert gpt



Create basic volumes for the System and Boot volume.

Create System volume

DISKPART>create partition primary size=100



Create Boot volume

DISKPART>create partition primary

DISKPART> list volume



Mark system partition as active.

DISKPART>list partition

DISKPART>select partition 1

DISKPART>active



Check the status of the system volume.

DISKPART> detail partition.



Note: Use active command only for the system partition.

(Optional) Assign the volume a drive letter and format it.

DISKPART>list volume

DISKPART>select volume 2

DISKPART>assign letter=C

DISKPART>format quick



Example 2: Creating a System and a Boot dynamic volume using the DiskPart command.

Select a disk, whether it is Raw or Basic disk, and convert it to a dynamic storage type.

X:\windows\system32\DR>diskpart



Display existing disks.

DISKPART>list disk

DISKPART>list volume



Create the boot and system volume on disk 0.

DISKPART>select disk 0



(Optional) Convert to GPT style if needed.

DISKPART>convert gpt

DISKPART>convert dynamic



Create simple dynamic volumes for the System and Boot volume.

Create a system volume.

DISKPART>create volume simple size=100



Create a boot volume.

DISKPART> create volume simple



Display created volumes.

DISKPART> list volume



Prepare volume 0 as the system volume.

DISKPART>select volume 0

DISKPART>retain



Prepare volume 1 as the boot volume.

DISKPART>select volume 1

DISKPART>retain

DISKPART> select disk 0



(Optional) Mark the system partition as active.

Display partitions.

DISKPART>list partition

DISKPART>select partition 2

DISKPART>active



Check the status of the system volume.

DISKPART> detail partition



(Optional) Assign the volume to a drive letter and format it.

DISKPART>list volume

DISKPART>select volume 1

DISKPART>assign letter=C

X:\windows\system32\DR>format C: /q



Note: If you created a UEFI System partition, format it to a FAT32 file system before you can restore data. You do not need to run the retain command.



Example 3: Creating a non-system/boot disk volume using the DiskPart command.

Select disks and convert to a Dynamic storage type.

X:\windows\system32\DR>diskpart



Display current disks and volumes.

DISKPART>list disk

DISKPART>list volume



Convert each disk except Disk 0 to dynamic disks.

DISKPART>select disk 1

DISKPART>convert dynamic

DISKPART>select disk 2

DISKPART>convert dynamic

DISKPART>select disk 3

DISKPART>convert dynamic



Create RAID-5 volumes on each disk. Similarly, you can create simple, stripe, or other dynamic disk types.

create volume raid disk=1,2,3



(Optional) Assign the volume to a drive letter and format it.

DISKPART>list volume

DISKPART>assign letter=E

X:\windows\system32\DR>format E: /q



Example 4: Creating UEFI system volume and boot volume

Select disks and convert to the GPT type.

X:\windows\system32\DR> diskpart


Display the existing disks.

DISKPART>list disk

DISKPART>select disk 0



To create UEFI partition, disks must be converted to GPT type first.

DISKPART>convert gpt



Create the UEFI System partition.

Create the UEFI partition.

DISKPART>create partition efi size=100



Create the MSR partition.

DISKPART> create partition msr size=128



Create the primary partition.

DISKPART> create partition primary

DISKPART>convert dynamic

DISKPART>list volume



Retain the boot volume.

DISKPART>select volume 1

DISKPART>assign letter=C

DISKPART>retain



(Optional) Format the system volume to FAT32.

Prepare volume 2 as system volume.

DISKPART>select volume 2

DISKPART>format fs=fat32 quick

DISKPART>list partition



Note: You only need to retain the boot volume. To restore data to the UEFI partition, the master server should be UEFI partitioned.



Example 5: Creating Mirrored system volume and boot volume.

The following steps describe how to create mirrored disks on UEFI volume. For more information about mirrored disk on UEFI volume refer to Microsoft document at this link: http://support.microsoft.com/kb/951985

Select disk 0 and create the primary UEFI boot/system volume.

DISKPART>list disk

DISKPART>select disk 0

DISKPART>convert gpt

DISKPART>create partition efi size=100

DISKPART> create partition msr size=128

DISKPART> create partition primary

DISKPART>convert dynamic

DISKPART>list volume

DISKPART>select volume 1

DISKPART>assign letter=C



Select disk 4 as the secondary disk to create boot/system volume.

DISKPART>list disk

DISKPART>select disk 4

DISKPART>convert gpt

DISKPART>list partition



(Optional, delete existing partition) Select partition 1 on disk 4, and then delete it with the override command.

DISKPART> Select partition 1

DISKPART> Delete partition override

DISKPART>create partition efi size=100

DISKPART> create partition msr size=128

DISKPART>list partition

DISKPART>convert dynamic



Establish a mirror from the boot volume to the secondary drive.

DISKPART>select volume C

DISKPART>add disk=4

DISKPART>retain



(Optional) Format the system volume with FAT32.

DISKPART>list volume

DISKPART> select volume 1

DISKPART> format fs=fat32 quick

DISKPART> select volume 2

DISKPART> format fs=fat32 quick


Note: Establish mirror on the boot volume and retain this volume. You can only restore one Master UEFI system partition.

For more information about the DiskPart command, refer to Microsoft documentation.





Wednesday, March 18, 2015

Enabling/Disabling the firewall using command line

फायरवाल को इनेबल या डिसेबल करना








With the command line
First open the command prompt: (Windows + R keys) and type : cmd
o    netsh firewall set opmode disable
o    netsh firewall set opmode enable

Validate with the Enter key.
With a.BAT file
It is also possible to create a batch file (with extension. Bat) incorporating one of these command to enable or disable the firewall by simply double-clicking.

You can create a batch file to enable or disable the firewall by double-clicking on Notepad and inserting one of two lines above, then saving the file with the .bat extension (ex: Activatefirewall.BAT).


To go further you can create two files on the desktop, to enable and disable the firewall:
  • Click on Start/All Programs/Accessories/Notepad (or Start/Run/notepad/[OK])
  • Add the command:
o    netsh firewall set opmode disable
  • Click on File/Save As
  • In "File name" write "Disablefirewall.BAT"
  • Save directly on your desktop
  • Double-click this file to disable the firewall in Windows XP
  • Repeat the above operation, but now using the command
o    netsh firewall set opmode enable
  • In "File name" write "Activatefirewall.BAT"
  • Save directly on your desktop
  • Double-click this file to activate the firewall in Windows XP



This article explains how you can quickly Turn Windows Firewall On or Off. This tips applies to Windows Vista, Windows 7 and Windows Server 2008 only!

Windows Firewall on computers running Windows Vista, Windows 7 and Windows Server 2008 is enabled by default. You may need turn it off for various reasons.
This is how you do it using a command prompt:
  • To Turn Off: 
  • NetSh Advfirewall set allprofiles state off
  • To Turn On: 
  • NetSh Advfirewall set allrprofiles state on
  • To check the status of Windows Firewall: 
  • Netsh Advfirewall show allprofiles

 

Saturday, March 7, 2015

WHAT ARE "ICF" AND "LHB" COACHES?

ICF और LHB कोचेज क्या है?

ICF coaches

ICF stands for "Integral Coach Factory" which is one of the railways' main coach production plants. The Integral Coach Factory is located in Perambur near Chennai.

The ICF design refers to the conventional design of coaches seen across trains in India - indeed, of the many trains in the header images on my site. Here are a few pictures of ICF design coaches:






LHB coaches

In 1999, the railways imported a set of coaches from Linke-Hoffman-Busch (Now a part of Alstom) for testing and use in India. After a few glitches, they slowly began to gain popularity. Today, LHB coaches are manufactured by the Rail Coach Factory (Kapurthala) under a Transfer of Technology agreement.

LHB coaches are characterised by a sleeker finish than ICF coaches, better suspension, sound reduction and ride quality, not to mention significantly larger windows that lack the heavy tinting seen in the most ICF AC coaches. They are also safer than ICF coaches in the event of an accident or collision. LHB coaches are longer than ICF coaches, and seat layouts in LHB and ICF coaches differ.



Here are some (not very good!) picture of LHB coaches.





A comparison

There is very little to compare between the two in terms of passenger experience; LHB coaches are miles ahead. Compare the following:

(a) A conventional ICF AC Chair coach and an LHB AC Chair coach:







(b) The corridor of an ICF First AC Sleeper coach and its LHB equivalent:






Which trains have LHB coaches?

After seeing these pictures, you might want to travel by a train that has LHB coaches. However, not too many trains operate with LHB coaches at the moment. Here is a list (not comprehensive) of trains that are LHB:

This list starts with Shatabdi Expresses, followed by Jan Shatabdi Expresses, Rajdhani Expresses, Duronto Expresses, Double Decker Expresses, ending with regular Mail/Express trains that run with LHB coaches. Special trains and seasonal trains are not included in this list.

To state the obvious, every train runs both ways - i.e, the Bhopal Shatabdi runs between Bhopal and New Delhi as well as New Delhi - Bhopal!

Note: This list does not include temporary, special or premium special trains.

This train operates with IRY-20 coaches, which are slightly different from LHB coaches.

# While AC Double Decker trains operate with LHB coaches, their seats are non-reclining; legroom between seats is less than regular trains, which makes them a less comfortable option than AC Chair Car on a regular train.