[LAU] getting sound working -- user id problems

David bouncingcats at gmail.com
Mon May 19 09:06:44 UTC 2014


On 19 May 2014 14:38, Rustom Mody <rustompmody at gmail.com> wrote:
>
> The problem is that the numerical id of the (my) username is different in
> the two systems. In DebOld the id is 1001 in Deb64 it is 1000.

The usual way to do this is to use the usermod command -u and -g to
change UID and GID for all the /etc database files and files in the
users home directory, . This is what you should have done on the Deb64
system. Read the man page warnings first. So you could undo what you
did and then run:

  # usermod -u <newu> -g <newg> <username>

Just make sure that you dont use a <new> value that collides with one
that was already in use in that database. Specific example, dont do
'usermod -u 1001 -g 1001 <username>' on the Deb64 system if 1001 is
already in use on the Deb64 system.

(all examples are untested)

You can see the numeric values with 'ls -n'

Check /etc/passwd and /etc/groups, and check first with

  # find / -user <newu>
  # find / -group <newg>

The <...> values can be symbolic or numeric.

To change the ownership of files outside of the home directory you can
either use 'find' like:

  # find <topdir> -user <oldu> -group <oldg> -execdir chown -c
<newu>:<newg> '{}' \;

Or you can use 'chown' recursively like

  # cd <topdir> && chown -c -R --from=<oldu>:<oldg> <newu>:<newg> *


More information about the Linux-audio-user mailing list