I want to SSH to a server and execute a simple command like \"id\" and get the output of it and store it to a file on my primary server. I do not have privileges to install
You can always install modules locally, and that is the method you should look into; however, you should be able to get away with
#!/usr/bin/perl use strict; use warnings; my $id = qx/ssh remotehost id 2>&1/; chomp $id; print "id is [$id]\n"