PDA

View Full Version : Eclipse PHPEclipse xampp root


u_b_u_&_i_b_me
December 25th, 2005, 08:09 PM
Firstly I have successfully installed Eclipse 3.1, PHP5, PHPEclipse and xampp in their appropriate directories. However in order to start and stop xampp within PHPEclipse I need to either be a root user or use the sudo command. Unfortunately, I can not execute a sudo command within the menu options in the PHPEclipse plugin to start and stop xampp.

In addition I have also uninstalled xampp and install Apache, MySQL and PHP through the Synaptic manager. Again in order to control Apache, MySQL and PHP you have to be a root user. However PHPEclipse in running under a non-root user and I need to be able to start, stop and control Apache, MySQL and/or PHP.

I have tried a number of things such as changing permission, etc.. Are there any ideas how to solve this problem?

The instruction at
http://www.plog4u.org/index.php/Using_PHPEclipse:Installation:XAMPP_Example_Instal lation
are pretty good, however they focus more on Windows than Linux let alone Ubuntu (without a root user)


Thanks
ubu & i b me

geek.de.nz
February 12th, 2006, 06:20 AM
Firstly I have successfully installed Eclipse 3.1, PHP5, ...

...

...

The instruction at
http://www.plog4u.org/index.php/Using_PHPEclipse:Installation:XAMPP_Example_Instal lation
are pretty good, however they focus more on Windows than Linux let alone Ubuntu (without a root user)


Thanks
ubu & i b me

Try http://http://ubuntuforums.org/showthread.php?t=104905&highlight=phpeclipse
;)

SreckoMicic
April 1st, 2006, 07:45 AM
I think that u can forget about starting xampp with buttons on php IDE. Just use classic comand.

Riddian
July 15th, 2006, 06:09 AM
It can be done! Well at least this is a simple workaround I came up with anyway but it works none the less.

Just create two shell script, called something like xampp_start.sh and xampp_stop.sh.

In the start script enter:

#!/bin/bash
gksudo /opt/lampp/lampp start

For the stop script enter:

#!/bin/bash
gksudo /opt/lampp/lampp stop

You can do the same for all the other buttons if you find you need them.

ednark
July 11th, 2008, 09:57 PM
A small tweak. Create only one extra file with the gksudo. In Eclipse you can now set the Location field to this one file and use the Arguments field to pass through directly to lampp as you would if you didn't use this file.


sudolampp.sh

#!/bin/bash
gksudo /opt/lampp/lampp $1


Location: /opt/lampp/sudolampp.sh
Arguments: start

Location: /opt/lampp/sudolampp.sh
Arguments: stop

Location: /opt/lampp/sudolampp.sh
Arguments: startapache

Location: /opt/lampp/sudolampp.sh
Arguments: startmysql

cecretnamezone
August 19th, 2008, 06:34 AM
hello! I do everything as u say but I have a problem like this:"You need to start XAMPP as root!"->so how can i start it with root?

intheback
July 31st, 2010, 05:19 PM
I'm literally just started using linux for my website development, and excuse me if this seems stupid, but i just put into terminal:

sudo chmod -R 777 /opt/lampp/htdocs/thedirectoythatineededpermissionschanged

and that changed the permissions of the folder. After that, Eclipse let me use it no problem.

Sorry if this is stupid, but it seemed to work for me.