专注收集记录技术开发学习笔记、技术难点、解决方案
网站信息搜索 >> 请输入关键词:
您当前的位置: 首页 > Solaris

solaris下增加swap空间失败: is not valid for swapping,该怎么处理

发布时间:2011-06-27 19:16:52 文章来源:www.iduyao.cn 采编人员:星星草
solaris下增加swap空间失败: is not valid for swapping
# ls
bin home net proc u01
dev kernel opt sbin u02
etc lib oradiag_root system usr
export mnt platform tmp var
# mkfile 10m /swapfile
# ls -al swapfile
-rw------- 1 root root 10485760 Oct 14 11:33 swapfile
# swap -a /swapfile
"/swapfile" is not valid for swapping.
It must be a block device or a regular file with the
"save user text on execution" bit set.

哪位高手指点一下!

------解决方案--------------------
它说你那个块设备或者文件必须要设置sticky bit才能作为swap文件系统。


For regular files on some older systems, the
bit saves the program’s text image on the swap device so it will load more quickly
when run; this is called the sticky bit.

所以你可以这么做。
# chmod 1777 /swapfile
友情提示:
信息收集于互联网,如果您发现错误或造成侵权,请及时通知本站更正或删除,具体联系方式见页面底部联系我们,谢谢。

其他相似内容:

热门推荐: