From 1e6bd608a89ddaa3c731102f3721b26a47c28741 Mon Sep 17 00:00:00 2001 From: Amir Shehata Date: Fri, 5 Jan 2018 14:20:04 -0800 Subject: [PATCH] LU-10003 lnet: deprecate lctl net commands Added a deprecated message for commands which are implemented in lnetctl. The lctl commands will continue to function. Signed-off-by: Amir Shehata Change-Id: I3f528d0145f7958106a2fc6842fcd1670c9b9d7c Reviewed-on: https://review.whamcloud.com/30755 Tested-by: Jenkins Tested-by: Maloo Reviewed-by: Andreas Dilger Reviewed-by: James Simmons Reviewed-by: Oleg Drokin --- lustre/utils/portals.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lustre/utils/portals.c b/lustre/utils/portals.c index b921631..4ebf306 100644 --- a/lustre/utils/portals.c +++ b/lustre/utils/portals.c @@ -299,6 +299,8 @@ int jt_ptl_network(int argc, char **argv) __u32 net = LNET_NIDNET(LNET_NID_ANY); int rc; + fprintf(stderr, "This command has been deprecated. Plesae use 'lnetctl net add'\n"); + if (argc != 2) { fprintf(stderr, "usage: %s |up|down\n", argv[0]); return -1; @@ -357,6 +359,8 @@ jt_ptl_list_nids(int argc, char **argv) int count; int rc; + fprintf(stderr, "This command has been deprecated. Plesae use 'lnetctl net show'\n"); + all = (argc == 2) && (strcmp(argv[1], "all") == 0); /* Hack to pass back value */ return_nid = (argc == 2) && (argv[1][0] == 1); @@ -918,6 +922,8 @@ int jt_ptl_ping(int argc, char **argv) char *sep; int i; + fprintf(stderr, "This command has been deprecated. Plesae use 'lnetctl ping'\n"); + if (argc < 2) { fprintf(stderr, "usage: %s id [timeout (secs)]\n", argv[0]); return 0; @@ -1223,6 +1229,8 @@ jt_ptl_print_routes (int argc, char **argv) int alive; unsigned int pri; + fprintf(stderr, "This command has been deprecated. Plesae use 'lnetctl route show'\n"); + for (index = 0; ; index++) { LIBCFS_IOC_INIT_V2(data, cfg_hdr); data.cfg_count = index; -- 1.8.3.1