ubuntu -> compiling -> make - install (of AMP)

ubuntu -> compiling -> make - install (of AMP)

by ryan sanders -
Number of replies: 14

having some issues with repo's for centos and ubuntu.  and in getting updated versions of AMP software onto the VPS. primary issue is with conflicts. and/or setting stuff one way vs another way.  

so going at it from scratch almost...  purgeing / deleting / unisntalling / removing, Apache, mysql, and php from ubuntu and downloading source code -> compling, -> to installing via SSH

i came across following link https://www.virgohacks.net/install-apache-2-4-mysql-5-6-php-5-5-source-ubuntu-14-04/ went through it.  then realized i need some additional stuff... and removal of extra crud.  for apache, mysql, and php. 

quick note: iztamar (hope i got your name right) i am starting to see more and more mariaDB vs mysql, more i search. interesting it is.  though still wanting to avoid lightspeed, ngix, mariaDB. they are still above my head. 

=================

my initial current ubuntu install is getting pretty ugly, of failed attempts and then attempts to uninstall and reinstall.  along with having some "preset" stuff that was set by the VPS ubuntu image of the OS. 

apache2.4 = seemed to go ok, but was hoping for information to set on the "./configure ((options here))"

mysql = i think i am better off using "apt get" even mysql website denotes using pre-install stuff. running into about 20 different errors / warnings that come up during "./configure", "make", and "make install"   mysql documentation for "./configure ((options))"  is a tad lacking. and i honestly do not know suggested configuration options to use / set. 

php5.5.22 and php5.6.x = yikes! so much to sift through for "./configure ((options))" finally started narrowing things down. but having some issues with "pecl" starting to realize not really worth third party "pecl" extensions. everything that use to be a "pecl" extension has been re-adjusted and put into php5.5 or above directly within the source code already.

some additional issues... is with "compliers / packages" required to compile source with ./configure, make, make install, make test, make check.  i have just been going directly to xyz.com website using a wget xyz.tar.gz,  then gzip the xyz.tar.gz,  and running a make, and make install.  the sudo apt-get install xyz seems to be giving older software versions of the compliers / packages "hence" manual installing them :/ so i can compile the newer versions of apache, mysql, php. 

=================

to above.... just want a straight cut and dry installations. with just what is needed for moodle 2.7, 2.8, 2.9  no need for vhost, and handling multi websites. easy enough just to drop www.mysite.com/moodle1  www.mysite.com/moodle2   or moodle1.mysite.com or moodle2.mysite.com

any suggestions for....

./configure ((options))  for apache2.4, mysql5.5,  php5.5 or php5.6? 

any suggestions for dealing with extra compilers / packages / libraries? 

Average of ratings: -
In reply to ryan sanders

Re: ubuntu -> compiling -> make - install (of AMP)

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

I cannot begin to imagine why you want to build PHP from scratch. It's not impossible, but it's far from trivial and you are blowing away all the (very real) advantages of running the 'standard' build which comes with loads of free testing by the thousands of others who use it. 

The MySQL website actually tells you not to build it yourself as you probably won't do it properly!

My advice - don't do that wink

Average of ratings: Useful (1)
In reply to ryan sanders

Re: ubuntu -> compiling -> make - install (of AMP)

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
Hi Ryan

Why have you chosen a polluted (heavily patched) distribution like Ubuntu for such a clean installation? (Look for "Why Linus Torvalds doesn't use Ubuntu or Debian" on YouTube.) I would go for old school Slackware or FreeBSD for such cases. In fact, compling from source is still common practice in those systems.

I didn't get why you need to take this path. If it is to learn the Linux system, take a look at Linux From Scratch.
Average of ratings: Useful (1)
In reply to Visvanath Ratnaweera

Re: ubuntu -> compiling -> make - install (of AMP)

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

True - but in the "real world" nobody actually does that. Everybody uses Ubuntu or CentOS and we know it works because it works for everybody else that does the same thing. A good case for going with the flow.

Of course, as an academic exercise you can build pretty much the whole system from source like, as you say, we did in the good old days. To be honest, I don't remember it being much fun and you were lucky if you ended up with a stable system.

In reply to Howard Miller

Re: ubuntu -> compiling -> make - install (of AMP)

by Marcus Green -
Picture of Core developers Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers

A group of old software developers talking...

Dev1: "When I were a lad we didn't have these fancy IDE's and compilers, we just had assembler"

Dev2: "Assembler, Assembler, you were lucky, all we had was zeros and ones"

