Problem when making many users with "users admin. tool" at one time
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
GST |
Fix Released
|
Critical
|
|||
gnome-system-tools (Ubuntu) |
Fix Released
|
High
|
Ubuntu Desktop Bugs |
Bug Description
We have seen in a school, making practice of creating users with the GUI'ed "users administration tool" (the one that is in System-
Cheers!
Rafael Ávila Coya and his students
O Porrino, Galicia, Spain.
Phil Bull (philbull) wrote : | #1 |
Changed in yelp: | |
status: | Unconfirmed → Needs Info |
Changed in gnome-system-tools: | |
assignee: | nobody → desktop-bugs |
Rafael Ávila Coya (ravila-edu) wrote : Re: [Bug 31675] Problem when making many users with "users admin. tool" at one time | #2 |
I tell you:
I am giving lessons of UNIX/Linux basics, using Ubuntu 5.10 Breezy (preview release in most of the computers) to 14 students, althougt at that time there were only 7 in the classroom.
We were making practice of creating users and groups, with the GUI 'user administration tool', and commands like adduser, useradd, usermod, addgroup, and so on. I told them that using the GUI tool could be the most easy and advisable way to create users, and then usermod and other commands to assign extra groups to each user and things like that. I suggested them to create accounts in there own computers for the rest of the users in the classroom (15, including me). As you know, with the GUI tool, you can edit 2 or more users, but they are not created until you click a "final" OK to the application. One student and me were clicking OK each 4 or 5 users (or so), and didn't have any problem. But it seems that the rest of them (5 students) introduced all the users (15) one after one, without clicking the "final OK" to the whole application. What happened is that, when they finally clicked OK, the app. start "working" but didn't finish. It didn't crashed, nor freezed. It got in
the state of "working", but never finishing the task, you understand?
I am now at home, and reproduced the situation in my laptop (I didn't bring it to the school, so it is a new machine!). I started the GUI and tried to create 13 new users (login names 'uno', 'dos', 'tres', 'cuatro', and so on (-< they are the numbers in spanish :-) )). I didn't put GECOS to anyone, and password was the login name of each user, just to make it the easy way. I assigned them, in the 'advanced' section, the home directory '/home/
for that state.
I think I didn't forget any important thing. My advice is that you try to reproduce the same situation, and see it youself. I'm affraid I don't have enough knowledge to help. I don't even know where the 'user administration tool' package's source is!
Cheers and deep thanks to all of the community. You make this world a bit nicer and worthwhile.
Anything I can't help you, don't hesitate to contact me.
Rafael Ávila Coya.
----- Mensaxe orixinal -----
De: Phil Bull <email address hidden>
Data: Xoves, Febreiro 16, 2006 7:22 pm
Asunto: [Bug 31675] Problem when making many users with "users admin. tool" at one time
> Public bug report changed:
> https:/
>
> Task: ubuntu yelp
> Sourcepackagename: yelp => gnome-system-tools
> Binarypackagename: yelp => None
> Status: Unconfirmed => Needs Info
>
> Comment:
> Thanks for the report.
>
> Could you provide some more information about the prob...
Rafael Ávila Coya (ravila-edu) wrote : | #3 |
I tell you:
I am giving lessons of UNIX/Linux basics, using Ubuntu 5.10 Breezy (preview release in most of the computers) to 14 students, althougt at that time there were only 7 in the classroom.
We were making practice of creating users and groups, with the GUI 'user administration tool', and commands like adduser, useradd, usermod, addgroup, and so on. I told them that using the GUI tool could be the most easy and advisable way to create users, and then usermod and other commands to assign extra groups to each user and things like that. I suggested them to create accounts in there own computers for the rest of the users in the classroom (15, including me). As you know, with the GUI tool, you can edit 2 or more users, but they are not created until you click a "final" OK to the application. One student and me were clicking OK each 4 or 5 users (or so), and didn't have any problem. But it seems that the rest of them (5 students) introduced all the users (15) one after one, without clicking the "final OK" to the whole application. What happened is that, when they finally clicked OK, the app. start "working" but didn't finish. It didn't crashed, nor freezed. It got in the state of "working", but never finishing the task, you understand?
I am now at home, and reproduced the situation in my laptop (I didn't bring it to the school, so it is a new machine! - Ubuntu Breezy (not preview, but the "real" one)). I started the GUI and tried to create 13 new users (login names 'uno', 'dos', 'tres', 'cuatro', and so on (-< they are the numbers in spanish :-) )). I didn't put GECOS to anyone, and password was the login name of each user, just to make it the easy way. I assigned them, in the 'advanced' section, the home directory '/home/
I think I didn't forget any important thing. My advice is that you try to reproduce the same situation, and see it youself. I'm affraid I don't have enough knowledge to help. I don't even know where the 'user administration tool' package's source is!
Cheers and deep thanks to all of the community. You make this world a bit nicer and worthwhile.
Anything I can't help you, don't hesitate to contact me.
Rafael Ávila Coya.
Phil Bull (philbull) wrote : | #4 |
Thanks for the explanation. I tried to reproduce this with ten users (named 'one' to 'ten'), but the users were created normally, with no freeze. Which version of the gnome-system-tools package do you have installed?
Could you run the application in a terminal, recreate the freeze, and see if any useful error text is printed to the terminal please? The command is:
sudo users-admin
Also, in another terminal, try the following command after the freeze has happened:
cat /etc/passwd | grep username
(where 'username' is replaced with the name of a user, e.g cuatro)
If the user has been added, it should appear in the output of that command.
Thanks!
Rafael Ávila Coya (ravila-edu) wrote : | #5 |
Hi again, Phil!
It's a pity that you didn't go on introducing users. I reproduced what you did (10 users from 'one' to 'ten', home directory '/home/
But after the successful creation of 10 users, I did the same again, but now with 15 users (this time in greek :-) 'ena', 'dio' up to 'dekapente', and home directory '/home/
In both cases (15 users to be created), no user is created, as I could check in /etc/passwd and /etc/shadow files.
For your information, my gnome-system-tools package version is 1.4.0-0ubuntu10, and users-admin version is 1.4.0
I recommend you to do it again with 15 (or more) users. Hope this info. is enough to give some light to this bug.
Cheers,
Rafael.
PD.: I have some screenshots of all processes, if you need them. If that's so, tell me and I'll send them to you.
Phil Bull (philbull) wrote : | #6 |
Well, I tried adding 15 users and I still couldn't reproduce the freeze. However, I got a nastier problem instead!
After adding all fifteen and clicking 'OK', the app seemed to be doing something for a few seconds, then quit (no crash report etc). So I took a look at /etc/passwd and none of the new users were listed. Directories had been created for them in /home though.
I then found out that I couldn't use sudo (root), because of some authentication error. On typing sudo <commandname>, it would prompt me for my password and then fail to execute the command, silently. I couldn't use slocate either because 'the slocate group does not exist'. With my root access gone, I had to reinstall Dapper off CD.
Tricky one!
Phil Bull (philbull) wrote : | #7 |
I've confirmed this, as I get problems too. Can anyone else reproduce this issue?
Also, I couldn't find an upstream bug.
Changed in gnome-system-tools: | |
status: | Needs Info → Confirmed |
Rafael Ávila Coya (ravila-edu) wrote : | #8 |
I would also put the severity up to "major", because in my opinion, loosing your own password is a really big problem. I found upstream a similar bug (http://
[I didn't find the accurate english term before. Where I should say "it hangs" I was saying "it freezes", that is similar, but not the same].
Daniel Holbach (dholbach) wrote : | #9 |
We should try to find ways of reproducing both issues and have separate bug reports for those. Could you try to get a backtrace, when users-admin hangs?
gdb -p $(pidof users-admin)
...
thread apply all bt
and paste the output here?
Changed in gnome-system-tools: | |
status: | Confirmed → Needs Info |
Phil Bull (philbull) wrote : | #10 |
I'm a bit reluctant to trash my system again. I'll get a Dapper install up and running in vmware when I can and grab a backtrace in that.
Rafael Ávila Coya (ravila-edu) wrote : | #11 |
Sorry, but I'm not expert in gdb.
I started users-admin and then, in a xterm, I did
sudo gdb -p 18641
The output was:
-------
GNU gdb 6.3-debian
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i486-linux-gnu".
Attaching to process 18641
Using host libthread_db library "/lib/tls/
warning: could not load vsyscall page because no executable was specified
warning: try using the "file" command first
Reading symbols from /usr/bin/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /lib/libpopt.
Loaded symbols for /lib/libpopt.so.0
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Rafael Ávila Coya (ravila-edu) wrote : | #12 |
I thought that maybe it should be done the opposite way.
I started users-admin and create 15 users (with long passwords (6 to 10 caracters or so), just in case). Then, when it hanged (as usual), I enter a terminal and typed:
sudo gdb -p pid-of-users-admin
The output was:
-------
GNU gdb 6.3-debian
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i486-linux-gnu".
Attaching to process 19617
Using host libthread_db library "/lib/tls/
warning: could not load vsyscall page because no executable was specified
warning: try using the "file" command first
Reading symbols from /usr/bin/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /lib/libpopt.
(no debugging symbols found)...done.
Loaded symbols for /lib/libpopt.so.0
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
(no debugging symbols found)...done.
Loaded symbols for /usr/lib/
Reading symbols from /usr/lib/
Gary Coady (garycoady) wrote : | #13 |
I think these are both the same problem.
Creating a large number of users causes an invalid XML file to be sent to the backend - a line is truncated at 4096 characters, so it looks like a static buffer is filled.
The backend tools don't use a "real" XML parser, so they will try to use an invalid XML document. The corrupted file causes users not to be added, groups to be deleted, etc.
In my case, it deleted the groups: adm, tty, disk, kmem, dialout, fax, voice, cdrom, floppy, tape, sudo, audio, dip, operator, src, shadow, utmp, video, sasl, plugdev, staff, users, crontab, ssh, slocate, scanner and admin.
Gary Coady (garycoady) wrote : Example truncated in.xml | #14 |
Gary Coady (garycoady) wrote : | #15 |
I didn't find where the 4095 char buffer problem is - it's somewhere in the processing of the backend script, the frontend sends the full contents without truncation.
A workaround would be to avoid having as long a line, by adding a linefeed after every addition of a user to the XML file.
Gary Coady (garycoady) wrote : Break up a long list of users into shorter lines | #16 |
- Break up a long list of users into shorter lines Edit (2.3 KiB, text/plain)
Patch adds linefeeds to keep the size of the lines below 4096 characters (in the XML file supplied to the backend). This works around an apparent limitation in the backend script.
Daniel Holbach (dholbach) wrote : | #17 |
gnome-system-tools (2.14.0-0ubuntu3) dapper; urgency=low
.
* debian/
- add patch from Gary Coady <email address hidden> to fix Malone: #31675
("Problem when making many users with "users admin. tool" at one time")
Changed in gnome-system-tools: | |
status: | Needs Info → Fix Released |
Changed in gst: | |
importance: | Unknown → Critical |
Thanks for the report.
Could you provide some more information about the problem, please? How are you trying to create many users at one time? One by one, and the application cannot add any more after 5 or 6 have been created? Or in another way?
What happens when adding users fails? Does the application crash, freeze, or just not add any more users?
Thanks again!