[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: preserving ssh keys



On Thu, 3 Apr 2003 Eric Doutreleau int-evry fr wrote:

>i m wondering if someone has already written a %pre kickstart script
>to backup ssh keys in order to put them back in place in the post
>kickstart script.

Didn't we have this thread three days ago?

https://listman.redhat.com/pipermail/kickstart-list/2003-March/007823.html
https://listman.redhat.com/pipermail/kickstart-list/2003-April/007842.html


No, perhaps we didn't. Try this:
(untested, might make your computer catch fire)

%pre
mkdir -p /mnt/ssh
# if you know where / is, use the next line:
#mount /dev/hda1 /mnt/ssh
# if not, use this:
#mount -L / /mnt/ssh
cp -a ssh_host_* /tmp
umount /mnt/ssh

and

%post --nochroot
mv -f /tmp/ssh_host_* /mnt/sysimage/etc/ssh


Cheers,
Phil





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]