LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 12-30-2006, 03:13 PM   #1
adam-red
Member
 
Registered: Oct 2004
Location: Manchester, UK
Distribution: openSUSE 11.2
Posts: 63

Rep: Reputation: 15
/etc/profile does not exist


I installed the ATI drivers on my Edgy installation following a guide I'd used before. When I try logging in now though it says that it can't find /etc/profile. On the plus side the ATI thing worked. I can login to Gnome in Failsafe mode, but is there a way to rebuild my profile?

Thanks
Adam
 
Old 12-30-2006, 09:20 PM   #2
stress_junkie
Senior Member
 
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873

Rep: Reputation: 335Reputation: 335Reputation: 335Reputation: 335
You could boot a live CD and copy the one on the running system to your hard disk.

Or you could restore from your backups. (I couldn't resist.)
 
Old 12-30-2006, 10:16 PM   #3
FnordPerfect
Member
 
Registered: Dec 2006
Location: Germany
Distribution: Kubuntu (Feisty Fawn), Debian (SID)
Posts: 127

Rep: Reputation: 15
The file /etc/profile and your personal counterpart ~/.bash_profile are executed by a shell (e.g. bash) when it is started in login mode.

It is not essential for a working system, when you are a GUI-only type of user.

It's a plain shell script which sets up some environmental variables and settings, e.g. configuring the prompt you see in a terminal window (user@host:/$ _).

Just recreate it with a text editor.

Or copy it from ~/.bash_profile (if it's there)

Or copy an example profile from /usr/share/doc/bash/examples/startup-files/Bash_profile to /etc/profile
(dunno. assuming it is there on a Ubuntu-system)

Or use mine :-) (I have never altered it):
Code:
# /etc/profile: system-wide .profile file for the Bourne shell (sh(1))
# and Bourne compatible shells (bash(1), ksh(1), ash(1), ...).

PATH="/usr/local/bin:/usr/bin:/bin:/usr/bin/X11:/usr/games:/usr/sbin"

if [ "$PS1" ]; then
  if [ "$BASH" ]; then
    PS1='\u@\h:\w\$ '
  else
    if [ "`id -u`" -eq 0 ]; then
      PS1='# '
    else
      PS1='$ '
    fi
  fi
fi

export PATH

umask 022
There is more than one way to do it.

cheers
fabian
 
Old 12-31-2006, 06:53 AM   #4
adam-red
Member
 
Registered: Oct 2004
Location: Manchester, UK
Distribution: openSUSE 11.2
Posts: 63

Original Poster
Rep: Reputation: 15
Thanks Fabian
 
  


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
Does this exist? Morbid SUSE / openSUSE 38 07-22-2006 08:16 PM
system profile vs user profile bonito SUSE / openSUSE 3 06-28-2006 01:02 PM
non roaming profile on a roaming profile system fieldyweb Linux - Newbie 1 10-03-2005 12:27 PM
make.profile doesnt exist on stage 3 gentoo SciYro Linux - Distributions 2 06-12-2004 05:24 AM
Does this exist? WorldBuilder General 3 08-20-2003 09:28 PM

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

All times are GMT -5. The time now is 03:13 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
Open Source Consulting | Domain Registration