Jump to content


Login from command line fails


  • Please log in to reply
2 replies to this topic

#1 GrahamL

GrahamL

    Newbie

  • Members
  • Pip
  • 8 posts

Posted 20 July 2020 - 09:47 AM

Hi
When I try to use P4 login or P4 info I am getting this error
Perforce client error:
    Connect to server failed; check $P4PORT.
    TCP connect to gb-wct-flexfs01:1666  failed.
    The specified class was not found.

Now I have checked P4PORT and it is correct
I can ping the server

What does the last line of the error mean?

Any other suggestions would be welcome

Thanks

#2 Sambwise

Sambwise

    Advanced Member

  • Members
  • PipPipPip
  • 1192 posts

Posted 20 July 2020 - 03:32 PM

Is there a trailing space in your P4PORT value?

Perforce client error:
Connect to server failed; check $P4PORT.
  TCP connect to gb-wct-flexfs01:1666  failed.
  The specified class was not found.

(Maybe set via a P4CONFIG file?  You'd have to work at it to get a trailing space with p4 set but it's pretty easy to leave a trailing space in a text file and not notice it.)

#3 Miles O'Neal

Miles O'Neal

    Advanced Member

  • Members
  • PipPipPip
  • 214 posts
  • LocationAustin. Texas. Y'all.

Posted 21 July 2020 - 09:38 PM

You can corrupt the P4PORT environment variable with a trailing space as well if you use quotes. If your P4PORT var is set, try "env | grep $P4PORT | od -c" (on Linux, no idea on Windows) to look for that space. Or just reset it without a space. :)

Here's what it looks like with a space (between the "6" and the "\n"):

%  env | grep P4PORT | od -c
0000000   P   4   P   O   R   T   =   m   y   h   o   s   t   :   1   6
0000020   6   6      \n
0000024




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users