Alternatively, introduce a new environment variable.  Call it, say, EX_ACTION (executing action).  It would contain the name of the action being executed.  ACTION can therefore stay as 'next', letting you be backward compatible, while still getting the new feature.

Steve


On 02/11/2013 09:43 AM, Jarrod B Johnson wrote:

So I think the current prescripts behavior is incorrect.  That is, when 'next' happens, ACTION should be set to the actual value rather than 'next', as is the case today.

Fixing this means anyone relying upon the current broken behavior of next would potentially be affected.  My bet is no one is doing that and we would be ok should that be feasible.  Anyone disagree with fixing ACTION to not say 'next' but instead say what next really means?

Inactive
          hide details for Steven Presser ---02/11/2013 09:09:43 AM---#
          tabdump prescripts #node,begin,end,comments,disableSteven Presser ---02/11/2013 09:09:43 AM---# tabdump prescripts #node,begin,end,comments,disable

From: Steven Presser <[email protected]>
To: xCAT Users Mailing list <[email protected]>,
Date: 02/11/2013 09:09 AM
Subject: Re: [xcat-user] Documentation! (nodeset documentation is wrong)





# tabdump prescripts
#node,begin,end,comments,disable
"node005",,,,
"node013",,,,
"node011",,,,
"node010",,,,
"node015",,,,
"node006",,,,
"node007",,,,x
"node009",,,,
"node004",,,,
"node001",,,,
"node008",,,,
"node016",,,,
"node014",,,,
"node002",,,,
"node012",,,,
"node003",,,,
"ceph","ceph",,,


And yes, if I explicitly call "nodeset <node> boot" the boot section gets called (with the value "boot" for ACTION).  However, the documentation implies it should get called when the install finishes.  Do I really need to monitor it through xcatmon if I want to hook a node having completed it's boot?  (Oh, and by the way, when reinstalling a node, xcatmon never goes to the installing state.  So I literally would have to hook both these places and create my own datastore both scripts can talk to if I want to be able to catch nodes being set to boot AND nodes being set to install.)

Steven Presser


On 02/11/2013 08:42 AM, Ling Gao wrote:
    What does prescripts table look like for the node? (tabdump prescripts). 
    In the case where you expect "boot" section to be called, you suppose to issue the "nodeset <nodes> boot" command. Then, does the script ever get called in this case? If it does, what is the value for
    ${ACTION} ?

    Ling
     

    Ling Gao
    Poughkeepsie Unix Development Lab
    IBM Systems and Technology Group
    Internal: T/L 293-5692  
    External:
    [email protected], 845-433-5692

    "I never worry about the future. It comes soon enough." --- Albert Einstein




    From:        
    Steven Presser <[email protected]> 
    To:        
    xCAT Users Mailing list <[email protected]> 
    Date:        
    02/11/2013 08:26 AM 
    Subject:        
    Re: [xcat-user] Documentation! (nodeset documentation is wrong) 




    #!/bin/sh
    # Place me in /install/prescripts, then modify the prescripts table appropriately.

    case ${ACTION} in
    install)
      logger Nodes ${NODES} set to install
      #runs just fine
    boot)
      logger Nodes ${NODES}
      #never called
    esac


    On 02/11/2013 08:09 AM, Jarrod Johnson wrote:
    What was attempted that failed?

    The behavior is that rinstall/winstall are just simple shell scripts.  Upon completion of install, the next entry in chain.currchain is used as the argument to 'nodeset' (effectively).

    For example:
    nodeset <noderange> runmcd=bmcsetup
    nodech <noderange> chain.currchain=osimage=blah,boot

    Would cause bmcsetup, then deployment of blah, then boot to storage.


    On Sat, Feb 9, 2013 at 5:59 PM, Steven Presser <
    [email protected]> wrote:
    Hi all,

    I have a piece of software I'm deploying into a cluster that requires
    some setup be done on the head node.  In order to do so, I'm trying to
    hook the nodeset command.  Per the nodeset command manpage:
    "nodeset  is  called  by rinstall and winstall and is also called by the
          installation process remotely to set the boot state back to "boot"."

    This however, doesn't appear to be the case.  I can successfully hook
    the node being set to install, but not it being returned to the boot case.

    Since there has been discussion here about features for 2.9 and
    documentation has come up, I thought I'd throw out that this is in fact
    the second instance of something like this I've run across in the
    process of setting up this software.  Please, please, PLEASE consider a
    complete documentation revamp for 2.9.  Otherwise no matter what
    features you have, people will be leaving for management systems where
    they can count on the documentation being correct.

    Steven Presser


    ------------------------------------------------------------------------------
    Free Next-Gen Firewall Hardware Offer
    Buy your Sophos next-gen firewall before the end March 2013
    and get the hardware for free! Learn more.

    http://p.sf.net/sfu/sophos-d2d-feb
    _______________________________________________
    xCAT-user mailing list

    [email protected]
    https://lists.sourceforge.net/lists/listinfo/xcat-user 



    ------------------------------------------------------------------------------
    Free Next-Gen Firewall Hardware Offer
    Buy your Sophos next-gen firewall before the end March 2013
    and get the hardware for free! Learn more.

    http://p.sf.net/sfu/sophos-d2d-feb 


    _______________________________________________
    xCAT-user mailing list

    [email protected]
    https://lists.sourceforge.net/lists/listinfo/xcat-user
    ------------------------------------------------------------------------------
    Free Next-Gen Firewall Hardware Offer
    Buy your Sophos next-gen firewall before the end March 2013
    and get the hardware for free! Learn more.

    http://p.sf.net/sfu/sophos-d2d-feb_______________________________________________
    xCAT-user mailing list

    [email protected]
    https://lists.sourceforge.net/lists/listinfo/xcat-user



    ------------------------------------------------------------------------------
    Free Next-Gen Firewall Hardware Offer
    Buy your Sophos next-gen firewall before the end March 2013
    and get the hardware for free! Learn more.
    http://p.sf.net/sfu/sophos-d2d-feb


    _______________________________________________
    xCAT-user mailing list
    [email protected]
    https://lists.sourceforge.net/lists/listinfo/xcat-user
    ------------------------------------------------------------------------------
    Free Next-Gen Firewall Hardware Offer
    Buy your Sophos next-gen firewall before the end March 2013
    and get the hardware for free! Learn more.
    http://p.sf.net/sfu/sophos-d2d-feb_______________________________________________
    xCAT-user mailing list
    [email protected]
    https://lists.sourceforge.net/lists/listinfo/xcat-user



------------------------------------------------------------------------------
Free Next-Gen Firewall Hardware Offer
Buy your Sophos next-gen firewall before the end March 2013 
and get the hardware for free! Learn more.
http://p.sf.net/sfu/sophos-d2d-feb


_______________________________________________
xCAT-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xcat-user

------------------------------------------------------------------------------
Free Next-Gen Firewall Hardware Offer
Buy your Sophos next-gen firewall before the end March 2013 
and get the hardware for free! Learn more.
http://p.sf.net/sfu/sophos-d2d-feb
_______________________________________________
xCAT-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xcat-user

Reply via email to