VectorLinux
October 01, 2014, 07:55:40 am *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Visit our home page for VL info. To search the old message board go to http://vectorlinux.com/forum1. The first VL forum is temporarily offline until we can find a host for it. Thanks for your patience.
 
Now powered by KnowledgeDex.
   Home   Help Search Login Register  
Please support VectorLinux!
Pages: [1] 2
  Print  
Author Topic: [SOLVED]apache php mysql  (Read 5249 times)
nulll
Member
*
Posts: 33


WWW
« on: August 19, 2007, 08:41:47 am »

hi, i have installed apache php and mysql, now how do i move to let them work?
« Last Edit: October 15, 2007, 04:20:24 am by nulll » Logged
nightflier
Administrator
Vectorian
*****
Posts: 4024



« Reply #1 on: August 19, 2007, 12:18:09 pm »

What version of VL?
Did you install from VL repository or other source?
What are you trying to accomplish?
Logged
nulll
Member
*
Posts: 33


WWW
« Reply #2 on: August 19, 2007, 01:20:32 pm »

i have a SOHO 5.8,
i did not find apache + php + mysql in the VL repository,
so i had to install it from the slackware repo.

My goal is to have a php development area on my PC
Logged
rbistolfi
Packager
Vectorian
****
Posts: 2284


« Reply #3 on: August 19, 2007, 02:14:09 pm »

For that task I recommend you to install XAMPP. It is a distribution of PHP, MySQL and Apache configured and ready to use. There is a package in the extra repo:

http://vectorlinux.osuosl.org/veclinux-5.8/extra/net/xammp-1.5.5a-i586-4vl58.tlz

For some reason I was unable to get it with slapt-get, I think there is something wrong with the names there, you can give it a try, may be is just my box.
The repo version is a little old, 1.5.5a, the current XAMPP is 1.6.3. If you are interested in geting the last version, you can get it from here.
It is very easy to install.

If you still want to go with the configurations of the slackware packages I recommend you to find some howto on the net and read it carefully. This is not an easy task. Is not impossible, but requires some experience and patience. The tldp project is a good place to start, the stuff there is always a little old, but you can trust in the contents: http://tldp.org/HOWTO/
Another one could be http://lamphowto.com/ Dont pay attention to the rpm part. The section about configuring the server is pretty good.
Please post questions here if you want to take the long way and you find any troubles Wink. If you take the short one, enjoy XAMPP, I am doing it  Smiley
Hope this help.
« Last Edit: August 19, 2007, 02:19:30 pm by rbistolfi » Logged

"There is a concept which corrupts and upsets all others. I refer not to Evil, whose limited realm is that of ethics; I refer to the infinite."
Jorge Luis Borges, Avatars of the Tortoise.

--
Jumalauta!!
nulll
Member
*
Posts: 33


WWW
« Reply #4 on: October 09, 2007, 04:08:40 pm »

ciao...sorry for being late replying!

so i've installed xampp 1.5 from the repo of my VL SOHO 5.8
so i understand that the dir
/opt/lampp/htdocs/xampp
is the
/var/www/
of the debian systems

i've starded xampp but when i tested it whit
http://localhost in a browser i get this php permission error
Quote
Warning: file_get_contents(lang.tmp) [function.file-get-contents]: failed to open stream: Permission denied in /opt/lampp/htdocs/xampp/index.php on line 2

i've looked to lang.php and it's owned by 1000 and group 1000
who is this user?
what is the apache user? (in debian is www-data)
the file lang.php is readeble from ugo...so why this php warning?

Logged
newt
Vectorian
****
Posts: 1132



« Reply #5 on: October 09, 2007, 07:04:59 pm »

Since xampp is intended to be a self-contained web development package, and is not secure (by default), it's root directory is stored within it's own path (/opt/lampp/...).  For all intents and purposes, this is the equivalent to /var/www.  xampp is not meant to be used in a production environment, however there is an "easy" way to improve security in xampp.

User 1000 is typically the first user you create on a VL system.  During the VL install you may have created a normal user after which you would have been asked what user number to assign to that user; by default it's 1000.  If you went with the default user number then user 1000 is you.  I'm not sure what group 1000 is.  Perhaps it's the default user group; in other words, perhaps it's the group 'user' in a VL system.

I'm not sure what the default apache user is since xampp is not created by VL but rather apachefriends.org.  If I had to guess (and I do) then I would guess that the default apache user is root or your username, but it's just a guess.

The permission problem is troublesome since I would expect a default installation of xampp to work correctly out-of-the-box.  It looks like filesystem access is not implemented correctly in php.  This may be caused by a previous installation of php.  You said that you had installed php from linuxpackages; did you happen to uninstall that package before installing xampp?  The problem could stem from that.

Hope this helps!
Logged
nulll
Member
*
Posts: 33


WWW
« Reply #6 on: October 09, 2007, 11:44:07 pm »

