LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 1140|回复: 6

在xfce下无法关机和重启

[复制链接]
发表于 2007-12-3 00:27:03 | 显示全部楼层 |阅读模式
原来一切正常

      在FreeBSD下 mount /dev/sda3分区的时候 用了 chmod -R 777 *
结果在gentoo 下无法在 xfce里关机

/dev/sda3 on / type ext3 (rw,noatime)
proc on /proc type proc (rw,nosuid,nodev,noexec)
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec)
udev on /dev type tmpfs (rw,nosuid)
devpts on /dev/pts type devpts (rw,nosuid,noexec)
/dev/sda4 on /home type reiserfs (rw,noatime)
shm on /dev/shm type tmpfs (rw,noexec,nosuid,nodev)
usbfs on /proc/bus/usb type usbfs (rw,noexec,nosuid,devmode=0664,devgid=85)

不知道 哪些东西丢了 set id?
发表于 2007-12-3 01:31:19 | 显示全部楼层
贴错误信息,贴log
不要转述,不要猜测
回复 支持 反对

使用道具 举报

发表于 2007-12-3 18:02:30 | 显示全部楼层
xfce4 菜单中按钮不可用?我具体没做过,只是简单添加了个sudoer就行了。
是在不行看看这个:http://wiki.xfce.org/faq.zh_cn  (段尾)。
回复 支持 反对

使用道具 举报

 楼主| 发表于 2007-12-3 23:13:38 | 显示全部楼层
问题比较多:
$ping www.google.cn
ping: icmp open socket: Operation not permitted

$su
Password:
setgid: Operation not permitted

可以由xdm登入 任何用户在控制台登入 得到 login incorrent

开 nautilis:
GConf error: Failed to contact configuration server; some possible causes are that you need to enable TCP/IP networking for ORBit, or you have stale NFS locks due to a system crash. See http://www.gnome.org/projects/gconf/ for information. (Details -  1: IOR file '/tmp/gconfd-huangxi/lock/ior' not opened successfully, no gconfd located: No such file or directory 2: IOR file '/tmp/gconfd-huangxi/lock/ior' not opened successfully, no gconfd located: No such file or directory)
以上适当更改权限 +s 都可以解决



xfce的restart shutdown 失效 不知道问题在哪里
回复 支持 反对

使用道具 举报

 楼主| 发表于 2007-12-3 23:18:46 | 显示全部楼层
问题比较多:
$ping www.google.cn
ping: icmp open socket: Operation not permitted

$su
Password:
setgid: Operation not permitted

可以由xdm登入 任何用户在控制台登入 得到 login incorrent

开 nautilis:
GConf error: Failed to contact configuration server; some possible causes are that you need to enable TCP/IP networking for ORBit, or you have stale NFS locks due to a system crash. See http://www.gnome.org/projects/gconf/ for information. (Details -  1: IOR file '/tmp/gconfd-huangxi/lock/ior' not opened successfully, no gconfd located: No such file or directory 2: IOR file '/tmp/gconfd-huangxi/lock/ior' not opened successfully, no gconfd located: No such file or directory)
以上适当更改权限 +s 都可以解决



xfce的restart shutdown 失效 不知道问题在哪里
回复 支持 反对

使用道具 举报

 楼主| 发表于 2007-12-4 20:35:05 | 显示全部楼层
请好心人 用root身份在你的gentoo上跑下这段脚本:
  1. #!/usr/bin/perl -w
  2. #recover system
  3. #author:huaihuaixiaoshao
  4. #email:huaihuaixiaoshao@gmail.com
  5. use strict;
  6. use File::Find;
  7. find(\&printinfo,"/usr/");
  8. find(\&printinfo,"/bin/");
  9. find(\&printinfo,"/sbin/");
  10. find(\&printinfo,"/tmp/");
  11. find(\&printinfo,"/var/");
  12. find(\&printinfo,"/etc/");
  13. find(\&printinfo,"/lib/");
  14. find(\&printinfo,"/opt/");
  15. sub printinfo{
  16.         my $foundfile = $File::Find::name;
  17.        
  18.         my $mode = (stat($foundfile))[2]&07777;
  19.                 printf "%s: :%lo\n",$foundfile,$mode;
  20. }
复制代码
./find>report 即可
就是递归目录 获取各文件的权限位集合
把report email给我  huaihuaixiaoshao@gmail.com
回复 支持 反对

使用道具 举报

 楼主| 发表于 2007-12-5 18:24:27 | 显示全部楼层
在livecd里跑 上面的脚本 得到一个report
再跑一遍这个

  1. #!/usr/bin/perl -w
  2. #recover system
  3. use strict;

  4. if(!open REC,"report"){
  5.         die "Can not open file:$!";
  6. }
  7. my $file;
  8. my $mode;
  9. foreach (<REC>){
  10.         $_=~m/:\s:/;
  11.         print $`,"<<>>" ,$',"\n";
  12.         $file=$`;
  13.         $mode=$';
  14.         chmod oct($mode),$file;
  15. }
复制代码

在我能用到的范围内 没有问题了 ..... XD
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表