From abfed2b0c6774761f9f05c35b48d0796a6a60a8f Mon Sep 17 00:00:00 2001 From: nott Date: Wed, 12 May 2010 12:14:15 +0000 Subject: [PATCH] Move the mkdir to before the getmypost call. git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@6071 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- xCAT/postscripts/xcataixpost | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/xCAT/postscripts/xcataixpost b/xCAT/postscripts/xcataixpost index 52b965c27..b5e1ed432 100755 --- a/xCAT/postscripts/xcataixpost +++ b/xCAT/postscripts/xcataixpost @@ -144,6 +144,13 @@ unless ($servnode) { exit 0; } +# create the xcatpost dir +my $cmd = "mkdir -p /xcatpost"; +if (&runcmd($cmd) != 0) { + print "$::sdate xcataixpost: Could not create the /xcatpost directory.\n"; + print $::LOG_FILE "$::sdate xcataixpost: Could not create the /xcatpost directory.\n"; +} + # request the xCAT postscript for this particular node my $scriptname = "/xcatpost/myxcatpost_" . $::shorthost; if (&getmypost != 0) { @@ -169,12 +176,6 @@ if (!$installdir) { # if the /xcatpost dir has not been populated or the -c option is # specified then do the mount and copy of /install/postscripts if ( !(-f "/xcatpost/xcataixpost") || $::opt_c ) { - # create the xcatpost dir - my $cmd = "mkdir -p /xcatpost"; - if (&runcmd($cmd) != 0) { - print "$::sdate xcataixpost: Could not make the /xcatpost directory.\n"; - print $::LOG_FILE "$::sdate xcataixpost: Could not make the /xcatpost directory.\n"; - } # get the contents of the /install/postscripts dir on the server # - mount dir from server and copy files