# rm-rf.es | Administración de sistemas

Bitácora personal de un SysAdmin Gnu/Linux, Windows, BSD...

GNS3: simulador gráfico de redes


Para todos aquellos que necesitéis crear entornos de redes virtuales, topologías de red complejas y además tener la posibilidad de integrarlos con simuladores de IOS (Dynamips/Dynagen) y entornos de virtualización (Quemu, emulador de PIX.GNS3), GNS3 os puede ser de gran utilidad.

La instalación en Debian/Ubuntu y otras distro Linux es sencilla, la hacéis por gestor de paquetes:

$ sudo apt-get install gns3

Una vez arrancada la aplicación tenéis un asistente que os permite subir las imágenes IOS que dispongáis (podéis encontrarlas buscando por Google) y comenzar a trabajar. Simplemente se trata de crear la topología de red arrastrando elementos al cuadro central y configurarlos. Posteriormente se pueden arrancar/parar, acceder por consola, etc.

Si estás en proceso de pasar un CCNA, CCNP, CCIE o similar, o simplemente quieres tener la posibilidad de crear entornos de red sin necesidad de adquirir hardware costoso, esta es tu oportunidad.

GNS3

Consola IOS GNS3

Cómo instalar el simulador de NetApp Data ONTAP


Hoy vamos a crear un entorno de pruebas para cabinas de almacenamiento Netapp. Se trata de un simulador de Data ONTAP (Sistema operativo de Netapp) con el cual podremos disponer de una cabina 100% funcional sobre la que hacer pruebas y modificaciones sin necesidad de utilizar las cabinas de producción.

El simulador se puede descargar desde el sitio web oficial (con registro). Esta es la dirección.

Vamos a proceder a la instalación, es realmente sencilla. Descomprimimos el fichero descargado y ejecutamos el setup (como root) del simulador:

# gunzip 7.3.4-tarfile-v22.tgz
# tar -xvf 7.3.4-tarfile-v22.tar
# sudo ./setup.sh

La salida de la instalación es similar a lo siguiente, veréis que os hace una serie de preguntas. Tenemos la posibilidad de añadir los discos que estimemos necesarios, crear un cluster, etc.

Script version 22 (18/Sep/2007)
Where to install to? [/sim]:
Would you like to install as a cluster? [no]:
Would you like full HTML/PDF FilerView documentation to be installed [yes]:
Continue with installation? [no]: yes
Creating /sim
Unpacking sim.tgz to /sim
Configured the simulators mac address to be [00:50:56:10:a8:fe]
Please ensure the simulator is not running.
Your simulator has 3 disk(s). How many more would you like to add? [0]: 9

The following disk types are available in MB:
        Real (Usable)
  a -   43   ( 14)
  b -   62   ( 30)
  c -   78   ( 45)
  d -  129   ( 90)
  e -  535   (450)
  f - 1024   (900)

If you are unsure choose the default option a
What disk size would you like to use? [a]: e
Disk adapter to put disks on? [0]:
Use DHCP on first boot? [yes]:
Ask for floppy boot? [no]:
Checking the default route...
Which network interface should the simulator use? [default]:
How much memory would you like the simulator to use? [512]: 256
Create a new log for each session? [no]:
Overwrite the single log each time? [yes]:
Adding 9 additional disk(s).
Complete. Run /sim/runsim.sh to start the simulator.

Procedemos a arrancar el simulador:

sudo /sim/runsim.sh

En el primer arranque, se ejecutará el asistente al igual que en una cabina real, donde configuraremos la red, hostname y demás configuraciones iniciales:

NetApp Release 7.3.4: Thu May 27 15:43:26 PDT 2010
System ID: 0099929383 ()
System Serial Number: 987654-32-0 ()
System Storage Configuration: Multi-Path
System ACP Connectivity: NA
Model Name: Simulator
Processors: 1
slot 0: NetApp Virtual SCSI Host Adapter v0
               12 Disks:              5.0GB
	1 shelf with LRC
	slot 1: NetApp Virtual SCSI Host Adapter v1
	slot 2: NetApp Virtual SCSI Host Adapter v2
	slot 3: NetApp Virtual SCSI Host Adapter v3
	slot 4: NetApp Virtual SCSI Host Adapter v4
                12 Disks:              5.0GB
		1 shelf with LRC
	slot 5: NetApp Virtual SCSI Host Adapter v5
	slot 6: NetApp Virtual SCSI Host Adapter v6
	slot 7: NetApp Virtual SCSI Host Adapter v7
	slot 8: NetApp Virtual SCSI Host Adapter v8
                4 Tapes:            VT-100MB
                                    VT-100MB
                                    VT-100MB
                                    VT-100MB
