Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
11-03-2005, 03:40 AM
|
#1
|
Member
Registered: Dec 2004
Location: Trondheim, Norway
Distribution: kubuntu 10.04
Posts: 308
Rep:
|
number of users
when I use top or users, I sometimes get one or two users logged in, which is the correct number, other times I get 14 or more copies of the same user. I know the number of users is logged in /var/run/utmp, but is there something I can do to make my system realize (and report) that there is only one (or two) users logged in. for a while, the number of users reported was (number of konsole windows open + number of tty's (1-6) used + 2), but that is no longer the case, making it hard to see how many are actually in (even in runlevel 1 I had about 8 users)
I run Mandriva 2006.0.
|
|
|
11-03-2005, 03:49 AM
|
#2
|
Senior Member
Registered: Mar 2004
Location: england
Distribution: Mint, Armbian, NetBSD, Puppy, Raspbian
Posts: 3,516
|
what about
who -q
Code:
hwdusa22!primaipa(146)$ who -q
neo21iA hub05i3E hub05d2D neocrcd beachmj primaipa beachmj neososA
# users=8
|
|
|
11-03-2005, 03:56 AM
|
#3
|
Member
Registered: Dec 2004
Location: Trondheim, Norway
Distribution: kubuntu 10.04
Posts: 308
Original Poster
Rep:
|
I get:
gjerp gjerp gjerp gjerp gjerp gjerp gjerp gjerp gjerp gjerp gjerp gjerp gjerp
# brukere=13
currently I have no tty's active, and I am the only user logged in, local only, with 4 konsole windows.
what I need is not really a way to see how many users that are logged in, but to figure out how to make top and "users" to display the right number.
|
|
|
11-03-2005, 08:36 AM
|
#4
|
Senior Member
Registered: Mar 2004
Location: england
Distribution: Mint, Armbian, NetBSD, Puppy, Raspbian
Posts: 3,516
|
aaah. oh well.
well I just think it's just one of those things that we can't do very well.
I've tried such as this before.
all such commands: who, finger
give variable results.
|
|
|
11-03-2005, 08:52 AM
|
#5
|
LQ Guru
Registered: Mar 2004
Distribution: Slackware
Posts: 6,634
|
|
|
|
11-03-2005, 12:14 PM
|
#6
|
Member
Registered: Dec 2004
Location: Trondheim, Norway
Distribution: kubuntu 10.04
Posts: 308
Original Poster
Rep:
|
is there a way I can tell my system "do not count each Konsole session as a separate login"? i.e. each tty, gui, and remote session counts for one (and only one) user in utmp and wtmp.
|
|
|
11-04-2005, 03:34 AM
|
#7
|
Senior Member
Registered: Mar 2004
Location: england
Distribution: Mint, Armbian, NetBSD, Puppy, Raspbian
Posts: 3,516
|
I doubt it.
I think You'll have to "do it yourself"
|
|
|
All times are GMT -5. The time now is 03:05 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|