LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Linux From Scratch
User Name
Password
Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system.

Notices



Reply
 
Search this Thread
Old 11-29-2004, 04:51 PM   #1
cphase
Member
 
Registered: Dec 2003
Location: Newnan, GA
Distribution: Archlinux
Posts: 77

Rep: Reputation: 15
enviroment variables


I hope this is the correct place to ask this, while fooling around with LFS I inadvertantly changed my enviroment, now I can nolonger get into my home dir or run X. Is tere a way to reset my enviroment variables? TKS in advance
 
Old 11-29-2004, 04:56 PM   #2
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 65
How did you change them? If you just did it for your current session then just logout and back in again.
 
Old 11-29-2004, 04:58 PM   #3
XavierP
Moderator
 
Registered: Nov 2002
Location: Kent, England
Distribution: Lubuntu
Posts: 19,176
Blog Entries: 4

Rep: Reputation: 430Reputation: 430Reputation: 430Reputation: 430Reputation: 430
Moved: This thread is more suitable in Linux From Scratch and has been moved accordingly to help your thread/question get the exposure it deserves.
 
Old 11-29-2004, 05:07 PM   #4
cphase
Member
 
Registered: Dec 2003
Location: Newnan, GA
Distribution: Archlinux
Posts: 77

Original Poster
Rep: Reputation: 15
I used the cat command that is in the setup for LFS but I was not in that dir so now my Slack env is changed and I cant get into my home dir or run X.
 
Old 11-29-2004, 05:11 PM   #5
cphase
Member
 
Registered: Dec 2003
Location: Newnan, GA
Distribution: Archlinux
Posts: 77

Original Poster
Rep: Reputation: 15
Below are the commands I issued that set the env:




cat > ~/.bash_profile << "EOF"
exec env -i HOME=$HOME TERM=$TERM PS1='\u:\w\$ ' /bin/bash
EOF

t > ~/.bashrc << "EOF"
set +h
umask 022
LFS=/mnt/lfs
LC_ALL=POSIX
PATH=/tools/bin:/bin:/usr/bin
export LFS LC_ALL PATH
EOF
 
Old 11-29-2004, 09:03 PM   #6
cphase
Member
 
Registered: Dec 2003
Location: Newnan, GA
Distribution: Archlinux
Posts: 77

Original Poster
Rep: Reputation: 15
Doesn't look like moving this post to LFS forum is getting very much exposure!
 
Old 11-30-2004, 02:00 PM   #7
tvburger
LQ Newbie
 
Registered: Nov 2004
Location: the Netherlands
Distribution: gentoo/ubuntu
Posts: 11

Rep: Reputation: 0
.bashrc

Normally your bash configured by the .bashrc file.

Probably your PATH is not correct to find the startx|xdm|whateverx program. Please send your .bashrc of your user (probably ~/.bashrc) and the output of "set" bash-builtin.

= Tom
 
Old 01-19-2005, 04:15 PM   #8
Mr.McCormick
LQ Newbie
 
Registered: Aug 2004
Location: Redford, MI
Distribution: lfs 6.0-testing-20040913/ blfs 5.1 modifyed
Posts: 10

Rep: Reputation: 0
Quote:
Originally posted by cphase
Below are the commands I issued that set the env:




cat > ~/.bash_profile << "EOF"
exec env -i HOME=$HOME TERM=$TERM PS1='\u:\w\$ ' /bin/bash
EOF

t > ~/.bashrc << "EOF"
set +h
umask 022
LFS=/mnt/lfs
LC_ALL=POSIX
PATH=/tools/bin:/bin:/usr/bin
export LFS LC_ALL PATH
EOF
i know this is a little old but this is your problem change you .bashrc file to read
...
PATH=/tools/bin:$PATH
...
when you set path it resets the env var
and you should use another user than your main so you dont mess with the main user

Last edited by Mr.McCormick; 01-19-2005 at 04:17 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 Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How can I see all the enviroment variables? zvonSully Linux - Software 3 02-09-2005 08:39 AM
Enviroment variables johnnydangerous Fedora 3 02-07-2005 06:45 AM
Where to set enviroment variables vavoem Linux - Software 7 09-07-2004 02:13 AM
setting enviroment variables unimaginative Linux - General 5 01-08-2004 02:22 AM
how to set enviroment variables RedHat123 Linux - Newbie 1 07-16-2002 11:48 PM


All times are GMT -5. The time now is 04:50 AM.

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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration