Validate_box issue

Have problem with Validate_box.
Got this error:
‘validate_box’ is not recognized as an internal or external command,
operable program or batch file.
Any suggestions?
/samir

Let’s see a screenshot

C:\Users\SamirTalic\m103-vagrant-env>vagrant provision
==> mongod-m103: Running provisioner: shell…
mongod-m103: Running: C:/Users/SAMIRT~1/AppData/Local/Temp/vagrant-shell20191116-11836-1lsxhl5
mongod-m103: + config
mongod-m103: + sudo su
mongod-m103: + echo -e never
mongod-m103: + echo -e never
mongod-m103: + echo manual
mongod-m103: + sudo tee /etc/init/mongod.override
mongod-m103: manual
mongod-m103: + ip_config
mongod-m103: ++ ifconfig
mongod-m103: ++ tail -1
mongod-m103: ++ awk ‘{ print $1}’
mongod-m103: ++ cut -d: -f2
mongod-m103: ++ grep -v 127.0.0.1
mongod-m103: ++ grep ‘inet addr:’
mongod-m103: + export CLIENT_IP_ADDR=192.168.103.100
mongod-m103: + CLIENT_IP_ADDR=192.168.103.100
mongod-m103: ++ hostname
mongod-m103: + export CLIENT_FQDN=m103
mongod-m103: + CLIENT_FQDN=m103
mongod-m103: ++ hostname
mongod-m103: ++ tr ‘[:upper:]’ ‘[:lower:]’
mongod-m103: ++ cut -d. -f 1
mongod-m103: + export CLIENT_NAME=m103
mongod-m103: + CLIENT_NAME=m103
mongod-m103: + echo ‘Configuring /etc/hosts …’
mongod-m103: Configuring /etc/hosts …
mongod-m103: + echo ‘127.0.0.1 localhost localhost.localdomain localhost4 localhost4.localdomain4 ’
mongod-m103: + echo ‘::1 localhost localhost.localdomain localhost6 localhost6.localdomain6’
mongod-m103: + echo ‘fe00::0 ip6-localnet’
mongod-m103: + echo ‘ff00::0 ip6-mcastprefix’
mongod-m103: + echo ‘ff02::1 ip6-allnodes’
mongod-m103: + echo ‘ff02::2 ip6-allrouters’
mongod-m103: + echo ‘ff02::3 ip6-allhosts’
mongod-m103: + echo ‘192.168.103.100 m103 m103’
mongod-m103: + update_repo
mongod-m103: + echo ‘Install MongoDB Enterprise Repository’
mongod-m103: Install MongoDB Enterprise Repository
mongod-m103: + echo ‘deb [ arch=amd64 ] http://repo.mongodb.com/apt/ubuntu trusty/mongodb-enterprise/3.6 multiverse’ mongod-m103: + sudo tee /etc/apt/sources.list.d/mongodb-enterprise.list
mongod-m103: deb [ arch=amd64 ] http://repo.mongodb.com/apt/ubuntu trusty/mongodb-enterprise/3.6 multiverse
mongod-m103: + sudo apt-key adv --keyserver keyserver.ubuntu.com --recv 0C49F3730359A14518585931BC711F9BA15703C6
mongod-m103: Executing: gpg --ignore-time-conflict --no-options --no-default-keyring --homedir /tmp/tmp.PDd16uWYXZ --no-auto-check-trustdb --trust-model always --keyring /etc/apt/trusted.gpg --primary-keyring /etc/apt/trusted.gpg --keyring /etc/apt/trusted.gpg.d/ubuntu-advantage-esm-infra-trusty.gpg --keyserver keyserver.ubuntu.com --recv 0C49F3730359A14518585931BC711F9BA15703C6
mongod-m103: gpg:
mongod-m103: requesting key A15703C6 from hkp server keyserver.ubuntu.com
mongod-m103: gpg: key A15703C6: “MongoDB 3.4 Release Signing Key packaging@mongodb.com” not changed
mongod-m103: gpg: Total number processed: 1
mongod-m103: gpg: unchanged: 1
mongod-m103: + echo ‘Update Repositories’
mongod-m103: Update Repositories
mongod-m103: + sudo apt-get update -y
mongod-m103: Ign http://repo.mongodb.com trusty/mongodb-enterprise/3.6 InRelease
mongod-m103: Ign http://archive.ubuntu.com trusty InRelease
mongod-m103: Hit http://archive.ubuntu.com trusty-updates InRelease
mongod-m103: Get:1 http://repo.mongodb.com trusty/mongodb-enterprise/3.6 Release.gpg [801 B]
mongod-m103: Hit http://security.ubuntu.com trusty-security InRelease
mongod-m103: Hit http://archive.ubuntu.com trusty-backports InRelease
mongod-m103: Hit http://archive.ubuntu.com trusty Release.gpg
mongod-m103: Hit http://repo.mongodb.com trusty/mongodb-enterprise/3.6 Release
mongod-m103: Ign http://repo.mongodb.com trusty/mongodb-enterprise/3.6 Release
mongod-m103: Hit https://esm.ubuntu.com trusty-infra-security InRelease
mongod-m103: Ign http://repo.mongodb.com trusty/mongodb-enterprise/3.6/multiverse amd64 Packages/DiffIndex
mongod-m103: Hit https://esm.ubuntu.com trusty-infra-updates InRelease
mongod-m103: Hit http://archive.ubuntu.com trusty-updates/main Sources
mongod-m103: Hit https://esm.ubuntu.com trusty-infra-security/main amd64 Packages
mongod-m103: Hit http://security.ubuntu.com trusty-security/main Sources
mongod-m103: Get:2 https://esm.ubuntu.com trusty-infra-security/main Translation-en_US
mongod-m103: Hit http://archive.ubuntu.com trusty-updates/restricted Sources
mongod-m103: Hit http://archive.ubuntu.com trusty-updates/universe Sources
mongod-m103: Hit https://esm.ubuntu.com trusty-infra-updates/main amd64 Packages
mongod-m103: Get:3 https://esm.ubuntu.com trusty-infra-updates/main Translation-en_US
mongod-m103: Hit http://archive.ubuntu.com trusty-updates/multiverse Sources
mongod-m103: Hit http://security.ubuntu.com trusty-security/universe Sources
mongod-m103: Hit http://archive.ubuntu.com trusty-updates/main amd64 Packages
mongod-m103: Hit http://archive.ubuntu.com trusty-updates/restricted amd64 Packages
mongod-m103: Hit http://archive.ubuntu.com trusty-updates/universe amd64 Packages
mongod-m103: Hit http://security.ubuntu.com trusty-security/main amd64 Packages
mongod-m103: Hit http://archive.ubuntu.com trusty-updates/multiverse amd64 Packages
mongod-m103: Hit http://repo.mongodb.com trusty/mongodb-enterprise/3.6/multiverse amd64 Packages
mongod-m103: Hit http://archive.ubuntu.com trusty-updates/main Translation-en
mongod-m103: Ign http://repo.mongodb.com trusty/mongodb-enterprise/3.6/multiverse Translation-en_US
mongod-m103: Ign http://repo.mongodb.com trusty/mongodb-enterprise/3.6/multiverse Translation-en
mongod-m103: Hit http://archive.ubuntu.com trusty-updates/multiverse Translation-en
mongod-m103: Hit http://security.ubuntu.com trusty-security/universe amd64 Packages
mongod-m103: Hit http://archive.ubuntu.com trusty-updates/restricted Translation-en
mongod-m103: Ign https://esm.ubuntu.com trusty-infra-security/main Translation-en_US
mongod-m103: Ign https://esm.ubuntu.com trusty-infra-security/main Translation-en
mongod-m103: Hit http://archive.ubuntu.com trusty-updates/universe Translation-en
mongod-m103: Ign https://esm.ubuntu.com trusty-infra-updates/main Translation-en_US
mongod-m103: Ign https://esm.ubuntu.com trusty-infra-updates/main Translation-en
mongod-m103: Hit http://archive.ubuntu.com trusty-backports/main Sources
mongod-m103: Hit http://security.ubuntu.com trusty-security/main Translation-en
mongod-m103: Hit http://archive.ubuntu.com trusty-backports/restricted Sources
mongod-m103: Hit http://archive.ubuntu.com trusty-backports/universe Sources
mongod-m103: Hit http://security.ubuntu.com trusty-security/universe Translation-en
mongod-m103: Hit http://archive.ubuntu.com trusty-backports/multiverse Sources
mongod-m103: Hit http://archive.ubuntu.com trusty-backports/main amd64 Packages
mongod-m103: Hit http://archive.ubuntu.com trusty-backports/restricted amd64 Packages
mongod-m103: Hit http://archive.ubuntu.com trusty-backports/universe amd64 Packages
mongod-m103: Hit http://archive.ubuntu.com trusty-backports/multiverse amd64 Packages
mongod-m103: Hit http://archive.ubuntu.com trusty-backports/main Translation-en
mongod-m103: Hit http://archive.ubuntu.com trusty-backports/multiverse Translation-en
mongod-m103: Hit http://archive.ubuntu.com trusty-backports/restricted Translation-en
mongod-m103: Hit http://archive.ubuntu.com trusty-backports/universe Translation-en
mongod-m103: Hit http://archive.ubuntu.com trusty Release
mongod-m103: Hit http://archive.ubuntu.com trusty/main Sources
mongod-m103: Hit http://archive.ubuntu.com trusty/restricted Sources
mongod-m103: Hit http://archive.ubuntu.com trusty/universe Sources
mongod-m103: Hit http://archive.ubuntu.com trusty/multiverse Sources
mongod-m103: Hit http://archive.ubuntu.com trusty/main amd64 Packages
mongod-m103: Hit http://archive.ubuntu.com trusty/restricted amd64 Packages
mongod-m103: Hit http://archive.ubuntu.com trusty/universe amd64 Packages
mongod-m103: Hit http://archive.ubuntu.com trusty/multiverse amd64 Packages
mongod-m103: Hit http://archive.ubuntu.com trusty/main Translation-en
mongod-m103: Hit http://archive.ubuntu.com trusty/multiverse Translation-en
mongod-m103: Hit http://archive.ubuntu.com trusty/restricted Translation-en
mongod-m103: Hit http://archive.ubuntu.com trusty/universe Translation-en
mongod-m103: Ign http://archive.ubuntu.com trusty/main Translation-en_US
mongod-m103: Ign http://archive.ubuntu.com trusty/multiverse Translation-en_US
mongod-m103: Ign http://archive.ubuntu.com trusty/restricted Translation-en_US
mongod-m103: Ign http://archive.ubuntu.com trusty/universe Translation-en_US
mongod-m103: Fetched 801 B in 4s (167 B/s)
mongod-m103: Reading package lists…
mongod-m103: W
mongod-m103: :
mongod-m103: GPG error: http://repo.mongodb.com trusty/mongodb-enterprise/3.6 Release: The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY 58712A2291FA4AD5
mongod-m103: + echo ‘Installing MongoDB Enterprise Dependencies’
mongod-m103: Installing MongoDB Enterprise Dependencies
mongod-m103: + sudo apt-get install -y libgssapi-krb5-2 libsasl2-2 libssl1.0.0 libstdc++6 snmp
mongod-m103: Reading package lists…
mongod-m103: Building dependency tree…
mongod-m103: Reading state information…
mongod-m103: libsasl2-2 is already the newest version.
mongod-m103: libgssapi-krb5-2 is already the newest version.
mongod-m103: libssl1.0.0 is already the newest version.
mongod-m103: libstdc++6 is already the newest version.
mongod-m103: snmp is already the newest version.
mongod-m103: 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
mongod-m103: + install_mongod
mongod-m103: + echo ‘Install MongoDB Enterprise’
mongod-m103: Install MongoDB Enterprise
mongod-m103: + sudo apt-get install --force-yes -y mongodb-enterprise
mongod-m103: Reading package lists…
mongod-m103: Building dependency tree…
mongod-m103: Reading state information…
mongod-m103: mongodb-enterprise is already the newest version.
mongod-m103: 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
mongod-m103: + mkdir -p /var/log/mongodb/
mongod-m103: + sudo chown vagrant:vagrant -R /var/log/mongodb
mongod-m103: + sudo chown vagrant:vagrant -R /var/lib/mongodb
mongod-m103: + sudo echo ’
mongod-m103: security:
mongod-m103: authorization: enabled’
mongod-m103: + sudo tee -a /etc/mongod.conf
mongod-m103:
mongod-m103: security:
mongod-m103: authorization: enabled
mongod-m103: + echo ‘Done installing MongoDB Enterprise’
mongod-m103: Done installing MongoDB Enterprise
mongod-m103: + user_setup
mongod-m103: + sudo sh -c ‘killall mongod; true’
mongod-m103: mongod: no process found
mongod-m103: + sudo mkdir -p /data
mongod-m103: + sudo chmod -R 777 /data
mongod-m103: + mkdir -p /data/db
mongod-m103: + mkdir -p /home/vagrant/data
mongod-m103: + chmod -R 777 /home/vagrant/data
mongod-m103: + chown -R vagrant:vagrant /home/vagrant/data
mongod-m103: + mkdir -p /var/m103/validation
mongod-m103: + echo ‘Set LC_ALL=C to .profile’
mongod-m103: Set LC_ALL=C to .profile
mongod-m103: + sudo echo ‘export LC_ALL=C’
mongod-m103: + sudo echo PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin:/var/m103/validation
mongod-m103: + data_path
mongod-m103: + sudo mkdir -p /data
mongod-m103: + sudo chown -R vagrant:vagrant /data
mongod-m103: + install_pymongo
mongod-m103: + sudo apt-get -y install python-pip
mongod-m103: Reading package lists…
mongod-m103: Building dependency tree…
mongod-m103: Reading state information…
mongod-m103: python-pip is already the newest version.
mongod-m103: 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
mongod-m103: + sudo pip install pymongo
mongod-m103: Requirement already satisfied (use --upgrade to upgrade): pymongo in /usr/local/lib/python2.7/dist-packages
mongod-m103: Cleaning up…
mongod-m103: + download_validators
mongod-m103: + echo ‘Downloading Validation Scripts’
mongod-m103: Downloading Validation Scripts
mongod-m103: + curl -s https://s3.amazonaws.com/edu-static.mongodb.com/lessons/M103/m103_validation.tgz -o m103_validation.tgz
mongod-m103: + tar -xzvf m103_validation.tgz -C /var/m103/validation
mongod-m103: ./._validate_lab_change_dbpath
mongod-m103: validate_lab_change_dbpath
mongod-m103: ./._validate_lab_configuration_file
mongod-m103: validate_lab_configuration_file
mongod-m103: ./._validate_lab_different_logpath
mongod-m103: validate_lab_different_logpath
mongod-m103: ./._validate_lab_document_chunks
mongod-m103: validate_lab_document_chunks
mongod-m103: ./._validate_lab_first_application_user
mongod-m103: validate_lab_first_application_user
mongod-m103: ./._validate_lab_first_sharded_cluster
mongod-m103: validate_lab_first_sharded_cluster
mongod-m103: ./._validate_lab_import_dataset
mongod-m103: validate_lab_import_dataset
mongod-m103: ./._validate_lab_initialize_local_replica_set
mongod-m103: validate_lab_initialize_local_replica_set
mongod-m103: ./._validate_lab_launch_mongod
mongod-m103: validate_lab_launch_mongod
mongod-m103: ./._validate_lab_remove_readd_node
mongod-m103: validate_lab_remove_readd_node
mongod-m103: validate_lab_shard_collection
mongod-m103: + rm -rf m103_validation.tgz
mongod-m103: + echo ‘#!/bin/bash
mongod-m103: curl -s https://s3.amazonaws.com/edu-static.mongodb.com/lessons/M103/m103_validation.tgz -o m103_validation.tgz
mongod-m103: sudo tar -xzvf m103_validation.tgz -C /var/m103/validation
mongod-m103: rm -rf m103_validation.tgz’
mongod-m103: + echo ‘#!/bin/bash
mongod-m103: echo -n ‘’‘m103 rocks’’’ | openssl sha256 | sed -e s/(stdin)=.//’
mongod-m103: + chmod -R +x /var/m103/validation/
mongod-m103: + chown root:root /var/m103/validation
mongod-m103: + echo ‘Done: Downloaded Validation Scripts’
mongod-m103: Done: Downloaded Validation Scripts
mongod-m103: + set +e
mongod-m103: + verify_ip
mongod-m103: + export EXPECTED_IP=192.168.103.100
mongod-m103: + EXPECTED_IP=192.168.103.100
mongod-m103: + ifconfig
mongod-m103: + grep 192.168.103.100
mongod-m103: inet addr:192.168.103.100 Bcast:192.168.103.255 Mask:255.255.255.0
mongod-m103: + ret=0
mongod-m103: + ‘[’ 0 -ne 0 ‘]’
mongod-m103: + echo DONE
mongod-m103: DONE

