Jump to content


'p4 clone' command line error: Can't find 'p4d.exe'

distributed version control clone

  • Please log in to reply
3 replies to this topic

#1 bjennings76

bjennings76

    Newbie

  • Members
  • Pip
  • 2 posts
  • LocationWellington, NZ

Posted 21 September 2017 - 09:45 AM

I normally use P4V and when working remotely and often use the 'Clone' button to create local repos so I can work in a distributed manner. Normally this works great, but I have one project that is way too large for the default clone depth due to multiple very large files being committed over the previous files every day.

I couldn't find a way to specify a depth when cloning in P4V, so I'm trying to use p4 clone instead. Unfortunately, I get an error when I run it. It says it can't find p4d.exe in my path, which is true. I can't find it either. It does seem odd, though, since P4V doesn't require any such .exe to run that I know of. (I'm assuming it's built into p4v.exe somehow.)

Here's the error I'm getting:
C:\P4\MyEmptyProjectFolder>p4 clone -m2 //Streams/SomeStream/SomeStreamFolder/

p4d server failed to initialize. A 2015.1 or later p4d server must be in your path and runable.
Execution Failed: p4d.exe -r c:\P4\InvadersUnity\.p4root -xnn -u bjennings -C0 -q -Joff: The system cannot find the file specified.

I've also tried downloading and installing P4D, but the installer says I already have distributed version control installed and need to uninstall the p4 command line to allow it to be installed. I doubt that's what I want since I'm, in fact, trying to use distributed version control.

Posted Image

So from here, I'm at a loss as to what to try next. Any insight would be much appreciated.

Thanks!

#2 P4Reg

P4Reg

    Advanced Member

  • Staff Moderators
  • 105 posts

Posted 21 September 2017 - 10:05 AM

The default location for the P4V copy of p4d.exe would usually be found in "C:\Program Files\Perforce\DVCS\" so if it is there,  try adding that to your PATH

#3 bjennings76

bjennings76

    Newbie

  • Members
  • Pip
  • 2 posts
  • LocationWellington, NZ

Posted 21 September 2017 - 10:19 AM

A-ha! That works, thank you!

The DVCS folder seems like a rather nutty place to put it. Sure enough, it's there in its own little directory. I wonder why it doesn't go alongside p4.exe and p4v.exe... and why DVCS wasn't automatically added to my path like the other Perforce folders were. Very strange.

I had a few problems with making a SUPER shallow clone, but depth 10 seems to be working for me. Thanks for the help!

Cheers,
BDJ

#4 P4Reg

P4Reg

    Advanced Member

  • Staff Moderators
  • 105 posts

Posted 21 September 2017 - 11:03 AM

Glad you are sorted out

BTW, the following Knowledge Base article discusses the initial warning you saw: http://answers.perfo...ticles/KB/15262





Also tagged with one or more of these keywords: distributed version control, clone

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users