Date: Tue, 25 Jun 2019 19:19:11 +0200 From: Solar Designer <solar@...nwall.com> To: john-users@...ts.openwall.com Subject: Re: Disable specific SIMD features like AVX, AVX2, etc. On Mon, Jun 24, 2019 at 10:21:36PM +0300, Jonathan A wrote: > The reason is that I need john running in many docker containers on > multiple pods and servers. Instead of always building john from source > (using the Dockerfile), I simply build it once and create a .deb package > which I install using the Dockerfile (install = simply copy the "run" > folder and one or two .so files). This works fine. Recently I built john on > a machine with AVX and of course it didn't execute on pods that were on > machines without AVX. So I wanted to build john without AVX, so I know it > will run on all pods/machines. > > I know that the cleaner way would be to build john from source on each pod, > but it's easier for me (and faster pod startup) to create the .deb package > and install from there. Of course if you think there's a better way I would > love to hear your input. Please see the README-DISTROS file mentioned in magnum's reply for how to do this right, but you might find that approach too cumbersome for your use. (It's more reasonable for use by an actual distro.) An easier approach you may use is a script like this (call it "john"): --- #!/bin/sh for john in john-avx512bw john-avx2 john-avx john-sse4 john-ssse3 john-sse2; do if ./$john | grep -q ^Usage:; then echo "Will use $john" ln -sf $john john exec ./john "$@" exit fi done echo 'No suitable john binary found' --- You may omit the "ln" line if you want it to go through the checks every time rather than just once. Alexander
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.