How to configure Apache2 on Bionic (and the entire LAMP)?

How to install, configure and use servers in Puppy Linux and its derivatives

Moderator: Forum moderators

Post Reply
User avatar
mohittomar13
Posts: 51
Joined: Wed Jul 29, 2020 5:12 pm
Location: New Delhi - INDIA
Has thanked: 17 times
Been thanked: 3 times

How to configure Apache2 on Bionic (and the entire LAMP)?

Post by mohittomar13 »

Hi..!

I recently installed puppy (Description in the Signature below).

The main reason for switching from Kubuntu to Puppy was speed. Now I'm not able to configure LAMP on my machine. I followed the instructions given on this link https://internetofhomethings.com/homethings/?p=1429. I couldn't run the following command from the instructions on this page

Code: Select all

 ln -s /etc/apache2/sites-available/default /etc/apache2/sites-enabled/
as on my system I have this file given below

Code: Select all

ln -s /etc/apache2/sites-available/default-ssl.conf

and running the below command generates the error as shown:

Code: Select all

root@puppyPC5832:~# /etc/init.d/apache2 restart
 * Restarting Apache httpd web server apache2                                                [fail] 
 * The apache2 configtest failed.
Output of config test was:
AH00534: apache2: Configuration error: No MPM loaded.
Action 'configtest' failed.
The Apache error log may have more information.

can someone please help me to configure the apache2 on puppy. On kubuntu it was a few steps and thus I never learnt the in-depth process and doesn't know what goes on behind the scenes. I just used to install lamp and start using it.

Though I have intermediate understanding of how linux files are organised and how to run commands, running a server is something new to me. I'm learning PHP as a hobby and thus need it to work.

I have the following packages installed:

Code: Select all

apache2_2.4.29
apache2-data_2.4.29
apache2-bin_2.4.29
apache2-utils_2.4.29
Thanks in advance for any help. :thumbup:

Laptop: Dell 3568
CPU: intel i3 6006U
RAM: 12 Gigs
4GB-micron + 8GB-kingston

yeah, it works.. :D
HDD: 1TB
OS: Tripple boot- (Windows-10, Xubuntu-20.4LTs, Bionic Puppy) 64Bit

User avatar
rockedge
Site Admin
Posts: 5727
Joined: Mon Dec 02, 2019 1:38 am
Location: Connecticut,U.S.A.
Has thanked: 1998 times
Been thanked: 2101 times
Contact:

Re: How to configure Apache2 on Bionic (and the entire LAMP)

Post by rockedge »

I can help you. There are some extra steps needed to get the LAMP going smoothly but once done Puppy Linux runs a LAMP very well and stable/reliable.

I need to step out a moment and when I return I will detail the steps needed.
User avatar
mikewalsh
Moderator
Posts: 5579
Joined: Tue Dec 03, 2019 1:40 pm
Location: King's Lynn, UK
Has thanked: 570 times
Been thanked: 1684 times

Re: How to configure Apache2 on Bionic (and the entire LAMP)

Post by mikewalsh »

@ mohittomar13:-

Hallo, hallo... Nice to see you here! Getting fed-up with TSG? :D

You've joined at the right time; we're only just getting the new forum organised, though not that many of the regulars have migrated across from the old Murga-Linux forum as yet.

I thought you were a solid Kubuntu man, BTW? You'll find Puppy's a wee bit more anarchic, I'm afraid, though a lot of fun for all that. Stick around...!!

(LAMP's a good query for here, y'know. AFAIK this forum is running on top of a Puppy LAMP stack....)

Rockedge'll put you straight. :thumbup:


Mike. ;)

Puppy "stuff" ~ MORE Puppy "stuff" ~ ....and MORE! :D
_______________________________________________________

Image

User avatar
mohittomar13
Posts: 51
Joined: Wed Jul 29, 2020 5:12 pm
Location: New Delhi - INDIA
Has thanked: 17 times
Been thanked: 3 times

Re: How to configure Apache2 on Bionic (and the entire LAMP)?

Post by mohittomar13 »

@Mike

hi Mike..!! I'm really happy to see you here. Finding old friends at a new place gives a kind of confidence.. hahahaha.... :lol: :lol: :lol:

To be honest, one of the many reasons for me to switch from Kubuntu to Puppy is your praise about puppy on TSG. I read a lot of your posts. I used puppy in the past and was really impressed with the speed. Opening firefox takes about.. hmm... 0.3 secs on puppy.. :D :D and the Terminal takes 0.1 sec. But not really fed up with TSG it's just that I think forums@rockedge is the best place to ask puppy related questions.