Please enter the new hostname []: filer1
Do you want to enable IPv6? [n]:
Do you want to configure virtual network interfaces? [n]:
Please enter the IP address for Network Interface ns0 []: 192.168.0.199
Please enter the netmask for Network Interface ns0 [255.255.255.0]:
Please enter media type for ns0 {100tx-fd, auto} [auto]:
Please enter the IP address for Network Interface ns1 []:
Would you like to continue setup through the web interface? [n]:
Please enter the name or IP address of the IPv4 default gateway:
	The administration host is given root access to the filer's
	/etc files for system administration.  To allow /etc root access
	to all NFS clients enter RETURN below.
Please enter the name or IP address of the administration host:
Please enter timezone [GMT]:
Where is the filer located? []:
What language will be used for multi-protocol files (Type ? for list)?:
language not set
Do you want to run DNS resolver? [n]:
Do you want to run NIS client? [n]:
	The Shelf Alternate Control Path Management process provides the ability
	to recover from certain SAS shelf module failures and provides a level of
	availability that is higher than systems not using the Alternate Control
	Path Management process.
Do you want to configure the Shelf Alternate Control Path Management interface for SAS shelves [n]:
Setting the administrative (root) password for filer1 ...
.
Do you want to configure the filer's DNS resolver service? [y]:
What is the filer's DNS domain name? []: 

CIFS local server is running.
....
....
....

Tras la configuración, accederemos directamente al login de la cabina y podremos comenzar a trabajar con el simulador:

filer1> sysconfig -r
Aggregate aggr0 (online, raid0) (zoned checksums)
  Plex /aggr0/plex0 (online, normal, active)
    RAID group /aggr0/plex0/rg0 (normal)

      RAID Disk	Device	HA  SHELF BAY CHAN Pool Type  RPM  Used (MB/blks)    Phys (MB/blks)
      ---------	------	------------- ---- ---- ---- ----- --------------    --------------
      data    	v4.16	v4    1   0   FC:B   -  FCAL  N/A  120/246784        127/261248
      data    	v4.17	v4    1   1   FC:B   -  FCAL  N/A  120/246784        127/261248
      data    	v4.18	v4    1   2   FC:B   -  FCAL  N/A  120/246784        127/261248 

Spare disks

RAID Disk	Device	HA  SHELF BAY CHAN Pool Type  RPM  Used (MB/blks)    Phys (MB/blks)
---------	------	------------- ---- ---- ---- ----- --------------    --------------
Spare disks for zoned checksum traditional volumes or aggregates only
spare   	v4.19	v4    1   3   FC:B   -  FCAL  N/A  520/1065984       527/1080448
spare   	v4.20	v4    1   4   FC:B   -  FCAL  N/A  520/1065984       527/1080448
spare   	v4.21	v4    1   5   FC:B   -  FCAL  N/A  520/1065984       527/1080448
spare   	v4.22	v4    1   6   FC:B   -  FCAL  N/A  520/1065984       527/1080448
spare   	v4.24	v4    1   8   FC:B   -  FCAL  N/A  520/1065984       527/1080448
spare   	v4.25	v4    1   9   FC:B   -  FCAL  N/A  520/1065984       527/1080448
spare   	v4.26	v4    1   10  FC:B   -  FCAL  N/A  520/1065984       527/1080448
spare   	v4.27	v4    1   11  FC:B   -  FCAL  N/A  520/1065984       527/1080448
spare   	v4.28	v4    1   12  FC:B   -  FCAL  N/A  520/1065984       527/1080448

En futuros artículos comenzaremos a modificar configuraciones en el simulador para ver todas sus posibilidades.

Simulador de Router Cisco 7200 en un PC


Este proyecto, tiene como fin disponer de un router cisco 7200 virtual en tu propio PC, y así poder realizar pruebas y estudios del mismo sin poner en peligro la configuración de un router en producción.

Personalmente lo estoy probando y es realmente útil para quienes nos adentramos en el maravilloso mundo de las redes y routers :P

El modo de instalación es bastante sencillo, sería el siguiente:

1) Descargamos el binario ejecutable de dynamips:

2) Para un arranque más rápido, descomprimimos la imagen IOS del router Cisco 7200 (la imagen la podéis descargar del propio router):

