Python – Command “python setup.py egg_info” failed with error code 1 /tmp/pip-build-21ft0H/pandas

Here is the solution how to fix the error when you trying to install Pandas

Python - Command “python setup.py egg_info” failed with error code 1 in /tmp/pip-build-21ft0H/pandas

First you need to uninstall all the Pythons (I knew it’s a bad idea but it works).

yum remove python

Then install python 2.7.10 using these commands.

wget https://www.python.org/ftp/python/2.7.10/Python-2.7.10.tgz
tar -xvzf Python-2.7.10.tgz
cd Python-2.7.10
make install

Make sure your python 2.7.10 installed in your system.

python -V

After that you need to install python 2.7.5 via RPM.

rpm -i ftp://195.220.108.108/linux/centos/7.1.1503/updates/x86_64/Packages/python-2.7.5-18.el7_1.1.x86_64.rpm

Install Pandas package via pip

sudo pip install pandas
sudo pip install pandas.

sudo pip install pandas.

Voila!! It’s done!!

How To Install Zimbra Collaboration Suite 8.6.0 On CentOS 7

Zimbra Collaboration Suite (ZCS) is a groupware product created by Zimbra, Inc. It is widely used in the world. Users can share folders, contacts, schedules and other things, using a very rich web interface. Currently the latest version of Collaboration Suite is Zimbra 8.6.0. It brings new features, improvements in Mail server and it provides a better web client experience. In this tutorial, I will explain how to install Zimbra 8.6.0 on RHEL 7 or CentOS 7.

If you don’t have Digital Ocean account yet, you need to sign up first. Sign Up Digital Ocean. Then you need to deploy your droplet. http://blog.revivalx.com/2014/10/15/deploy-droplet-in-digital-ocean/

Login your VPS via SSH using Terminal (Mac) or Putty (Windows). First, we need to ensure that CentOS 7 is up to date. Therefore, we’ll run the following command:

yum update –y
yum update

yum update

yum update

yum update

Next, we need to install some pre-requisites. Since there are 12 different applications required to install Zimbra, we can handle the installation in one single command:

yum install -y gmp libidn wget nano make nc sudo sysstat libtool-ltdl glibc perl ntp libaio unzip perl-core

Next, we’ll need to install check if postfix is running – if it is, disable it. Since we cannot have two different mail transfer agents running, postfix must go.

service postfix status

If postfix is running, we’ll need to disable it:

service postfix stop && chkconfig postfix off

Setup DigitalOcean DNS for your domain, head over to the DNS tab in the DO control panel. Once there, add your domain.

DNS - Add a Domain

DNS – Add a Domain

Point to mail.aceakl.my (your Droplet FQDN) with a high priority (lowest number).

DNS - Add a Domain

DNS – Add a Domain

Once you’ve added your domain, add the following records to your DNS settings. In this example, the IP address 128.199.72.229 is used for my DigitalOcean Droplet. However, yours will be different, so set this value to your Droplet IP.

DNS - Add a Domain

DNS – Add a Domain

Final result.

DNS - Add a Domain

DNS – Add a Domain

Go to Zimbra official website to get a download link for the latest version of Zimbra.

Zimbra download page

Zimbra download page

And then fetch the file from the Zimbra website. You can use wget to achieve this. Obviously, you’ll need to place the URL you copied earlier into this command rather than using the link here.

wget https://files.zimbra.com/downloads/8.6.0_GA/zcs-8.6.0_GA_1153.RHEL7_64.20141215151110.tgz
wget Zimbra for Centos 7

wget Zimbra for Centos 7

Now we’ll need to edit the hosts file in CentOS to contain the IP address of the Droplet, the FQDN, and name of the server. We can do this by typing:

nano /etc/hosts

Once opened, the hosts file should look similar to the following:

nano /etc/hosts

nano /etc/hosts

Remove IPV6 and this line.

127.0.0.1 Aceakl Aceakl

# The following lines are desirable for IPv6 capable hosts
::1 Aceakl Aceakl
::1 localhost.localdomain localhost
::1 localhost6.localdomain6 localhost6

