AIX

AIX

Connect with fellow AIX users and experts to gain knowledge, share insights, and solve problems.


#Power
#Power
 View Only
  • 1.  Problem configuration PowerHA

    Posted Thu July 06, 2023 10:30 AM
      |   view attached

    n the initial PowerHA configuration I have a problem with flag of many command:

    "Usage: grep [-r] [-R] [-H] [-L] [-E|-F] [-c|-l|-q] [-insvxbhwyu] [-p[parasep]] -e pattern_list... [-f pattern_file...] [file...]"

    This message appears when use command that using script ksh93

    AIX 7300-01-02-2320
    POWERHA 7.2.7 SP1

    Example:
    /usr/es/sbin/cluster/utilities/cllog -c 'clstrmgr.debug' -v '/halog'
    Usage: grep [-r] [-R] [-H] [-L] [-E|-F] [-c|-l|-q] [-insvxbhwyu] [-p[parasep]] -e pattern_list...
    [-f pattern_file...] [file...]
    Usage: grep [-r] [-R] [-H] [-L] [-E|-F] [-c|-l|-q] [-insvxbhwyu] [-p[parasep]] [-e pattern_list...]
    -f pattern_file... [file...]
    Usage: grep [-r] [-R] [-H] [-L] [-E|-F] [-c|-l|-q] [-insvxbhwyu] [-p[parasep]] pattern_list [file...]
    Usage: grep [-r] [-R] [-H] [-L] [-E|-F] [-c|-l|-q] [-insvxbhwyu] [-p[parasep]] -e pattern_list...
    [-f pattern_file...] [file...]
    Usage: grep [-r] [-R] [-H] [-L] [-E|-F] [-c|-l|-q] [-insvxbhwyu] [-p[parasep]] [-e pattern_list...]
    -f pattern_file... [file...]
    Usage: grep [-r] [-R] [-H] [-L] [-E|-F] [-c|-l|-q] [-insvxbhwyu] [-p[parasep]] pattern_list [file...]
    After all log directory changes have been made, please perform
    a cluster synchronization from this node. This will
    ensure that all desired changes have been propagated throughout
    the cluster.



    ------------------------------
    Massimo Catti
    ------------------------------


  • 2.  RE: Problem configuration PowerHA

    Posted Mon July 10, 2023 05:17 AM

    Had a couple of similar issues (a long time ago), once it was related to LANG, the other time it was related to LIBPATH/PATH (can't remember which).

    If you have someting that seems to be related to ksh93, check your /etc/profile and kshrc ($ENV).  I've seen daft attempts at interactive commands in .kshrc cause all sorts of trouble.



    ------------------------------
    José Pina Coelho
    IT Specialist at Kyndryl
    ------------------------------



  • 3.  RE: Problem configuration PowerHA

    Posted Wed July 12, 2023 03:38 AM

    Thank you Josè for your answer.

    My /etc/profile is correct and kshrc not present:

    # @(#)27        1.20  src/bos/etc/profile/profile, cmdsh, bos730, initial_extract 8/9/94 12:01:38
    # IBM_PROLOG_BEGIN_TAG
    # This is an automatically generated prolog.
    #
    # bos730 src/bos/etc/profile/profile 1.20
    #
    # Licensed Materials - Property of IBM
    #
    # COPYRIGHT International Business Machines Corp. 1989,1994
    # All Rights Reserved
    #
    # US Government Users Restricted Rights - Use, duplication or
    # disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
    #
    # IBM_PROLOG_END_TAG
    #
    # COMPONENT_NAME: (CMDSH) Shell related commands
    #
    # FUNCTIONS:
    #
    # ORIGINS: 3, 26, 27
    #
    # (C) COPYRIGHT International Business Machines Corp. 1989, 1994
    # All Rights Reserved
    # Licensed Materials - Property of IBM
    #
    # US Government Users Restricted Rights - Use, duplication or
    # disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
    #
    ################################################################

    # System wide profile.  All variables set here may be overridden by
    # a user's personal .profile file in their $HOME directory.  However,
    # all commands here will be executed at login regardless.

    trap "" 1 2 3
    readonly LOGNAME

    # Automatic logout, include in export line if uncommented
    # TMOUT=120

    # The MAILMSG will be printed by the shell every MAILCHECK seconds
    # (default 600) if there is mail in the MAIL system mailbox.
    MAIL=/usr/spool/mail/$LOGNAME
    MAILMSG="[YOU HAVE NEW MAIL]"

    # If termdef command returns terminal type (i.e. a non NULL value),
    # set TERM to the returned value, else set TERM to default lft.
    TERM_DEFAULT=lft
    TERM=`termdef`
    TERM=${TERM:-$TERM_DEFAULT}

    # If LC_MESSAGES is set to "C@lft" and TERM is not set to "lft",
    # unset LC_MESSAGES.
    if [ "$LC_MESSAGES" = "C@lft" -a "$TERM" != "lft" ]
    then
            unset LC_MESSAGES
    fi

    export LOGNAME MAIL MAILMSG TERM

    trap 1 2 3

    Best regards

    Massimo



    ------------------------------
    Massimo Catti
    ------------------------------