Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Now I have a case study working on php to create a web-based for configure the SLES10 network interface such as ip, netmask, gateway, dns and etc..
I know that Webmin is written in perl, but i want to write in php.
I tried to write some shell run with exec in php page, but they was something wrong "permission denied" or something similar.
I followed your instruction, but there was the same error as i shown you. Em.. I forgot to tell u the result of that command to the web interface as below:
Code:
Shutting down network interfaces:
eth0 device: Advanced Micro Devices [AMD] 79c970 [PCnet32 LANCE] (rev 10)
eth0 configuration: eth-id-00:0c:29:19:fa:65
[1A..doneShutting down service network . . . . . . . . . . . . . . ...done
Setting up network interfaces:
lo
lo IP address: 127.0.0.1/8
Checking for network time protocol daemon (NTPD): ..unused
eth0 device: Advanced Micro Devices [AMD] 79c970 [PCnet32 LANCE] (rev 10)
eth0 configuration: eth-id-00:0c:29:19:fa:65
eth0 IP address: 192.168.169.3/24
Checking for network time protocol daemon (NTPD): ..unused
eth0 device: Advanced Micro Devices [AMD] 79c970 [PCnet32 LANCE] (rev 10)
eth0 configuration: eth-id-00:0c:29:19:fa:65
eth0 IP address: 192.168.169.3/24
[1A..doneSetting up service network . . . . . . . . . . . . . . . ...done
Remember that I'm using SLES10.2 and I install sudo-1.7.0 on my Suse box. Do I have something wrong with the installation of sudo-1.7.0? What should I do next? Please?
I used command "su wwwrun", but there's nothing happen and in system log is "Feb 24 01:52:26 SLES10 su: (to wwwrun) root on /dev/pts/0
" and whoami is still "root".
But we i created a user name "test", and "su test", then log: "Feb 24 01:52:40 SLES10 su: (to test) root on /dev/pts/0"
and whoami is "test".
Then i used "su root" and type root's password. whoami is changed to "root".
That is because the user wwwrun does not have a valid shell. You can use:
Code:
sudo -u wwwrun -s
to become wwwrun using the current SHELL.
Or you can edit /etc/passwd and give wwwrun a valid shell (replace /bin/false with /bin/sh), but that is a security risk.
I've found a box running openSuse 10.3 and tested the above setup. It works either with "/etc/.init.d/network ..." or "/sbin/service network ...", with the following in /etc/sudoers:
Of course it's better to use /etc/init.d/<service-name>, specifying the service you want to manage, because using /sbin/service you can mess with all the available services
If you still have problems, I guess you're running some security software (apparmor?) that is preventing wwwrun to run sudo commands.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.