From a7b54d89d5bcf1f9d1b475cbb527db6b83f2dce4 Mon Sep 17 00:00:00 2001 From: creativezj Date: Tue, 15 Jan 2013 01:56:16 +0000 Subject: [PATCH] update error messages git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@14877 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT-server/lib/xcat/plugins/profilednodes.pm | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/xCAT-server/lib/xcat/plugins/profilednodes.pm b/xCAT-server/lib/xcat/plugins/profilednodes.pm index 47e233d10..8dc6a2d2b 100644 --- a/xCAT-server/lib/xcat/plugins/profilednodes.pm +++ b/xCAT-server/lib/xcat/plugins/profilednodes.pm @@ -111,7 +111,15 @@ sub process_request { if (grep{ $_ eq $command} ("nodeimport", "nodepurge", "nodechprofile", "nodeaddunmged", "nodechmac")){ my $discover_running = xCAT::ProfiledNodeUtils->is_discover_started(); if ($discover_running){ - setrsp_errormsg("Cannot run the $command command, the node discovery process is already running."); + my %errormsg_dict = ( + 'nodeimport' => 'import nodes', + 'nodepurge' => 'remove nodes', + 'nodechprofile' => 'change profiles', + 'nodeaddunmged' => 'add devices', + 'nodechmac' => 'change MAC address' + ); + + setrsp_errormsg("Cannot $errormsg_dict{$command} while node discovery is running."); xCAT::Utils->release_lock($lock, 1); return; }