Assuming that IP and port are actually valid here.
Start by enabling your error reporting. Any of those methods could be failing, but you're not checking the results of them.
PHP Code:
ini_set('display_errors', 1);
error_reporting(E_ALL);
Next, handle the error checking on each:
PHP Code:
if ($con = ssh2_connect('host', 22))
{
if (ssh2_auth_password($con, 'user', 'password'))
{
$stream = ssh2_exec($con, '/home/mc/start.sh');
}
else
{
print 'Invalid username/password';
}
}
else
{
print 'Failed to connect to host';
}
Does that produce either error message?