转自 :http://blog.163.com/junwu_lb/blog/static/1916798920120103647199/

Authentication token manipulation error
发生该错误原因是:

1、分区没有空间导致。

2、/etc/passwd 和/etc/shadow不同步

但是这次上面两条却行不通,通过df查看根分区还有40%剩余。

1、尝试修改密码,出现错误

# passwd
Changing password for user root.
New UNIX password:
BAD PASSWORD: it is WAY too short
Retype new UNIX password:
passwd: Authentication token manipulation error

2、同步/etc/passwd 和/etc/shadow出错
#pwconv
pwconv: can't lock passwd file

3、看权限没有异常,也没有进程锁定该文件
# ll /etc/passwd
-rwxr--r--  1 root root 2752 Dec 31 17:29 /etc/passwd
# fuser -u /etc/passwd
# lsof |grep passwd

4、cp lock文件出错,提示空间不足

# cp /tmp/.pwd.lock /etc/
cp: cannot create regular file `/etc/.pwd.lock': No space left on device

5、上面的错误惊醒了我,查看确实是inode满了,删除无用的文件
#df -i
Filesystem            Inodes   IUsed   IFree IUse% Mounted on
/dev/sda5            2562240 2562240       0  100% /
/dev/sda1              50200      47   50153    1% /boot
/dev/sda2            51300000      12 51299988    1% /data/cache1
/dev/sdb1            51300000 7080311 44219689   14% /data/cache2
/dev/sdb2            9863168      11 9863157    1% /data/proclog
none                  215907       1  215906    1% /dev/shm
/dev/sda3            3842720  305795 3536925    8% /usr
/dev/sda7            3162112    7893 3154219    1% /var
6、再次修改密码仍然出错,于是尝试修改/etc/passwd也出现错误

# chmod 777 /etc/passwd
chmod: changing permissions of `/etc/passwd': Operation not permitted
7、执行chattr 
#chattr -i  /etc/passwd
# lsattr -v /etc/passwd
2095582053 ------------- /etc/passwd

# chattr -i  /etc/shadow

8、同步文件
pwconv

9、成功修改密码
passwd
Changing password for user root.
New UNIX password:
BAD PASSWORD: it is WAY too short
Retype new UNIX password:
passwd: all authentication tokens updated successfully.

pwconv

功能说明:开启用户的投影密码。
  语 法:pwconv
  补充说明:Linux系统里的用户和群组密码,分别存放在名称为passwd和group的文 件中,这两个文件位于/etc目录下。因系统运作所需,任何人都得以读取它们,造成安全上的破绽。投影密码将文件内的密码改存在/etc目录下的 shadow和gshadow文件内,只允许系统管理者读取,同时把原密码置换为"x"字符,有效的强化了系统的安全性。
  pwconv:开启用户的shadow口令.
一般来用pwconv来同步口令,下面来说一下,它的工作流程:
  pwconv依赖于passwd中的密码区'x'来同步/etc/passwd与/etc/shadow这两个文件;以/etc/passwd为主来控制/etc/shadow中的各项:
  A:若/etc/shadow不存在,则pwconv将用/etc/passwd来建立
  B:若/etc/shadow已存在,则:
  1.若条目在passwd中已存在,而不在shadow中,则在shadow中添加相关条目
  2.若条目在shadow中已存在,而不在passwd中,则从shadow中删除相关条目

