support makeknownhosts on debian/ubuntu
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@15478 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
parent
2ce147d84b
commit
2de350cf80
@ -689,11 +689,12 @@ sub genSSHRootKeys
|
||||
if ( -e "/etc/debian_version" ){
|
||||
my $out = `/bin/cat $cfgfile | grep 'HashKnownHosts'`;
|
||||
if ( $out ){
|
||||
`/bin/sed -e 's/.*HashKnownHosts.*/HashKnownHosts no/' $cfgfile > tempcfg;mv -f tempcfg $cfgfile`
|
||||
`/bin/sed -e 's/.*HashKnownHosts.*/HashKnownHosts no/' $cfgfile > tempcfg;mv -f tempcfg $cfgfile`;
|
||||
}
|
||||
else{
|
||||
`/bin/echo HashKnownHosts no >> $cfgfile`;
|
||||
}
|
||||
`chmod 600 $cfgfile`;
|
||||
}
|
||||
}
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user