debian

Keeping server time correct on Debian

I got confused trying to get the clock on one of my Debian servers to keep time. It's actually quite easy, though, using the ntpdate package.

After installing ntpdate, set a crontab entry to run ntpdate-debian. Running ntpdate itself results in errors, but ntpdate-debian correctly checks central timeservers and updates the clock.

freetags:

Git fails to use ssh key file

Had a little trouble figuring out a problem with adding git users this morning.  I have previously set up an account successfully from my Windows desktop.

First, I followed all of instructions for creating a new ssh key on the new client (a Debian Lenny server, in this case).  I renamed the key file to be identifiable as the key used for connecting to gitosis on another Debian box.  Copied to the other client, which is managing the admin repo, added to the index, modified the conf, and pushed.  Connect attempt?  Failed.  Well, technically, it asked for a password.  As bad as a fail.

I tried a few more renames thinking that I had the wrong name in the gitosis authorized_keys file.  Still no luck - the server wanted a password no matter what I tried.

Just for fun, I tried renaming the key file back on the Debian client to the default id_rsa(.pub).  Success!  Apparently, git defaults to the key named id_rsa in the ~/.ssh/ directory.  I suspect there's a config option to change this, but I haven't taken the time to look for it yet.

EDIT:

Git lays the blame on SSH, so there is no config option.  I wonder whether there's an option to specify the ssh command so that the -i option (selecting the identity to use for the conenction) could be passed.  No matter.  The current "fix" works for me, so I'll go ahead with it for now.  At some point, I may need to clean up my keys, though.

How to enable or disable startup "services" on Debian

I'm disabling an FTP server (pureftp) and need a way to just keep it from starting up rather than completely purging it - never know when I might want to make temporary use of it. The All About Linux blog over at Blogspot had a good set of instructions:

To disable
update-rc.d -f pure-ftpd-mysql remove
To re-enable:
update-rc.d pure-ftpd-mysql defaults

freetags:

Subscribe to RSS - debian