• Welcome to Overclockers Forums! Join us to reply in threads, receive reduced ads, and to customize your site experience!

Unix Test... a few questions

Overclockers is supported by our readers. When you click a link to make a purchase, we may earn a commission. Learn More.

Gravity Man

Member
Joined
Oct 4, 2001
Location
Edina, MN
I need to finish a take-home test today, but I can't find a few answers. We can use any resources we like, so...

What command on some unix systems will show you the messages that occured when the system was last booted?

What is the purpose of the getty process?

Write a command to change all files owned by GID 1002 to GID 1256 automatically.

and finally, Which class of process(es) in unix have the highest priority? Which have the lowest?
 

moorcito

Member
Joined
Sep 19, 2002
Location
Chicago, IL
1. Something like 'cat boot log file | more ' would do the trick. On linux the command is 'dmesg', but I'm not sure on other unix systems.

2. Getty, opens a tty port, prompts for a login name and invokes the /bin/login command, or other non-standard login process.

3. chgrp [option] group file...
So, maybe 'chgrp 1256 *' Or, something like that.

4. I'd say daemons have the highest priority, and lowest would be user specific commands.

Hope some of that helps, 1 & 2 are definates, but 3 &4 are a bit iffy.:beer:
 

David

Forums Super Moderator
Joined
Feb 20, 2001
4. The kernel and init have the highest priorities. Then come essential system processes, such as daemons. Then come userspace programs run in the background, such as servers etc. Then come programs that you run.

Also programs can be 'nice'ed to increase/decrease their priority.

AFAIK a nice of -19 is the highest, and 20 is the lowest priority.

David