↑↓ selectEnter openEsc close

    1. Elbuz

    How to connect a site to Elbuz Tunnel

    11 min readUpdated

    Elbuz connects to your site by itself: you put the tunnel module on your hosting and enter the site address; the app takes the module password and database details from the CMS configuration.

    When you need this:

    • The module is already on the site — only the site address is needed; the app does the rest.
    • You already pull orders through the tunnel — the new export template reuses those details.
    • Your hosting blocks the tunnel — the log says what to enable: local_infile, zip or timeouts.
    • A new module version is out — the “Update” button installs it.

    Where to start: put the module in the site root.

    What the tunnel connection does

    • Three starting points — the module is already there, there's no module yet, or the tunnel already works for import.
    • Module installation — an archive in the site root in a few minutes.
    • Auto-setup — the module password and database access details from the configuration.
    • Module updates — with a button, no , and the password is kept.

    What the site needs

    The tunnel is a set of files on your site hosting: the etrade_http_tunnel2 folder in the root.

    You don't have to guess the hosting requirements: once the connection is set up, the “Check Connection” button lists the required PHP extensions together with memory_limit, post_max_size, upload_max_filesize, max_execution_time, the locale and the module version.

    The module is already on the site

    Then all you need to provide is the site address. The app figures out the rest at the connection step: it builds the module URL, picks the login, sets the password and reads the database details from your CMS configuration file.

    There's no module on the site yet

    Then you need to put it on your hosting — the “Download module” button in the “Site and CMS” section of the template card gives you the archive. The steps are below, in “Installing the module on your hosting”. After installation the module URL looks like this: https://your-site/etrade_http_tunnel2/etrade_http_tunnel.php — this is what the app enters in the “Module URL” field.

    The tunnel is already set up for data import

    The shortest path. If your account already has a tunnel import template — the one you use to pull orders from the site — the new export template copies its settings: the CMS and its version, module URL, login and password, all site database details, and table type.

    The list of objects from “Additional settings” is carried over too. In this case you don't need to fill in the connection sections at all.

    If there's no such template, the fields get default values: CMS — OpenCart, version 3, port 3306, encoding utf8mb4, collation utf8mb4_unicode_ci, table type InnoDB.

    Installing the module on your hosting

    The tunnel is the etrade_http_tunnel2 folder in your site's root. Until it's there, there's nothing to connect to, so the first step is always to put the module on the server. It's a one-time job of a few minutes — the module then updates itself.

    1. Download the module. The “Download module” button in the template's “Select CMS” block gives you the current archive. Or use the direct link: etrade_http_tunnel2.zip.
    2. Unpack the archive on your computer.
    3. Copy the contents to your hosting — into the site's root folder, where the main index.php is, with the etrade_http_tunnel2 folder itself. An FTP client such as FileZilla is handy here. The module's address then looks like this: https://your-site/etrade_http_tunnel2/etrade_http_tunnel.php.
    4. Connect in Elbuz: in the template's “Select CMS” block, choose your CMS (for OpenCart, also the version), enter the site address, and click “Connect”.

    Elbuz does the rest itself: it sets the module's access password (on first installation) and reads your CMS configuration file for the database connection parameters — server, database name, user, password, and table prefix. No manual entry needed. When it works, you'll see the message “Module connected successfully!”.

    Besides the tunnel, the module folder has empty temp and backup folders: working files go in the first, archive copies of the site's database in the second. The hosting must have the PHP extensions mysqli, zip, and curl enabled.

    The label depends on whether the connection is set up. While the parameters are empty, it reads “Connect” and runs the automatic setup. Once the credentials are filled in, “Check connection” takes its place: it reconfigures nothing, only checks that the module responds, and shows the module version and the hosting's PHP settings.

    There's also a “Get settings” button in the manual parameters block — it re-reads the site configuration, for example after the database moves.

    Then you enter the same parameters by hand:

    • Link to the module — https://your-site/etrade_http_tunnel2/etrade_http_tunnel.php;
    • Login — admin;
    • Password — the one set in the etrade_http_tunnel_login.php file inside the module;
    • Database access for the site — server, port, database name, user, password, and table prefix. You'll find these values in your CMS configuration file (usually config.php or similar).

    Common reasons the automatic connection failed: the site address wasn't entered or the CMS wasn't chosen (Elbuz warns you in a separate window); the module wasn't copied to the site's root folder; the hosting blocks access to the module file.

    Elbuz support can install and set up the tunnel for you — this requires access to your hosting. It's a separate service: write to support, and they'll tell you the terms.

    Updating the module

    Usually there's nothing to update by hand. Click “Check connection”: Elbuz compares the module version on your hosting with the latest. If there's a newer one, the line “A new version of the E-Trade Tunnel module is available:” and an “Update” button appear — the button updates the files on the site itself, no copying needed.

    The manual route is needed when the automatic update fails — for example, the hosting doesn't let the module write to its own folder. Then you take the update archive: etrade_http_tunnel2_update.zip. Unpack it and overwrite the files in the etrade_http_tunnel2 folder on the hosting.

    The update archive contains only the module core — the working files that need to be replaced with new ones. It doesn't contain what appeared on the hosting while the module was running:

    • etrade_http_tunnel_login.php — the file with the module's login and password. That's why an update doesn't reset access: the password Elbuz set at the first connection stays, and the connection needs no new setup;
    • the backup folder — archive copies of your site's database;
    • the temp folder — the module's working files.

    That's why the update archive is unpacked over the existing folder, not in place of it. The full archive (etrade_http_tunnel2.zip) is only needed for the first installation — it includes these files and empty folders.

    Connecting in the template card

    The tunnel template card is a single scrolling page. At the top is a sticky section bar: “Site and CMS”, “Tunnel module”, “Site database”, “What to export”, “Product selection”, “Prices”, “Deletion”, “DB archive”. Clicking a name scrolls to that section, and as you scroll, the bar highlights the one you're in. The connection takes up the first three sections. The form saves itself: the footer shows “All changes saved” or “Saving…”.

    Here's the order.

    1. In the “Site and CMS” section, on the “Select CMS” card, select your site's CMS and, if it has versions, the version. The list has CS-Cart, Magento (versions 1 and 2), OpenCart (2, 3), PrestaShop, WooCommerce and a separate “MySQL (SQL custom query)” option — for a site on any other engine, when queries are written by hand.
    2. Enter “Link to your site” — just the home page address, like https://yoursite.com.
    3. Click “Connect”.

    What happens after the click. First the app agrees on a password with the module: if the module still has the factory password, the app generates a random one and writes it both into the module and into its own settings. So the factory password lasts only until the first connection.

    Next the app reads the CMS configuration file and takes the database server address, port, user, password, database name, table prefix and encoding from it. On success you see “Module connected successfully!” and a “Next” button that scrolls to “What to export”. If the module returns an error, a window shows its text and “Connect” becomes available again: fix the cause and click it again.

    The first two branches: what's missing in the form and whether the module responded. After that the path is the same: the module password changes only once, at the first connection
    NoYesNoYesNoYesThe module rejected thewriteWritten: the password isalso saved in the templateClicked “Connect”“Link to your site” filled in and CMSselected?Message “Please provide a link toyour website!” or “Select the CMSthat your website is based on!”Module password: from the templatecard, otherwise from an importtemplate with the same module,otherwise the factory oneDid the module respond without anerror?Window with the module's error text.The “Connect” button is availableagainDoes the module already have itsown password?The app generates a password andwrites it into the moduleThe app reads the CMSconfiguration file and fills in thedatabase details“Module connected successfully!”and the “Next” button
    • Action or result
    • Decision: the path depends on the answer

    The app puts what it found into the next two sections. “Tunnel module” — the “Tunnel connection setup” card — has three fields: “Module URL”, “User name” (the app sets admin) and “Password”. “Site database” — the “Site database connection settings” card — has the database details: “MySQL server address”, “Port”, “DB username”, “Password”, “DB name”, “Table prefix”, “Connection encoding”, “Encoding for character comparison” and “Table type”.

    Both cards fill in automatically, but the fields stay editable: if the site configuration file couldn't be read, enter the details by hand. At the bottom of the database card is a “Get Settings” button — it reads the site configuration again.

    If the site doesn't run on MySQL, the “Site database connection settings” card has a “DBMS selection” row above the button with three options: MySQL, MariaDB, PostgreSQL. The default is MySQL.

    Once the details are filled in, the “Connect” button changes to “Check Connection”. Click it before the first run: the module responds with information about the hosting and its own version.

    If a newer module version is out, the same response shows the line “A new version of the E-Trade Tunnel module is available:” and an “Update” button. It updates the module on your hosting by itself, with no need to go to the site over FTP: the response is “Module updated successfully!” or “Module update failed!”. For the second case, see “Updating the module”.

    Top of the Elbuz Tunnel template card: header, section bar and the Select CMS card
    1Section bar
    2Link to your site
    3Download module
    4Template state
    1. Card sections — click a name to scroll to that section.
    2. The address of your site's home page.
    3. Downloads the tunnel module archive to upload to your hosting.
    4. The template state; turning it on enables scheduled export.

    Scenarios

    The module is already on the site

    What to do. “Add” → “Elbuz” → “Elbuz Tunnel”. In the “Site and CMS” section select the CMS and version, enter the site address and click “Connect”, then “Check Connection”.

    What you get. The app replaces the module's factory password with a random one, reads the database details from the CMS configuration and shows “Module connected successfully!”. The second button shows the PHP extensions and module version. What won't happen. No data goes to the site yet — the run is started separately.

    The site database moved to another server

    What to do. In the “Site database” section, click “Get Settings” at the bottom of the “Site database connection settings” card.

    What you get. The app reads the site configuration again and fills in the new database details. What won't happen. For CS-Cart, Magento and PrestaShop 1.7 a manually entered collation isn't kept — the button writes utf8_general_ci; check it again (collation).

    The hosting won't let the module update itself

    What to do. Download the update archive, unpack it and copy the files over the etrade_http_tunnel2 folder on your hosting.

    What you get. The module core is updated, while the login and password file, archive copies and working files stay in place. What won't happen. You won't need to set up the connection again after the update.

    What to do when the tunnel won't connect

    What you seeWhyWhat to do
    “Please provide a link to your website!” You clicked “Connect” with the site address field empty Enter the site home page address (about connecting)
    “Select the CMS that your website is based on!” The site engine isn't selected Select the CMS and, if available, the version. If yours isn't on the list, choose “MySQL (SQL custom query)”
    “The E-Trade Tunnel module URL, login or password is missing!” You clicked “Check Connection”, but the module details are empty Click “Connect” — the app fills them in by itself (about connecting)
    “Incorrect login or password for the E-Trade Tunnel module!” The password in the module on the hosting doesn't match the one in the template settings Reinstall the module folder on the site and click “Connect” again: the app writes a new password into the module
    “Data export NOT completed: the file was not generated” For the tunnel this almost always means one of the six required connection fields is empty: module URL, user name, password, database server address, database user name, database name Click “Tunnel module” or “Site database” in the section bar, fill in the empty field and click “Check Connection” (about connecting)
    “Error! Need mode LOAD DATA LOCAL INFILE! Variable local_infile: OFF” or “mysqli_query(): LOAD DATA LOCAL INFILE forbidden” Data arrives on the site as a CSV file, and the module loads it into a temporary table with LOAD DATA LOCAL INFILE. Your hosting has this command disabled In php.ini — mysqli.allow_local_infile = On (by default the line is commented out with a semicolon). In my.cnf — local-infile=ON in the [mysqld] and [mysql] sections, then restart MySQL. To check: SHOW VARIABLES LIKE 'local_infile'. This is a hosting setting; Elbuz can't change it
    The run fails with a mention of zip The hosting doesn't have the PHP zip extension, and files are sent to the site compressed Install the extension (php-zip) and restart the web server. The “Check Connection” button shows which extensions the hosting has
    “504 Gateway Time-out” or “502 Bad Gateway” The site's web server didn't get a response from PHP in time and dropped the request. With a large amount of data the tunnel runs longer than the default limit allows This is a site hosting setting, not an Elbuz one: increase the timeout (proxy timeouts in nginx, script execution time in PHP). As a temporary measure, split the export into smaller batches with product selection
    “MySQL server has gone away” The site database closed the connection: either the timeout expired or a data batch is larger than the allowed packet size Again, a site hosting setting: increase wait_timeout and max_allowed_packet in the MySQL configuration. On the Elbuz side, reducing the size of a single run helps
    The run log shows a site database error “Illegal mix of collations (…) and (…) for operation '='” Before sending, the tunnel creates temporary tables in the site database with the encoding and collation from the “Site database” section. If that collation differs from the site's tables, MySQL refuses to compare rows of the two tables. The app fills an empty field with utf8mb4_unicode_ci; for CS-Cart, Magento and PrestaShop 1.7 the “Connect” and “Get Settings” buttons always write utf8_general_ci and overwrite a value entered by hand Look up the collation of the site's product table in phpMyAdmin or your hosting panel and enter it in “Encoding for character comparison”, and the part before the first underscore in “Connection encoding”: utf8mb4_general_ci → utf8mb4, utf8_general_ci → utf8. Do this after “Connect”, and don't click it or “Get Settings” again afterwards. For Magento, temporary tables are always created in utf8, so only a utf8_… collation works there: with utf8mb4_… the tables aren't created at all. Start the run again (about connecting)

    FAQ

    The tunnel shows a collation error (Illegal mix of collations). What values should I set?

    The same collation as in the site's tables. Look up the “Collation” of the product table in phpMyAdmin, enter it in “Encoding for character comparison”, and the part before the first underscore in “Connection encoding”. Do this after “Connect” (troubleshooting).

    Do I need to update the module on the hosting by hand?

    Usually not: “Check Connection” shows the module version, and the “Update” button updates it on the site by itself. You need the manual update archive when the hosting doesn't let the module write to its own folder.

    Where do I get the module password if I connect manually?

    In the etrade_http_tunnel_login.php file inside the module; the login is admin. After the first automatic connection, it holds the password Elbuz set.

    Do I need to set up the connection again after updating the module?

    No. The update archive doesn't include the login and password file, so access stays as Elbuz set it at the first connection.

    Which PHP extensions does the hosting need?

    mysqli, zip and curl; for a database archive copy, also pdo. The “Check Connection” button shows which extensions the hosting has.

    Where to find it and who has access

    Menu
    Directories → Operations → Data export → Elbuz Tunnel template card
    Other entry points
    the “Site and CMS”, “Tunnel module” and “Site database” sections of the template card
    Access right
    the export template card
    Prepare
    access to your site hosting; PHP mysqli, zip and curl

    Related topics

    Was this article helpful?

    Missing a feature? Tell us.

    We will add it for free if other users need it too.

    If only you need it, we will agree on it separately.

    Article contents

    Suggest an improvement

    Try Elbuz free