Dissecting a Patch or two? Package Installations by hand - their process and control from Wemin or SSH?

Landis Arnold's picture

I am interested in looking at the details of a few patches, but not getting bogged down with the packages they may contain.  Can scripts be easily read inside the patches?  I am working in Windows as my workstation envirionment.

From this I want to see if I can go through the process of individually applying some of the patch sequences so that I can better understand the whole Linux/TKL process.

Finally, I would like to explore some variations.  IE, I would like to install Zend Server CE over LAMP, and then Move a previous Magento installation into Lamp/Zend Apache setup.

Lots too learn I know.  Unfortunately, the optics of "learning" are often lost on those who have already crossed the rubicon.  It would seem that what I want to do is actually pretty simple.  That said, all my instinct tells me to do is to build some folders, drop some tarballs in, run them (in the case of Zend), then build another folder (in Share or WWW?) for my Magento Install,  import SQL into a new Magento Database (RootSQL user and Password noted), reconfigure config.xml type files,,, and shoot away.  Of course there is the firewall, DNS good SSL setup that needs to be handled - and correctly pointed to.

I suppose it would be easiest to try moving the Magento without Zend First, but I fear there are a bunch of dependencies Magento normally builds in its own installation.  (why I want to look at Patch scripts).

all for now. Remodelling time,

best and thank you,

L. Arnold


Jeremy Davis's picture

If you are in Windows here's how I do it:

Remove patch files from the archives (I use IZArc - its free but not open source, works well though)

Locate the conf file, that's basically the bash script that does most of the work. (Some patches will have a conf folder instead, you'll find multiple conf scripts in there). In Windows I use Notepad++ (open source text/script editor) its complient with Linux bash (and other) scripts and won't corrupt them (as notepad does). If you wish you can copy paste one line at a time into an SSH client (such as PuTTY) connected to a TKL appliance.

If there are any custom debs installed then you will find them in the debs folder. And custom config and other required files/folders are found in the overlay folder. By default debs install first, then overlay files/folders applied, then the conf script runs.

If you wish to recreate a TKLPatch, remember after working on the script(s) in Win, upload them to a TKL appliance and make them executable prior to rebundling with TKLPatch.

For your own purposes you can do it however you like, but if you want to share new or remodeled patches with others, its probably a good idea to try to follow the conventions that are documented. Have a good read of the TKLPatch Documentation.

I'm unfamilar with what you are trying to achieve but I hope this relatively generic information is of some use to you?

Landis Arnold's picture

Might 7-Zip also work?  I have modified a Firefox extension once using it.  I will find out about IZArc.

I suppose I also need to learn the navigation for all the Patches and TKLDev arena.

I have now modified a TKL Lamp Appliance to being a Zend/Magento applliance and should see how I do either a Patch or ISO of it to see if it is transportable.

I have no idea what a Deb is yet.  I also need to learn how to "make a patch executable".  I am actually unclear as to why a "patch" would be pursued rather than a full appliance  - seems you can hand code the appliance and have it built.  I suppose it is so folks can check the sequence for debugging and security issues.

I do know that I needed to manually install Zend and Magento to the build and I am not sure yet if they are "self updating"  (I had to remove from  my sources a reference I had entered to Zend CE so that it would be self updating - in that the reference was causing complaints in "apt-get install" routines)

Anyway,  Thank you for the guidance!


Jeremy Davis's picture

And as its open source that's even better. I just haven't used it so I only recommended what I know works.

If you read through all the documentation that should head you in the right direction as far as the what why and where of patches. 

A couple of answers to your other queries:

A .deb is basically an installer package (to install an app or component), somewhat similar to an .msi file in Windows. Because of the modular nature of Linux though often they are small and require other debs (dependencies) to be installed prior or at the same time. That is why installing debs is usually to be avoided if possible (using apt-get with repos is better because dependencies are auto handled).

"Making executable" is a permissions thing. To be able to execute a script in Linux the script must be designated as executable or otherwise it won't run. As Windows doesn't have this if you edit a file in Windows the execute permission is removed and must be reset in Linux. This can be done at the command line (have a quick google) or using the file manger in Webmin.

The initial purpose of a patch is so the community can feed their ideas and desires back to the core dev team and hopefully have them included in the next TKL release as official appliances. They also allow others to test out the appliance prior to official release. Even if the devs decline to make it into an official TKL appliance community members can still use it if they wish.

If you install stuff using apt-get install then it will be easy to upgrade it as desired. If you install debs using dpkg then its not so easy. Although by default only security concerns are auto-updated.

Hope that helps a bit and good luck!

Post new comment