#!/usr/bin/perl -w use strict; use warnings; use Net::SSH qw(ssh); my $user = "root"; my $hostname = "orarac1"; my $command = "cat /proc/meminfo |grep -w MemTotal |awk '{print \$2}'"; ssh("$user\@$hostname", "$command"); Host key verification failed.