Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 2nd October 2010, 15:50
edge edge is offline
Moderator
 
Join Date: Dec 2005
Location: The Netherlands
Posts: 2,044
Thanks: 269
Thanked 154 Times in 133 Posts
Default Debian Lenny: How password-less SSH root login?

I'm trying to setup a backup script that needs a password-less SSH root login to the server that needs to be backuped.

Both servers are running Debian Lenny.
The server than needs to be backuped does not allow a direct root login (to get root you need to login with a normal account and su / root password)

Is it possible to get a password-less SSH root login (with a key file?) even when root login is disabled, and if so, how can this be done?
__________________
Never execute code written on a Friday or a Monday.
Reply With Quote
Sponsored Links
  #2  
Old 3rd October 2010, 13:41
Hans Hans is offline
Moderator
 
Join Date: Dec 2005
Location: Montfoort, The Netherlands
Posts: 2,263
Thanks: 216
Thanked 649 Times in 295 Posts
Default

Hi Edge,

How that can be done is written here at step 3.

As root access is dangerous, please set bantime and maxretry to strict values within your fail2ban config file.
(jail.conf /local.conf)
__________________
Hans

MrHostman | Managed Hosting

Last edited by Hans; 3rd October 2010 at 13:44.
Reply With Quote
The Following User Says Thank You to Hans For This Useful Post:
edge (3rd October 2010)
  #3  
Old 3rd October 2010, 19:14
Franz Franz is offline
Senior Member
 
Join Date: Jul 2009
Location: Cakovec
Posts: 120
Thanks: 7
Thanked 24 Times in 18 Posts
Send a message via Skype™ to Franz
Default

Try this link
__________________
my PAGE
VoIP
my IT help blog
Reply With Quote
  #4  
Old 3rd October 2010, 22:50
edge edge is offline
Moderator
 
Join Date: Dec 2005
Location: The Netherlands
Posts: 2,044
Thanks: 269
Thanked 154 Times in 133 Posts
Default

Quote:
Originally Posted by Franz View Post
Thats what I tried, but like the other poster "cat /tmp/id_dsa.pub >> ~/.ssh/authorized_keys2" is giving me an error “bash: /.ssh/authorized_keys2: No such file or directory”.
__________________
Never execute code written on a Friday or a Monday.
Reply With Quote
  #5  
Old 3rd October 2010, 23:03
Franz Franz is offline
Senior Member
 
Join Date: Jul 2009
Location: Cakovec
Posts: 120
Thanks: 7
Thanked 24 Times in 18 Posts
Send a message via Skype™ to Franz
 
Default

check if .ssh directory exist

Code:
ls -la ~
if not
Code:
mkdir ~/.ssh 
chmod 700 ~/.ssh
cat /tmp/id_dsa.pub >> ~/.ssh/authorized_keys2
__________________
my PAGE
VoIP
my IT help blog
Reply With Quote
The Following User Says Thank You to Franz For This Useful Post:
edge (3rd October 2010)
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Update to php 5.2.6 problem with the aliases Stown Installation/Configuration 9 18th September 2009 12:44
messed up apache2-php5 installation klonos HOWTO-Related Questions 2 25th January 2009 00:12
Missing Email dayjahone General 7 30th June 2008 16:29
clamassassin - centos 4.3 wcsmith Installation/Configuration 41 20th November 2007 00:30
Apache2 Freezes celtic Server Operation 31 28th May 2007 18:18


All times are GMT +2. The time now is 02:03.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.