I'm not really sure what you are trying to do, but ssh (openssh anyway) has the functionality to run commands remotely, and doesn't have the security headaches of sending your root password unencrypted. If you typically do the same stuff, it might be a better idea to write a shell script on the remote server to do the work, and use ssh to start that script.