Feb 27

Installing iAMP in 5 minutes or less.

Thought we would create a video showing just how easy it is to install iAMP server on the IBMi. This is a fully functioning Apache,MySQL,PHP server with Easycom providing access to the IBMi data and objects using the i5_toolkit functions.

You will see from previous posts about installing PHP on the IBMi it has never been as easy as this was, and yes it only takes 5 minutes to install.

If you have been thinking about PHP and the IBMi and were put off by the complexity of other installs iAMP server is for you. Take it for a test drive today, you don’t have to remove any existing HTTP servers for this install and removal is just as simple as the install.

If you need an un-install script here is one we generated for a base install, just compile the CL and run.


PGM
MONMSG MSGID(CPF0000)
ENDSBS SBS(EASYCOM) OPTION(*IMMED)
ENDSBS SBS(IAMPSVR) OPTION(*IMMED)
DLYJOB DLY(5)
RMVLNK OBJLNK('/etc/iamp.tab')
RMVDIR DIR('/usr/local/iamp') SUBTREE(*ALL)
RMVDIR DIR('/usr/local/Easycom') SUBTREE(*ALL)
RMVDIR DIR('/var/mysql') SUBTREE(*ALL)
RMVDIR DIR('/www/iamp') SUBTREE(*ALL)
DLTLIB LIB(EASYCOM)
DLTLIB LIB(EASYCOMXMP)
DLTLIB LIB(IAMPSVR)
ENDPGM

If you need any help or advice on setting up and running iAMP server let us know, we are happy to help. You can also follow the links provided from the installed webserver welcome.html page to the Forums and documentation.

Chris…

Feb 22

Scam or not?

We recently received the following email.

Dear CEO,

(If you are not in charge of this, please forward this to your CEO, because this is urgent. Thanks)

We are a Network Service Company which is the domain name registration center in Shanghai, China. On Feb 20, 2012, we received an application from Hantong company requested “shieldadvanced” as their internet keyword and China (CN) domain names. But after checking it, we find this name conflict with your company name or trademark. In order to deal with this matter better, it’s necessary to send email to you and confirm whether this company is your distributor or business partner in China?

Kind regards

Edward Wang
Office Manager
Shanghai Office (Head Office)
3002, Nanhai Building, No. 854 Nandan Road,
Xuhui District, Shanghai 200070, China
Tel: +86-21-6191-8696
Mobile: +86-182-2195-1605
Fax: +86-21-6191-8697

So we thought this was a sincere attempt to stop a company from registering our domain with a Chinese (CN) registration. We responded with the following note suggesting that we had no affiliation with the company and that we felt they should not register the .CN domain for the company.

Edward

We do not have any partners in China so this is not a valid request from the Hantong company. We thank you for your attention in this matter and hope you can resolve the questions with that company.

Chris..

The today we received the following message.

Dear Chris,
Based on your company having no relationship with them, we have suggested they should choose another name to avoid this conflict but they insist on this name as CN domain names (.cn/.com.cn/.net.cn/.org.cn) and internet keyword on the internet. In our opinion, maybe they do the similar business as your company and register it to promote his company.
According to the domain name registration principle: Domain name and internet keyword which applied based on the international principle are opened to companies as well as individuals. Any companies or individuals have rights to register any domain name and internet keyword which are unregistered. Because your company haven’t registered this name as CN domains and internet keyword on the internet, anyone can obtain them by registration. However, in order to avoid this conflict, the trademark or original name owner has priority to make this registration in our audit period.
If your company is the original owner of this name and want to register these CN domain names (.cn/.com.cn/.net.cn/.org.cn) and internet keyword to prevent anybody from using them, please inform us. We can send you an application form with price list and help your company register them.

Kind regards

Edward Wang
Office Manager
Shanghai Office (Head Office)
3002, Nanhai Building, No. 854 Nandan Road,
Xuhui District, Shanghai 200070, China
Tel: +86-21-6191-8696
Mobile: +86-182-2195-1605
Fax: +86-21-6191-8697

It appears to be a scam where the Registrar is scouring the .com domains and sending this note out to hundreds if not thousand of them! I found the following link to a post about a similar request from the same person.

Just as a further push I did receive a note from a Lee Gareth email gareth@live.cn with the following content.

Dear Sirs,
We are Hantong company based in China. We will register the “shieldadvanced” as internet keyword and CN domain names .cn, .com.cn, .net.cn, .org.cn. We have handed in our application and are waiting for Mr. Edward Wang’s approval. We think this name is important for our products in Chinese market. Even though Mr. Edward Wang advises us to change another name, we will persist in this name.
Best regards
Gareth Lee

