On Monday 13 October 2008 14:19:13 stanliao wrote:
> Dear All,
>
> I use busybox/adduser to create a new user account. However, it prompts
> error message "Operation not permitted". The user account is created under
> an FAT32 partition. Options to mount this FAT32 partition are shown as the
> followings:
> /dev/sda/part1 on /home2 type msdos
> (rw,noatime,nodiratime,uid=1000,gid=1000,fma
> sk=0000,dmask=0000,codepage=cp437)
>
> Command/operation to create a new user account is as follows:
> # whoami
> root
> # id
> uid=0(root) gid=0(root)
> # adduser -h /home2/xyz xyz
> adduser: /home2/xyz: Operation not permitted
> Changing password for xyz
> New password:
> Retype password:
> Password for xyz changed by root
>
> And I found that owner and group of /home2/xyz is not xyz but another id
> (the user who own id = 1000). Please note that uid for xyz is 1002. So, I
> execute "chown" and get the error message:
> # chown xyz /home2/xyz
> chown: /home2/xyz: Operation not permitted
>
> Excuse me, what else I missed in order to create this user account? What
> operation is tried while I execute "adduser" and "chown" but is denied?
>
> Thank you very much.
> Stan Liao
>
>
> _______________________________________________
> busybox mailing list
> [email protected]
> http://busybox.net/cgi-bin/mailman/listinfo/busybox
>
Hi,
adduser does:
if (mkdir(pw.pw_dir, 0755)
|| chown(pw.pw_dir, pw.pw_uid, pw.pw_gid)
|| chmod(pw.pw_dir, 02755) /* set setgid bit on homedir */
) {
bb_simple_perror_msg(pw.pw_dir);
}
so i suspect that chown and/or chmod fail on fat as this operations
are not supported on that filesystem.
Ciao,
TIto
_______________________________________________
busybox mailing list
[email protected]
http://busybox.net/cgi-bin/mailman/listinfo/busybox