Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OSX Kernel Build Failed, Can't Find Includes #335

Closed
BeetleChunks opened this issue May 15, 2016 · 25 comments
Closed

OSX Kernel Build Failed, Can't Find Includes #335

BeetleChunks opened this issue May 15, 2016 · 25 comments

Comments

@BeetleChunks
Copy link

I am getting the following error when specifically using device 3, it works for the other devices. It appears it is not able to locate the constants.h from the local includes directory. I have verified that file is present and is in the includes directory in "/Users/beetle/Documents/ocltmp/oclHashcat/include/".

I am using a MacBook Pro (Retina, 15-inch, Mid 2014). Device 3 is a "GeForce GT 750M, 512/2048 MB allocatable, 925Mhz, 2MCU"

$ ./hashcat.app -m 2500 test/test.hccap ../../hashcat-0.49/wordlists/rockyou.txt -d3
hashcat (v3.00-beta-20-g2937c83) starting...

Device #1: Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz, skipped
Device #2: Iris Pro, skipped
Device #3: GeForce GT 750M, 512/2048 MB allocatable, 925Mhz, 2MCU

Device #3: Kernel /Users/beetle/Documents/ocltmp/oclHashcat/./kernels/m02500.774f9c7e.kernel not found in cache! Building may take a while...

=== Build failed, retry with optimization disabled ===

ERROR: clBuildProgram() : -11 : CL_BUILD_PROGRAM_FAILURE

=== Build Options : -cl-std=CL1.1 -I"/Users/beetle/Documents/ocltmp/oclHashcat/./" -DVENDOR_ID=2 -DCUDA_ARCH=0 -DVECT_SIZE=1 -DDEVICE_TYPE=4 -DKERN_TYPE=2500 -D_unroll ===

=== Build Log (start) ===
:10:10: fatal error: 'include/constants.h' file not found

include "include/constants.h"

     ^

=== Build Log (end) ===
Device #3: Kernel /Users/beetle/Documents/ocltmp/oclHashcat/./OpenCL/m02500.cl build failure. Proceed without this device.
Checking for weak hashes...

ERROR: clSetKernelArg() : -48 : CL_INVALID_KERNEL

Any help would be appreciated.

@lfaoro
Copy link

lfaoro commented May 15, 2016

Make sure you have gmp available in the system, if you have brew it's a simple brew install gmp and have you downloaded the OpenCL-Headers dependency?

@BeetleChunks
Copy link
Author

I have brew installed and have version gmp-6.1.0 installed. I have the OpenCL-Headers in the following directory, "oclHashcat/deps/OpenCL-Headers/CL/". I used the git clone method found in the BUILD.md file.

@jsteube
Copy link
Member

jsteube commented May 17, 2016

GMP is not required for hashcat 3.00 anymore

So with both of the other devices it works just not with the nvidia gpu ?

@noaht8um
Copy link

@BeetleChunks I am having the same issues. I also have the include files in the proper place. I do not have gmp installed because I thought it was not required. I am running 10.11.5.

@arnaudsj
Copy link

Same here with 10.11.4

@arnaudsj
Copy link

It works against CPU, and Intel Iris card, but not NVidia (device 3)

@lfaoro
Copy link

lfaoro commented May 17, 2016

@jsteube you should specify that in the readme when you can

@jsteube
Copy link
Member

jsteube commented May 17, 2016

Please try to find out which paths are searched. I don't know how to do that on OSX, on Linux I'd use strace

@arnaudsj
Copy link

I confirmed that hardcoding the path in the *.cl files solves the problem. So it is definetly a problem with the search path.

It might be dumb, but should:
-I"/Users/beetle/Documents/ocltmp/oclHashcat/./" not be -I"/Users/beetle/Documents/ocltmp/oclHashcat" instead?

If not, where is this path generated? It is obviously passed along dynamically in the JIT portion...

@jsteube
Copy link
Member

jsteube commented May 17, 2016

Yeah but I can't fix it without being able to reproduce

@noaht8um
Copy link

When I build and run hashcat.app, this is what I get. I am running bench using method 1000 (NTLM) as an example:


Computer:oclHashcat username$ ./hashcat.app -d2 --bench -m1000
hashcat (v3.00-beta-32-gde2074d) starting in benchmark-mode...

Device #1: Intel(R) Core(TM) i7-4790K CPU @ 4.00GHz, skipped
Device #2: GeForce GTX 970, 1024/4096 MB allocatable, 1253Mhz, 13MCU

ERROR: clBuildProgram() : -11 : CL_BUILD_PROGRAM_FAILURE

=== Build Options : -cl-std=CL1.1 -I"/Users/username/Desktop/hashcat-build/oclHashcat/./" -DVENDOR_ID=2 -DCUDA_ARCH=0 -DVECT_SIZE=2 -DDEVICE_TYPE=4 -DKERN_TYPE=1000 -D_unroll ===

=== Build Log (start) ===
:10:10: fatal error: 'include/constants.h' file not found
#include "include/constants.h"
^

=== Build Log (end) ===
Device #2: Kernel /Users/username/Desktop/hashcat-build/oclHashcat/./OpenCL/m01000_a3.cl build failure. Proceed without this device.
Hashtype: NTLM

Started: Tue May 17 17:28:12 2016
Stopped: Tue May 17 17:28:13 2016

Computer:oclHashcat username$

It does this for all different methods that I have tested. In the m01000_a3.cl file, it gets stuck at line 10 which is:

