Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Why root? | 54 comments | Create New Account
Click here to return to the 'Why root?' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Why root?
Authored by: derrickbass on Feb 12, '05 02:55:11AM

Here's one reason I ran into once. I wanted to copy some system files from one computer to another. The only (easy) way I could think of to do it, preserving permissions, was:
sudo rsync /path/to/source root@remote.host:/path/to/dest
You need root enabled on the remote host in order for this to work.
(Of course, another way would be to copy the files as a user and then use sudo chmod and sudo chown on the remote machine; in this case, the files had a variety of permissions (and perhaps even owners; can't recall now), so that would have been painful.)



[ Reply to This | # ]
Why root?
Authored by: shavenyak on Feb 14, '05 08:51:38AM

You could tar up the files on the source machine, scp the .tar file over, log on to the remote machine and use sudo to un-tar. A couple more steps, but certainly no pain.



[ Reply to This | # ]
Why root?
Authored by: name99 on Mar 07, '06 08:17:37AM

Have you ever actually used rsync?
If one uses rsync for nightly backups, then a tar solution is completely useless --- the rsync solution will copy over maybe 2 or 3 MB and take 15 minutes, the tar solution will copy over 50GB and take 4 hours.

The fact is that one apparently really does have to have a root account active (meaning available via an ssh private/public key) in this case; sudo just won't do it. HOWEVER this does not mean that a password is necessary for root; it is not, so one is protected there.



[ Reply to This | # ]