linux profile
来源:互联网 发布:如何学电脑编程 编辑:程序博客网 时间:2024/04/30 11:53
(1)/etc/profile: 此文件为系统的每个用户设置环境信息,当用户第一次登录时,该文件被执
行. 并从/etc/profile.d目录的配置文件中搜集shell的设置。
(2)/etc/bashrc: 为每一个运行bash shell的用户执行此文件.当bash shell被打开时,该文件
被读取。
(3)~/.bash_profile: 每个用户都可使用该文件输入专用于自己使用的shell信息,当用户登录
时,该文件仅仅执行一次!默认情况下,他设置一些环境变量,执行用户的.bashrc文件。
(4)~/.bashrc: 该文件包含专用于你的bash shell的bash信息,当登录时以及每次打开新的
shell时,该该文件被读取。
(5)~/.bash_logout:当每次退出系统(退出bash shell)时,执行该文件. 另外,/etc/profile中
设定的变量(全局)的可以作用于任何用户,而~/.bashrc等中设定的变量(局部)只能继承
/etc/profile中的变量,他们是"父子"关系。
(6)~/.bash_profile 是交互式、login 方式进入 bash 运行的~/.bashrc 是交互式 non-
login 方式进入 bash 运行的通常二者设置大致相同,所以通常前者会调用后者。
/etc/profile文件
1 修改的内容是对所有用户起作用的
2 如何添加环境变量, 在profile文件的最后添加如下内容export NAME=liheng
3 在profile文件添加或修改的内容需要注销系统才能生效
4 使用env命令显示所有的环境变量 。在命令提示符下键入env就行了。
- linux profile
- Linux -- profile
- linux profile
- linux之profile
- linux profile of env
- Linux /etc/profile
- Linux刷新profile
- Linux中profile
- Linux jdk profile
- linux profile of env
- linux Profiling/profile
- Linux profile文件解析
- Linux 下 profile 技巧
- Linux环境变量profile bashrc
- linux /etc/profile相关
- 关于linux里的".profile"
- linux 公共配置文件 profile .zshrc
- LINUX一句话,使profile生效
- 简述Linux 文件系统的目录结构
- 10个你也许不知道的Ubuntu技巧
- 报表 之 饼状图 单组柱状图 多组柱状图 堆积柱状图 折线图
- DELPHI 图片任意角旋转。 我看着书上的C++代码改的,加了点自己的理解。huruihappy
- 写一个好的sql语句(转载)
- linux profile
- 从JAR文件中读取文件
- Linux的基本指令(一)
- 软件工程-三层架构
- 栈和托管堆/值类型和引用类型/强制类型转换/装箱和拆箱[C#]
- c#3.5的新特性
- Linux下无线网卡配置
- Berkeley DB 示例程序详解(2)
- 你必须知道的.NET之class和struct