I am reading about basic shell scripting from Linux Command Line and Shell Scripting Bible.

It says that the /etc/profile file sets the environment variables at startup of the Bash shell. The /etc/profile.d directory contains other scripts that contain application-specific startup files, which are also executed at startup time by the shell.

bash窗口里看JAVA_HOME设置好了,但是./xxx总说没设置,原来是这个原因,运维tmd设置了java_home但是只导出了path,一直以为bash窗口里echo能看到就是没问题,最后发现是这么回事儿。

profile和bash的更多相关文章

  1. Bash: about .bashrc, .bash_profile, .profile, /etc/profile, etc/bash.bashrc and others

    Some interesting excerpts from the bash manpage:When bash is invoked as an interactive login shell, ...

  2. 修改profile导致bash不能用的补救方法

    输入这条命令:export PATH=/usr/bin:/usr/sbin:/bin:/sbin:/usr/X11R6/bin 由于shell命令基本都在/usr/bin,/usr/sbin,/bin ...

  3. [No0000177]详解/etc/profile、/etc/bash.bahsrc、~/.profile、~/.bashrc的用途

    之前安装Linux的一些软件时,总要修改Linux的配置文件.当时也是一知半解.而且,网上有些安装教程,会说,修改配置文件后要重启Linux.但事实上是不需要重启的. Linux安装时可能要修改的配置 ...

  4. 【总结】/etc/rc.d/rc.local 与 /etc/profile .bash_profile .bashrc 文件执行顺序

    登陆shell与交互式非登陆shell的区别 登录shell 所谓登录shell,指的是当用户登录系统时所取的那个 shell.登录shell属于交互式shell. 登录shell将查找4个不同的启动 ...

  5. /etc/profile、/etc/bashrc、~/.bash_profile、~/.bashrc 的区别(转)

    /etc/profile:此文件为系统的每个用户设置环境信息,当用户第一次登录时,该文件被执行并从/etc/profile.d目录的配置文件中搜集shell的设置. /etc/bashrc:为每一个运 ...

  6. /etc/bashrc和/etc/profile傻傻分不清楚?

    导读 在一般的 linux 或者 unix 系统中, 都可以通过编辑 bashrc 和 profile来设置用户的工作环境, 很多文章对于 profile 和 bashrc 也都有使用, 但究竟每个文 ...

  7. linux /etc/profile和/etc/bashrc

    /etc/profile:此文件为系统的每个用户设置环境信息,当用户第一次登录时,该文件被执行,并从/etc/profile.d目录的配置文件中搜集shell的设置,/etc/bashrc:为每一个运 ...

  8. bash的操作环境[转]

          Bash Shell 的操作环境: 是否记得我们登陆主机的时候,屏幕上头会有一些说明文字,告知我们的 Linux 版本啊什么的, 还有,登陆的时候我们还可以给予用户一些信息或者欢迎文字呢. ...

  9. 浅析Linux下的/etc/profile、/etc/bashrc、~/.bash_profile、~/.bashrc文件

    转自:http://www.ahlinux.com/shell/20239.html 0x01 /etc/profile:此文件为系统的每个用户设置环境信息,当用户第一次登录时,该文件被执行,并从/e ...

随机推荐

  1. L3-004. 肿瘤诊断

    L3-004. 肿瘤诊断 题目链接:https://www.patest.cn/contests/gplt/L3-004 BFS 之前尝试使用递归dfs,提交后发现有两个段错误,发现递归层数太多,然后 ...

  2. EasyuiAPI:菜单

    一.LinkButton(按钮) 1.通过标签创建: <a id="btn" href="#" class="easyui-linkbutton ...

  3. wamp,phpserver,xampp环境冲突

    这几天在使用laravel5.2时 执行:php artisan migrate [PDOException] could not find driver 分析可能是以下情况造成 1 php.ini配 ...

  4. dplyr 数据操作 数据排序 (arrange)

    在R中,我们在整理数据时,经常需要对数据排序,以便数据增强数据的可读性. 下面我们来看下dplyr中的,arrange函数 arrange(.data, ...) 跟filter()类似,arrang ...

  5. [ An Ac a Day ^_^ ] [kuangbin带你飞]专题四 最短路练习 POJ 2387 Til the Cows Come Home

    求1到N的最短路 注意有重边 跑一遍dijkstra就行 /* *********************************************** Author :Sun Yuefeng ...

  6. NOIP2012-普及组复赛-第一题-质因数分解

    题目描述 Description 已知正整数n是两个不同的质数的乘积,试求出两者中较大的那个质数.  输入输出格式 Input/output 输入格式:输入只有一行,包含一个正整数n.输出格式:输出只 ...

  7. css遗漏

    对于float浮动 子级元素浮动之后,因为元素脱离了文档流所以父级元素的高度不会auto而是变成0的解决方案 父级元素增加伪类 父级:after{ content:""; disp ...

  8. 使用block函数的基本形式

    以前从未接触过block函数. 如果在.h头文件中定义的形式如下的话: @property (nonatomic, copy) void(^fontValueChangedBlock)(void); ...

  9. 正则匹配 sql语句参数

    List<string> listcommand = new List<string>(); string sql = "update BMDMB set bmdmb ...

  10. toggle的使用心得

    点击同一个标签可以实现不同效果 或者几个效果 以前一般都是if 判断的 逻辑还有判断比较繁琐 看啦手册后 发现这个功能可以不用判断的自动循环点击事件 比以前的简单好用 主要用法:$("td& ...