Jump to content


SSL not working on Windows Server


  • Please log in to reply
7 replies to this topic

#1 MrDevelop

MrDevelop

    Newbie

  • Members
  • Pip
  • 3 posts

Posted 02 May 2012 - 02:36 AM

[newbie question]

I've downloaded and installed the latest (2012.1) server and installed it on my Windows server (Windows Server Web 2007, SP2)

The problem is that when I set my P4PORT variable from "1666" to "ssl:1666", it refuses to connect, even when I run p4 on the server machine, saying:

C:\Users\Administrator>p4
Perforce client error:
	SSL connect to ssl:1666 failed (An existing connection was forcibly closed by the remote host. ).
	Remove SSL protocol prefix from P4PORT.

I've set P4SSLDIR to a folder in my Administrator's "My Documents".  I've run both p4d -Gc and p4d -Gf, which work fine.

What could be the problem?  Would I get this error if I'd set the permissions incorrectly for the P4SSLDIR?

(EDIT: fixed mistyped port number.)

#2 Pete

Pete

    Newbie

  • Members
  • Pip
  • 9 posts
  • LocationIceland

Posted 02 May 2012 - 08:43 AM

I’ve explored this a little and had no problems on windows server. Going to start with the obvious, the error message says port “16666”. is the problem just the case of an extra "6" in the port?

#3 MrDevelop

MrDevelop

    Newbie

  • Members
  • Pip
  • 3 posts

Posted 02 May 2012 - 11:44 AM

View PostPete, on 02 May 2012 - 08:43 AM, said:

I’ve explored this a little and had no problems on windows server. Going to start with the obvious, the error message says port “16666”. is the problem just the case of an extra "6" in the port?
Ah, no, sorry that was just me mistyping the error message in my post.  It does say 1666.

Would you mind going through the steps you took to make it work on windows server?

Here's what I did:
1. Create a directory SSLKeys in my Administrator's documents folder. (I've also tried it with
2. Set P4SSLDIR to the SSLKeys folder.
3. p4d -Gc
4. Set P4PORT to ssl:1666
5. Run p4 and see that it no longer works.

I tried setting the owner of the SSLKeys folder to Administrator, but that didn't change anything.  The only thing I'm not sure about is whether or not the permissions are set to "700".

#4 Pete

Pete

    Newbie

  • Members
  • Pip
  • 9 posts
  • LocationIceland

Posted 02 May 2012 - 12:10 PM

digged into it a little and it seems that the error your getting happens when the server is not accepting connections on port ssl:bla and the client tries to connect on a ssl port.

can you try connecting to the server on port 1666 please? if that works, then the server is not accepting ssl connections.

can you verify what port the server is set to accept connections on please? if it's a windows service, you need to go to the registry,

    computer/
        HKEY_LOCAL_MACHINE/
            SYSTEM/
                ControlSet001/
                    services/

find the name of your perforce server service. expand parameters and you should find the port in that key.

/Pete

#5 MrDevelop

MrDevelop

    Newbie

  • Members
  • Pip
  • 3 posts

Posted 02 May 2012 - 01:06 PM

Aha!  So I found that registry entry, it was set to just 1666.  I changed it to "ssl:1666", and it works perfectly now.  Thank you very much!

So is this processed separately from the environment variable?  I thought you just have to set the P4PORT in the environment?

#6 Pete

Pete

    Newbie

  • Members
  • Pip
  • 9 posts
  • LocationIceland

Posted 02 May 2012 - 01:23 PM

i believe that it will use the registry if the variable is present, else it will use the environment variable.

#7 Bisu85

Bisu85

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 11 June 2018 - 05:37 PM

Hi,

Is this solution still valid?

I tried replacing 1667 with ssl:1667 but then the perforce service wont start.

Any other solution with the latest version of p4d on Windows server 2016?

thanks,
Abhishek

#8 p4rfong

p4rfong

    Advanced Member

  • Staff Moderators
  • 285 posts

Posted 22 June 2018 - 05:28 PM

Rename or erase your server log then restart the server and look at the error in the Helix server log.  This should provide some clues.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users