In linux platform, sometimes you have to modify the .bash_profile under the root of login user to make changes on the environment variables. After it is changed, there are two common ways to make it affected: 1. relogin; 2. restart the system. Both of these two methods are not good.
Here a new command you can execute after changing it: source .bash_profile
After executing it, the modification of environment varaibles become effective immediately.
Such as after installing Oracle Database on Linux, you have to add the Oracle environment variables: ORACLE_HOME, ORACLE_SID to make it effective in Linux immediately.