|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
VeriSign Code Signing Digital Certificates provides assurance to end users. Read about this and more in the free white paper: “How to Digitally Sign Downloadable Code for Secure Content Transfer.” Learn More! |
|
#1
|
|||
|
|||
|
awk help needed
Hi.
I am trying to write a script that will parse my /etc/passwd file and return a list of all non system users. (All UID's above 500) I am using awk to isolate the usernames and uid's like this: awk 'BEGIN { FS = ":" } ; { print $1, $3 }' /etc/passwd > /tmp/usrlist And it works fine but of course it still lists all system users as well. Is there a way to get awk to process the list even further so that only users with a UID > 500 is output? Thanks |
|
#2
|
|||
|
|||
|
awk 'BEGIN { FS = ":" } ; $3 > 500 { print $1, $3 }' /etc/passwd > /tmp/usrlist
|
![]() |
| Viewing: Dev Shed Forums > Operating Systems > UNIX Help > awk help needed |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|