linux修改密码出现Authentication token manipulation error的解决办法的更多相关文章

  1. 无法修改linux/ubuntu密码(Authentication token manipulation error )问题解决过程【转】

    转自:https://blog.csdn.net/caizi001/article/details/38659189 Vmware虚拟机里的ubunut系统长期不用,密码忘记了,无奈只能通过slax ...

  2. 解决"authentication token manipulation error"

      昨天安装是Ubuntu Server. 配置好了几个软件后就忘记继续了...今天打开,居然忘记了密码...真是的..  后来还是要改了. 不想重新弄什么的了..百度了下怎么改密码...然后就有一篇 ...

  3. vmware 解决 authentication token manipulation error

    vmvare虚拟机长时间未使用,导致再次登录的时候密码忘了,无法登录. 启动时长按shift,进入root(recovery)模式, (recovery mode),进入"Recovery ...

  4. authentication token manipulation error

    用户服务器中修改密码,输入passwd命令后,报错authentication token manipulation error   发生该错误原因是: 1.分区没有空间导致. 2./etc/pass ...

  5. Authentication token manipulation error报错解决办法

    Authentication token manipulation error报错解决办法 #参考http://blog.163.com/junwu_lb/blog/static/1916798920 ...

  6. linux中普通用户修改密码出现(passwd:Authentication token manipulation error)

    如果在linux中,不管是root用户还是普通用户登录后,修改自己的密码,出现---passwd:Authentication token manipulation error---错误的解决办法: ...

  7. 解决:阿里云服务器被植入挖矿程序后修改密码失败的问题(报错:passwd: Authentication token manipulation error)

    如下图,在修改密码的时候会报错 原因: 通常不能修改密码都是/etc/passwd文件或者/etc/shadow文件被锁住了 解决: 检查/etc/passwd文件和/etc/shadow文件是否被锁 ...

  8. Ubuntu忘记用户密码解决方法--Authentication token manipulation error

    1.重启系统,按住shift键进入grub菜单: 2.选择recovery mode恢复模式: 3.在recovery menu中选择root drop to root shell prompt: 4 ...

  9. Authentication token manipulation error for ubuntu ubuntu-16.04.1-desktop-amd64

    https://ubuntuforums.org/showthread.php?t=1772894 Hi, I faced the same problem when I tried to recov ...

随机推荐

  1. hdu1006 Tick and Tick (数学题 借鉴了大神的博客)

    先缩短一半的时间:早上的12个小时和下午的12小时对时钟是一样的,因为时钟12小时与0小时的三针位置相同.接着就是了解到每次所有的针从有重合到再次有重合至多有一段连续的段符合三针分离度大于n.所以只要 ...

  2. luogu 6月月赛 E 「数学」约数个数和

    题面在这里! 第一眼感觉炒鸡水啊...只要把N质因数分解一下,因为k次约数相当于求k+2元一次方程的非负整数解,所以答案就是和每个质因子指数有关的一些组合数乘起来. 但是要用pillard's rho ...

  3. BZOJ 3289 Mato的文件管理(莫队+树状数组)

    [题目链接] http://www.lydsy.com/JudgeOnline/problem.php?id=3289 [题目大意] 求静态区间逆序对. [题解] 我们对查询进行莫队操作,对于区间的删 ...

  4. [LOJ2541]猎人杀

    好题== 先转化一下,每个人被杀死后给他打标记,以后随机杀人时选到有标记的人就继续随机,这样并不会改变每个人被杀死的概率 直接算很难算,考虑容斥,我们枚举$S$表示在$1$死后才死的人至少在集合$S$ ...

  5. mybatis批量插入oracle时报错:unique constraint (table name) violated

    mybatis批量插入oracle时报错:unique constraint (table name) violated,是因为插入的集合中有两条相同唯一约束的数据.

  6. 20172333 2017-2018-2 《Java程序设计》第4周学习总结

    20172333 2017-2018-2 <Java程序设计>第4周学习总结 教材学习内容 1.类结构的定义与概念 2.利用实例数据建立对象状态的概念 3.描述可见性修饰符作用在方法和数据 ...

  7. Codeforces Round #114 (Div. 1) E. Wizards and Bets 高斯消元

    E. Wizards and Bets 题目连接: http://www.codeforces.com/contest/167/problem/E Description In some countr ...

  8. Navicat无法连接到MySQL

    今天新装的linux,装好以后想用Navicat连接一下数据库,发现连接不上 思路,捋一下 第一种:Access denied for user 'root'@'localhost' (using p ...

  9. Mysql - 登录错误

    来源: 问题的引出: 我 在CentOS上装完mysql后,用navicat链接的时候,抛出MySql - SQL Error (1130): Host IP is not allowed to co ...

  10. synchronized 线程同步-类级别锁定

    1.demo 说明:代码中通过 printNum 方法传入参数判断 a.b 分别对 num 这个参数的值进行了修改. package demo1; import sun.applet.Main; pu ...