[CS-FSLUG] SHELP!!!

N. Thompson n.thomp at sasktel.net
Thu Jul 22 15:11:05 CDT 2004


On July 22, 2004 10:00 am, Tim Young wrote:
> The problem is actually on the command-line itself.
>
> konsole -e   sudo /sbin/ifdown eth0; /sbin/ifup eth0&
>
> Bash reads the command from left to right.
>
> konsole -e sudo /sbin/ifdown eth0
>
> When it gets to the ; it says, "this comand has ended" and it sends the
> command to the xterm.  Then it runs /sbin/ifup in the background.
>
> The next problem is that sudo only accepts one command at a time.  You will
> either need to bake a bash script that groups them al together or:
>
> konsole -e sudo bash -c "/sbin/ifdown eth0 ; ifup eth0"
>
> Of course, allowing someone to have permission to sudo a bash shell is
> basically allowing them to have root access.  :)
>
> The better way is to have a bash script that runs that you can give them
> sudo access to.
>
> 	- Tim

I don't know if this will be of much help but when I was working with Java in 
Linux I had to use : (colon) as a command separator when compiling or 
executing instead of ; (semicolon).

Does that make any difference?

[snip]




More information about the Christiansource mailing list