System Administration
cancel
Showing results for 
Search instead for 
Did you mean: 

Some questions on user management, urgent!

 
SOLVED
Go to solution
Becke
Super Advisor

Some questions on user management, urgent!


Hi Guys,

I need exact answers on some of the basic questions, its very urgent

Q.1 Give an example of how to define an alias. Include infomation of where the alias is defined and an example defination?


Q.2. What does the command 'set -o vi' do? I know it recalls the previous commands? but any specific answer for this one?

Q.3. What keys are used by a user to access his shell history in...
a, The korn shell using vi?

b, The Bash shell?


Q.4. When a user logs in and enters his password the system...

a. Un-encrypts his password in the password file and compares it with the password the user has entered OR

b. Encrypts the password the user has entered and compares it with the encrypted one in the password file.

What is the answer for the above a or b?

Thanks,
Raf
7 REPLIES 7
Becke
Super Advisor

Re: Some questions on user management, urgent!


Few more questions guys and that's all..

Q.1 rwxrwxr-x 1 6170 staff 48127 Jun 06 2003 nc

a, what is the umask required to create a file with the same permission?

b, if I'm not the member of staff group can I delete this file?

Q.2. If a user is configured to use korn shell (ksh) where does this user get their environment?
a. ~/.profile
b. ~/.kshrc
c. ~/.bashrc
d. /etc/profile
e. /etc/environment
f. Combination of a,b,d,e
g. Combination of b,c,d
h. All of a,b,c,d,e
i. None of Above
Answer (a,b,c,d,e,f,g,h,i) :

I think answer is f but what do u recon?

Q. Can you create users whose security levels are based on their roles - ie role based asscess?

a. Yes
b. No
c. Only if appropriate software is installed.

What is the answer a,b or c?
njia_1
Trusted Contributor
Solution

Re: Some questions on user management, urgent!

To Q1.

I alwasy use vim instead of vi so I will define the following alias in .cshrc file in my home directory for tcsh or .bashrc if I am using Bash

alias vi=/usr/loca/bin/vim

To Q2
This will set the command line editing style to vi, so you can use vi commands to do command editing.

To Q3
Just like Q2, if you set command line editing style to vi for ksh then you can use vi commands like / to searck and "j" "k" to move between previously issued commands

To Q4
My understanding is that the system will generate some kind of hash from the password you entered and then compare this to /etc/passwd file.
njia_1
Trusted Contributor

Re: Some questions on user management, urgent!

Few more questions guys and that's all..

Q.1 rwxrwxr-x 1 6170 staff 48127 Jun 06 2003 nc

a, what is the umask required to create a file with the same permission?

I think the umask should be set to 002 to remove the write permission from others.

b, if I'm not the member of staff group can I delete this file?

you should not be able to remove this file if you are not a member of staff group and you do not own this file.

Q.2. If a user is configured to use korn shell (ksh) where does this user get their environment?
a. ~/.profile
b. ~/.kshrc
c. ~/.bashrc
d. /etc/profile
e. /etc/environment
f. Combination of a,b,d,e
g. Combination of b,c,d
h. All of a,b,c,d,e
i. None of Above
Answer (a,b,c,d,e,f,g,h,i) :

I think answer is f but what do u recon?

have a look here
http://www.linuxlots.com/~dunne//getting_the_most_from_your_shell.html

Q. Can you create users whose security levels are based on their roles - ie role based asscess?

a. Yes
b. No
c. Only if appropriate software is installed.

What is the answer a,b or c?

Not quite sure about his one.
Becke
Super Advisor

Re: Some questions on user management, urgent!


Thank you so much for your help, I'm still working on some of these questions as it is urgent..talk to you soon, or please tell me if you come up with any answers for the questions you are not sure???

Thanks a lot
Arunvijai_4
Honored Contributor

Re: Some questions on user management, urgent!

Hi Raf,

Here are my answers,

Q.1 Give an example of how to define an alias. Include infomation of where the alias is defined and an example defination?

### In POSIX shell, just type # alias =''

#alias my_alias='date'
#my_alias
Sun Mar 5 22:57:39 EST 2006

To remove an alias,
#unalias my_alias
#my_alias
sh: my_alias: not found.

Q.2. What does the command 'set -o vi' do? I know it recalls the previous commands? but any specific answer for this one?

### It is used for command line editing.

http://www.kingcomputerservices.com/unix_101/using_history_and_command_line_editing.htm

Q.3. What keys are used by a user to access his shell history in...
a, The korn shell using vi?

### k

b, The Bash shell?

UP, Down arrow keys.

Q.4. When a user logs in and enters his password the system...

a. Un-encrypts his password in the password file and compares it with the password the user has entered OR

b. Encrypts the password the user has entered and compares it with the encrypted one in the password file.

What is the answer for the above a or b?

(B)

-Arun

"A ship in the harbor is safe, but that is not what ships are built for"
Becke
Super Advisor

Re: Some questions on user management, urgent!


Thanks Arun and Njia for your help, I have got what I wanted so I probably close this thread later on today or tommorow.

Have a great day guys I'm now assigning points..

Cheers
Raf
Becke
Super Advisor

Re: Some questions on user management, urgent!


Hi Arun,

I appreciate Arun and Njia, that you guys always respond quickly, Below is my email please send me an email so I can add you guys in my friends list....send me an email Arun and I will reply to that..we have an excellent team here

farhanbiz@hotmail.com

Cheers
Raf