Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-23894

P4PASSWD has additional quotation when passing to MAC system, and it failed.

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Blocker
    • Resolution: Not A Defect
    • Component/s: perforce-plugin
    • Labels:
      None
    • Environment:
      Mac OSX 10.9.
    • Similar Issues:

      Description

      Either with Env-inject or SCM itself, the P4PASSWD will have additional single quote to it. see below:
      ....
      OPTERR=1
      OPTIND=1
      OSTYPE=darwin13
      P4CLIENT=client_mac--672026695
      P4PASSWD='xxxxxx'
      P4PORT=ssl:perforceserver:0000
      P4USER=p4user
      PATH='/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin'
      ....

      then the error message:
      Using remote perforce client: p4client_mac--672026695
      [mac_node] $ /usr/bin/p4 workspace o p4client_mac-672026695
      [mac_node] $ /usr/bin/p4 -p ssl:p4server:0000 trust -y
      [mac_node] $ /usr/bin/p4 login -a -p
      [mac_node] $ /usr/bin/p4 login -a -p
      Caught exception communicating with perforce. Login attempt failed: Password invalid.com.tek42.perforce.PerforceException: Login attempt failed: Password invalid.
      at com.tek42.perforce.parse.AbstractPerforceTemplate.p4Login(AbstractPerforceTemplate.java:639)
      at com.tek42.perforce.parse.AbstractPerforceTemplate.login(AbstractPerforceTemplate.java:580)
      at com.tek42.perforce.parse.AbstractPerforceTemplate.getPerforceResponse(AbstractPerforceTemplate.java:396)
      at com.tek42.perforce.parse.AbstractPerforceTemplate.getPerforceResponse(AbstractPerforceTemplate.java:301)
      at com.tek42.perforce.parse.Workspaces.getWorkspace(Workspaces.java:61)
      at hudson.plugins.perforce.PerforceSCM.getPerforceWorkspace(PerforceSCM.java:1615)
      at hudson.plugins.perforce.PerforceSCM.getPerforceWorkspace(PerforceSCM.java:1576)
      at hudson.plugins.perforce.PerforceSCM.checkout(PerforceSCM.java:892)
      at hudson.model.AbstractProject.checkout(AbstractProject.java:1252)
      at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:615)
      at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:86)
      at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:524)
      at hudson.model.Run.execute(Run.java:1710)
      at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
      at hudson.model.ResourceController.execute(ResourceController.java:88)
      at hudson.model.Executor.run(Executor.java:234)
      ERROR: Unable to communicate with perforce. Login attempt failed: Password invalid.

      please help!

        Attachments

          Activity

          Hide
          rpetti Rob Petti added a comment -

          p4 login is failing, which does not use P4PASSWD, so that's not the issue. Your password has simply been incorrectly provided.

          Show
          rpetti Rob Petti added a comment - p4 login is failing, which does not use P4PASSWD, so that's not the issue. Your password has simply been incorrectly provided.
          Hide
          haiqing7 Haiqing Zhang added a comment -

          that's the issue. the password has extra single quote in it so it's invalid. on Windows machine it works fine.

          Show
          haiqing7 Haiqing Zhang added a comment - that's the issue. the password has extra single quote in it so it's invalid. on Windows machine it works fine.
          Hide
          rpetti Rob Petti added a comment -

          Make sure P4PASSWD is not set anywhere in jenkins, your slave configuration, or on the system itself. Also, uninstall env-inject if possible, as it causes issues like this regularly.

          Show
          rpetti Rob Petti added a comment - Make sure P4PASSWD is not set anywhere in jenkins, your slave configuration, or on the system itself. Also, uninstall env-inject if possible, as it causes issues like this regularly.

            People

            • Assignee:
              haiqing7 Haiqing Zhang
              Reporter:
              haiqing7 Haiqing Zhang
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: