Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I have a target and host setup with Linux as the OS on both.

I have a root file system(RFS) in my target. I have a setup in which my RFS is in development state so it will undergo changes on the fly. My requirement is that, every time I make a change, I need to sync my current RFS to my target RFS.

One of my colleague suggested that I can use rsync to attain my task.

Please shed your valuable suggestions on this idea.
All other ideas are also welcomed.

share|improve this question
    
be aware there's no need for greetings on SE: meta.stackoverflow.com/questions/2950/… –  Tshepang Jan 13 '11 at 13:20
    
ok.. Thanks.. i 've updated the question –  Sen Jan 13 '11 at 13:23
    
Do you want to manually sync it (ie, like Gille's answer) or do you want a solution that will sync automatically anytime a change is made? I don't recommend this, but it is possible. –  Steven D Jan 13 '11 at 21:51
    
@Seven: If it is possible to do it automatically i would also like to know that. –  Sen Jan 14 '11 at 5:55
add comment

1 Answer

What kind of access do you have to the target? If you can ssh into it, it's just

rsync -au "$RFS" target:/

Note that you'll need an rsync executable on the target as well.

You'll want to set up some kind of passwordless authentication. I guess during development you would just allow root so ssh in, and put a public key for root in place. If the ssh server on the target is OpenSSH, then you need PermitRootLogin Yes in /etc/sshd_config (or /etc/ssh/sshd_config or something), and the root public key would be in /root/.ssh/authorized_keys or /.ssh/authorized_keys depending on where root's home directory is set in /etc/password.

If you changed the bootloader, and perhaps if you changed the kernel, you'll also need to run the bootloader update utility.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.