So if you are sent a note about a company trying to register your domain in China with a follow-up offer to sell it to you to protect your rights its probably going to be a scam. Not sure if anything can be done about this or even if it is legal to carry out this kind of fraudulent activity. We are going to ignore the request, if they do sell our domain to another company we can deal with that when it happens.

Chris…

Feb 22

Installing RedHat into a IBMi Guest LPAR

We had a lot of issues recently with the hosting LPAR which caused us to un-install all of the Guest partitions except the iOS partition to see if they were having any adverse effects on the Hosting partition. A Reclaim Storage found a number of damaged objects but none of them related to the installs we had done. It also gives us a chance to go back over the installs and document what we did to get them up and running.
So this is a list of the actions we took with a number of pretty pictures to show some of the important steps. The HMC is used to setup the Partitions, we were going to use VPM but the restrictions on the number of Guest partitions meant we had to step up to the HMC/VIOS standard edition to meet the requirements.
This is the current partition information it shows we still have a Hosting partition (SHIELD3) and a Guest partition (IOS2) running. We also have a couple of other servers which are powered off at the moment which are not important for this exercise.

Initial-HMC

First thing to do is create the configuration for the LPAR, we created one called RedHat with the following requirements.
1. The Partition would use .2 of a processor uncapped.
2. Maximum Virtual processors will be 2.
3. It will have 1GB of memory.
4. It will use the LHEA resource for the LAN.
5. We need a Serial Server Virtual adapter for the console.
6. It will not have Power control
This is the summary which is produced for the LPAR profile.

New-RedHat-partition-information

You will notice we have no Physical IO, all of the storage is provided by the Virtual storage device. The next change we have to make is to add the storage definition to the Hosting partition. We need to add the change twice as the LPAR is currently running because updating the profile will only take effect once the partition is restarted, we need the active partition to be updated to recognize the new storage requirement.

Here is a picture of the updated Host Partitions Virtual adapter settings. We also added it to the profile so when a restart of the LPAR happens the new profile will have the same information. Strange IBM doesn’t automatically update the profile.

SCSI-adapter-update-Host-LPAR

That is all we had to do for the HMC configuration we did a quick start of the LPAR with a console screen which showed it connected correctly and we did manage to see the initial startup of the console connection.
Next we created the objects required in the hosting partition to allow the LPAR to be started and installed.
First step is to create the Console user for the remote console access. This allows the console to be started and have sufficient authority to carry out the required tasks. To configure you need to go through SST and create a new Console user which is accessed from the Work with service tools user IDs and Devices menu option then the Service tools user IDs menu option. Most of the default options are acceptable but you need to add at least the following options when you create the new ID.
– System partitions – operations
– System partitions – administration
– Partition remote panel key
Once you have updated the profile you can exit back to the command line and the profile should be enabled for use. Here is a view of the profile authorities after creation.

Console-User

To install RedHat we need to create a Network Server Description, this is connected to a Network Storage Space which is how the installation can be carried out. To install RedHat we need to create a storage space of about 6GB according to the manuals we looked through. The recent install of Linux SuSe (which was the first install we did) worked well with 10GB of disk space so we thought we would use a bit more for this install just so we can install more utilities so we settled on 20GB.
Creating the NWSD is the first object to be created, there are a couple of items we tripped over so we have added a couple of images of our configs to show them.
First of all we found the use of *AUTO required the Partition entry had to match exactly the HMC definition we had created. We also wanted to control when the partition was started so we changed the Online at IPL to *NO.

Network Storage definition 1

The next changes are related to the installation media, we used the WRKLNK command to find the correct path to the install image on the CD, the manuals we had read through previously had totally different paths defined so it is important you find the correct path before you attempt to do the install

Network Storage definition 2

We are going to install the product from a *STMF (we were baffled by the AIX install which was installed from CD but had *NWSSTG as the IPL source?). Another gotcha is the Power Control setting, make sure that this is set to *NO for the installation otherwise the NWSD will refuse to vary on. We added the VNC=1 to say we want to have a VNC server started at IPL. This allows us to get to the graphical interface when using RedHat.
Now the definition is created we need to create the network storage space to attach to the definition. As with all IBMi functions you can access them via the menu or list options plus use the command directly. Here is our storage space setup.

Network Storage Space 1

After pressing enter the system will go out and allocate the entire space and format it for use. The disk utilization will increase based on the amount allocated not

Network Storage definition 2

The format and allocation of the space takes a bit of time so time to make a coffee while you wait. Once the storage space has been created and formatted you now need to link the storage space to the definition.

Network Storage Link defined

Now we are ready to activate the partition. You can achieve this by taking option 8 from the WRKNWSD list which will show you the partition and take option 1 against it. If the NWSD does not become ACTIVE you have a configuration problem somewhere which has to be resolved before you can go any further.