C:\Users\SamirTalic\m103-vagrant-env>validate_box
‘validate_box’ is not recognized as an internal or external command,
operable program or batch file.

C:\Users\SamirTalic\m103-vagrant-env>ssh
usage: ssh [-46AaCfGgKkMNnqsTtVvXxYy] [-B bind_interface]
[-b bind_address] [-c cipher_spec] [-D [bind_address:]port]
[-E log_file] [-e escape_char] [-F configfile] [-I pkcs11]
[-i identity_file] [-J [user@]host[:port]] [-L address]
[-l login_name] [-m mac_spec] [-O ctl_cmd] [-o option] [-p port]
[-Q query_option] [-R address] [-S ctl_path] [-W host:port]
[-w local_tun[:remote_tun]] destination [command]

C:\Users\SamirTalic\m103-vagrant-env>validate_box
‘validate_box’ is not recognized as an internal or external command,
operable program or batch file.

Regrds
SAmir

@Samir_Talic_39646 suggest you follow the instructions again:

1 Like

Hi
I did it but I got the same error:

C:\Users\SamirTalic\m103-vagrant-env>ssh
usage: ssh [-46AaCfGgKkMNnqsTtVvXxYy] [-B bind_interface]
[-b bind_address] [-c cipher_spec] [-D [bind_address:]port]
[-E log_file] [-e escape_char] [-F configfile] [-I pkcs11]
[-i identity_file] [-J [user@]host[:port]] [-L address]
[-l login_name] [-m mac_spec] [-O ctl_cmd] [-o option] [-p port]
[-Q query_option] [-R address] [-S ctl_path] [-W host:port]
[-w local_tun[:remote_tun]] destination [command]

C:\Users\SamirTalic\m103-vagrant-env>vagrant status
Current machine states:

mongod-m103 running (virtualbox)

The VM is running. To stop this VM, you can run vagrant halt to
shut it down forcefully, or you can run vagrant suspend to simply
suspend the virtual machine. In either case, to restart it again,
simply run vagrant up.

C:\Users\SamirTalic\m103-vagrant-env>validate_box
‘validate_box’ is not recognized as an internal or external command,
operable program or batch file.

Samir

As per the lab instructions, you need to run vagrant ssh. What you ran is ssh which is incorrect.
That command will log you into the box after which you can validate the box.

Now is working
Huge thanks
Samir

No problem Samir :wink: