Permission denied to root

This is a discussion on Permission denied to root within the Linux Security forums, part of the System Security and Security Related category; I installed a (debian) pkg to supply 'service' in this machine. It is there, but I cannot use it. Will ...


Go Back   Usenet Forums > System Security and Security Related > Linux Security

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 09-11-2007
klop
 
Posts: n/a
Default Permission denied to root

I installed a (debian) pkg to supply 'service' in this machine. It is
there, but I cannot use it. Will someone be kind enough to tell me
why root is denied access, or what I need to do to use it, please. Details
of what I found below. This is on Ubuntu Feisty.

root@dell:~# service
/usr/bin/service: 5: /etc/init.d/: Permission denied
root@dell:~# ls -l /usr/bin/service
-rwxr-xr-x 1 root root 41 2005-11-05 16:12 /usr/bin/service
root@dell:~# file /usr/bin/service
/usr/bin/service: Bourne shell script text executable
root@dell:~# less /usr/bin/service
root@dell:~# uname -a
Linux dell 2.6.20-16-generic #2 SMP Fri Aug 31 00:55:27 UTC 2007 i686 GNU/Linux
root@dell:~# ls -l /etc/init.d/
total 231
-rwxr-xr-x 1 root root 3075 2007-06-26 09:18 915resolution
-rwxr-xr-x 1 root root 2701 2007-06-21 10:10 acpid
-rwxr-xr-x 1 root root 867 2007-06-21 10:10 acpi-support
-rwxr-xr-x 1 root root 9501 2007-06-21 10:10 alsa-utils
-rwxr-xr-x 1 root root 1084 2007-06-21 10:10 anacron
-rwxr-xr-x 1 root root 1386 2007-06-21 10:10 apmd
-rwxr-xr-x 1 root root 3024 2007-06-21 10:10 apport
-rwxr-xr-x 1 root root 969 2007-06-21 10:10 atd
-rwxr-xr-x 1 root root 4318 2007-06-21 10:10 avahi-daemon
-rwxr-xr-x 1 root root 1109 2007-06-21 10:10 binfmt-support
-rwxr-xr-x 1 root root 6557 2007-06-21 10:10 bluetooth
-rwxr-xr-x 1 root root 3597 2007-06-21 10:10 bootclean
-rwxr-xr-x 1 root root 2121 2007-06-21 10:10 bootlogd
-rwxr-xr-x 1 root root 1883 2007-06-21 10:10 bootmisc.sh
-rwxr-xr-x 1 root root 1383 2007-06-21 10:10 brltty
-rwxr-xr-x 1 root root 2887 2007-06-21 10:10 checkfs.sh
-rwxr-xr-x 1 root root 9875 2007-06-21 10:10 checkroot.sh
-rwxr-xr-x 1 root root 5827 2007-04-14 19:07 clamav-freshclam
-rwxr-xr-x 1 root root 6355 2007-06-21 10:10 console-screen.sh
-rwxr-xr-x 1 root root 1612 2007-06-21 10:10 console-setup
-rwxr-xr-x 1 root root 1761 2007-06-21 10:10 cron
-rwxr-xr-x 1 root root 2476 2007-06-21 10:10 cupsys
-rwxr-xr-x 1 root root 2760 2007-06-21 10:10 dbus
-rwxr-xr-x 1 root root 5649 2007-06-21 19:57 dkms_autoinstaller
-rwxr-xr-x 1 root root 1222 2007-06-21 10:10 dns-clean
-rwxr-xr-x 1 root root 1567 2007-04-10 09:11 firestarter
-rwxr-xr-x 1 root root 3136 2007-06-21 10:10 gdm
-rwxr-xr-x 1 root root 3214 2007-06-21 10:10 glibc.sh
-rwxr-xr-x 1 root root 1228 2007-06-21 10:10 halt
-rwxr-xr-x 1 root root 5137 2007-06-21 10:10 hdparm
-rwxr-xr-x 1 root root 909 2007-06-21 10:10 hostname.sh
-rwxr-xr-x 1 root root 2458 2007-06-21 10:10 hotkey-setup
-rwxr-xr-x 1 root root 4516 2007-06-21 10:10 hplip
lrwxrwxrwx 1 root root 15 2007-09-05 11:42 hsf -> /usr/sbin/rchsf
-rwxr-xr-x 1 root root 3634 2007-06-21 10:10 hwclock.sh
-rwxr-xr-x 1 root root 1120 2007-06-21 10:10 keyboard-setup
-rwxr-xr-x 1 root root 944 2007-06-21 10:10 killprocs
-rwxr-xr-x 1 root root 1752 2007-06-21 10:10 klogd
-rwxr-xr-x 1 root root 1809 2007-06-21 10:10 laptop-mode
-rwxr-xr-x 1 root root 349 2007-06-21 10:10 linux-restricted-modules-common
-rwxr-xr-x 1 root root 748 2007-06-21 10:10 loopback
-rwxr-xr-x 1 root root 1054 2007-06-21 10:10 makedev
-rwxr-xr-x 1 root root 1399 2007-06-21 10:10 module-init-tools
-rwxr-xr-x 1 root root 737 2007-03-09 08:52 modutils
-rwxr-xr-x 1 root root 617 2007-06-21 10:10 mountall-bootclean.sh
-rwxr-xr-x 1 root root 2354 2007-06-21 10:10 mountall.sh
-rwxr-xr-x 1 root root 1491 2007-06-21 10:10 mountdevsubfs.sh
-rwxr-xr-x 1 root root 1087 2007-06-21 10:10 mountkernfs.sh
-rwxr-xr-x 1 root root 615 2007-06-21 10:10 mountnfs-bootclean.sh
-rwxr-xr-x 1 root root 2689 2007-06-21 10:10 mtab.sh
-rwxr-xr-x 1 root root 1725 2007-06-21 10:10 networking
-rwxr-xr-x 1 root root 860 2007-06-21 10:10 nvidia-kernel
-rwxr-xr-x 1 root root 612 2007-06-21 10:10 oem-config
-rwxr-xr-x 1 root root 2351 2007-06-21 10:10 pcmciautils
-rwxr-xr-x 1 root root 2974 2007-03-28 10:40 postfix
-rwxr-xr-x 1 root root 4108 2007-06-21 10:10 powernowd
-rwxr-xr-x 1 root root 177 2007-06-21 10:10 powernowd.early
-rwxr-xr-x 1 root root 375 2007-06-21 10:10 pppd-dns
-rwxr-xr-x 1 root root 1208 2007-06-21 10:10 procps.sh
-rwxr-xr-x 1 root root 8186 2007-06-21 10:10 rc
-rwxr-xr-x 1 root root 522 2007-06-21 10:10 rc.local
-rwxr-xr-x 1 root root 117 2007-06-21 10:10 rcS
-rwxr-xr-x 1 root root 1492 2007-06-21 10:10 readahead
-rwxr-xr-x 1 root root 1957 2007-06-21 10:10 readahead-desktop
-rw-r--r-- 1 root root 1335 2007-06-21 10:10 README
-rwxr-xr-x 1 root root 692 2007-06-21 10:10 reboot
-rwxr-xr-x 1 root root 1000 2007-06-21 10:10 rmnologin
-rwxr-xr-x 1 root root 4096 2007-06-21 10:10 rsync
-rwxr-xr-x 1 root root 452 2007-06-21 10:10 screen
-rwxr-xr-x 1 root root 800 2007-06-21 10:10 sendsigs
-rwxr-xr-x 1 root root 585 2007-06-21 10:10 single
-rwxr-xr-x 1 root root 4215 2007-06-21 10:10 skeleton
-rwxr-xr-x 1 root root 510 2007-06-21 10:10 stop-bootlogd
-rwxr-xr-x 1 root root 647 2007-06-21 10:10 stop-bootlogd-single
-rwxr-xr-x 1 root root 864 2007-06-21 10:10 stop-readahead
-rwxr-xr-x 1 root root 2563 2007-06-21 10:10 sysklogd
-rwxr-xr-x 1 root root 2592 2007-06-21 10:10 udev
-rwxr-xr-x 1 root root 3477 2007-06-21 10:10 umountfs
-rwxr-xr-x 1 root root 1833 2007-06-21 10:10 umountnfs.sh
-rwxr-xr-x 1 root root 1105 2007-06-21 10:10 umountroot
-rwxr-xr-x 1 root root 1815 2007-06-21 10:10 urandom
-rwxr-xr-x 1 root root 2105 2007-06-21 10:10 usplash
-rwxr-xr-x 1 root root 820 2007-06-21 10:10 vbesave
-rwxr-xr-x 1 root root 1939 2007-06-21 10:10 waitnfs.sh
-rwxr-xr-x 1 root root 1626 2007-06-21 10:10 wpa-ifupdown
-rwxr-xr-x 1 root root 1832 2007-06-21 10:10 x11-common
-rwxr-xr-x 1 root root 486 2007-06-21 10:10 xserver-xorg-input-wacom
root@dell:~#
Reply With Quote
  #2 (permalink)  