You’ll need to edit the file to contain another row with your Droplet’s IP address, FQDN and name. The line should look like the following:

127.0.0.1 localhost.localdomain Aceakl localhost
127.0.0.1 localhost4.localdomain4 localhost4
128.199.72.229 mail.aceakl.my mail

You’ll need to ensure that you replace the above with the actual data values for your Droplet. You should also make sure that you use a tabbed space between each value. This means that you’ll have a host file looking something similar to:

nano /etc/hosts

nano /etc/hosts

Once done, press CTRL+O and then Enter to save. Then press CTRL+X to return.

The next stage is to unpack the tgz file we downloaded earlier. To do this, we can execute the following command:

tar zxvf zcs-*.tgz

Next, change directory into the folder that the files were extracted into:

cd zcs-*

Finally, we can run the installer.

./install.sh --platform-override

Once the installer starts, you’ll need to accept the license agreements by pressing Y at each license prompt.

Accept the license agreements

Accept the license agreements

When you reach the ‘select packages to install’ section, simply press enter at each of the options which will select the default value.

Installing Zimbra packages

Installing Zimbra packages

Type No and Enter.

DNS ERROR resolving localhost.localdomain

DNS ERROR resolving localhost.localdomain

Type Yes and set your domain name.

DNS ERROR resolving MX for localhost.localdomain

DNS ERROR resolving MX for localhost.localdomain

