473,396 Members | 2,026 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

List Only Usernames

Iwant to list only users names in a Linux system byusing the /etc/passwd file.
May 26 '20 #1
1 3428
SioSio
272 256MB
Expand|Select|Wrap|Line Numbers
  1. $ cut -d: -f1 /etc/passwd
  2. $ cat /etc/passwd | sed -e 's/:.*//g'
  3. $ awk -F":" '{ print $1 }' /etc/passwd
  4.  
Use one of three command lines.
If you want to show in each page of the screen, add "| more".
May 27 '20 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Hollek | last post by:
Before users can use my asp-site, they have to login. The username is stored in a session variable "USR". I need a list of all users that are active in my site. I tried to store the logged...
8
by: Declan Barry | last post by:
Hi all.. Does anyone have a php script that would allow me to encrypt the contents of a txt file? I have an excel file which has a list of usernames and generated passwords. What I would...
0
by: npaulus | last post by:
Hi, I am trying to list all usernames from active directory under the domain 'tefter.com' DirectoryEntry entry = new DirectoryEntry(); DirectorySearcher mySearcher = new...
0
by: Victoria Bolton | last post by:
I have an insert form that I want to double up as a edit form. I pass an id number by querystring and then in the page_Loadcomplete I call a function that fills the controls on the page with the...
1
by: furiousmojo | last post by:
The problem: Most usernames show up in the dropdownlist, but a random few do not show up. Why? If I put the filter below into my Users and Computers snap-in as an advanced search, it finds all...
2
by: Infopumper | last post by:
:mad: OK. I have been attempting to do this for some time: Dynamic List/Menu Dropdiwn with Usernames Need to update Record Using the Dropdown Using ASP, VB, And Dreamweaver Form Code: <form...
5
by: admin | last post by:
I have a class that has a function that should query a database and return a list of usernames as well as their id. What type should I use as a return type, that can hold data such as: user1, 1...
1
by: newscorrespondent | last post by:
I am using System.Security.Principal to identify clients and allow functionality based on the groups they belong to. In one case I would like to let them know who can do the function they cannot....
1
by: =?Utf-8?B?RGF6bWFuOTg=?= | last post by:
Hi I have no real experience with VBA other than basic macro's, but I have created a list of usernames in Excel and now I wish to Query AD to see if the user's account is: 1. Active 2....
13
by: dexter48 | last post by:
Hi all, i wonder if any one could help with this problem I have a fileA: a list of usernames I have a fileB: a list of events with a field containinng the username I want to search the list of...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.