T o n g wrote:
> I had no problem invoking my scripts embedded with sudo as root before,
> but not now in my new installation:
> r...@coral:~# echo abc | sudo tee /tmp/t
> sudo: can't open /etc/sudoers: Permission denied
> sudo: no valid sudoers sources found, quitting
What does this give you:
Another way to do it would be to have the "invisible" sudo similar to
NEEDSUDO=""
if [ "`id -u`" != 0 ] ; then
NEEDSUDO="sudo"
fi
echo abc | $NEEDSUDO tee /tmp/t
Then, if the uid is not 0 (root), then it inserts the sudo line...If run by
root, then NEEDSUDO is empty.
--b
On Tue, Sep 28, 2010
On Tue, 28 Sep 2010 09:42:40 -0400, Stephen Powell wrote:
> I don't speak for the OP, but my guess is that the OP has a script that
> he wants to be able to run either as his non-superuser self or as root.
Exactly. Thanks Stephen.
--
Tong (remove underscore(s) to reply)
http://xpt.sourceforge
On Tue, 28 Sep 2010 16:14:24 +0200, Alois Mahdal wrote:
>>> I dont use sudo, but can you explain me,so I will go to bed with more
>>> knowledge, why root would need sudo?
>>
>> invoking my scripts embedded with sudo as root
>>
> I'm, not sure what you mean by "embedded" here, so my guess is that y
>> On Tue, 28 Sep 2010 09:42:40 -0400 (EDT),
>> Stephen Powell said:
S> I don't speak for the OP, but my guess is that the OP has a script that
S> he wants to be able to run either as his non-superuser self or as root.
Easy. This preserves arguments including spaces:
#!/bin/sh
PA
On Tue, 28 Sep 2010 09:42:40 -0400, Stephen Powell wrote:
> On Tue, 28 Sep 2010 06:13:58 -0400 (EDT), Camaleón wrote:
>> On Tue, 28 Sep 2010 09:01:10 +0200, Alexander Hintzer wrote:
>>> Why should one use "sudo" in addition to being root and thus having
>>> all rights?
>>
>> +1 :-)
>
> I don't s
On Tue, 28 Sep 2010 03:26:42 +0200, T o n g
wrote:
On Tue, 28 Sep 2010 02:58:05 +0200, Thierry Chatelet wrote:
I dont use sudo, but can you explain me,so I will go to bed with more
knowledge, why root would need sudo?
invoking my scripts embedded with sudo as root
I'm, not sure what yo
On Tue, 28 Sep 2010 06:13:58 -0400 (EDT), Camaleón wrote:
> On Tue, 28 Sep 2010 09:01:10 +0200, Alexander Hintzer wrote:
>> Why should one use "sudo" in addition to being root and thus having all
>> rights?
>
> +1 :-)
I don't speak for the OP, but my guess is that the OP has a
script that he want
I was looking at this last night. As a test, I pulled root out of sudoers,
and it gives the same error as it would for a non-root user, "root is not in
the sudoers. This will be reported."
I can't figure out why it is giving you a permission denied. Are you running
extended acls or anything like t
On Tue, 28 Sep 2010 09:01:10 +0200, Alexander Hintzer wrote:
> Am 28.09.2010 02:16, schrieb Tom H:
>> On Mon, Sep 27, 2010 at 7:53 PM, T o n g wrote:
>>>
>>> What could be wrong?
>>
>> grep root /etc/sudoers
>>
>>
> Why should one use "sudo" in addition to being root and thus having all
> rights?
Am 28.09.2010 02:16, schrieb Tom H:
On Mon, Sep 27, 2010 at 7:53 PM, T o n g wrote:
I had no problem invoking my scripts embedded with sudo as root before,
but not now in my new installation:
r...@coral:~# echo abc | sudo tee /tmp/t
sudo: can't open /etc/sudoers: Permission denied
sudo: no va
On Mon, Sep 27, 2010 at 10:52 PM, T o n g wrote:
> My bad.
>
> The failed environment is a linux-live environment that I built myself.
> When mirroring it to HD, everything works fine. So it's actually the live
> environment's problem, not sudo's.
>
> Thanks again for your comprehensive tips, whic
My bad.
The failed environment is a linux-live environment that I built myself.
When mirroring it to HD, everything works fine. So it's actually the live
environment's problem, not sudo's.
Thanks again for your comprehensive tips, which I'll garter bellow in
case someone else need to troubles
On Mon, Sep 27, 2010 at 10:22 PM, T o n g wrote:
> On Mon, 27 Sep 2010 22:16:34 -0400, Tom H wrote:
>
>> Do you have the "!root_sudo" option set?
>
> Nope:
>
> $ sudo cat /etc/sudoers | grep root_sudo || echo no
> no
>
> Thank you all the same.
You're welcome.
Do you have an "/etc/pam.d/sudo" fi
On Mon, 27 Sep 2010 22:16:34 -0400, Tom H wrote:
> Do you have the "!root_sudo" option set?
Nope:
$ sudo cat /etc/sudoers | grep root_sudo || echo no
no
Thank you all the same.
--
Tong (remove underscore(s) to reply)
http://xpt.sourceforge.net/techdocs/
http://xpt.sourceforge.net/tools/
On Mon, Sep 27, 2010 at 10:09 PM, Tom H wrote:
> On Mon, Sep 27, 2010 at 8:34 PM, T o n g wrote:
>> On Mon, 27 Sep 2010 20:16:05 -0400, Tom H wrote:
>>
What could be wrong?
>>>
>>> grep root /etc/sudoers
>>
>> % grep ^root /etc/sudoers
>> root ALL=(ALL) ALL
>>
>> It has always been there.
>
On Mon, Sep 27, 2010 at 8:34 PM, T o n g wrote:
> On Mon, 27 Sep 2010 20:16:05 -0400, Tom H wrote:
>
>>> What could be wrong?
>>
>> grep root /etc/sudoers
>
> % grep ^root /etc/sudoers
> root ALL=(ALL) ALL
>
> It has always been there.
Sorry, no idea then.
--
To UNSUBSCRIBE, email to debian-us
> I dont use sudo, but can you explain me,so I will go to bed with more
> knowledge, why root would need sudo?
It doesn't make any sense to use sudo as root without an "-u user"
(and therefore to sudo to root as root) but it should work.
--
To UNSUBSCRIBE, email to debian-user-requ...@lists.deb
sudo means what super user can do, you can also do provided you have given
permission in /etc/sudoers file.
By default in certain system sudoers file is read only.If you want to change
that file make it writeable,modify and then again make it read only.
On Tue, Sep 28, 2010 at 6:28 AM, Thierry C
On Mon, Sep 27, 2010 at 17:58, Thierry Chatelet wrote:
> I dont use sudo, but can you explain me,so I will go to bed with more
> knowledge, why root would need sudo?
> Thierry
I have used sudo as root - but with a username as an argument. Without
a username, it defaults to root, and I can't figur
I dont use sudo, but can you explain me,so I will go to bed with more
knowledge, why root would need sudo?
Thierry
--
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/201
On Mon, 27 Sep 2010 20:16:05 -0400, Tom H wrote:
>> What could be wrong?
>
> grep root /etc/sudoers
% grep ^root /etc/sudoers
root ALL=(ALL) ALL
It has always been there.
--
Tong (remove underscore(s) to reply)
http://xpt.sourceforge.net/techdocs/
http://xpt.sourceforge.net/tools/
--
T
On Mon, Sep 27, 2010 at 7:53 PM, T o n g wrote:
>
> I had no problem invoking my scripts embedded with sudo as root before,
> but not now in my new installation:
>
> r...@coral:~# echo abc | sudo tee /tmp/t
> sudo: can't open /etc/sudoers: Permission denied
> sudo: no valid sudoers sources found,
23 matches
Mail list logo