Home > Archive > Linux/Unix > June 2002 > Unix vs Linux





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author Unix vs Linux
Boulware5

2002-06-02, 6:20 pm

I have a few questions for the Unix people who know Linux. Some of the files and locations are slightly different in the Unix class I'm taking and in Red Hat Linux. Just want to make sure I got it right to prevent confusion.

1. In a Unix system the shell checks for a startup file named .profile in your home directory. This is not the case on my Red Hat box. In Linux is this equivalent to the .bash_profile file or the .bashrc file?

2. The system profile file in Unix is located in /etc/profile. That's in Linux, but there is also an /etc/bashrc file. Is the /etc/bashrc file the place to put startup commands (like date), shell scripts, motd, etc or would that go in /etc/profile?
dpx

2002-06-02, 7:08 pm

when you create a new user ,the defaults located in the /etc/profile file are read and executed to create the user's environment.Next the shell looks for the files .bash_profile,bash_login,and .profile in the user's home directory if one or more of this files are found they are read and executed in the order listed
if you want to change your path to something different from the system path you can make the change in the .profile file in your home dir.
The VMS Kid

2002-06-03, 8:48 am

The $HOME/.bash_profile file is a shell configuration file . . . you can use it to override the defaults placed in /etc/profile. The $HOME/.bashrc file is used mainly for run commands and aliases that you use after your bash shell initialization. For example, you may want to check for an interactive terminal in your .bash_profile script, but if you want to set a command-line editor, usually it is done in .bashrc.
neuralfx

2002-06-07, 9:16 pm

UNIX is more of a design philosophy than anything else .. Solaris, HPUX, and AIX will vary in a lot of ways .. and they are all considered Unices ..
-neural
Sponsored Links





Free Braindumps | MCSE braindumps software forum

Copyright 2003 - 2009 examnotes.net