mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 14:01:15 +02:00
Fixes C7200 IO cards insert/remove issues and makes C7200-IO-FE the default.
This commit is contained in:
1 parent
4918675cd5
commit
d97ba11728
4 files changed
+8
-8
No files matched your search
@@ -22,7 +22,7 @@ http://github.com/GNS3/dynamips/blob/master/README.hypervisor#L294
|
||||
|
||||
from ..dynamips_error import DynamipsError
|
||||
from .router import Router
|
||||
from ..adapters.c7200_io_2fe import C7200_IO_2FE
|
||||
from ..adapters.c7200_io_fe import C7200_IO_FE
|
||||
from ..adapters.c7200_io_ge_e import C7200_IO_GE_E
|
||||
|
||||
import logging
|
||||
@@ -70,7 +70,7 @@ class C7200(Router):
|
||||
if npe == "npe-g2":
|
||||
self.slot_add_binding(0, C7200_IO_GE_E())
|
||||
else:
|
||||
self.slot_add_binding(0, C7200_IO_2FE())
|
||||
self.slot_add_binding(0, C7200_IO_FE())
|
||||
|
||||
def defaults(self):
|
||||
"""
|
||||
|
||||
@@ -1324,7 +1324,7 @@ class Router(object):
|
||||
adapter=current_adapter))
|
||||
|
||||
# Only c7200, c3600 and c3745 (NM-4T only) support new adapter while running
|
||||
if self.is_running() and not (self._platform == 'c7200'
|
||||
if self.is_running() and not ((self._platform == 'c7200' and not str(adapter).startswith('C7200'))
|
||||
and not (self._platform == 'c3600' and self.chassis == '3660')
|
||||
and not (self._platform == 'c3745' and adapter == 'NM-4T')):
|
||||
raise DynamipsError("Adapter {adapter} cannot be added while router {name} is running".format(adapter=adapter,
|
||||
@@ -1369,7 +1369,7 @@ class Router(object):
|
||||
slot_id=slot_id))
|
||||
|
||||
# Only c7200, c3600 and c3745 (NM-4T only) support to remove adapter while running
|
||||
if self.is_running() and not (self._platform == 'c7200'
|
||||
if self.is_running() and not ((self._platform == 'c7200' and not str(adapter).startswith('C7200'))
|
||||
and not (self._platform == 'c3600' and self.chassis == '3660')
|
||||
and not (self._platform == 'c3745' and adapter == 'NM-4T')):
|
||||
raise DynamipsError("Adapter {adapter} cannot be removed while router {name} is running".format(adapter=adapter,
|
||||
|
||||
Reference in new issue
Block a user