centos shadowso shadowsock安卓最新版
centos6.5安装wps提示缺libc.so.6(GLIBC_2.15)(64bit),怎办
1.试图运行程序,提示"libc.so.6: version `GLIBC_2.14' not found",原因是系统的glibc版本太低,软件编译时使用了较高版本的glibc引起的:
[ghui@StuOS bin]$ pwd
/var/VMdisks/cross/mingw32/bin
[ghui@StuOS bin]$ ls
lrelease QtCore4.dll QtNetwork4.dll QtSql4.dll QtXml4.dll
moc QtDeclarative4.dll QtOpenGL4.dll QtSvg4.dll rcc
phonon4.dll QtGui4.dll QtScript4.dll QtTest4.dll uic
qmake QtMultimedia4.dll QtScriptTools4.dll QtWebKit4.dll
[ghui@StuOS bin]$./qmake
./qmake:/lib64/libc.so.6: version `GLIBC_2.14' not found(required by./qmake)
2.查看系统glibc支持的版本:
[ghui@StuOS bin]$ strings/lib64/libc.so.6|grep GLIBC_
GLIBC_2.2.5
GLIBC_2.2.6
GLIBC_2.3
GLIBC_2.3.2
GLIBC_2.3.3
GLIBC_2.3.4
GLIBC_2.4
GLIBC_2.5
GLIBC_2.6
GLIBC_2.7
GLIBC_2.8
GLIBC_2.9
GLIBC_2.10
GLIBC_2.11
GLIBC_2.12
GLIBC_PRIVATE
[ghui@StuOS bin]$ rpm-qa|grep glibc
glibc-static-2.12-1.80.el6_3.6.x86_64
glibc-headers-2.12-1.80.el6_3.6.x86_64
glibc-common-2.12-1.80.el6_3.6.x86_64
glibc-devel-2.12-1.80.el6_3.6.x86_64
glibc-static-2.12-1.80.el6_3.6.i686
glibc-devel-2.12-1.80.el6_3.6.i686
glibc-2.12-1.80.el6_3.6.i686
glibc-2.12-1.80.el6_3.6.x86_64
3.可以看到最高只支持2.12版本,所以考虑编译解决这个问题:
a.到下载最新版本,我这里下载了glibc-2.14.tar.xz这个版本,解压到任意目录准备编译
b.这里解压到/var/VMdisks/glibc-2.14/
[ghui@StuOS bin]$ cd/var/VMdisks/glibc-2.14/
[ghui@StuOS glibc-2.14]$ pwd
/var/VMdisks/glibc-2.14
[ghui@StuOS glibc-2.14]$ ls
abilist config.h.in intl README.libm
abi-tags config.log io resolv
aclocal.m4 config.make.in libc-abis resource
aout configure libidn rt
argp configure.in libio Rules
assert conform LICENSES scripts
autom4te.cache CONFORMANCE locale setjmp
bits COPYING localedata shadow
BUGS COPYING.LIB login shlib-versions
build cppflags-iterator.mk mach signal
CANCEL-FCT-WAIVE crypt Makeconfig socket
CANCEL-FILE-WAIVE csu Makefile soft-fp
catgets ctype Makefile.in stdio-common
ChangeLog debug Makerules stdlib
ChangeLog.1 dirent malloc streams
ChangeLog.10 dlfcn manual string
ChangeLog.11 elf math sunrpc
ChangeLog.12 extra-lib.mk misc sysdeps
ChangeLog.13 extra-modules.mk NAMESPACE sysvipc
ChangeLog.14 FAQ NEWS termios
ChangeLog.15 FAQ.in nis test-skeleton.c
ChangeLog.16 gmon NOTES time
ChangeLog.17 gnulib nptl timezone
ChangeLog.2 grp nptl_db tls.make.c
ChangeLog.3 gshadow nscd version.h
ChangeLog.4 hesiod nss Versions.def
ChangeLog.5 hurd o-iterator.mk wcsmbs
ChangeLog.6 iconv po wctype
ChangeLog.7 iconvdata posix WUR-REPORT
ChangeLog.8 include PROJECTS
ChangeLog.9 inet pwd
conf INSTALL README
c.在glibc源码目录建立构建目录,并cd进入构建目录
[ghui@StuOS glibc-2.14]$ mkdir build
[ghui@StuOS glibc-2.14]$ cd build
d.运行configure配置,make&& sudo make install
[ghui@StuOS build]$../configure--prefix=/opt/glibc-2.14
[ghui@StuOS build]$ make-j4
[ghui@StuOS build]$ sudo make install
[sudo] password for ghui:
4.临时修改环境变量
[ghui@StuOS bin]$ export LD_LIBRARY_PATH=/opt/glibc-2.14/lib:$LD_LIBRARY_PATH
[ghui@StuOS glibc-2.14]$ cd/var/VMdisks/cross/mingw32/bin/
[ghui@StuOS bin]$./qmake
Usage:./qmake [mode] [options] [files]
QMake has two modes, one mode for generating project files based on
some heuristics, and the other for generating makefiles. Normally you
shouldn't need to specify a mode, as makefile generation is the default
mode for qmake, but you may use this to test qmake on an existing project
...
Centos下限制SSH登录次数详解
应公司内部网站等级测评的需求,正逐渐加强系统安全防护。
设备默认 3次验证失败自动退出,并且结束会话;网络登录连接超时自动退出时间 5分钟;
第一种方法:已验证。
1.ssh超时时间设置
# cd/etc/profile.d/#创建两个空白文件autologout.csh、autologout.sh用来保存TMOUT配置
# touch autologout.csh
# touch autologout.sh
# vi autologout.sh#编辑autologout.sh
#auto out in 5 minutes
TMOUT=300#超时时间,单位为s
readonly TMOUT#设置TMOUT变量只读
export TMOUT#设置环境TMOUT
# vi autologout.csh#编辑autologout.csh
set-r autologout 2
# chmod+x autologout.*#可执行权限,其实单给u+x就行了。
断开Client,重新登录终端5分钟不使用ssh就会自动断开连接.
2.ssh认证次数限制:
/etc/ssh/sshd_config
MaxAuthTries=3这仅是超过3次验证错误断开连接。
第二种方法:(试验中还是有问题出现)
原理:通过系统的pam认证实现。
1.备份/etc/pam.d/system_auth文件,更改:
#%PAM-1.0
# This file is auto-generated.
# User changes will be destroyed the next time authconfig is run.
auth required pam_env.so
auth required pam_unix.so nullok try_first_pass将原来的sufficient改为required
#auth requisite pam_succeed_if.so uid>= 500 quiet注释掉此行
auth required pam_tally.so deny=3unlock_time=300增加一行,失败超过3次限制5分钟后登录
#auth required pam_deny.so注释掉此行
account required pam_unix.so
account sufficient pam_succeed_if.so uid<500 quiet
account required pam_permit.so
account required pam_tally2.so增加一行
password requisite pam_cracklib.so try_first_pass retry=3
password sufficient pam_unix.so md5 shadow nullok try_first_pass use_authtok
password required pam_deny.so
session optional pam_keyinit.so revoke
session required pam_limits.so
session [success=1default=ignore] pam_succeed_if.so service in crond quiet use_uid
session required pam_unix.so
2.建议sshtest帐户,进行密码错误登录验证。查看tail/var/log/secure|grep sshtest记录:
Feb 22 15:21:11 SN524 sshd[4900]: Failed password for sshtest from 192.168.40.130 port 53995 ssh2
Feb 22 15:21:17 SN524 sshd[4900]: pam_tally(sshd:auth): user sshtest(503) tally 7, deny 3
Feb 22 07:21:19 SN524 sshd[4903]: Disconnecting: Too many authentication failures for sshtest
Feb 22 15:21:19 SN524 sshd[4900]: Failed password for sshtest from 192.168.40.130 port 53995 ssh2
Feb 22 15:22:05 SN524 sshd[4906]: pam_unix(sshd:auth): authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=192.168.40.130 user=sshtest
帐户已被锁住,无法登录,等待5分钟后才能重新登录.
3.限制SSH过期时间:
/etc/ssh/sshd_config
ClientAliveInterval 60
ClientAliveCountMax 60
centos为什么passwd root 没有进入密码修改
CENTOS单用户下修改密码报passwd: Authentication Token Manipulation Error解决一台CentOS 5.3的WEB服务器之前都能通过ssh用key可以正常远程连接,突然有一天不能远程连了,具体现象是:a)通过SecureCRT用key连接的时候没有响应;b)直接密码连接报密码或用户名错误;c)通过其他有key的linux服务器连接的时候报Connection closed by 10.10.10.100;d)在本地的console登录的时候,输入用户名后直接报login incorrec。可以确定的是这之前就没有人更改过密码。具体解决过程如下:1.在本地用单用户模式进入系统,2.直接passwd,报passwd: Authentication Token Manipulation Error,搜了一下这个错误网上有多种解决方法,详见本文最后,可这些方法我都试了也没有起作用。3.#df-hl的时候,发现根文件系统满了,清出部分空间后,passwd更改密码仍然报上面那个错误;4.查看/var/log/secure日志是,发现了下面的错误:Nov 26 05:16:46 rcwweb2 sshd[1065]: PAM unable to dlopen(/lib/security/pam_unix.so)Nov 26 05:16:46 rcwweb2 sshd[1065]: PAM [error:/lib/security/pam_unix.so: invalid ELF header]Nov 26 05:16:46 rcwweb2 sshd[1065]: PAM adding faulty module:/lib/security/pam_unix.soNov 26 05:16:46 rcwweb2 sshd[1066]: fatal: Access denied for user root by PAM account configurationp5.从日志中看出是/lib/security/pam_unix.so文件出了问题,之前本机有一个pam_unix.so.bak文件,删除损坏文件,将备份恢复后,可以正常登录了。不知道是不是因为根盘满了造成此文件损坏导致的。这期间参考了网上的一些处理报passwd: Authentication Token Manipulation Error报错的方法,具体如下:1)可能是/etc/passwd和/etc/shadow文件不同步导致的,使用pwconv命令同步;2)/etc/passwd和/etc/shadow设置了安全设置,通过chattr-i/etc/passwd/etc/shadow解决;3)通过echo 123456 passwd--stdin root或echo root:lanmang chpasswd手动修改密码解决;4)关闭selinux解决;5)通过perl-e'print crypt(passw0rd,/$1/$YkRDae.B/$),/n'手动生成密码串,并手动拷贝到/etc/shadow文件中解决;