#include "include/constants.h"

I don't know why it would get stuck here because that seems to be the right path.

@arnaudsj I saw that you were able to fix the problem by hard-coding; where did you edit the path?

Sorry if this is long-winded, but I wanted to show as much data as possible.

@jsteube
Copy link
Member

jsteube commented May 18, 2016

I think the Problem discussed here is the same one as in #345

... It's a bug in the OpenCL runtime of nvidia. We can't do anything on it. You can try reporting the problem to the vendor, but sadly from my experience they will ignore you if it's about GPGPU and not games.

@cclements
Copy link

I'm getting the same constants.h file not found on intel only. I tried hardcoding the path in the .cl files as arnaudsj suggested, but the build still fails:

./hashcat.app --opencl-device-types=1 -d1 -b -m1000
hashcat (v3.00-beta-60-g35d7e67) starting in benchmark-mode...

Device #1: Intel(R) Core(TM) i7-4850HQ CPU @ 2.30GHz, 4096/16384 MB allocatable, 2300Mhz, 8MCU
Device #2: Iris Pro, skipped
Device #3: GeForce GT 750M, skipped

ERROR: clBuildProgram() : -11 : CL_BUILD_PROGRAM_FAILURE

=== Build Options : -cl-std=CL1.1 -I"/private/var/root/tools/oclHashcat/./" -DVENDOR_ID=2 -DCUDA_ARCH=0 -DVECT_SIZE=4 -DDEVICE_TYPE=2 -DKERN_TYPE=1000 -D_unroll ===

=== Build Log (start) ===
<program source>:10:10: fatal error: '/private/var/root/tools/oclHashcat/include/constants.h' file not found
#include "/private/var/root/tools/oclHashcat/include/constants.h"
         ^

=== Build Log (end) ===
Device #1: Kernel /private/var/root/tools/oclHashcat/./OpenCL/m01000_a3.cl build failure. Proceed without this device.
Hashtype: NTLM

Started: Tue May 24 08:12:30 2016
Stopped: Tue May 24 08:12:32 2016 

I am on a late 2013 rMBP with 10.11.5 installed.

@matrix
Copy link
Member

matrix commented May 24, 2016

@cclements , you run hashcat.app by root?

@cclements
Copy link

yes. I have also tried as a non-root user with the same results.

@matrix
Copy link
Member

matrix commented May 24, 2016

@cclements, could you paste the log of the execution by non-root user ?
Thanks

@cclements
Copy link

I neglected to change the paths in the .cl files back to the defaults after I moved the directory for the non-root user. I changed them back and all is well with the non-nvidia devices. Sorry for the confusion.

@unix-ninja
Copy link
Contributor

BeetleChunks and noaht8um, do you guys have XCode installed?

@jsteube
Copy link
Member

jsteube commented May 25, 2016

Maybe some can please pull latest version from github and retry? I don't have much hopes that this one fixed it but it's worth a try.

@cclements
Copy link

I take it the nvidia specific issue from #345 applies to Windows builds as well? I ask because I am getting the same includes failure trying to run on nvidia on win10 x64 with the latest drivers now as well. If this isn't expected let me know and I'll open a new issue.

@jsteube
Copy link
Member

jsteube commented May 28, 2016

This issue should be fixed, please make sure to use latest github version

@cclements
Copy link

oclHashcat v2.01 (gc0d0ef6) starting...

Device #1: Intel(R) Core(TM) i7-6700K CPU @ 4.00GHz, 8173/32693 MB allocatable, 4000Mhz, 8MCU
Device #2: GeForce GTX 980, 1024/4096 MB allocatable, 1329Mhz, 16MCU

Hashes: 19 hashes; 19 unique digests, 19 unique salts
Bitmaps: 16 bits, 65536 entries, 0x0000ffff mask, 262144 bytes, 5/13 rotates
Rules: 1
Applicable Optimizers:
* Zero-Byte
* Not-Iterated
Watchdog: Temperature abort trigger set to 90c
Watchdog: Temperature retain trigger disabled

Device #1: Kernel D:\Downloads\oclHashcat/kernels/m05600_a0.715b2085.kernel (475824 bytes)
Device #2: Kernel D:\Downloads\oclHashcat/kernels/m05600_a0.390aa4a0.kernel not found in cache! Building may take a while...

=== Build failed, retry with optimization disabled ===

ERROR: clBuildProgram() : -11 : CL_BUILD_PROGRAM_FAILURE

=== Build Options : -I"D:\Downloads\oclHashcat/" -DVENDOR_ID=4318 -DCUDA_ARCH=502 -DVECT_SIZE=1 -DDEVICE_TYPE=4 ===

=== Build Log (start) ===
<kernel>:10:10: fatal error: 'inc_hash_constants.h' file not found
#include "inc_hash_constants.h"
         ^

=== Build Log (end) ===
Device #2: Kernel D:\Downloads\oclHashcat/OpenCL/m05600_a0.cl build failure. Proceed without this device.

@cclements
Copy link

Apologies, didn't notice that "oclHashcat" had been deprecated in favor of simply "hashcat". Calling hashcat instead allowed the kernel to build without error.

@cclements
Copy link

OSX kernel compilation for nvidia works as of your last commit as well. Thanks!

@jsteube
Copy link
Member

jsteube commented Jun 2, 2016

Problem fixed

@jsteube jsteube closed this as completed Jun 2, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants