免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 3206 | 回复: 3
打印 上一主题 下一主题

总结及疑问:系统参数。 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2006-01-19 09:31 |只看该作者 |倒序浏览
前几天在论坛上泡着的时候,也发现有人问道了系统参数的问题,自己这里总结一下,同时把自己的疑问谈出来。\r\n首先在系统装好后/.profile这个文件并不存在,所以需要创建,那么问题就来了。\r\n#set\r\n当我们使用这个命令的时候,显示的内容来自于何处  /etc/.profile? 我没有看到这个文件(flatform86 sol10)。我还在/usr下看了也没有。于是我就通过如下步骤:\r\n#set > /.profilecc\r\n#vi /.profilecc\r\n#cp /.profilecc /.profile\r\n#reboot\r\n#set\r\n这时我看到显示的信息是我修改后的/.profile\r\n那么问题就来了,之前没有进行 \r\n#set > /.profilecc\r\n操作时显示的内容来自于何处?\r\n关于这个问题,希望能够探个究竟!

论坛徽章:
0
2 [报告]
发表于 2006-01-19 10:38 |只看该作者
Here i post the /etc/profile content:\r\n#ident        \"@(#)profile        1.19        01/03/13 SMI\"        /* SVr4.0 1.3        */\r\n\r\n# The profile that all logins get before using their own .profile.\r\n\r\ntrap \"\"  2 3\r\nexport LOGNAME PATH\r\n\r\nif [ \"$TERM\" = \"\" ]\r\nthen\r\n        if /bin/i386\r\n        then\r\n                TERM=sun-color\r\n        else\r\n                TERM=sun\r\n        fi\r\n        export TERM\r\nfi\r\n\r\n#        Login and -su shells get /etc/profile services.\r\n#        -rsh is given its environment in its .profile.\r\n\r\ncase \"$0\" in\r\n-sh | -ksh | -jsh | -bash)\r\n\r\n        if [ ! -f .hushlogin ]\r\n        then\r\n                /usr/sbin/quota\r\n                #        Allow the user to break the Message-Of-The-Day only.\r\n                trap \"trap \'\' 2\"  2\r\n                /bin/cat -s /etc/motd\r\n                trap \"\" 2\r\n\r\n                /bin/mail -E\r\n                case $? in\r\n                0) \r\n                        echo \"You have new mail.\"\r\n                          ;;\r\n                2) \r\n                        echo \"You have mail.\"\r\n                           ;;\r\n                esac\r\n        fi\r\nesac\r\n\r\numask 022\r\ntrap  2 3

论坛徽章:
0
3 [报告]
发表于 2006-01-19 13:21 |只看该作者
/etc下不是.profile是profile

论坛徽章:
0
4 [报告]
发表于 2006-01-19 14:25 |只看该作者
终于有人回帖了。\r\n\r\n赞一个!\r\n\r\n更正有效!
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP