Thursday, September 9, 2010

CISCO IOS Tips & Tricks

Basic switch configuration

To set password to protect exec/privileged mode

Type

en
conf t
enable secret password
 
To set password to protect user mode
Type

line console 0
password password
login
exit
 
If the ios doesn't support enable secret

enable password password
 
To disable enable password cisco

Type
 
no enable password
to enable telnet
Type
line vty 0 4
password password
login
exit
 
To set a banner
Type

banner motd *
*********************
WELCOME TO HELL
*********************

Sunday, September 5, 2010

Converting FAT Filesystem to NTFS without losing data

C:\> CONVERT  C:  /fs:ntfs

C: It is the drive letter whose filesystem is to be changed

Kat Foster,The hottest thing from “Till Death”

Date of Birth
17 May 1978, Alameda County, California, USA

Had many non-acting jobs, including waitress, bartender (specialities included bloody Marys, margaritas and excellent white Russian), cocktail waitress at a strip club and a mover (which was her favorite).Now you can watch her in “Till Death”.

xrh8z1sifciyxyhf js7e4s6b7d9wb6de 1249902989806818  American Idol Season 5 Finale Arrivals pLpoOoZXC6Ll kat-foster-fox-tca-all-star-party-at-the-pier-csm0X8 33rd Annual People Choice Awards Arrivals -K8lcfTORBGl FOX 2007 Programming Presentation 2tKhSLL-M2sl

FosterJS1314

Friday, September 3, 2010

Cisco IOS Basics

In cisco switches 6 lights are at the left (for example 3550 series)
 
There is a mode button at the left,pushing that will take us to another mode in six modes. 
 
1.system:first the green will blink and after it started properly the green light stays on,if the light is amber give the switch back. 
 
2.RPS(Redundant Power Supply):Some switches have multiple power supply in case one got bad.If the redundant power supply us connected to power the green light will be on. 
 
3.STAT:shows status of the port,if something is connected to the port it will be green,some port will blink if its having some network activity ,if nothing plugged in the stat will be dark.

4.UTIL:utilization which constantly monitors the the utilization of the ports.
5.DUPLEX:checks if full duplex is configured. 
 
6.SPEED:checks if the port is 100 mb/s or 10mb/s.The light is on for 100 and not on for 10.
 
When a switch boots up(here for example 3550 series) 
 
the post operation(power on self test)starts
 
It shows the base mac address 
 
Shows information about the flash bios system where it stores the ios 
 
It basically copy the flash in ram and uncompress it 
 
Then you can see some copyright information 
 
Then the model of the switch 
 
Then the version of the ios 
 
Then will check every component inside it the processor,the memory,the interfaces 
 
When it show its memory it will basically devide the whole memory in separate chunks as all cisco devices,so the whole memory would be the summation of those for example 65526k/8192k 
 
Then it shows what kind of switching image you are running (if it's layer 2/3 or compatible with both layer 2 and 3) 
 
Then shows the interfaces  
 
Then summarizes the interfaces. For example
24 fast ethernet interfaces/IEEE 802.3 interface(s)
2 Gigabit Ethernet/IEEE 802.3 interface(s)

Then shows how much nvram(non-volatile memory)it has for example 384K bytes of flash-simulated non-volatile configuration memory 
 
Then comes the intial config dialog box 
 
just type n  and press enter

Type en to enter the exec mode abd then type conf t to enter the global mode 
 
? for help

to set a hostname 


from flobal config mode
hostname devicename 
 
There are 3 modes
User mode ,privileged mode or exec mode, global configuration mode 
 
To get back to exec mode
Type end or exit or ctrl + z 
 
Error code ambiguous command means it's right but still need to be defined more 
 
Error code invalid input detected means command is wrong 
 
From exec mode type show history to see all commands 
 
ctrl + e moves cursor to the end of the line 
 
ctrl + a moves cursor to beginning of the line 
 
To give switch an ip 
 
By default every port in a switch is in vlan1 
 
So we have to create a virtual interface named interface vlan 1(doesn't exist physically)

Every device on vlan 1 are now able to access it and we can access the switch remotely using this ip 
 
To configure interface vlan 1 
 
In global config mode
Type 
 
interface vlan 1
ip address 192.168.1.1 255.255.255.0(just an example)
no shutdown(no basically negates a command to reverse it's effect for example no hostname negates the hostname that you put in ur switch and changes the hostname to the previous one)
exit 
 
To see an interface 
 
In the exec mode 
 
type 

sh int vlan 1
now we have to give the switch a gateway address so that it can go in different network 
 
go in the global mode 
 
Type 
 
ip default-gateway 192.168.1.254 
 
Now to see the running configuration
From exec mode 
 
show running-config or sh run 
 
To save the configuration from ram to nvram

copy running-config startup-config 
 
To see the startup configuration 
 
From exec mode 
 
show startup-config 
 
To see the basic information about switch 
 
From exec mode 
 
Type
 
show version

Thursday, September 2, 2010

Backup and Restore of Active Directory and using Command Line in Authoritative Restore

In a windows 2000 server working as a dc I have created an OU named Kolkata under my domain sourav.com and an Ou named sales under kolkata and created an user named rabin deb under sales.Then I have taken the backup of active directory.

Check out the video

Then I have deleted the user rabin deb and tried to restore it by restoring active directory logging in active directory restore mode.However by performing non-authoritative restore(the general restore process)here I am able to get back the user rabin deb but in most cases in dc adc environment we are not supposed to.The reason is after performing non-authoritative restore although windows 2000 server is able to get back the data(here the user rabin deb) but a restart is needed to log in to the normal os mode and then after performing multimaster replication with other adc the server is being informed that the usn(update sequence number) of the user rabin deb is old than that of present in the adc and thus replace it with new information and delete the user.So what we have to do is perform an authoritative restore in the active directory restore mode where some command line operations are needed to do it so that we can get back the data(the user rabin deb)when we reboot the server in mormal mode.

The whole process is given below

Part 2

Part 3