LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
楼主: barbie2pig

为什么在slackware9.0下窗口很容易crash

[复制链接]
 楼主| 发表于 2004-2-29 23:35:06 | 显示全部楼层
最初由 hgty123456789 发表
开了20多个窗口都有没有问题!!


你用的是slackware9.0吗?机器的配置是什么样的?我的机器配置是PIII700, 128M内存。
试一下在一个terminal编译一个比教大的project,比如mplayer或xine之类,同时用mozilla或firefox上网。一般这种情况下我的浏览器很快就crash了。如果编译的的东西更大,比如qt,桌面上的图标和任务条都有可能消失,这是kde出现crash的表现。
我很希望找到原因。因为以前安装得的slackware的版本和redhat的版本都没有这个问题。
发表于 2004-2-29 23:42:52 | 显示全部楼层
试试升级内核
发表于 2004-3-1 14:33:40 | 显示全部楼层
check memory usage (top or free), if you are about using up the memory, the kernel OOM killer may be the reason to kill some processes to save memory
 楼主| 发表于 2004-3-1 20:26:34 | 显示全部楼层
最初由 terminator 发表
check memory usage (top or free), if you are about using up the memory, the kernel OOM killer may be the reason to kill some processes to save memory


感觉很有道理,其实我也觉得是内存申请不到之类的错误,可是如何解决这个问题呢?我记得win2000会把内存中的东西暂时缓存到硬盘上。而且好的操作系统应该可以处理这种情况而不杀掉进程。

希望大侠再伸援手
 楼主| 发表于 2004-3-1 20:37:16 | 显示全部楼层
最初由 barbie2pig 发表
感觉很有道理,其实我也觉得是内存申请不到之类的错误,可是如何解决这个问题呢?我记得win2000会把内存中的东西暂时缓存到硬盘上。而且好的操作系统应该可以处理这种情况而不杀掉进程。

希望大侠再伸援手


Terminator大侠,现在觉得可能是我的swap分区开的太小,只开了128M,可是最近又不想重新分区,真是苦恼啊
发表于 2004-3-2 09:44:53 | 显示全部楼层
建一个swap file.

root@cactux:/home/frenzy# dd if=/dev/zero of=/tmp/swapfile bs=1024 count
=65536
65536+0 records in
65536+0 records out
root@cactux:/home/frenzy# ls -l /tmp/swapfile
-rw-r--r--  1 root root 67108864 Mar  2 09:43 /tmp/swapfile
root@cactux:/home/frenzy# mkswap /tmp/swapfile
Setting up swapspace version 1, size = 67104 kB
root@cactux:/home/frenzy# swapon /tmp/swapfile
root@cactux:/home/frenzy#
发表于 2004-3-2 10:09:55 | 显示全部楼层
yes, swapfile is a good solution - actually I always use it. btw, I created my swap file in /boot instead of /tmp since files in /tmp may be deleted by cron jobs.

to enable swapfile during boot, you can simply change /etc/fstab and add the swap file entry into it.

if you are using kernel 2.6, you will need to change /etc/rc.d/rc.S, and move the line 'swapon -a' after line '/sbin/mount -w -o remount /'. This is because at the position of the original 'swapon -a', / file system is still read-only, but you need read-write for swap file. so kernel 2.6 will refuse to turn on swap. I've reported it to Patrick, but he is reluctant to make the change. :-)
发表于 2004-3-2 10:46:50 | 显示全部楼层

回复: 真是受不了了!!!!!!!!

最初由 barbie2pig 发表
最近想了很多办法还是无法解决这个窗口crash的问题。还试了最简单的fvwm,仍然是会在load比较重的时候崩溃,真是受不了了。
尤其是喜欢一边用xine看网上直播,一边用firefox的时候,总是会莫名其妙的有窗口crash,只好在看视频的时候少开几个窗口了。
每次crash的时候总是显示出一个killed就完了,真是受不了了!:mad:


crash能不能清楚一点?是关闭还是停止响应
 楼主| 发表于 2004-3-3 15:26:27 | 显示全部楼层
最初由 terminator 发表
yes, swapfile is a good solution - actually I always use it. btw, I created my swap file in /boot instead of /tmp since files in /tmp may be deleted by cron jobs.

to enable swapfile during boot, you can simply change /etc/fstab and add the swap file entry into it.

if you are using kernel 2.6, you will need to change /etc/rc.d/rc.S, and move the line 'swapon -a' after line '/sbin/mount -w -o remount /'. This is because at the position of the original 'swapon -a', / file system is still read-only, but you need read-write for swap file. so kernel 2.6 will refuse to turn on swap. I've reported it to Patrick, but he is reluctant to make the change. :-)


真的很感谢你, 昨天晚上最后发现原因是在fstab里没有swap的内容, 所以根本没有办法交换内存. 这么快就把问题定位, 大牛!!!!:2cool
 楼主| 发表于 2004-3-3 15:28:56 | 显示全部楼层
最初由 frenzy 发表
建一个swap file.

root@cactux:/home/frenzy# dd if=/dev/zero of=/tmp/swapfile bs=1024 count
=65536
65536+0 records in
65536+0 records out
root@cactux:/home/frenzy# ls -l /tmp/swapfile
-rw-r--r--  1 root root 67108864 Mar  2 09:43 /tmp/swapfile
root@cactux:/home/frenzy# mkswap /tmp/swapfile
Setting up swapspace version 1, size = 67104 kB
root@cactux:/home/frenzy# swapon /tmp/swapfile
root@cactux:/home/frenzy#


感谢贴出这么详细的步骤, 让我又学到不少 :thank
您需要登录后才可以回帖 登录 | 注册

本版积分规则

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