CentOS 6.X, iptables 1.47 and Geolite2: how can I make this work? - geoip

I use the Geolite legacy databases together with iptables 1.47 to filter traffic for a variety of ports and only allow .AU traffic to have access.
Maxmind changed the default DB to the latest version which is GeoLite2 (jan), this leaves all users in need of the old Geolite Legacy database in the dark, they cannot update.
If I download a later version of xtables (>2.0) it will complain that it requires iptables>1.6 which I do not think I can get going on CentOS 6.X.
Is there a way that I can convert Geolite2 CSV files to Geolite Legacy CSV Files and then compile those into BE/LE?
Are there any other ways I can use Geolite2 on a CentOS 6.X system?

This project :
https://github.com/mschmitt/GeoLite2xtables
has scripts and in the README shell commands (work flow) to download GeoLite2 CSV files from maxmind, convert to Geolite legacy format CSV and call xt_geoip_build to compile to BE/LE.
It works for me on Debian 9, but would probably work on CentOS too.

I don't know any existing script available to convert Geolite2 to Geolite.
However, you can export the Australia IP address list in iptables format from free web service https://www.ip2location.com/free/visitor-blocker
You can import the list into iptables to allow traffics from Australia.

Related

Can we install teradata express on GCP compute instance?

I'm trying to work out a way to install teradata express on GCP compute instance or any other GCP compute service?? any leads would be appreciated.. thank you..!!
Teradata Express for VMware Player is provided as a pre-configured VMware virtual machine based on SUSE Linux Enterprise Server 11 (SLES11). It supposes VMware Player or VMware Server as an execution environment.
Inside of the downloaded package there is a VMX file. This is the primary configuration file, which stores settings chosen in the New Virtual Machine Wizard or virtual machine settings editor. See VMware: What Files Make Up a Virtual Machine?
SLES version 11 is not supported on GCE so you can't install Teradata Express on GCP "as is". See Compute Engine > Documentation > Supported operating systems
If you really need to get the Teradata Express for VMware Player working on GCE you should upgrade the SLES11 VM to SLES12 or SLES15 on VMware Player, and then import this VM into GCE.
Updating and Upgrading SUSE Linux Enterprise › Upgrading SUSE Linux Enterprise
Upgrading to SUSE® Linux Enterprise 12 > SLE11 to SLE12 Migration
While upgrading from SLES11 to SLES12 you should keep in mind that UEFI bootloaders are not supported in GCE for imported disks.
Having got Teradata Express on SLES12, you can consider two ways for import.
1. Create a new VM instance on GCE and use a pre-configured virtual disk with Teradata on SLES12 for creation of a boot disk image. The import tool supports most virtual disk file formats, including VMDK, VHD, and RAW. For more information, see Compute Engine > Documentation > Importing virtual disks.
2. Import a VM in OVF format into Compute Engine accordingly with Compute Engine > Documentation > Importing virtual appliances. The source VM could be whether in an OVF package or in an OVA single file. To convert VMware VMX to OVF or OVA you can use Open Virtualization Format Tool (ovftool). Please see OVF Tool User Guide for more details.
Both of these methods look a bit more complicated when you consider that Google provides its own data warehouse solutions: you could consider migration from Teradata to BigQuery so that use native solution provided and (what's important) supported by Google.
BigQuery Data Transfer Service > Documentation > Migrating data from Teradata
Solutions > Migrating data warehouses to BigQuery
Yes, you can run Vantage Express on GCP using nested virtualization. Here is the official how-to document: https://quickstarts.teradata.com/vantage.express.gcp.html.

VMware Workstation 15 export to customers ESXi5.5

I don't have ESXi inhouse, but am building a VM for a customer and they have two environments, an ESXi5.5 deployment and a 6.7.
At the moment I'm only able to export to an OVF/OVA format, which (for my customer) has worked in their 6.7 environment as I've downloaded the (Linux) version of Workstation 15 and am wondering how on earth I get to export the VM for ESX5.5. The VMware forums and online help don't seem to have been updated for Workstation 15 as they refer to a wizard which isn't available in the version of Workstation 15 that I have (only available in the paid version?)
I've also downloaded the VMware vCenter Converter (Windows version, standalone) as I was under the impression that that would be able to do convert anything to anything and therefore do what I needed, but it will only allow me to export to a 5.5 ESXi server within my environment, which I don't have.
What I'm looking at doing is building a VM that can be used in any ESXi environment, so I guess I should ask: what really is the best tool for me to be able to do that, considering that I don't have ESXi deployed here and am using VMWare Workstation and VirtualBox.
I had hoped that OVA/OVF would be a standard, and perhaps that's correct for newer VMWare Type I hypervisors?
My assumption is that you're running into an issue where the VM of a specific hardware version cannot be imported to the 5.5 environment. Each version of vSphere has a compatible hardware version, they're listed here: https://docs.vmware.com/en/VMware-vSphere/6.7/com.vmware.vsphere.vm_admin.doc/GUID-64D4B1C9-CD5D-4C68-8B50-585F6A87EBA0.html
To downgrade an existing VM's hardware, you can manually create a new (custom) VM in Workstation and when asked for the Virtual Disk, point to the existing disks you have already created. Additional information: https://kb.vmware.com/s/article/1028019

Connect to a mysql source in Cloud Dataflow without requirements

Is there a package that is currently installed in the Python SDK that would allow me to connect to a mysql source? If not, I'll need to add in a requirements.txt file, which I'm trying to eliminate, as it drastically increases the setup time for things.
Update: I suppose pandas can, though I believe it needs an additional 'binding' for each sql source it connects to if I'm not mistaken?.
Since you are trying to connect to MySQL you need a specific client that will establish a channel between you and the database. Therefore, you will have to use the requirements.txt file to install this library.
You can refer to this StuckOverflow link that has a similar question. The answer specifies that "You must install a MySQL driver before doing anything. Unlike PHP, Only the SQLite driver is installed by default with Python. ...".
So only the SQLite driver is installed with Python SDK, not the MySQL one.

How to Export Virtualbox to other PC

Hi I have just downloaded an Ubuntu Box and installed all web dev tools I need. Now I want to get a copy of this settings as is and use it from a place without internet connection.
What should I do to get a complete backup of my virtual box so I can use it at home? What files I need to copy.
Note: I am using Virtualbox and Vagrant.
Virtual box has export and import appliance features. Use them.

How I can install AsteriskNOW on Amazon EC2?

I have a question about asterisk, I know that I can install asterisk on EC2, but my questions is:
Its possible install AsteriskNOW on Amazon EC2? if not, why? and where its the best possible server or solution for install this
thanks
AsteriskNow is a complete distribution based on CentOS available as an ISO file. There doesn't appear to be an EC2 AMI available for it so you would have to build an image yourself.
Here's an overview of the process for Oracle Linux which boils down to:
Install AsteriskNow onto a VirtualBox or VMWare instance locally.
Configure all the EC2 specifics (This is the fiddly bit)
Export that virtual machine as a VMDK.
Copy the VMDK to S3
Import the VMDK to an EBS volume and launch on Amazon EC2.
Before you export you will have to make sure AsteriskNow has a kernel that supports EC2. In CentOS this would be the Xen kernel but I don't know if Asterisk would supply one, which means compiling. The PV-GRUB docco also covers a lot of what can and can't be used on EC2. If it doesn't work out of the box it will take some Linux smarts to figure it all out.
It will probably take a number of exports/imports to get it running. Once you have it up on EC2 you can turn that instance into an AMI to quickly create clones in the future without going through the whole export/import process.
can you not just download the ISO directly?
ubuntu#ip-172-31-14-19:~/iso$
ubuntu#ip-172-31-14-19:~/iso$ wget -v https://downloads.asterisk.org/pub/telephony/asterisk-now/AsteriskNow-1013-current-64.iso
--2017-11-17 05:52:53-- https://downloads.asterisk.org/pub/telephony/asterisk-now/AsteriskNow-1013-current-64.iso
Resolving downloads.asterisk.org (downloads.asterisk.org)... 76.164.171.238, 2001:470:e0d4::ee
Connecting to downloads.asterisk.org (downloads.asterisk.org)|76.164.171.238|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 1343909888 (1.3G) [application/x-iso9660-image]
Saving to: ‘AsteriskNow-1013-current-64.iso’
AsteriskNow-1013-curr 100%[======================>] 1.25G 1.79MB/s in 9m 54s
2017-11-17 06:02:48 (2.16 MB/s) - ‘AsteriskNow-1013-current-64.iso’ saved [1343909888/1343909888]
ubuntu#ip-172-31-14-19:~/iso$
https://downloads.asterisk.org/pub/telephony/asterisk-now/