Q:

How to get partition's free space in a linux machine

I have to get harddisk's free space available from 7 Windows 2008 servers and 4 Linux machines. For windows machines I wrote a tiny .Net Program. This will get details from all windows machines. 
In Linux machine I used 
df -h 

command. And I used the following command 
ssh username@linuxmachine df -h 

to get details from other Linux machine. But this command asks for password every time. Is there any way to get hard disk details from all Linux machines ? 
OR is there any way to get Linux machine's partition's details from a windows machine ? 
All Linux machines have same username and password. 
PS: I don't have any knowledge on shell scripting. kindly elaborate your solutions :) 

A:

You can use public/private key pairs for authentication. First generate public/private key. On linux you can do this:
ssh-keygen

You can find the keys in your homedir in .ssh :
ceco@persika ~/.ssh $ ls id_rsa*
id_rsa  id_rsa.pub

Then distribute public key on the machines you want to log in:
ssh-copy-id MACHINE_IP_ADDR

It will ask you for password and you are good to go. The public key is saved in ~/.ssh/authorized_keys. After this procedure you can make passwordless logins. I won't discuss security risks about this - I believe you are aware what might go wrong :)

