我想在注册新用户时在服务器上发送配置文件。我在我的php文件上执行此操作:
$command = "scp -B -i $priv_key -o StrictHostKeyChecking=no $tmp_file $user@$host:/home/asterisk/etc/asterisk/$filename 2>&1";
shell_exec($command);
但我有异常Permission denied (publickey,password).lost connection
出了什么问题?