General discussion

  • Creator
    Topic
  • #2093130

    Creating user in linux as Numeric Only

    Locked

    by malikaqib ·

    I want to create users in linux as numeric (numbers only).Normally we create users as starting with alphabats.Some one told me to create alias file for that users. But is there any better way, so i can directly create users as in numerics

All Comments

  • Author
    Replies
    • #3871209

      Creating user in linux as Numeric Only

      by spamlover ·

      In reply to Creating user in linux as Numeric Only

      If you haven’t tried directly editing the /etc/passwd file you might try that. At least doing it that way would bypass any limitations of the adduser command or any GUI tools for adding users.

      Make sure you are superuser/root and edit the /etc/passwd file.
      Each user on the system has a separate line in the file with the following format:

      username:password:uid:gid:optional_info:home_dir:shell

    • #3871176

      Creating user in linux as Numeric Only

      by petronil ·

      In reply to Creating user in linux as Numeric Only

      yeah sure! You can directly create users in numerics through the adduser command but how about your previous users? Thus this mean that you edit manually your /etc/passwd and your /etc/shadow? If so then it requires you a lot of work to do. I advisethat you create a simple perl script to handle that task for this will minimize your work specially if you have created many users already.

    • #3850071

      Creating user in linux as Numeric Only

      by bruce timberlake ·

      In reply to Creating user in linux as Numeric Only

      You can create usernames that are just numbers; you don’t need to do any aliasing or anything.

    • #3699433

      Creating user in linux as Numeric Only

      by malikaqib ·

      In reply to Creating user in linux as Numeric Only

      This question was auto closed due to inactivity

Viewing 3 reply threads