LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS
User Name
Password
CentOS This forum is for the discussion of CentOS Linux. Note: This forum does not have any official participation.

Notices


Reply
  Search this Thread
Old 05-17-2018, 03:45 PM   #1
robertkwild
Member
 
Registered: Feb 2015
Posts: 362

Rep: Reputation: Disabled
adding permanent enviroment variable for all users


hi all,

i want to add this enviroment variable to all users -

https://knowledge.autodesk.com/suppo...ux-server.html

so my question is how do i add it to all users not just for one users home directory as more than one person logs in using different logins/profiles

i have edited the file "/etc/profile" and added this line to the end but doesnt work

"export ADSKFLEX_LICENSE_FILE=@192.168.1.233"

what am i doing wrong, how do i also call it a filename as it says ie .flexlmrc

cheers,

rob
 
Old 05-17-2018, 04:04 PM   #2
MensaWater
LQ Guru
 
Registered: May 2005
Location: Atlanta Georgia USA
Distribution: Redhat (RHEL), CentOS, Fedora, CoreOS, Debian, FreeBSD, HP-UX, Solaris, SCO
Posts: 7,388
Blog Entries: 15

Rep: Reputation: 1406Reputation: 1406Reputation: 1406Reputation: 1406Reputation: 1406Reputation: 1406Reputation: 1406Reputation: 1406Reputation: 1406Reputation: 1406
The files sourced during login depend on the user's shell. For posix shell and korn shell /etc/profile was the global file. For bash look at /etc/bashrc. For csh look at /etc/login.

Note that many things can set environment variables. Any default sourced file might in turn source other files which in their turn might source files. Also the $HOME files are sourced by default AFTER the system profiles in /etc so any value set can be overridden. (And they can also source other things.)
 
Old 05-18-2018, 07:51 AM   #3
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 20,014

Rep: Reputation: 4756Reputation: 4756Reputation: 4756Reputation: 4756Reputation: 4756Reputation: 4756Reputation: 4756Reputation: 4756Reputation: 4756Reputation: 4756Reputation: 4756
Quote:
Originally Posted by robertkwild View Post
hi all,
i want to add this enviroment variable to all users -

https://knowledge.autodesk.com/suppo...ux-server.html

so my question is how do i add it to all users not just for one users home directory as more than one person logs in using different logins/profiles i have edited the file "/etc/profile" and added this line to the end but doesnt work

"export ADSKFLEX_LICENSE_FILE=@192.168.1.233"

what am i doing wrong, how do i also call it a filename as it says ie .flexlmrc
Sorry, but is this a trick question?

The instructions from Autodesk support you link to (and have you CALLED Autodesk support for assistance with their pay-for product???) specifically tell you that it looks for the .flexlmrc file in whatever users home directory. So no matter WHERE you put that in their .profile, .bashrc, .bash_profile, whatever...it will not work. The instructions say that.

You can deploy things to all new users using the /etc/skel directory, but aside from that the solution to your problem is in the link you posted. In short, follow their instructions.

::EDIT::
I thought this sounded familiar:
https://www.linuxquestions.org/quest...er-4175626129/

Working on this for two months, and you said you were going to follow up and 'let us know'.

Last edited by TB0ne; 05-18-2018 at 04:36 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
adding sth. to all users' PATH variable (sudo included) tpresa Linux - Software 2 08-03-2010 03:16 PM
The XAPPLRESDIR enviroment variable. SeanW Programming 3 05-02-2008 02:31 AM
Enviroment Variable for all users? thuanpv Fedora 1 07-19-2006 11:10 PM
enviroment variable PATH Moataz Linux - Newbie 2 04-25-2005 08:25 PM
MOZILLA_FIVE_VARIABLE enviroment variable Lechium Slackware 4 08-31-2004 04:19 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > CentOS

All times are GMT -5. The time now is 08:50 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration