Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I Recently installed gitweb onto our gitosis source code repo server..

(Ubuntu 10.04 LTS Server)

Somewhere along the line i changed something i shouldn't have and whenever attempting to clone from or do anything with gitosis.. i get the following message:

Permission denied (publickey)

Which i believe to be an issue with ssh and my rsa keys..

on further inspection of the /var/log/auth.log file i discovered a lot of mention of an issue with the permissions on the /user/.ssh/ directory (it was too open):

Authentication refused: bad ownership or modes for directory /user/.ssh/

so after googling it i ran the following commands to remedy..

chmod 755 userfolder chmod go-w userfolder

chmod 700 .ssh

chmod 600 authorized_keys

Now their are no more mentions of this in the auth.log however it is still denying my public key... how can i fix this??

Thanks

Daniel

share|improve this question
1  
Run the ssh client with -vvv and the ssh server with -ddd, and look through all the debugging output for relevant messages. If you can't find the problem, post the logs here (edited for privacy if necessary). –  Gilles Aug 19 '10 at 14:47
    
Thanks giles.. in the end it was eating a massive chunk out of my coding day and a project was due very soon, so i did an scp backup to my local machine, made a new user, reinstalled gitosis and manually uploaded all of the repos again.. thanks for your help =P –  Daniel Upton Aug 22 '10 at 17:49

Your Answer

 
discard

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

Browse other questions tagged or ask your own question.