Dev3 "Zeroes, and Ones, Zeroes AND Ones, we dreamed of Zeroes AND ones, all we had were zeroes!"

Average of ratings: Useful (1)
In reply to Marcus Green

Re: ubuntu -> compiling -> make - install (of AMP)

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
In reply to Visvanath Ratnaweera

Re: ubuntu -> compiling -> make - install (of AMP)

by ryan sanders -
thank you all for your replies. 


facing linux and hosting provider. and trying to figure out what "tricks" they did to the software, that is pre-installed *arghs*  compiling was last ditch effort. of getting away from pre-compiled stuff, that was giving my grief on non standard hosting provider setup it would have seemed.  plesk / parallel software *shakes head no*  to many mismatch settings to try and deal with all at once. 

i almost thought i had linux snipped, but then it continue to draw out, to extra problems kept arising, enough was enough, so i switched to a windows VPS on www.1and1.com nearlly have it finally after a couple days. and a couple re-images.  ((finding the ugly bugs along the way 0f plesk / parallels crud))  


In reply to ryan sanders

Re: ubuntu -> compiling -> make - install (of AMP)

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
Hi Ryan

Good to know that you are finally there, through doors or Windows!
wink

As an advocate of Free Software I am very much interested in understanding what went wrong with your Linux journey. My main problem is that I don't understand your language. So please reply only if you don't mind and are in peace of mind. Otherwise just ignore.

> facing linux and hosting provider. and trying to figure out what "tricks" they did to the software, that is pre-installed *arghs* compiling was last ditch effort. of getting away from pre-compiled stuff, that was giving my grief on non standard hosting provider setup it would have seemed. plesk / parallel software *shakes head no* to many mismatch settings to try and deal with all at once.

I would understand that to mean:
a) You tried to install in an environment provided by a hosting provider
b) the environment was Plesk/Parallels
c) they provided you a pre-packaged, socalled one-click, Moodle
d) the provider was non-standard (in which way? Plesk/Paralles are well-known)
e) Moodle refused to run due to mismathes (what were the error messages?)
f) You tried to get ride of them all at once (how?) and failed

> i almost thought i had linux snipped, but then it continue to draw out, to extra problems kept arising,
g) So Moodle almost ran (how far?)
h) then stopped and came with additional problems (what happened in between?)

> enough was enough, so i switched to a windows VPS on www.1and1.com nearlly have it finally after a couple days. and a couple re-images. ((finding the ugly bugs along the way 0f plesk / parallels crud))
i) Windows VPS at 1and1.com almost works (who was the Linux hoster?)
j) Moodle on Windows took a couple of days to run (which is prohibitive, any explanations?)
h) You needed to "re-image" Windows a couple of times (what is "re-imaging"?)
k) You found a bug in Plesk/Paralles (willing to shere it with us?)

As already mentioned, we seem to talk different languages. Possibly the former British colonies developed (or stood still) in different directions. Coming back to the IT age, this is the kind of language the Unixers speak: https://docs.moodle.org/28/en/Step-by-step_Installation_Guide_for_Ubuntu. Please don't bother, if the combined effect is "too much" for you.
;-'(
In reply to Visvanath Ratnaweera

Re: ubuntu -> compiling -> make - install (of AMP)

by ryan sanders -

easier to copy / paste for reply to you see stuff in bold as my reply 

As an advocate of Free Software I am very much interested in understanding what went wrong with your Linux journey. My main problem is that I don't understand your language. So please reply only if you don't mind and are in peace of mind. Otherwise just ignore.

> facing linux and hosting provider. and trying to figure out what "tricks" they did to the software, that is pre-installed *arghs* compiling was last ditch effort. of getting away from pre-compiled stuff, that was giving my grief on non standard hosting provider setup it would have seemed. plesk / parallel software *shakes head no* to many mismatch settings to try and deal with all at once.

I would understand that to mean:
a) You tried to install in an environment provided by a hosting provider YES
b) the environment was Plesk/Parallels YES and also with out plesk. just Parallels and ubunutu, centos (parrallels = remote control of server in a sense) plesk = bundling of one click stuff. 
c) they provided you a pre-packaged, socalled one-click, Moodle  one click outdated AMP that only worked for there parrallels / plesl,  YES to moodle one click install via plesk
d) the provider was non-standard (in which way? Plesk/Paralles are well-known) out data AMP, with variables for pretty much everything in plesk format. where you might find php.ini .htaccess .conf files are some place else in plesk notations. and/or parallels tied into them. other words specific parrallel variables attached
e) Moodle refused to run due to mismathes (what were the error messages?) AMP (apache, mysql, php)  
f) You tried to get ride of them all at once (how?) and failed one at time of A or M or P to see were issues aroused and how they would behave. and were there might be errors. issue was getting updated AMP to work with Parrallels / Plesk using various REPO's,  different REPO's tried just by themselves along with combining different REPO's together. 

