• linux as4u2 下安装openssh


    2006年11月24日(星期五) 10点43分 作者: 天天小白 天气: 心情: 一般

    一、准备工作

    1、安装包(最好都有)
    glibc-kernheaders-2.4-9.1.87.i386.rpm
    glibc-headers-2.3.4-2.i386.rpm
    glibc-devel-2.3.4-2.i386.rpm
    gcc-3.4.3-9.EL4
    gd-2.0.28-4.i386.rpm
    gd-devel-2.0.28-4.i386.rpm
    pam-devel-0.77-65.1
    pam-0.77-65.1
    e2fsprogs-devel-1.35-11.6.EL4.i386.rpm
    krbafs-devel-1.2.2-6.i386.rpm
    openssl-devel-0.9.7a-43.1.i386.rpm
    zlib-1.2.1.2-1
    zlib-devel-1.2.1.2-1
    openssl-0.9.8d.tar.gz
    openssh-4.5p1.tar.gz

    2、查看openssh版本
    因为as4u2默认安装了openssl、openssh

    检查openssl版本
    #openssl version
    OpenSSL 0.9.7a Feb 19 2003

    检查ssh版本
    #ssh -V
    OpenSSH_3.9p1, OpenSSL 0.9.7a Feb 19 2003

    二、安装openssl

    卸载掉老的opensll库
    #rpm -e --nodeps openssl

    解包
    #tar xzvf openssl-0.9.8d.tar.gz

    进入openssl目录安装openssl,用--prefix指定openssl安装目录
    #cd openssl-0.9.8d
    #./config --prefix=/usr/local/openssl-0.9.8

    修改mandir的内容
    #vi Makefile
    Makefile=/usr/share/man

    编译
    #make
    #make test
    #make install

    测试
    #/usr/local/openssl-0.9.8/bin/openssl version
    OpenSSL 0.9.8d 28 Sep 2006

    三、安装OpenSSH

    #tar xzvf openssh-4.5p1.tar.gz

    #cd openssh-4.5p1

    #./configure --prefix=/usr --sysconfdir=/etc/ssh --with-pam --with-zlib --with-ssl-dir=/usr/local/openssl-0.9.8 --with-md5-passwords --mandir=/usr/share/man --without-zlib-version-check

    --prefix=/usr                               //指定安装目录
    --sysconfdir=/etc/ssh                       //系统配置目录
    --with-pam
    --with-zlib                                 //如果自己编译安装了zlib,就加--with-zlib=DIR这个参数,如果默认安装,就换成--with-zlib,其他参数同理
    --without-zlib-version-check                //使用低版本的zlib,不检查zlib版本(推荐使用zlib 1.2.3)
    --with-ssl-dir=/usr/include/openssl         //ssl目录
    --with-md5-passwords
    --mandir=/usr/share/man

    编译
    #make
    #make install

    测试
    #su -
    #ssh -V
    OpenSSH_4.5p1, OpenSSL 0.9.8d 28 Sep 2006

    已经更新成功,重起一下服务
    #service sshd restart

    现在在用SSH客户端连接一下主机,就应该可以登录了。

    注意:sftp-server默认是在 /usr/libexec/openssh/sftp-server,在更新后需要在/etc/ssh/sshd_config里面修改
    #Subsystem       sftp    /usr/libexec/sftp-server
    否则无法启动sftp

  • 相关阅读:
    charindex代替like并非"更快更全面"
    SQLServer2005中的几个统计技巧
    SQLServer获取Excel中所有Sheet
    SQLServer2005的查询独占模拟
    SSAS事实表和维度表数据类型必须一致
    monodevelop 出现has line endings which differ from the policy settings.的解决方法
    mono for android Main.axml
    vs2010 错误提示框:文件加载 使用 简体中文(GB2312
    在Virtual Machine上运行Hello China的方法和工具
    embed基本语法
  • 原文地址:https://www.cnblogs.com/huqingyu/p/1424885.html
Copyright © 2020-2023  润新知