2

I am currently trying to make junctions in my Windows 10 filesystem and also need to delete a directory with process-locked files in it.

SysInternals seems to have 2 great packages in the form of handle and junction. I'd love to use them if only I could figure out how to install them. I have tried:

  1. Downloading the junction source directly and using ./junction64.exe /install=agent (even though I don't know what that means, probably not wise really). This prints a promising message about the program to terminal but does not make it accessble from path.
  2. Using this article (which initially looked like a parting in the clouds) - I can download the suite but it does not work as shown, just provides 2 PowerShell scripts. When trying to run the (presumed) install script at C:\chocolatey\lib\sysinternals.2018.12.27\tools\chocolateyInstall.ps1 with Set-ExecutionPolicy Bypass -Scope Process -Force | Powershell .\chocolateyInstall.ps1 it comes up that a keyword "Install-ChocolateyZipPackage" is not recognised.

I am sure for such a ubiquitous tool that I am searching the nooks and the solution is hiding in plain sight, but I am not very experienced in package managers and thus I am getting a tad weary in this search

EDIT: Whilst the accepted answer below is valid for the question I have come to realise that I could have just used chocolatey for the entire process, as chocolatey quite rightly recognises it as a package: choco info SysInternals to find available packages with this name and then choco install <packageName>. All executables within SysInternals will be available from $Path

3
  • I'm not sure I understand correctly but as sysinternals tools are xcopy deployment, you can just download the entire suite, unzip it to wherever you like on your system and for ease of use, add that folder to your path environment variable. From then on, you can open a command prompt (cmd, powershell, …) and run junction/handle. Note that handle is deprecated in favor of processexplorer/procmon (going from memory here so this might be a bit off) Commented Jan 4, 2019 at 7:39
  • That works like a charm thankyou - if you want to post it as an answer I'm happy to accept it Commented Jan 5, 2019 at 14:18
  • mklink /j included with Windows might do what junction does.
    – LawrenceC
    Commented Jun 29, 2020 at 16:24

1 Answer 1

2

Using package managers is great.

I use Chocolatey myself but the downside (personally) is that you don't need to use them regular enough to get it ingrained in memory.

As for the Sysinternals tools, this is just an xcopy deployment so you just download the entire suite and unzip it to wherever you like on you system.

For ease of use, you can add the folder where you've copied the tools to the path environment variable. From then on, you can open your favorite command line shell and run any tool Sysinternals provides.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .