还原权限默认为/ usr文件夹

我运行了一个愚蠢的命令: sudo chown -R ngoclb:ngoclb /usr 。 然后我无法使用sudo命令登录Ubuntu。 为了解决这个问题,我使用恢复模式chown /usr to root( sudo chown -R root:root /usr )并且可以登录到Ubuntu,但是现在,Ubuntu的GUI不像默认(它和Windows经典一样)对于某些组件:滚动条,菜单…),我无法访问系统设置/用户帐户。 我怎样才能解决这个问题 ?

/usr几乎所有内容都归root:root

我使用15.04运行find /usr -not -gid 0 -printf "%M\t%u\t%g\t%p\n" ,输出为

 -r-xr-sr-x root postdrop /usr/sbin/postqueue -rwsr-xr-- root dip /usr/sbin/pppd -r-xr-sr-x root postdrop /usr/sbin/postdrop drwxrwsr-t root lpadmin /usr/share/ppd/custom drwxrwsr-x root staff /usr/local/share/xml drwxrwsr-x root staff /usr/local/share/xml/declaration drwxrwsr-x root staff /usr/local/share/xml/entities drwxrwsr-x root staff /usr/local/share/xml/schema drwxrwsr-x root staff /usr/local/share/xml/misc drwxrwsr-x root staff /usr/local/share/emacs drwxrwsr-x root staff /usr/local/share/emacs/site-lisp drwxrwsr-x root staff /usr/local/share/sgml drwxrwsr-x root staff /usr/local/share/sgml/declaration drwxrwsr-x root staff /usr/local/share/sgml/entities drwxrwsr-x root staff /usr/local/share/sgml/dtd drwxrwsr-x root staff /usr/local/share/sgml/stylesheet drwxrwsr-x root staff /usr/local/share/sgml/misc drwxrwsr-x root staff /usr/local/share/ca-certificates drwxrwsr-x root staff /usr/local/share/fonts drwxrwsr-x root staff /usr/local/lib/python3.4 drwxrwsr-x root staff /usr/local/lib/python3.4/dist-packages drwxrwsr-x root staff /usr/local/lib/python2.7 drwxrwsr-x root staff /usr/local/lib/python2.7/dist-packages drwxrwsr-x root staff /usr/local/lib/python2.7/site-packages drwxr-xr-x root utempter /usr/lib/utempter -rwxr-sr-x root utmp /usr/lib/utempter/utempter -rwxr-sr-x root mail /usr/lib/evolution/camel-lock-helper-1.2 -rwsr-xr-- root messagebus /usr/lib/dbus-1.0/dbus-daemon-launch-helper -rwxr-sr-x root utmp /usr/lib/libvte-2.91-0/gnome-pty-helper -rwxr-sr-x root crontab /usr/bin/crontab -rwxr-sr-x root tty /usr/bin/wall -rwxr-sr-x root tty /usr/bin/bsd-write -rwxr-sr-x root shadow /usr/bin/chage -rwxr-sr-x root shadow /usr/bin/expiry -rwxr-sr-x root mail /usr/bin/mail-unlock -rwxr-sr-x root mlocate /usr/bin/mlocate -rwxr-sr-x root mail /usr/bin/dotlockfile -rwxr-sr-x root mail /usr/bin/mail-touchlock -rwxr-sr-x root mail /usr/bin/mail-lock -rwxr-sr-x root ssh /usr/bin/ssh-agent -rwsr-sr-x daemon daemon /usr/bin/at 

并且考虑到输出,我看不出你可能有什么错误来得到你所描述的。 可能是dbus的东西……

但是你可以手动chown上面的文件来尝试让你的ubuntu回来。

你可能没有相同的文件或者我可能会错过你的一些文件,所以即使你手动选择上面的文件,你也没有完全完成它。