> i almost thought i had linux snipped, but then it continue to draw out, to extra problems kept arising,
g) So Moodle almost ran (how far?) i want to say i got moodle to RUN. BUT i lost FTP access completely including, was not able to set extensions for PHP, without moodle crashing opcache, intl, xmlrpc, and 1 or 2 other extensions of php. was not able to adjust any PHP setting without PHP crashing. was not able to figure out Plesk variables and file names and were they stored the files / settings.
h) then stopped and came with additional problems (what happened in between?)

> enough was enough, so i switched to a windows VPS on www.1and1.com nearlly have it finally after a couple days. and a couple re-images. ((finding the ugly bugs along the way 0f plesk / parallels crud))
i) Windows VPS at 1and1.com almost works (who was the Linux hoster?) www.1and1.com = linux hoster
j) Moodle on Windows took a couple of days to run (which is prohibitive, any explanations?) exact same cost, exact same server specs, just swamping LAMP package for windows, IIS, mysql, php package.  windows bonus = remote desktop err graphical user interface.  actual windows package is easier to adjust in parrallels. for if you have a windows 2008 server crash. and need to do a repiar mode.
h) You needed to "re-image" Windows a couple of times (what is "re-imaging"?) re image = format and reinstall in a sense of basic package that www.1and1.com intially setups on a VPS
k) You found a bug in Plesk/Paralles (willing to shere it with us?) see other thread... Moodle in English

/ General / Installation help / 1and1.com + windows VPS + moodle = ???



As already mentioned, we seem to talk different languages. Possibly the former British colonies developed (or stood still) in different directions. Coming back to the IT age, this is the kind of language the Unixers speak: https://docs.moodle.org/28/en/Step-by-step_Installation_Guide_for_Ubuntu. Please don't bother, if the combined effect is "too much" for you.  Boy i wish that worked right off from the get go. or i would not of started this thread. part of reason, of trying another re-image but instead of trying centos try ubuntu.  it is no longer funny how many re-images i have done. trying to figure out were issues came up at. granted i will put blame on myself for not being a linux person. i can hunt and peck my way through.  but i honestly was not having any luck at all. and documentation was poor of plesk / parrallals. 

here *hold my drink* watch me do this on a virtual software (hyper-V on windows pro 8.1, and give me centos, ubuntu in hyper-V) here on my local desk computer  and having up in running in an hour.  www.1and1.com VPS *meh* forget it.  

www.1and1.com = both parrallels and plesk setup for a "hosting provider" as a SOHO (small office / home office) setup running multi word press sites, and multi simple HTM / HTML sites.  not even sure latest and greatest word press would even run (have not tried it).

In reply to ryan sanders

Re: ubuntu -> compiling -> make - install (of AMP)

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
Hi Ryan

Thanks for taking time for all the clarifications! Summarizing I would say the cause of the problems was how the user interface at your hosting service integrated the software components, including Moodle. The manual installation as in that step-by-step guide for Ubuntu works as documented, that I know.

Wish you good luck in your new approach, with Windows, IIS, etc.

P.S. Since you invest so much in quoting the previous post, why don't you follow a known method, like https://en.wikipedia.org/wiki/Usenet_quoting ?
In reply to ryan sanders

Re: ubuntu -> compiling -> make - install (of AMP)

by Ken Task -
Picture of Particularly helpful Moodlers

Many moons ago, compiled AMP stack ... Fedora flavored before discovery of CentOS and LTS versions.   Found a gentleman who shared exactly how to:

http://lamphowto.com/

The disadvantage to that approach, can't use the OS's package manager to get security updates ... unless one set that up manually as well.   If security issue was serious enough, one had to re-compile ALL three (Apache/MySQL/PHP) all over again.  Loosing 'tweaks' added to the system after initial compile was always present.   Thus, all in all ... good learning exercise, but the pre-compiled binaries provided by repos were 'just as good' and, more importantly, updatable using package manager.

'spirit of sharing', Ken

In reply to Ken Task

Re: ubuntu -> compiling -> make - install (of AMP)

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
Ken

