cryptogen
is already installed along with Hyperledger Fabric, the reason it's not found is because it is not set in your PATH environment variable.
- Find the location where you have installed Hyperledger Fabric
- Set the
PATH
environment variable to the location'sbin
folder
- Example: If Hyperledger Fabric is installed in /root/fabric-samples/, then set -
export PATH=$PATH:/root/fabric-samples/bin/
- Additionally, also update your
.profile
or.bashrc
with the above PATH configuration, so that it will be reflected correctly every time you login the next time.