Old 09-12-2007
klop
 
Posts: n/a
Default Re: Permission denied to root

On Mon, 10 Sep 2007 21:33:17 -0500, klop wrote:

> I installed a (debian) pkg to supply 'service' in this machine. It is
> there, but I cannot use it. Will someone be kind enough to tell me
> why root is denied access, or what I need to do to use it, please. Details
> of what I found below. This is on Ubuntu Feisty.


[...]

Answering my own post, what a klop. The command was not right or
complete, and would not work on this Ubuntu system if it were right. The
whole boot and start-up process is different than in my limited experience.
I was trying to avoid the 'm$' model of a complete system rebooting for
every configuration change. I will continue to try to avoid that model.

The answer is that the error messages do not easily reflect the exact,
correct information. Further investigation shows that this command will
never work on this system, even though it was a debian package.

Hope this is helpful to somebody. I'll get my grits here or elsewhere, no
problem. Thanks for reading.

Interesting subject line, though. Don't you think?
Reply With Quote
  #3 (permalink)  
Old 09-12-2007
Chris Davies
 
Posts: n/a
Default Re: Permission denied to root

klop <klop@klop.klop> wrote:
> I installed a (debian) pkg to supply 'service' in this machine. It is
> there, but I cannot use it. Will someone be kind enough to tell me
> why root is denied access, or what I need to do to use it, please.


I run Debian and I've not used "service" since around RH6 days. I recall,
however, that it requires a couple of parameters, for example:

service exim4 restart

The Debian (and therefore presumably Ubuntu) equivalent is "invoke-rc.d",
viz:

invoke-rc.d exim4 restart


> root@dell:~# service
> /usr/bin/service: 5: /etc/init.d/: Permission denied


It sounds like this implementation of "service" doesn't check its
parameters, and it's simply prefixing the first parameter with the string
'/etc/init.d/' before trying to execute the resulting path.

Chris
Reply With Quote
  #4 (permalink)  
Old 09-13-2007
klop
 
Posts: n/a
Default Re: Permission denied to root

On Wed, 12 Sep 2007 10:03:40 +0100, Chris Davies wrote:

[...]

> Chris


Thank you Chris. I will try that.
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 02:10 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0