次の方法で共有


Native Binary Scanning Tool (NanoServerApiScan.exe) for Nano Server

This blog post is now obsolete. Please go to the new one here: https://blogs.technet.com/b/nanoserver/archive/2016/04/27/nanoserverapiscan-exe-updated-for-tp5.aspx

 

If you developed a 64-bit application, tool, or agent for Windows Server in C/C++, you can use NanoServerApiScan.exe to check if your app will also run on Nano Server. Remember that Nano Server is 64-bit only and won’t run 32-bit binaries.

NanoServerApiScan.exe scans a directory containing your binaries and reports an error if it finds an API that is not available in Nano Server. It even provides replacement API suggestions in many cases. NanoServerApiScan.exe requires .NET Framework version 4.0 or higher.

Syntax

NanoServerApiScan.exe /BinaryPath: <directory containing your binaries> /WindowsKitsPath: <Windows SDK directory> /ReverseForwardersPath: <directory containing Reverse Forwarders binaries>

/BinaryPath (Mandatory): The directory containing your binaries. NanoServerApiScan.exe will parse all sub-directories as well.

/WindowsKitsPath (Optional): If you install a newer version of the Windows 10 SDK and would prefer to use the OneCore.lib file that came with this newer SDK, instead of the version bundled with NanoServerApiScan.exe, use this parameter to specify the Windows 10 SDK directory.

/ReverseForwardersPath (Optional): The directory containing the extracted Reverse Forwarders binaries. If you will use your tool with the Nano Server Reverse Forwarders package, you can extract the binaries from this package (by unzipping the cab file) to a local folder and specify the path to this folder as the argument to this parameter.

Example

NanoServerApiScan.exe /BinaryPath:e:\Temp\Test

Sample output from NanoServerApiScan.exe:

=== e:\Temp\Test\LrmApi.dll ===

ERRORS:

 

  KERNEL32.dll

    GetStartupInfoA (Proc not found)

      Please use API GetStartupInfoW as substitution.

    SetHandleCount (Proc not found)

 

For a list of supported APIs in Nano Server, please go to: https://msdn.microsoft.com/en-us/library/mt588480(v=vs.85).aspx

 

ref@

Comments

  • Anonymous
    November 27, 2015
    Does Nano have a compiler prerequisite for runtime dependencies (eg. observation of 'Proc not found" were under MSVCP110.dll)?
  • Anonymous
    January 06, 2016
    VC runtime is not part of Nano and is not a prerequisite of Nano. However, if your application depends on it, it needs to be installed first. The tool reports the API dependence of your application to run in Nano.
  • Anonymous
    January 21, 2016
    As organizations move toward modern DevOps practices, the role of the operating system needs to evolve
  • Anonymous
    April 29, 2016
    This post doesn't work anymore. Don't waste your time on this. Have a look at the new link provided by MSFT. It's an amazing. it worked for me as i was trying to apply on http://snapchattrophiess.com it worked and i haven't faced any problem