This error is presented by Zimbra because it’s looking for an MX record for the domain ‘subdomain.example.com’. Instead, we want it to search for an MX record for ‘example.com’. This means that we should press Y`, and change the domain name to just ‘example.com’. If you get a port conflict error, you may need to exit the installer and resolve the issue before continuing. You’ll soon reach the configuration page, similar to that below. First we should choose option 3 to allow us to enter the zimbra-store section.

Zimbra main menu

Zimbra main menu

Address unconfigured (**) items (? – help)   7

Next, choose 4. This will allow us to configure the admin username and password.

Select, or 'r' for previous menu [r]  3
Create admin user: [admin@aceakl.my] admin@aceakl.my
Password for admin@aceakl.my (min 6 characters): [MBUKGBcH] password

Next, choose r to return to the previous menu.

Select, or 'r' for previous menu [r]  r

Then, choose 1 to go to the common configuration section.

*** CONFIGURATION COMPLETE - press 'a' to apply
Select from menu, or press 'a' to apply config (? - help)   1
Zimbra common configuration

Zimbra common configuration

Zimbra main menu

Zimbra main menu

After this, choose 6 to edit the time zone.

Select, or 'r' for previous menu [r]  6
Zimbra common configuration

Zimbra common configuration

Here, you should choose the number relative to the time zone you’re in. For example, you could type 50 to get the Kuala Lumpur time zone.

Enter the number for the local timezone: [39]  50
Zimbra timezone

Zimbra timezone

Then choose ‘r’ to return and ‘a’ to apply the configuration. You should also choose the log the installation to a file, in case any errors arise.

Select, or 'r' for previous menu [r] r
*** CONFIGURATION COMPLETE - press 'a' to apply

Select from menu, or press 'a' to apply config (? - help) a
Save configuration data to a file? [Yes]  yes
Save config in file: [/opt/zimbra/config.7622] /root/zimbra-installation.txt
Saving config in /root/zimbra-installation.txt...done.
The system will be modified - continue? [No] yes
Zimbra configuration complete

Zimbra configuration complete

The system will then continue the installation. Setup of Zimbra should take about 20 minutes, depending on the Droplet size you selected.

Finally, you’ll be given the option of notifying Zimbra of the installation, which allows them to track the uptake of their products. You can either type ‘yes’ or ‘no’ here, either way, this is the final step of the installation. You can make sure that the installation was successful from the final confirmation message:

Configuration complete – press return to exit
Finishing Zimbra installation zimlets

Finishing Zimbra installation zimlets

It is recommended that you reboot your Droplet.

Accessing The Zimbra Admin Control Panel
The control panel can be easily accessed by visiting the following URL:

https://mail.aceakl.my:7071/zimbraAdmin

Deploy droplet in Digital Ocean

In this tutorial, you will learn how to deploy droplet in Digital Ocean.

Overview

DigitalOcean is an American virtual private server provider based in New York City. The company leases capacity from existing datacenters, including sites in New York, Amsterdam, San Francisco, London and Singapore.

http://en.wikipedia.org/wiki/DigitalOcean

Let’s get start

Go to Digital Ocean. You will see this home page on their website. To sign up, enter your email address and password then click create account.

digital ocean homepage

digital ocean homepage

If you already have the account, you can go to login page and enter your account details.

digital ocean login page

digital ocean login page

After you login, you will directly go to dashboard page where all your droplets will be located here. Currently I already 4 droplets inside Digital Ocean. Click Create Droplet to deploy a new one.

digital ocean dashboard

digital ocean dashboard

Enter your Droplet Hostname.

digital ocean droplet hostname

digital ocean droplet hostname

Select your droplet size. It depends how much your budget monthly and requirements.

digital ocean select size

digital ocean select size

Select your nearest region. Leave it for available settings.

digital ocean select region

digital ocean select region

In select image > linux distributions, you can select which OS you want. For this tutorial, I select Centos 7. For new registration, my images, my backups and destroyed droplets are empty. But you have choice to select any applications for your droplet.  After done all steps, click Create Droplet to complete.

digital ocean select image

digital ocean select image

Wait until it’s finish processing.

digital ocean processing

digital ocean processing

Voilà !! Your droplet already done deployed !! Now you can use it for your own project. Enjoy!!

digital ocean droplet

digital ocean droplet

DHCP reservation, ssh and ftp with raspberry PI

Today I want to show you how to connect and communicate with your beloved Raspberry PI using SSH. If you using mac or linux, you can directly using terminal, otherwise for windows user, you need to use Putty. You can download Putty here, http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html .

raspberry PI

raspberry PI

This tutorial continues from the previous tutorial, learning python in 1 hour. Before you start this tutorial, make sure you have all this tools.

  • Router (Any).
  • Lan cable.
  • Raspberry PI with SD card (recomended 8gb pre-installed Wheezy Rapsberry PI OS).
  • Putty(for Windows) / Terminal (Mac/Linux).

Connect your Raspberry PI to your router using lan cable. Mine using Linksys E1000. Make sure your machine connected to router either wireless or cable.

linksys E1000

linksys E1000

Open up your browser and type 192.168.1.1 then a popup dialog request you enter username and password. The default password is admin and leave it blank for username. Then you will be redirect to main page.

linksys main page

linksys main page

Then you click DHCP Reservation button at DHCP Server Setting to determine which ip address belonging to Raspberry PI.

DHCP

DHCP

You will notice raspberry PI’s ip address is 192.168.1.109. It depends how your router scan your raspberry PI. Copy this ip address into your clipboard. Open up your terminal then type this command to connect with you raspberry PI.

ssh 192.168.1.109  -l pi

When terminal request your password, you enter the raspberry PI default password, raspberry .

SSH

SSH

If you want to close the connection, type this command. Make sure you in root.

sudo su
shutdown -r now

File transfer

Besides that, this tutorial teach you how to make file transfer using filezilla to your raspberry PI. Download and install this tool before we proceed. https://filezilla-project.org/download.php?type=client . Open up your filezilla application then enter these details to access raspberry PI file directory.

host: 192.168.1.1
username: pi
password: raspberry

filezilla raspberry PI 1

filezilla raspberry PI 1

Then a popup appear, tick always trust this host, add this key to the cache. Below is a file directory in raspberry PI.

filezilla raspberry PI 2

filezilla raspberry PI 2

Thanks for reading my tutorial for today. Next, I will post a tutorial about integrating a few pieces of electronic hardwares with raspberry PI such as servo, motor and ultrasonic. Don’t hesitate to contact me. Cheers !!