• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 23249
  • Last Modified:

What is .profile in UNIX? How do I set it up?

What is .profile in UNIX? How do I set it up?

I am using HP  UX

Thax.
_Esam

0
_Esam
Asked:
_Esam
  • 3
  • 3
  • 2
1 Solution
 
TintinCommented:
.profile is a special file in your HOME directory that gets invoked when you login (if your login shell is sh, ksh, bash etc)

You can use any editor to change the contents as it is a simple file.

The most typical things that people change in their .profile is their PATH and prompt, eg:

PATH=$PATH:$HOME/bin
export PATH
PS1='mypath$ '
export PS1
0
 
_EsamAuthor Commented:
Hi Tintin,

I am using HP UX with ksh I think (perdon my ignorace....)

How do I find this .profile file and edit it??


When I do an ls in my home directory,,, I do not see any .profile file..

Let me know..

Thax.
_Esam
0
 
TintinCommented:
Any files that are prefixed with a . are "hidden" when you do a straight ls

use

ls -la

to see all files (including dot files)

if .profile doesn't exist in your home directory, simply create it with your preferred editor.
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
_EsamAuthor Commented:
I think I need to use vi to create one...

How do I do that?

Which directory I go to first?
I know I can open the vi with just the vi command...

How do I create the .profile file and save it ... and in which directory I save it to???


Please let me know..

Thax..
_Esam
0
 
TintinCommented:
To create a new .profile, just do

cd
vi .profile
0
 
gheistCommented:
Is this a homework question???
Why don't you as your system admin?

I doubt one actually working with HP-UX does not know where to stick .profile.
0
 
_EsamAuthor Commented:
>Is this a homework question???
No, it's not.
And, I don't like this kind of discouraging interjections!!!


>I doubt one actually working with HP-UX does not know where to stick .profile.
Well, you are wrong! and this is not the proper way to answer some question.

0
 
gheistCommented:
Have you contacted your system administrator regarding setting environment ???
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

  • 3
  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now