$ unzip -p c7200-advipservicesk9-mz.124-9.T.bin > image.bin

3) Confirmamos que la nueva imagen ha sido creada correctamente:

$ file image.bin
image.bin: ELF 32-bit MSB executable, cisco 7200, version 1 (SYSV), statically linked, stripped

4) Y finalmente arrancamos la imagen:

$ ./dynamips-0.2.7-x86.bin dynamips-0.2.7/image.bin -t npe-400 -p 1:PA-A1 -p 2:PA-8T -p 3:PA-4E -p 4:PA-POS-OC3 -p 6:PA-FE-TX

Ya podremos comenzar a configurar el Router:

Cisco 7200 Simulation Platform (version 0.2.5-x86)
Copyright (c) 2005,2006 Christophe Fillot.

IOS image file: image.bin

CPU0: carved JIT exec zone of 64 Mb into 2048 pages of 32 Kb.
NVRAM is empty, setting config register to 0x2142
C7200 instance 'default' (id 0):
  VM Status  : 0
  RAM size   : 256 Mb
  IOMEM size : 0 Mb
  NVRAM size : 128 Kb
  NPE model  : npe-400
  Midplane   : vxr
  IOS image  : image.bin

Loading ELF file 'image.bin'...
ELF entry point: 0x80008000

C7200 'default': starting simulation (CPU0 PC=0xffffffffbfc00000), JIT enabled.
ROMMON emulation microcode.

Launching IOS image at 0x80008000...

              Restricted Rights Legend

Use, duplication, or disclosure by the Government is
subject to restrictions as set forth in subparagraph
(c) of the Commercial Computer Software - Restricted
Rights clause at FAR sec. 52.227-19 and subparagraph
(c) (1) (ii) of the Rights in Technical Data and Computer
Software clause at DFARS sec. 252.227-7013.

           cisco Systems, Inc.
           170 West Tasman Drive
           San Jose, California 95134-1706

Cisco IOS Software, 7200 Software (C7200-ADVIPSERVICESK9-M), Version 12.4(9)T, RELEASE SOFTWARE (fc1)
Technical Support: http://www.cisco.com/techsupport
Copyright (c) 1986-2006 by Cisco Systems, Inc.
Compiled Fri 16-Jun-06 17:27 by prod_rel_team
Image text-base: 0x60009084, data-base: 0x6308C000

This product contains cryptographic features and is subject to United
States and local country laws governing import, export, transfer and
use. Delivery of Cisco cryptographic products does not imply
third-party authority to import, export, distribute or use encryption.
Importers, exporters, distributors and users are responsible for
compliance with U.S. and local country laws. By using this product you
agree to comply with applicable laws and regulations. If you are unable
to comply with U.S. and local laws, return this product immediately.

A summary of U.S. laws governing Cisco cryptographic products may be found at:

http://www.cisco.com/wwl/export/crypto/tool/stqrg.html

If you require further assistance please contact us by sending email to
export@cisco.com.

Cisco 7206VXR (NPE400) processor (revision A) with 245760K/16384K bytes of memory.
Processor board ID 4294967295
R7000 CPU at 150MHz, Implementation 39, Rev 2.1, 256KB L2, 512KB L3 Cache
6 slot VXR midplane, Version 2.1

Last reset from power-on

PCI bus mb0_mb1 (Slots 0, 1, 3 and 5) has a capacity of 600 bandwidth points.
Current configuration on bus mb0_mb1 has a total of 540 bandwidth points.
This configuration is within the PCI bus capacity and is supported.

PCI bus mb2 (Slots 2, 4, 6) has a capacity of 600 bandwidth points.
Current configuration on bus mb2 has a total of 500 bandwidth points
This configuration is within the PCI bus capacity and is supported.

Please refer to the following document "Cisco 7200 Series Port Adaptor
Hardware Configuration Guidelines" on Cisco.com <http://www.cisco.com>
for c7200 bandwidth points oversubscription and usage guidelines.

4 Ethernet interfaces
2 FastEthernet interfaces
8 Serial interfaces
1 ATM interface
1 Packet over SONET interface
125K bytes of NVRAM.
Installed image archive

65536K bytes of ATA PCMCIA card at slot 0 (Sector size 512 bytes).
8192K bytes of Flash internal SIMM (Sector size 256K).

         --- System Configuration Dialog ---

Would you like to enter the initial configuration dialog? [yes/no]:

Para más información, dudas o FAQ podéis acudir al sitio web del proyecto.