That is basically what Howard was saying too. The binary packages from a repo is much more convenient than compiling from source. The difference could be huge when it comes to maintaining the server. I agree.

My point was, if there is a compelling reason, compiling from source is doable. The simple trick is to construct your own set of shell scripts for that!

If we start discussing why one would need to compile and how he could avoid it, we'll be going too far. That is why I suggested to listen to Ryan, why he needs it. Posted a couple of minutes ago a message requesting more information from him.
In reply to Ken Task

Re: ubuntu -> compiling -> make - install (of AMP)

by ryan sanders -

easier for me to copy paste, see my reply in bold

Many moons ago, compiled AMP stack ... Fedora flavored before discovery of CentOS and LTS versions.   Found a gentleman who shared exactly how to:

http://lamphowto.com/

the link is outdated.  seeing comments of apache and httpd as different RPM's  (depends on linux flavor using). but not explanation.

/etc/my.cnf for mysql for www.1and1.com they were there, but they had to be plesk or parrallel versions. (i do not remember exactly)

http://lamphowto.com/lampssl.html

seems a better complete version to follow granted outdata. but still. more near up todate. as far as what commands to use (substituting version numbers of AMP for newer stuff). 

The disadvantage to that approach, can't use the OS's package manager to get security updates ... unless one set that up manually as well.   If security issue was serious enough, one had to re-compile ALL three (Apache/MySQL/PHP) all over again.  Loosing 'tweaks' added to the system after initial compile was always present.   Thus, all in all ... good learning exercise, but the pre-compiled binaries provided by repos were 'just as good' and, more importantly, updatable using package manager.

i was purposely wanting to lose tweeks! tweaks coming from www.1and1.com and some of the different REPO's (repostories) tweaks. that were conflicting with one another. hence seeking compiling.   to note yes mysql = using pre-compiled stuff.  but apache/httpd  and php different story altogether. still some issues with plesk / parrallel software in the mix though, that i could not figure out. more time yes, but not what i am wanting to do. 

In reply to ryan sanders

Re: ubuntu -> compiling -> make - install (of AMP)

by Ken Task -
Picture of Particularly helpful Moodlers

If you have a moodle server up, go look at the PHP info link and atop the phpinfo, one will see how that installation of PHP was compiled when made into a binary (package manager) any flavor.   That's what Mr. Timberlake's **OLD** web page on how to build LAMP used to look like.  A section on PHP, a section on compiling Apache, and a section on compiling MySQL ... the 'fun' was finding all those 'switches' one should have included when building so that Apache could talk to PHP/MySQL and vice versa.

Tweaks ... once you get a moodle site up and running ... AND USED ... there will be tweaks - PERIOD.  Defaults for php.ini for example.   Another ... my,cnf ... a busy site *WILL* get over the 151 connections default.  InnoDB settings will also have to be 'tweaked'.  On a new server/fresh install, now-a-days I do those 'tweaks' in advance of much usage ... knowing full well they will be "required" later.

Repository conflicts are always a possibility but they can be almost negated IF one learns how to use the package manager ... enabled/disabled, priorities, others for yum on CentOS/Fedora.

No offense, but sometimes, it appears to me you are you're own worst enemy.  That's OK ... been there done that myself!  Until I learned to slow down and concentrate more on one approach to the very end.

'spirit of sharing', Ken

In reply to Howard Miller

Re: ubuntu -> compiling -> make - install (of AMP)

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
Howard

> but in the "real world" nobody actually does that

OK, you are right that not many do that any more. Stil, I know two FreeBSD cracks doing it all the time, and very accurate, flexible and stable their systems are. And one more Unix allrounder doing it on different Unix flavours.

> Everybody uses Ubuntu or CentOS and we know it works because it works for everybody else that does the same thing. A good case for going with the flow.

I too got used to binary packages and must say that they are extremely stable. The down side is that if you need a special combination of versions, either you need to do do all sorts of risky things or back to the roots.

> Of course, as an academic exercise you can build pretty much the whole system from source like, as you say, we did in the good old days. To be honest, I don't remember it being much fun and you were lucky if you ended up with a stable system.

You are wrong about source compliation was not fun. I had a set of shell scripts to compile, install and test the AMP stack on Slackware. If any of those version, modules, etc. need to be changed, either they were parametrized or needed to edit some highly-readable shell script and re-run. I was fun! And gave an ides of the system performance _before_ you run anything.

Anyway, we are digressing towards the purpose of compiling source in general. The topic at hand is why Ryan wants to do that. Until he explains that, no point in continuing. (May be he has already lost interest! sad)