Quote
The permission problem is troublesome since I would expect a default installation of xampp to work correctly out-of-the-box.  It looks like filesystem access is not implemented correctly in php.  This may be caused by a previous installation of php.  You said that you had installed php from linuxpackages; did you happen to uninstall that package before installing xampp?  The problem could stem from that.
mmm since my first post i've totally re-installed VL SOHO 5.8 and i haven't installed apache and php and mysql separatly...so it's not that...
have you got other suggestions?
Logged
rbistolfi
Packager
Vectorian
****
Posts: 2284


« Reply #7 on: October 10, 2007, 06:33:19 am »

Check the file lang.tmp. Make sure xampp has read permissions over that file. Check the contents too, it should be just "en" without quotes. Sorry if I cant give more detailed info, I usually delete the xampp folder. The real public folder is /opt/xampp/htdocs. xampp is a directory which stores some examples about what you can do with xampp. The index.php file in htdocs redirects you to that dir.

Let us know how its going.

BTW, the package in the repo is a little old, if you like, you can download the latest version from apachefriends.org. The install is very easy:
Code:
tar xvfz xampp-x.x.x.x.tar.gz -C /opt
from the directory where you downloaded the tarball.

Logged

"There is a concept which corrupts and upsets all others. I refer not to Evil, whose limited realm is that of ethics; I refer to the infinite."
Jorge Luis Borges, Avatars of the Tortoise.

--
Jumalauta!!
nulll
Member
*
Posts: 33


WWW
« Reply #8 on: October 10, 2007, 10:31:27 am »

uff
the permessions of the dir (and the lang.php) seem to bee ok (read to UGO).
So i've removed xampp from gslapt and downloaded and installed
xampp-linux-1.6.4.tar.gz
width
tar xvfz xampp-linux-1.6.4.tar.gz -C /opt
as root
and then i've tryed to
/opt/lampp/lampp start

but konsole returned
Quote
-bash: /opt/lampp/lampp: No such file or directory

i've searched inside the /opt/lampp dir but i can't find a file called lampp!!!

suggestions?
Logged
rbistolfi
Packager
Vectorian
****
Posts: 2284


« Reply #9 on: October 10, 2007, 11:00:03 am »

The executable should be there, that seems like a faulty extract. Are you sure you downloaded the right package? This is very weird.
Logged

"There is a concept which corrupts and upsets all others. I refer not to Evil, whose limited realm is that of ethics; I refer to the infinite."
Jorge Luis Borges, Avatars of the Tortoise.

--
Jumalauta!!
exeterdad
Packager
Vectorian
****
Posts: 2046



« Reply #10 on: October 10, 2007, 12:05:45 pm »

I agree... weird.  Try installing again?
If it doesn't work could you give us the output of:
Quote
ls /opt/lampp
Logged
nulll
Member
*
Posts: 33


WWW
« Reply #11 on: October 10, 2007, 12:56:30 pm »

i've downloaded again the tarball and i've reinstalled...now it works!
i think that before i must have downloaded the wrong one (maybe the update one?)

now how can i change the configuration files of apache and php?
how can i choose to use php4 insted of php5?
Logged
nulll
Member
*
Posts: 33


WWW
« Reply #12 on: October 10, 2007, 01:02:23 pm »

ok all my answers are here
http://www.apachefriends.org/en/xampp-linux.html#611
thanks! Wink
Logged
nulll
Member
*
Posts: 33


WWW
« Reply #13 on: October 10, 2007, 01:25:01 pm »

i've tried to make php write a file...this was to know what was the owner and the group of apache...
in ubuntu/debian is www-data (owner and group)
but the file created via php has nobody as owner and nogroup as group...
how can i change this?

what about php-cli (php from command line?)
Logged
rbistolfi
Packager
Vectorian
****
Posts: 2284


« Reply #14 on: October 10, 2007, 03:38:06 pm »

i've tried to make php write a file...this was to know what was the owner and the group of apache...
in ubuntu/debian is www-data (owner and group)
but the file created via php has nobody as owner and nogroup as group...
how can i change this?

I guess you could just create a user/group and give the proper permissions to php. Sorry if I cant help you more, I never did something like that before.

Quote
what about php-cli (php from command line?)

I am not at my box atm, but I think XAMPP ships a special binary for cle, called php-cli. Anyway, try writing a regular php file just for testing, give it execution rights with chmod +x <file.php> and then try
Code:
php /path/to/the/file.php
Give it a try with other binaries in the php dir of xampp. Sorry if this is a little vague   Sad, I am not at my box atm to give more exact info.
Logged

"There is a concept which corrupts and upsets all others. I refer not to Evil, whose limited realm is that of ethics; I refer to the infinite."
Jorge Luis Borges, Avatars of the Tortoise.

--
Jumalauta!!
Pages: [1] 2
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!