I always liked puppy but chose Kubuntu as the UI is similar to windows and I was new to linux at that time. But now after using Linux for many years I think I can finally switch. I'm a solid Linux man :mrgreen: :mrgreen:

Really nice to see you.. :thumbup: :thumbup2: :thumbup: :thumbup2:

Laptop: Dell 3568
CPU: intel i3 6006U
RAM: 12 Gigs
4GB-micron + 8GB-kingston

yeah, it works.. :D
HDD: 1TB
OS: Tripple boot- (Windows-10, Xubuntu-20.4LTs, Bionic Puppy) 64Bit

User avatar
rockedge
Site Admin
Posts: 5727
Joined: Mon Dec 02, 2019 1:38 am
Location: Connecticut,U.S.A.
Has thanked: 1998 times
Been thanked: 2101 times
Contact:

Re: How to configure Apache2 on Bionic (and the entire LAMP)?

Post by rockedge »

I have started a thread with some rough steps to get the Apache2 web server going here:

viewtopic.php?f=85&t=374
User avatar
CasparPup
Posts: 3
Joined: Sat Aug 22, 2020 11:11 am
Location: Holland
Contact:

Re: How to configure Apache2 on Bionic (and the entire LAMP)?

Post by CasparPup »

Some time ago I've tried to install Apache, PHP7 and MySql on Puppy (I believe it was Bionic) from scratch. I managed to get Apache and PHP7 working by installing the files from PPM but I failed to get MySql working. I didn't wrote it down somewhere so I will have another go at it on Fossa. Because my time ran out I had to switch to Ubuntu where the install was pretty easy. I was learning Symfony so I had to have a 'quick fix' for a server package. Sorry about that :?
I don' t want old stuff so my goal now is: Fossa+ Apache2 + PHP7 and MySql. As Admin I want to use Adminer, not PHPAdmin.
Now somewhere I've heard about a replacement for apt-install that was called dpkg I believe so you could install packages from the Ubuntu repository, but I can't seem to find a manual for that.
Another fast way to get a server up and running is the live server from Dog Linux: works like a dream I must say. You can download it here: https://github.com/mbinnun/MBPUP/blob/master/README.md. But.. it's not so different from a normal Ubuntu installation and it's really made for a server package 'on the go'. But it saved my xxx multiple times to be honest.
And how about installing it from .tar with configure, make and make install? Haven't figured that out yet.

I'll keep y'all posted.

User avatar
rockedge
Site Admin
Posts: 5727
Joined: Mon Dec 02, 2019 1:38 am
Location: Connecticut,U.S.A.
Has thanked: 1998 times
Been thanked: 2101 times
Contact:

Re: How to configure Apache2 on Bionic (and the entire LAMP)?

Post by rockedge »

you can install the mysql server from the PPM, but you will need to do some steps manually to configure and start it. Or run this script:

Code: Select all

#!/bin/sh

# # create the user for the mysql server
adduser mysql -D

# install the mysql server and intialize it
pkg add mariadb mariadb-server

# create run time directories and set the correct permissions and ownership
[ ! -d  /var/run/mysqld ]  && mkdir /var/run/mysqld

chown -R mysql /var/run/mysqld
mysql_install_db
sleep 2
mysqld  &
sleep 2
 
 echo "Make sure that NOBODY can access the server without a password"
 
# Make sure that NOBODY can access the server without a password
mysql -e "UPDATE mysql.user SET Password = PASSWORD('admin') WHERE User = 'root'"

# Kill the anonymous users
mysql -e "DROP USER ''@'localhost'"

# Because our hostname varies we'll use some Bash magic here.
mysql -e "DROP USER ''@'$(hostname)'"

# Make our changes take effect
mysql -e "FLUSH PRIVILEGES"

echo "Finished stage 1. mariadb is installed"

you can do each step manually as well. If you run into a message of depreciation on the usage of:

Code: Select all

mysql -e "UPDATE mysql.user SET Password = PASSWORD('admin') WHERE User = 'root'"

we can adjust the statement.

Also if you want to use the PPM and not Pkg that will work just as well, and you will need to do those manual steps using this method as well.

User avatar
CasparPup
Posts: 3
Joined: Sat Aug 22, 2020 11:11 am
Location: Holland
Contact:

Re: How to configure Apache2 on Bionic (and the entire LAMP)?

Post by CasparPup »

Well I'm always a bit lazy and I found a Xampp 7.3.3-1 sfs that seems to work fine. I've tested it with Puppy Fossa and dpup Buster. I've put it on my Google drive https://drive.google.com/file/d/17rq-n_ ... sp=sharing.

Post Reply

Return to “Servers”