Wednesday, 27 January 2010

Astazi am facut - any to PDF

Orice document printabil poate fi transformat in .pdf utilizand
virtual printer pdf

Monday, 11 January 2010

Astazi am facut MPLS VRFs RD

RT- route target

RT are 2 functii:
a) marcarea rutelor dintr-un vrf.
b)folosind marcarea de la punctul a) se importa sau se exporta anumite rute din tabela bgp corespunzatoare unui vrf.

Deoarece are 2 functii RT poate sa produca confuzie. O alta sursa de confuzie este formatul asemanator cu al RD (route distinguisher). RT si RD sunt doua lucruri diferite si asa trebuiesc tratate.

Cazuri ce pot fi intalnite in practica:

i.doua VPN-uri diferite fara overlapping de rute

Ganditiva ca la doua multimi fara elemente comune



Cele doua VPN-uri pot exista pe aceeasi platforma fizica sau pe platforme fizice diferite, dar interconecatate intre ele.
Se definesc doua vrf-uri diferite

vrf VPNA
rd 100:1
route-target export 500:1
route-target import 500:1
!
vrf VPNB
rd 200:1
route-target export 160:1
route-target import 160:1


-rd va fi explicat mai tarziu
-numerele alese sunt aleatorii pentru RT, puteau lua orice valoare
-ce trebuie observat in definirea celor 2 vrf-uri este:
1.cu ajutorul route-target export se marcheaza in tabela de rutare rutele corespunzatoare vrf VPNA cu RT:500:1 respectiv pentru vrf VPNB cu RT 160:1 dupa aceasta marcare ele sunt exportate.
2.cu ajutorul route-target import se importa in cazul vrf VPNA rutele marcate cu RT:500:1 respectiv pentru vrf VPNB rutele marcate cu RT:160:1
*nota
Ceea ce rezulta in urma acestor setari(luam ca exemplu vrf VPNA)
vrf-ul VPNA va exporta rutele din acest vrf prin bgp cu RT setat 500:1. Acest export de route se face catre alte routere care au setat sa importe rutele cu RT setat 500:1

Asadar routele din vrf VPNA sunt anuntate doar in vrf VPNA si rutele in vrf VPNB sunt anuntate doar in vrf VPNB.

ii.in cazul in care se doreste o configurare hub and spoke in acelasi vpn.

In acest caz routerul spoke trebuie sa primeasca doar rutele de la hub,nu si route de la un alt router spoke

configurare router spoke
vrf VPNA
rd 100:1
route-target export 500:1
route-target import 500:2
!
configurare router hub
vrf VPNA
rd 100:1
route-target export 500:2
route-target import 500:1

Ceea ce rezulta in urma acestor setari:
1.un router spoke va anunta(exporta) rute marcate cu RT:500:1. Aceste rute vor fi ascultate(importate) doar de routerul hub( doar acest router are route-target import 500:1)
2.un router hub va exporta rute marcate cu RT:500:2. Aceste rute vor fi ascultate(importate) de routerele spoke.

*nota
Daca intre cele doua routere spoke din figura de mai sus ar fi existat o conexiune, rutele nu s-ar fi anuntat prin aceasta conexiune, in tabela de rutare aparand doar rutele invatate de la routerul hub.


iii. Hub and spoke(sau overlapping) intre doua vrf-uri diferite



vrf VPNA
rd 100:1
route-target export 500:1
route-target import 500:1
!
vrf VPNB
rd 100:2
route-target export 160:1
route-target import 160:1

vrf VPNAB
rd 100:12
route-target export 500:1
route-target import 500:1
route-target import 160:1
route-target export 160:1

Ceea ce rezulta in urma acestor setari:
1.rutele din vrf VPNA sunt anuntate(exportate) cu RT setat 500:1. Aceste rute sunt importate in vrf VPNAB ( datorita comenzii route-target import 500:1)
2.rutele din vrf VPNB sunt anuntate(exportate) cu RT setat 160:1. Aceste rute sunt importate in vrf VPNAB ( datorita comenzii route-target import 160:1)
3.rutele din vrf VPNAB sunt exportate atat in vrf VPNA cat si in vrf VPNB.
Datorita comenzilor rute-target export 500:1 respectiv route-target export 160:1( in vrf-ul VPNAB) cele doua vrf-uri (VPNA si VPNB) desi au denumire diferita si rd diferit sunt de fapt un vrf unit. In acest caz vrf-ul VPNAB joaca rolul unui redistribute de vrf-uri( in ambele sensuri)

Pornind de la cele 3 cazuri de mai sus se pot face mai multe cazuri particulare.
De asemenea se poate folosii route-map-uri pentru a exporta/importa granular dintr-un vrf in altul( in loc de toate rutele, doar anumite rute)


Thursday, 7 January 2010

Astazi am facut - kill/view process in windows XP

Tskill
The syntax for the command is

TSKILL processid processname [/SERVER:servername] [/ID:sessionid /A] [/V]

-processid - PID for process to be terminated. Use only if processname is not used
-processname - Process name to be terminated. Wildcards can be used here . Do not use if PID is used
-/SERVER:servername - Server containing processID (default is current). Usually not needed on home PCs
-/ID:sessionid - End process running under the specified session. Often not needed on home PCs
-/A - End process running under ALL sessions (administrator privileges required)
-/V - Display information about actions being performed

Example

tskill wscript

Taskkill

A tool with more options is provided by Taskkill. The command syntax is
TASKKILL [/S system [/U username [/P[password]]]]{ [/FI filter]
[/PID processid /IM imagename] } [/F] [/T]

-/S system - Specifies the remote system to connect to. Not needed for most home PCs
-/U username - User context under which the command should execute. Often not needed on home PCs
/P password - Password for username
/FI filter - Displays a set of tasks that match criteria specified by the filter
/PID processid - Specifies the PID of the process that has to be terminated. Not used when image name is given in the command
/IM imagename - Specifies the image name of the process that has to be terminated. Wildcard '*' can be used to specify all image names. Not used if PID is given in the command
/F - Forces the termination of all processes
/T - Tree kill: terminates the specified process and any child processes which were started by it

Example

taskkill /f /im wscript.exe


Pentru a vedea procesele folosind CMD


Type the command given below exactly:

WMIC /OUTPUT:C:\ProcessList.txt PROCESS get Caption,Commandline,Processid & C:\ProcessList.txt

Poate fi folosita comanda de mai sus doar daca aveti drepturi de admin

Astazi am facut - port TCP 445 file sharing in Windows 2000/XP

http://www.lockergnome.com/it/2005/04/13/windows-file-sharing-facing-the-mystery/