Active Network Storage Definition

We are now ready to install the Linux OS. The redbook we looked at mentioned the ability to use the VNC graphical interface to do the install but as we have no network connection to the install device we could not figure out what they were on about? So we took the console window option as the only way we could install the RHE OS. To get to the console just start the partition from the HMC and select the Open Terminal Window from the Console dropdown. You should see something like the following.

Console-window

The option 1 which is out of sight in this picture is the first option to take it sets the language for the install. Next we need to set up the boot options. Your install may be different so you may need to change a few things. We were installing from the CD so we had to select the device information using the options presented after pressing option 5. Once the boot device had been set the console will re-connect and see the installation image available on the CD.

Booting-from-CD-into-RedHat

We had to press enter a couple of time to get through to the actual installer (anaconda) and we also took the option not to check the media as we decided as it has only just been created and it has not been scratched or anything else it should be OK. The install procedure is pretty straight forward although the selection process for some entries was a bit confusing but after letting the Autopartition do its business and allowing it to remove all existing data the install went off pretty smoothly. We only used the default installation for expediency as we are only going to use this demo development with PHP and Easycom in mind although that did amount to 692 packages..
Once the installation is finished you can remove the installation CD and press enter to reboot the partition. At this point it will not be able to start RedHat because the NWSD is set to start from the CD so it will simple go into the console management software, just close the terminal window at that point.
We now need to tell the NWSD where the real boot device is so we need to go in and set the correct boot point which is the *NWSSTG option. This requires the NWSD is turned off and started again after it is updated. The following screen shows the new settings.

Active Network Storage Definition

Now we should be able to start the partition again and it will boot into RedHat. For us the partition in the HMC was showing it was loading the Firmware so we took the option to end the partition and started it up again. This did bring up the same state because it was trying to boot from the network, we simply change the boot device back to the Hard Drive we had configured and it started up.

RedHat partition re-booted

Now we need to configure the network etc so we can access the OS from the VNC client and Putty, as this is specific to our install we have not provided screen shots and this is a normal activity for configuring Linux. Perhaps once we get the Apache Server up and running with Easycom installed we will go over that part?

So that is it we now have a fully functioning RedHat Enterprise partition running as a Guest under an IBMi hosting partition.

If you have any questions about the install or what we have done since let us know.

Chris…

Feb 15

IBMi running a Guest AIX Partition accessing IBMi data.

We have been playing around with the setup of our IBMi system to run various guest partitions that are running difference supported OS’s. The first install was another IBMi guest partition which would allow us to run HA testing between partitions and not require the use of a second system. The next partition we installed was a Linux partition which is running SuSe Linux, this is going to allow us to test the running of Easycom clients to the IBMi Easycom servers to pull back IBMi data and objects. Finally the last partition is going to be running AIX which will be used as a test platform to run PHP/Easycom in the same manner we do for Linux. As an additional future option we will install a RedHat partiton to allow us to run the PHP Easycom processes mainly to allow us to get comfortable with running RedHat and the PHP/Easycom setup.

The IBMi install was a breeze when we look back, setting up the initial Partition information using the HMC and building the NWSD etc was a challenge but IBM was very good at helping us get things running. Due to the lack of supply of the AIX software (that’s a whole story on its own) we moved to the Linux install next, with all of the information we had gathered while setting up the IBMi partition that went very well and took less than a day to complete including all the configuration.

AIX is a totally different story, to say I hate AIX is pretty strong but I am not far off. Trying to get a reason interface (KDE was our preference) and a VNC server setup and running has been a nightmare! I though with the limited knowledge we have with Linux it should be pretty achievable but that was not to be! BUT we have finally managed to get things up and running (I am not sure I want to try to restart the box though in case it does not come back up in the same manner) and have a working PHP/Easycom install. I should warn you the PHP/Easycom install is a botch up that we did with the help of our friends at Aura, we have taken the iAMP server and chnaged a few things to allow it to run on AIX, putting it all together in an RPM is a distant dream but it should be possible. IBM does have its own Apache and PHP bundle but we took the iAMP server route to see just what issue it would present and how effective it will be when running the i5_toolkit function to the IBMi and we could not be sure the AIX modules generated would run under the IBM bundle.

So long story short we now have a working POWER Systems configuration that allow AIX to pull IBMi data and objects for the HTTP server to present.

Here is a picture of the VNC client running on a Windows 7 Laptop that is connected to a AIX Guest running under a IBMi hosting partition running iAMP server and pulling data from another IBMi parition! WoW that a lot of complexity!

AIX running under IBMi through a VNC connection

Now to grow some hair back.

Chris..