Uploaded image for project: 'ASTPP Community'
  1. ASTPP Community
  2. ASTPPCOM-812

Community version upgrade v4.0 to 5.0 := When run community upgrade v5.0 scripts in centos server, it getting error as " unexpected token `|'

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Highest
    • Resolution: Done
    • Affects Version/s: v5.0
    • Fix Version/s: v5.0
    • Labels:
      None
    • Reproducibility:
      always
    • Category:
      Functional
    • Edition:
      Community

      Description

      steps :- 

      1. create a instance by using centos operating system.
      2. Set-up community v4.0.1 source code by using centos operating system.
      3. Upgrade to version 5.0
      4. During upgradation check error in console.

      Actual result :- When run Community upgrade v5.0 scripts It getting below error :- 

      [root@ip-172-31-1-236 src]# /bin/bash community_upgrade_v4_v5_111021.sh Nq1v*1smck25gIMtBJsG
      community_upgrade_v4_v5_111021.sh: command substitution: line 4: syntax error near unexpected token `|'
      community_upgrade_v4_v5_111021.sh: command substitution: line 4: `| cut -c24-43'
      Usage: which [options] [--] COMMAND [...]
      Write the full path of COMMAND(s) to standard output.

      --version, -[vV] Print version and exit successfully.
      --help, Print this help and exit successfully.
      --skip-dot Skip directories in PATH that start with a dot.
      --skip-tilde Skip directories in PATH that start with a tilde.
      --show-dot Don't expand a dot to current directory in output.
      --show-tilde Output a tilde for HOME directory for non-root.
      --tty-only Stop processing options on the right if not on tty.
      --all, -a Print all matches in PATH, not just the first
      --read-alias, -i Read list of aliases from stdin.
      --skip-alias Ignore option --read-alias; don't read stdin.
      --read-functions Read shell functions from stdin.
      --skip-functions Ignore option --read-functions; don't read stdin.

      Recommended use is to write the output of (alias; declare -f) to standard
      input, so that which can show aliases and shell functions. See which(1) for
      examples.

      If the options --read-alias and/or --read-functions are specified then the
      output can be a full alias or function definition, optionally followed by
      the full path of each command used inside of those.

      Report bugs to <which-bugs@gnu.org>.
      community_upgrade_v4_v5_111021.sh: command substitution: line 6: syntax error near unexpected token `|'
      community_upgrade_v4_v5_111021.sh: command substitution: line 6: `| grep dbpass | cut -c10-29'
      community_upgrade_v4_v5_111021.sh: line 9: syntax error near unexpected token `('
      community_upgrade_v4_v5_111021.sh: line 9: `${FILE} | cut -c1-1` size=$(( $size + 0 )) get_linux_distribution () {'
      [root@ip-172-31-1-236 src]#

       

      Expected result :- it should be upgrade successfully.

      See Screenshot :- 

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              sahil.sheikh Sahil Sheikh (Inactive)
              Reporter:
              prashant.kumar Prashant Kumar
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - Not Specified
                  Not Specified
                  Logged:
                  Time Spent - 50m
                  50m