}
if (lmd->lmd_nal == SOCKNAL ||
- lmd->lmd_nal == OPENIBNAL) {
+ lmd->lmd_nal == OPENIBNAL ||
+ lmd->lmd_nal == IIBNAL ||
+ lmd->lmd_nal == VIBNAL ||
+ lmd->lmd_nal == RANAL) {
PCFG_INIT(pcfg, NAL_CMD_ADD_PEER);
pcfg.pcfg_nal = lmd->lmd_nal;
pcfg.pcfg_nid = lmd->lmd_server_nid;
pcfg.pcfg_id = lmd->lmd_server_ipaddr;
pcfg.pcfg_misc = lmd->lmd_port;
- pcfg.pcfg_size = 8388608;
- pcfg.pcfg_flags = 0x4; /*share*/
err = libcfs_nal_cmd(&pcfg);
if (err <0)
GOTO(out, err);
out_del_conn:
if (lmd->lmd_nal == SOCKNAL ||
- lmd->lmd_nal == OPENIBNAL) {
+ lmd->lmd_nal == OPENIBNAL ||
+ lmd->lmd_nal == IIBNAL ||
+ lmd->lmd_nal == VIBNAL ||
+ lmd->lmd_nal == RANAL) {
PCFG_INIT(pcfg, NAL_CMD_DEL_PEER);
pcfg.pcfg_nal = lmd->lmd_nal;
pcfg.pcfg_nid = lmd->lmd_server_nid;
self.run(cmds)
def add_peer(self, net_type, nid, hostaddr, port):
- if net_type in ('tcp','ra') and not config.lctl_dump:
+ if net_type in ('tcp','openib','ra') and not config.lctl_dump:
cmds = """
network %s
add_peer %s %s %d
quit""" % (net_type,
nid, hostaddr, port )
self.run(cmds)
- elif net_type in ('openib','iib',) and not config.lctl_dump:
+ elif net_type in ('iib',) and not config.lctl_dump:
cmds = """
network %s
add_peer %s
quit""" % (net_type,
nid )
self.run(cmds)
+ elif net_type in ('vib',) and not config.lctl_dump:
+ cmds = """
+ network %s
+ add_peer %s %s
+ quit""" % (net_type,
+ nid, hostaddr )
+ self.run(cmds)
def connect(self, srv):
self.add_uuid(srv.net_type, srv.nid_uuid, srv.nid)
- if srv.net_type in ('tcp','openib','iib','ra') and not config.lctl_dump:
+ if srv.net_type in ('tcp','openib','iib','vib','ra') and not config.lctl_dump:
if srv.hostaddr[0]:
hostaddr = string.split(srv.hostaddr[0], '/')[0]
self.add_peer(srv.net_type, srv.nid, hostaddr, srv.port)
quit""" % (net_type,
nid, hostaddr)
self.run(cmds)
- elif net_type in ('openib','iib','ra') and not config.lctl_dump:
+ elif net_type in ('openib','iib','vib','ra') and not config.lctl_dump:
cmds = """
ignore_errors
network %s
# disconnect one connection
def disconnect(self, srv):
self.del_uuid(srv.nid_uuid)
- if srv.net_type in ('tcp','openib','iib','ra') and not config.lctl_dump:
+ if srv.net_type in ('tcp','openib','iib','vib','ra') and not config.lctl_dump:
if srv.hostaddr[0]:
hostaddr = string.split(srv.hostaddr[0], '/')[0]
self.del_peer(srv.net_type, srv.nid, hostaddr)
def sys_get_local_address(net_type, wildcard, cluster_id):
"""Return the local address for the network type."""
local = ""
- if net_type in ('tcp','openib','iib','ra'):
+ if net_type in ('tcp','openib','iib','vib','ra'):
if ':' in wildcard:
iface, star = string.split(wildcard, ':')
local = if2addr(iface)
manager.add_portals_module("knals/openibnal", 'kopenibnal')
if self.net_type == 'iib':
manager.add_portals_module("knals/iibnal", 'kiibnal')
+ if self.net_type == 'vib':
+ self.add_portals_module("knals/vibnal", 'kvibnal')
if self.net_type == 'lo':
manager.add_portals_module("knals/lonal", 'klonal')
if self.net_type == 'ra':
lo, hi):
# only setup connections for tcp, openib, and iib NALs
srvdb = None
- if not net_type in ('tcp','openib','iib','ra'):
+ if not net_type in ('tcp','openib','iib','vib','ra'):
return None
# connect to target if route is to single node and this node is the gw
--node node_name
--nid nid
--cluster_id
- --nettype tcp|elan|gm|openib|iib
+ --nettype tcp|elan|gm|openib|iib|vib|ra
--hostaddr ip[/netmask]
--port port
--tcpbuf size
('subsystem', "Specify which Lustre subsystems have debug output recorded in the log", PARAM),
# network
- ('nettype', "Specify the network type. This can be tcp/elan/gm/openib/iib.", PARAM),
+ ('nettype', "Specify the network type. This can be tcp/elan/gm/openib/iib/vib/ra.", PARAM),
('nid', "Give the network ID, e.g ElanID/IP Address as used by portals.", PARAM),
('port', "Optional argument to specify the TCP port number.", PARAM, DEFAULT_PORT),
('hostaddr', "Optional argument to specify the host address.", PARAMLIST),
hostaddr = get_option(options, 'hostaddr')
net_type = get_option(options, 'nettype')
- if net_type in ('tcp',):
+ if net_type in ('tcp','openib','ra'):
port = get_option_int(options, 'port')
- elif net_type in ('elan', 'gm', 'openib','iib','lo'):
+ elif net_type in ('elan','gm','iib','vib','lo'):
port = 0
else:
print "Unknown net_type: ", net_type