osdir.com
mailing list archive F.A.Q. -since 2001!



Subject: Re: Sudo + ssh and rsnapshot - msg#00021

List: sysutils.backup.rsnapshot.general

Mail Archive Navigation:
by Date: Prev Next Date Index by Thread: Prev Next Thread Index

On Sun, Aug 06, 2006 at 07:56:50PM +0200, S?bastien CRAMATTE wrote:
> Hello list,
>
> I'm a newbie in rsnapshot but seems to be amazing :)
>
> I've got various linux server configured to use sudo
> the root access is disabled (like in Ubuntu)
>
> How can I setup rsnapshots to get data from these servers
>
> I think that I should do :
> - do ssh public keys exchange between servers
>
> - configure sudo to allow rsync call without password
>
> LAN = NOPASSWD: /usr/bin/rsync ...
>
>
> I believe that I need to call a line like this ...
>
> //rsync -avz -e "ssh -i /home/backup/.ssh/id_dsa" --rsync-path='sudo rsync'
> backup at server <http://lists.samba.org/mailman/listinfo/rsync>:/
> /backup/server///
>
> But with rsnapshots how can I do that ?

You probably don't need the "-i /home/backup/.ssh/id_dsa" if you are
running rsnapshot as user backup. But in ay case if you want it,
just put this in your rsnapshot.conf:
ssh_args -i /home/backup/.ssh/id_dsa

The rsync path is a little tricky because it has a space in it.
This was discussed in rsnapshot-discuss on July 12 :-
http://sourceforge.net/mailarchive/forum.php?thread_id=22990829&forum_id=41320

I would suggest the easiest thing is for you to create a shell script that
just consists of
sudo /usr/bin/rsync "$@"
and use that shell script as your --rsync-path.

So you could add something like
+rsync_long_args=--rsync-path=/usr/local/bin/sudo_rsync
to each backup line (as long as you have a script /usr/local/bin/sudo_rsync
on the machine to be backed up).

___________________________________________________________________________
David Keegel <djk@xxxxxxxxxxxxxxxxxx> http://www.cyber.com.au/users/djk/
Cybersource P/L: Linux/Unix Systems Administration Consulting/Contracting

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV


Thread at a glance:

Previous Message by Date:

优惠代开发票!

您好! 本公司为税务机关代开发票授权公司,本公司可优惠对外开具。普通发票收取税率为0.8-2%, 详细税率可根据票额大小商谈! 普通国税发票为商品销售(包含所有行业的商品)。普通地税发票为建筑、安装、广告、设计、 运输、信息、咨询、培训、会务、住宿等其它服务行业 。   公司本着顾客至上的宗旨,可先开具发票给贵公司,待验证无问题后再付款! 本公司确保所开具之发票为税务机关领取的正规真票,对于双方的合作关系绝对保密。若贵公司 有需要,请来电联系! 代理人:张 先 生 手 机: 13927434328 邮 箱: ytmfvfhpn@xxxxxxx ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV_______________________________________________ rsnapshot-discuss mailing list rsnapshot-discuss@xxxxxxxxxxxxxxxxxxxxx https://lists.sourceforge.net/lists/listinfo/rsnapshot-discuss

Next Message by Date:

Re: Sudo + ssh and rsnapshot

On Sun, Aug 06, 2006 at 07:56:50PM +0200, S?bastien CRAMATTE wrote: > I think that I should do : > - do ssh public keys exchange between servers That's the best solution in my opinion - there's a good write-up here http://troy.jdmz.net/rsnapshot/ on configuring ssh to work securely with rsnapshot and the root user. My apologies to you all for not working this into the online docs yet - I've been struggling with DocBook. Unfortunately the online DocBook converter that Nathan originally used has gone away, and I can't persuade DocBook to work on my machines. If anyone can point me at a step-by-step HOWTO to get it installed on Debian, and how to do the neccesary XML -> HTML and XML -> PDF conversions, I'd be most grateful. -- David Cantrell | Official London Perl Mongers Bad Influence There's a hole in the world like a great black pit And the vermin of the world inhabit it And its morals aren't worth what a pig could spit And it goes by the name of London. ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

Previous Message by Thread:

Sudo + ssh and rsnapshot

Hello list, I'm a newbie in rsnapshot but seems to be amazing :) I've got various linux server configured to use sudo the root access is disabled (like in Ubuntu) How can I setup rsnapshots to get data from these servers I think that I should do : - do ssh public keys exchange between servers - configure sudo to allow rsync call without password LAN = NOPASSWD: /usr/bin/rsync ... I believe that I need to call a line like this ... //rsync -avz -e "ssh -i /home/backup/.ssh/id_dsa" --rsync-path='sudo rsync' backup at server <http://lists.samba.org/mailman/listinfo/rsync>:/ /backup/server/// But with rsnapshots how can I do that ? Thanks for your help Regards Sebastien ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

Next Message by Thread:

Re: Sudo + ssh and rsnapshot

On Sun, Aug 06, 2006 at 07:56:50PM +0200, S?bastien CRAMATTE wrote: > I think that I should do : > - do ssh public keys exchange between servers That's the best solution in my opinion - there's a good write-up here http://troy.jdmz.net/rsnapshot/ on configuring ssh to work securely with rsnapshot and the root user. My apologies to you all for not working this into the online docs yet - I've been struggling with DocBook. Unfortunately the online DocBook converter that Nathan originally used has gone away, and I can't persuade DocBook to work on my machines. If anyone can point me at a step-by-step HOWTO to get it installed on Debian, and how to do the neccesary XML -> HTML and XML -> PDF conversions, I'd be most grateful. -- David Cantrell | Official London Perl Mongers Bad Influence There's a hole in the world like a great black pit And the vermin of the world inhabit it And its morals aren't worth what a pig could spit And it goes by the name of London. ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
blog comments powered by Disqus

Home | News | Sitemap | FAQ | advertise | OSDir is an Inevitable website. GBiz is too!