更新2015Mar12-2238:未解决!我还在努力。
原始(非)答案:
由于startx
适用于root
且失败user
,因此是权限问题。
回答问题。“在我所有已安装的软件中,什么能root
执行而不能执行user
?”,我首先使用以下方法收集了数据:
#!/bin/bash
#
for pkg in $( dpkg -l | egrep '^ii' | awk '{print $2 }' ) ; do
echo "$(date '+%F %T') $pkg" >&2
dpkg -L "$pkg" | \
sed -e 's/^.*to: //' | \
while read phile ; do
sudo /usr/bin/stat \
--printf="=%a,%A %u:%g Chgd: %z = %Z %N\n" ":$clean" | \
tr -d '‘’'
done
done > plan.out
然后,通过egrep '^=...,[dr]..x.....-' plan.out | sort -n -k8 | uniq
查看(截断了空格,只有“最近的”更改):
=700,drwx------ 101:4 Chgd: 2015-01-30 19:11:24.363915087 -0500 = 1422663084 ‘/var/spool/rsyslog’
=700,drwx------ 0:0 Chgd: 2015-01-31 11:21:44.664379962 -0500 = 1422721304 ‘/var/lib/libvirt/sanlock’
=700,drwx------ 0:0 Chgd: 2015-02-22 12:25:22.314994852 -0500 = 1424625922 ‘/root’
=700,drwx------ 0:0 Chgd: 2015-02-23 11:40:00.909677880 -0500 = 1424709600 ‘/var/lib/polkit-1’
=700,drwx------ 0:0 Chgd: 2015-02-23 11:40:00.917677856 -0500 = 1424709600 ‘/etc/polkit-1/localauthority’
=700,drwx------ 154:161 Chgd: 2015-02-24 16:06:58.612884945 -0500 = 1424812018 ‘/var/run/gdm/greeter’
=750,drwxr-x--- 144:128 Chgd: 2015-02-24 16:07:01.015677190 -0500 = 1424812021 ‘/var/cache/libvirt/qemu’
=750,drwxr-x--- 154:161 Chgd: 2015-02-24 16:07:19.838216115 -0500 = 1424812039 ‘/var/lib/gdm’
=700,drwx------ 0:0 Chgd: 2015-02-24 16:07:38.480845470 -0500 = 1424812058 ‘/var/lib/sudo’
=750,drwxr-x--- 144:128 Chgd: 2015-02-24 16:07:45.033551778 -0500 = 1424812065 ‘/var/lib/libvirt/qemu’
=750,drwxr-x--- 134:4 Chgd: 2015-02-25 07:57:51.259376791 -0500 = 1424869071 ‘/var/log/glance’
=750,drwxr-x--- 33:4 Chgd: 2015-02-26 08:08:02.006782269 -0500 = 1424956082 ‘/var/log/nginx’
=750,drwxr-x--- 131:139 Chgd: 2015-03-02 08:32:46.122363558 -0500 = 1425303166 ‘/var/log/couchdb’
=750,drwxr-x--- 128:4 Chgd: 2015-03-02 08:33:02.030331682 -0500 = 1425303182 ‘/var/log/privoxy’
=750,drwxr-x--- 146:4 Chgd: 2015-03-02 08:33:03.322329094 -0500 = 1425303183 ‘/var/log/tomcat7’
=710,drwx--x--- 0:7 Chgd: 2015-03-04 07:53:31.955392233 -0500 = 1425473611 ‘/var/spool/cups’
似乎与登录和设置我的显示器最相关的条目是:
=700,drwx------ 154:161 Chgd: 2015-02-24 16:06:58.612884945 -0500 = 1424812018 ‘/var/run/gdm/greeter’
完成后,sudo chmod 755 /var/run/gdm /var/run/gdm/greeter
我解决了问题,现在可以正常登录了。
我将提交错误报告。
但是,尽管上述破解一次解决了该问题,但它再次发生。不解决!我将必须进行调查,/var/cache/apt/archives
以了解周围安装了什么2015-02-24
startx
用户身份使用,而/etc/X11/xinit/
目录中的所有文件都是root拥有的(是的,它们应该是root拥有的)。