![]() |
2011-01-11
, 08:38
|
Posts: 3,617 |
Thanked: 2,412 times |
Joined on Nov 2009
@ Cambridge, UK
|
#21
|
![]() |
2011-01-11
, 09:26
|
Posts: 46 |
Thanked: 7 times |
Joined on Jan 2011
@ AU/MY
|
#22
|
![]() |
2011-01-11
, 10:26
|
Posts: 3,617 |
Thanked: 2,412 times |
Joined on Nov 2009
@ Cambridge, UK
|
#23
|
grep gainroot /etc/sudoers.d/01sudo
lsof /var/lib/dpkg/lock
![]() |
2011-01-11
, 10:35
|
Posts: 46 |
Thanked: 7 times |
Joined on Jan 2011
@ AU/MY
|
#24
|
Okay, so that's working at least.
The "sudo gainroot" shouldn't be asking for a password though, so the next thing to do is check whether the sudoers entry is correct - what's the result of running (as root) the following?:
As for the lock error, you can try checking for applications holding the lock file. You'll need to be root, and have lsof installed (not sure whether it's standard or not - it's in the Nokia SSU repository though), then run:Code:grep gainroot /etc/sudoers.d/01sudo
If that doesn't list anything, I'd also suggest checking rootfs space (df -h /) - it may well be unable to lock the file if there's no rootfs space free.Code:lsof /var/lib/dpkg/lock
![]() |
2011-01-11
, 13:33
|
Posts: 46 |
Thanked: 7 times |
Joined on Jan 2011
@ AU/MY
|
#25
|
Okay, so that's working at least.
The "sudo gainroot" shouldn't be asking for a password though, so the next thing to do is check whether the sudoers entry is correct - what's the result of running (as root) the following?:
Code:grep gainroot /etc/sudoers.d/01sudo
BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) Enter 'help' for a list of built-in commands. Nokia-N900-51-1:~# grep gainroot /etc/sudoers.d/01sudo user ALL = NOPASSWD: /usr/sbin/gainroot Nokia-N900-51-1:~#
![]() |
2011-01-11
, 14:22
|
Posts: 3,617 |
Thanked: 2,412 times |
Joined on Nov 2009
@ Cambridge, UK
|
#26
|
Running the code gives me the following:
Code:BusyBox v1.10.2 (Debian 3:1.10.2.legal-1osso30+0m5) built-in shell (ash) Enter 'help' for a list of built-in commands. Nokia-N900-51-1:~# grep gainroot /etc/sudoers.d/01sudo user ALL = NOPASSWD: /usr/sbin/gainroot Nokia-N900-51-1:~#
grep gainroot /etc/sudoers
The Following User Says Thank You to Rob1n For This Useful Post: | ||
![]() |
2011-01-11
, 14:30
|
Posts: 46 |
Thanked: 7 times |
Joined on Jan 2011
@ AU/MY
|
#27
|
That's okay anyway - it specifies NOPASSWD so it shouldn't be asking for any password. What about:
If that only gives the exact same result, can you post the contents of /usr/sbin/gainroot (cat /usr/sbin/gainroot)?Code:grep gainroot /etc/sudoers
![]() |
2011-01-11
, 18:14
|
Posts: 255 |
Thanked: 107 times |
Joined on Nov 2010
|
#28
|
Rob1n, I appreciate your help with this matter. but I I wont run the code, as when I tried apt-get install preenv, we were able to download and install the application. Since this was the original aim to root the N900, I feel theres no need to delve deeper into the problem.
Again many thanx to everyone for your helpAppreciate it a lot