Unable to create new user without lower character

Hi friends,

I want to create new user BG0001 in SunOS and getting below error

bash-3.2# useradd -d /home/BG0001 -m -s /bin/sh  BG0001
UX: useradd: BG0001 name should have at least one lower case character.
bash-3.2#
bash-3.2#

OS version is as below

bash-3.2# cat /etc/release
                   Oracle Solaris 10 8/11 s10s_u10wos_17b SPARC
  Copyright (c) 1983, 2011, Oracle and/or its affiliates. All rights reserved.
                            Assembled 23 August 2011
bash-3.2#

Please suggest

Well it is not in UNIX philosophy to use upper case for names e.g commands, users etc... as UPPERCASE is more reserved for VARiables names as you see when you set your environment... What account do you use to create a user? Is it in uppercase?

Hi VBE,
we are using root user to create new users

I do not know enough AIX to give an exact answer. Many UNIX variants have a file that controls what characters are required in passwords. This sounds like a limitation of a similar security setting, which if you do not understand, is very likely a bad thing to alter.

Is this some kind of a specific requirement? As VBE mentioned, most unix usernames are lowercase.

FYI, it's creating the user, it's just warning you that you should use a mix of upper and lower case.

go check /etc/passwd

You can create an account with a user name that does not contain any lowercase letters, but that poor user will curse you every time they try to login if you do so. When you login to a UNIX system (such as Solaris release 10) with a user name that doesn't contain any lowercase letters, the system will assume that you are logging in from a device (such as a TTY Model 33 teletype) that only has uppercase letters. To login as BG0001 , they will need to type in the string \B\G001 and any uppercase characters in their password will also have to be escaped. After they have successfully logged in (if they are able to do so), they'll need to use stty to tell the TTY subsystem that the terminal emulator they're using does understand both uppercase and lowercase letters. Then that user will need to remember the different possible modes they might be working in whenever they try to change their password, enter their user name, type commands into their shell, etc.

The automated scripts that set up new user accounts complain about uppercase only user names for a reason. I strongly encourage you to heed the warning provided by the useradd warnings.

1 Like

Don, while I don't doubt your statement on whatever *nix you use. I've not found this to be the case on Solaris 11. I have several accounts on my systems that don't have lower case letters in their usernames and I have never experienced the difficulties you describe.

I've not had an issue with all capital letter users either, except on the console. There I would fail a login using any random lower-case characters and then you can login with the one you want.

I ran AIX, Solaris (2.5 to v8), HP-UX 11.11, Dynix 4 and RHEL 5 & 6 quite happily like this. Our application required all capitals because it was originally grown on an IBM mainframe running VM/XA & MVS/ESA (gosh I'm old! :o) and they assumed every user account was only capitals.

Login over the network seemed never to be a problem. Are we worried about users defined in LDAP / AD perhaps etc.? We'd gone away from user login to the server by that point so they logged in to the application instead.

Robin