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

Key not present on hopeful-pig -- pushing #847

Open
swaroop929 opened this issue May 7, 2024 · 0 comments
Open

Key not present on hopeful-pig -- pushing #847

swaroop929 opened this issue May 7, 2024 · 0 comments
Labels
Hardware:Dev Board Mini Coral Dev Board Mini Issues subtype:Mendel Linux Mendel Linux Build/installation issues type:build/install Build and install issues

Comments

@swaroop929
Copy link

swaroop929 commented May 7, 2024

Description

I am trying to use a Coral mini board from my University and when I try to run "mdt shell" on my Windows PC, I am getting this error

`Waiting for a device...
Connecting to hopeful-pig at 192.168.101.2
Key not present on hopeful-pig -- pushing

Couldn't connect to keymaster on hopeful-pig: [WinError 10061] No connection could be made because the target machine actively refused it.

Did you previously connect from a different machine? If so,
mdt-keymaster will not be running as it only accepts a single key.

You will need to either:

  1. Remove the key from /home/mendel/.ssh/authorized_keys on the
    device via the serial console
  • or -

    1. Copy the mdt private key from your home directory on this host
      in ~/.config/mdt/keys/mdt.key to the first machine and use
      'mdt pushkey mdt.key' to add that key to the device's
      authorized_keys file.

Failed to push via keymaster -- will attempt password login as a fallback.
Can't login using default credentials: Bad authentication type; allowed types: ['publickey']`

I have found the private key on my host computer but I am not able to push it on to the board and when I try mdt push mdt.key I again get the same error as above

Click to expand!

Issue Type

Build/Install

Operating System

Mendel Linux

Coral Device

Dev Board Mini

Other Devices

No response

Programming Language

No response

Relevant Log Output

C:\Users\Sai Swaroop Maram\.config\mdt\keys>mdt devices
hopeful-pig             (192.168.101.2)

C:\Users\Sai Swaroop Maram\.config\mdt\keys>mdt push mdt.key
Waiting for a device...
Connecting to hopeful-pig at 192.168.101.2
Key not present on hopeful-pig -- pushing

Couldn't connect to keymaster on hopeful-pig: [WinError 10061] No connection could be made because the target machine actively refused it.

Did you previously connect from a different machine? If so,
mdt-keymaster will not be running as it only accepts a single key.

You will need to either:
   1) Remove the key from /home/mendel/.ssh/authorized_keys on the
      device via the serial console

- or -

   2) Copy the mdt private key from your home directory on this host
      in ~/.config/mdt/keys/mdt.key to the first machine and use
      'mdt pushkey mdt.key' to add that key to the device's
      authorized_keys file.

Failed to push via keymaster -- will attempt password login as a fallback.
Can't login using default credentials: Bad authentication type; allowed types: ['publickey']

C:\Users\Sai Swaroop Maram\.config\mdt\keys>mdt set username mendel
Set username to mendel

C:\Users\Sai Swaroop Maram\.config\mdt\keys>mdt set password mendel
Set password to mendel

C:\Users\Sai Swaroop Maram\.config\mdt\keys>mdt devices
hopeful-pig             (192.168.101.2)

C:\Users\Sai Swaroop Maram\.config\mdt\keys>mdt help

Usage: mdt <subcommand> [<options>]

Where <subcommand> may be one of the following:
    help              - this command, gets help on another command.
    devices           - lists all detected devices.
    wait-for-device   - waits for a device to be discovered on the network
    get               - gets an MDT variable value
    set               - sets an MDT variable value
    clear             - clears an MDT variable
    genkey            - generates an SSH key for connecting to a device
    pushkey           - pushes an SSH public key to a device
    setkey            - imports a PEM-format SSH private key into the MDT
                        keystore
    resetkeys         - removes all keys from the given board and resets key
                        authentication to factory defaults
    shell             - opens an interactive shell to a device
    exec              - runs a shell command and returns the output and the
                        exit code
    install           - installs a Debian package using mdt-install-package on
                        the device
    push              - pushes a file (or files) to the device
    pull              - pulls a file (or files) from the device
    reboot            - reboots a device
    reboot-bootloader - reboots a device into the bootloader
    version           - prints which version of MDT this is

Use "mdt help <subcommand>" for more details.


C:\Users\Sai Swaroop Maram\.config\mdt\keys>mdt exec "sudo useradd -m newuser"
Waiting for a device...
Connecting to hopeful-pig at 192.168.101.2
Key not present on hopeful-pig -- pushing

Couldn't connect to keymaster on hopeful-pig: [WinError 10061] No connection could be made because the target machine actively refused it.

Did you previously connect from a different machine? If so,
mdt-keymaster will not be running as it only accepts a single key.

You will need to either:
   1) Remove the key from /home/mendel/.ssh/authorized_keys on the
      device via the serial console

- or -

   2) Copy the mdt private key from your home directory on this host
      in ~/.config/mdt/keys/mdt.key to the first machine and use
      'mdt pushkey mdt.key' to add that key to the device's
      authorized_keys file.

Failed to push via keymaster -- will attempt password login as a fallback.
Can't login using default credentials: Bad authentication type; allowed types: ['publickey']

C:\Users\Sai Swaroop Maram\.config\mdt\keys>mdt resetkeys 192.168.100.2
Connecting to 192.168.100.2 at 192.168.100.2
Couldn't establish ssh connection to device: socket error: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond

C:\Users\Sai Swaroop Maram\.config\mdt\keys>whoami
buddy\sai swaroop maram

C:\Users\Sai Swaroop Maram\.config\mdt\keys>
@google-coral-bot google-coral-bot bot added Hardware:Dev Board Mini Coral Dev Board Mini Issues subtype:Mendel Linux Mendel Linux Build/installation issues type:build/install Build and install issues labels May 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Hardware:Dev Board Mini Coral Dev Board Mini Issues subtype:Mendel Linux Mendel Linux Build/installation issues type:build/install Build and install issues
Projects
None yet
Development

No branches or pull requests

1 participant