The problem with busybox is that it doesn't support a whole bunch of useful stuff that would help in this situation, such as sudo, and therefore the wheel solution proposed in other posts, in /etc/sudoers, can't be done. Likewise, usermod is not available, and even adduser -u 0 doesn't work because it complains that "UID 0 is already used".
What you have to do is simple:
- adduser user
- vi /etc/passwd and modify the uid of user.
/etc/passwd will look something like this:
root:x:0:0:root:/home:/bin/sh
daemon:x:1:1:daemon:/usr/sbin:/bin/sh
sampleUser:x:1000:1000:Linux User,,,:/home/sampleUser:/bin/sh
to give sampleUser root privileges, edit like this:
sampleUser:x:0:0:Linux User,,,:/home/sampleUser:/bin/sh
I.e. set sampleUser's uid = 0
Comments