https://qa.mandrakesoft.com/show_bug.cgi?id=571
Product: setup
Component: setup
Summary: Error message '[: too many arguments' on login for users
generated by samba winbind
Version: 2.2.0-25mdk
Platform: PC
OS/Version: All
Status: UNCONFIRMED
Severity: trivial
Priority: P2
AssignedTo: [EMAIL PROTECTED]
ReportedBy: [EMAIL PROTECTED]
Symptoms:
On Login or the first xterm opened, a Winbind-generated user with a username of
the form "Domain\User" gets the message "[: too many arguments". Note that
Login still succeeds, it's just annoying.
Cause:
Line in /etc/bashrc does not quote backtick substitution of "id" query, and
presumably the \ messes things up if not quoted.
Problem line is
if [ `id -gn` = `id -un` -a `id -u` -gt 99 ]; then
Suggested Fix:
if [ "$(id -gn)" = "$(id -un)" -a "$(id -u)" -gt 99 ]; then
to ensure quoting of user and group names.
Background:
Winbind allows linux boxes to participate in a windows network. It generates
linux users for NT-Domain users. One possible form for the user name is
"MyDomain\User" (excluding quotes - INCLUDING backslash).
Winbind is often configured to use "MyDomain+User" as the username. However, on
real windows the standard syntax (and the winbind default) is "MyDomain\User".
To minimise user confusion it is useful to stick with \.
However, /etc/bashrc has the above minor problem with this. Doubtless some
other things do too, but this is the only visible one I've seen so far.
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.