Thursday, October 23, 2014

openSUSE 13.x / Factory processor P-States and Performance

Since the introduction of P-States in the Intel SandyBridge and newer processors and the introduction of the P-States driver in the kernel since 3.9 there have been some changes to the power management on systems in regards to userspace tools. It has moved from cpufreq to cpupower and you may have written a script in times past to help set the right power management governor for your system. On a system with P-States you find that using cpupower has no effect on the performance whatsoever when you change the governor with cpupower. In order to get high performance out of your system with P-States you will need to look at some parameters into sysfs and change them using the userspace tool cpupower. Lets have a look at what there is for P-States.
Change your directory to /sys/devices/system/cpu/intel_pstate

system:/sys/devices/system/cpu/intel_pstate # l
total 0
drwxr-xr-x  2 root root    0 Oct 21 18:45 ./
drwxr-xr-x 14 root root    0 Oct 21 18:45 ../
-rw-r--r--  1 root root 4096 Oct 21 18:45 max_perf_pct
-rw-r--r--  1 root root 4096 Oct 21 18:45 min_perf_pct
-rw-r--r--  1 root root 4096 Oct 21 18:45 no_turbo
We have the max_perf_pct and the min_perf_pct and if we cat these files we can see their values.
# cat max_perf_pct
100
# cat min_perf_pct
32
This is the default for a powersave governor which you can gather from running the following command.
# cpupower frequency-info
  analyzing CPU 0:
  driver: intel_pstate
  CPUs which run at the same hardware frequency: 0
  CPUs which need to have their frequency coordinated by software: 0
  maximum transition latency: 0.97 ms.
  hardware limits: 1.20 GHz - 3.70 GHz
  available cpufreq governors: performance, powersave
  current policy: frequency should be within 1.20 GHz and 3.70 GHz.
                  The governor "powersave" may decide which speed to use
                  within this range.
  current CPU frequency is 3.53 GHz (asserted by call to hardware).
  boost state support:
    Supported: yes
    Active: yes
    3500 MHz max turbo 4 active cores
    3500 MHz max turbo 3 active cores
    3600 MHz max turbo 2 active cores
    3700 MHz max turbo 1 active cores
Notice the driver is intel_pstate and the current policy is set to powersave

We want the performance governor. So we will need to change our governor to performance. Execute the following.
# cpupower frequency-set -g performance

# cpupower frequency-info
analyzing CPU 0:
  driver: intel_pstate
  CPUs which run at the same hardware frequency: 0
  CPUs which need to have their frequency coordinated by software: 0
  maximum transition latency: 0.97 ms.
  hardware limits: 1.20 GHz - 3.70 GHz
  available cpufreq governors: performance, powersave
  current policy: frequency should be within 1.20 GHz and 3.70 GHz.
                  The governor "performance" may decide which speed to use
                  within this range.
  current CPU frequency is 2.83 GHz (asserted by call to hardware).
  boost state support:
    Supported: yes
    Active: yes
    3500 MHz max turbo 4 active cores
    3500 MHz max turbo 3 active cores
    3600 MHz max turbo 2 active cores
    3700 MHz max turbo 1 active cores
Also if we cat /sys/devices/system/cpu/intel_pstate/min_perf_pct you will notice that it has changed to 100

Thats good its all at 100% but wait we still are not done. There is another setting for P-States. Its called Performance Bias. From the man page cpupower-set you can read the following about it.

----snip----
Options
--perf-bias, -b
Sets a register on supported Intel processore which allows software to convey its policy for the relative importance of performance versus energy savings to the processor.

The range of valid numbers is 0-15, where 0 is maximum performance and 15 ismaximum energy efficiency.

The processor uses this information in model-specific ways when it must select trade-offs between performance and energy efficiency.

This policy hint does not supersede Processor Performance states (P-states) or CPUIdle power states (C-states), but allows software to have influence where it would otherwise be unable to express a preference.

For example, this setting may tell the hardware how aggressively or conservatively to control frequency in the "turbo range" above the explicitly OS-controlled P-state frequency range.It may also tell the hardware how aggressively it should enter the OS requested C-states.

This option can be applied to individual cores only via the --cpu option, cpupower(1).

Setting the performance bias value on one CPU can modify the setting on related CPUs as well (for example all CPUs on one socket), because of hardware restrictions. Use cpupower -c all info -b to verify.

This options needs the msr kernel driver (CONFIG_X86_MSR) loaded.
----snip----

So lets set our bias to 0 so we can get absolute maximum performance. The default is 8 on openSUSE. Execute the following.
# cpupower set -b 0
and to check it.
# cpupower info
analyzing CPU 0:
perf-bias: 0
even though it only shows CPU 0 it applies for all and you can see that by adding the -c all switch before info.
Now you have a system running at full performance with P-States.
Note: This will run the CPU's hot and the fans will kick in full speed all the time. So when your away from your system or don't need full performance you will want to put it back in powersave. I'm not responsible for overheating of your CPU. :-)

Thursday, October 16, 2014

SUSE Cloud 4 OpenStack Admin Appliance; Updated

I hope all who have been using the appliance are enjoying it and finding it useful. I felt it time to update the appliance to include patches to the latest known threats and critical updates to OpenStack.

Latest version 4.0.3

Changes from Github Project
  • Refreshed the Update Repositories to contain latest patches
  • Applied latest Updates to the Appliance
Direct Download links
Please visit the the landing page for the appliance to get more information and documentation here.
Some future things that are coming to look forward to. 
  • Incorporating an Installation media which includes the latest packages from the update repositories for SLES 11 SP3, High Availability Extension, and SUSE Cloud 4 OpenStack. This Installation media will allow me to exclude the full update repositories on the image and therefore reduce the size of the image to just under 2GB. 
  • Moving the build of the image over to openSUSE OBS (Open Build Service) to allow more rapid deployment and testing.
These things will allow for greater portability of the OpenStack software and inherent with it you can install anywhere. Install on VMware. Install on Virtual Box. Install on KVM. Install on Bare Metal. You can truly use this image to deploy and test it out on VMware or KVM, and from the same image you can use it to deploy a full production OpenStack on Bare Metal.  I have even used it to install and test OpenStack out on AWS. So go forth and enjoy installing OpenStack with ease. I challenge you to start using this appliance and see how easy it can be to setup and run OpenStack software. 

Thursday, August 28, 2014

SUSE® Cloud 4 OpenStack Admin Appliance – An Easier Way to Start Your Cloud

If you used the SUSE Cloud 3 OpenStack Admin Appliance, you know it was a downloadable, OpenStack Havana-based appliance, which even a non-technical user could get off the ground to deploy an OpenStack cloud. Today, I am excited to tell you about the new Icehouse-based SUSE Cloud 4 OpenStack Admin Appliance.

With that initial SUSE Cloud 3 release, there were two versions: Standard and Embedded. After feedback from users it was clear that the user experience was not much different between the two, and the important goal was to reduce the overall size of the download. To address the situation, I came up with some innovations that led to a single, smaller image that incorporates the functionality of both the Standard and Embedded versions.

The new appliance incorporates all of the needed software and repositories to set up, stage and deploy OpenStack Icehouse in your sandbox lab, or production environments. Coupled with it are the added benefits of automated deployment of highly available cloud services, support for mixed-hypervisor clouds containing KVM, Xen, Microsoft Hyper-V, and VMware vSphere, support from our award-winning, worldwide service organization and integration with SUSE Engineered maintenance processes. In addition, there is integration with tools such as SUSE Studio™ and SUSE Manager to help you build and manage your cloud applications.

With the availability of SUSE Cloud 4, and based on feedback from partners, vendors and customers deploying OpenStack, it was time to release a new and improved Admin Appliance. This new image incorporates the most common use cases and is flexible enough to add in other components such as SMT (Subscription Management Tool) and SUSE Customer Center registration, so you can keep your cloud infrastructure updated.

The creation of the SUSE Cloud 4 OpenStack Admin Appliance is intended to provide a quick and easy deployment. The partners and vendors we are working with find it useful to quickly test their applications in SUSE Cloud and validate their use case. For customers it has become a great tool for deploying production private clouds based on OpenStack.

With version 4.0.x you can proceed with the following to get moving now with OpenStack.

Its important that you start by reading and understanding the Deployment Guide before proceeding. This will give you some insight into the requirements and an overall understanding of what is involved to deploy your own private cloud.

As a companion to the Deployment Guide we have provided a questionnaire that will help you answer and organize the critical steps talked about in the Deployment Guide.

To help you get moving quickly the SUSE Cloud OpenStack Admin Appliance Guide provides instructions on using the appliance and details a step-by-step installation.

The most updated guide will always be here

Changes from Github Project
- This version contains the GM version of SUSE Cloud 4 and any updates to this date
- Prepare source for SUSE Cloud 4 media and requirements
- Added proxy as a module in the firstboot phase
- Added HA patches
- Replaced lamp_server pattern with SMT server pattern, so SMT is now integrated
- Added ability to grab SMT repos from external USB drive source. Inherent now with the image
- Added ability to attach to remote SMT. Inherent now with the image
- Reformatted the SLES 11 SP3 update repo into a mini formatted repo
- Redesigned firstboot
- Removed build repos from appliance after build phase

Now is the time. Go out to http://www.suse.com/suse-cloud-appliances and start downloading version 4, walk through the Appliance Guide, and see how quick and easy it can be to set up OpenStack. Don't stop there. Make it highly available and set up more than one hypervisor, and don't forget to have a lot of fun.


Enjoy!

Friday, April 25, 2014

Updated: SUSE Cloud 3 Admin Appliance 1.2.0 available

Continuing in our efforts to create the SUSE Cloud 3 Admin Appliance into a quick and easy way to deploy OpenStack, we have reached version 1.2.0. You can download the Standard or Embedded version. The major change in this version has to do with the consolidation of the logic code required to maintain both images and splitting out some obvious differences between the two appliances. The Embedded appliance now distinctly has the customer center registration and patch mirror process removed as part of the setup as it slowed down the deployment and ease of use it was intended to have. Although it still maintains its ease of use and deployment it is much quicker now and requires less required input to get OpenStack up and running. This is certainly ideal for quick testing and kicking the tires with SUSE Cloud and OpenStack. The Standard version is still the same, but again has all of the same logic rolled up into it, but the steps still remain the same. It is ideal for deploying SUSE Cloud into a production environment.

Standard v1.2.0: https://susestudio.com/a/Mrr6vv/suse-cloud-3-admin
Direct Download links for SUSE Cloud 3 Admin:

Direct Download links for SUSE Cloud 3 Admin (Embedded):

The most updated guide will always be here
Changes from Github Project
1. consolidate as best I can first boot and init scripts
2. add a proper README.md
3. README and appliance guide don't distinguish between two types of appliances
4. documentation missing
5. don't require NCC (Customer Center Registration) / SMT registration by default on Embedded images

Enjoy!

Monday, April 21, 2014

Updated: SUSE Cloud 3 Admin Appliance 1.1.0 available

Continuing in our efforts to create SUSE Cloud 3 Admin Appliance into a quick and easy way to deploy OpenStack, we have reached version 1.1.0. You can download the Standard or Embedded version.

Standard v1.1.0: https://susestudio.com/a/Mrr6vv/suse-cloud-3-admin
Embedded v1.1.0: https://susestudio.com/a/Mrr6vv/suse-cloud-3-admin-embedded

Standard has a process which will mirror all of the required repositories for the Admin Server, and contains the SLES 11 SP3 / SUSE Cloud ISO's

Embedded has everything that the standard image has and all of the required patch and update repositories in the image ready for you to consume. It might take a little longer to download but might be worth the wait if you need something with everything included and you want a quick testing environment to play with.

Changes from Github Project
1. restructure files into proper kiwi build directories to make it easier to build from a checkout
2. shell code needs consistent indentation
3. add a proper README.md
4. eliminate disk wastage from rebuilding huge .txz
5. eliminate copy'n'paste between setup-suse-crowbar*
6. Provide sensible default network config as outlined in the Deployment Guide
7. mount SLES 11 SP3/Cloud ISOs permanently instead of extracting files once the appliance is deployed

Monday, April 7, 2014

Quickly Setting-up an OpenStack Cloud with the SUSE Cloud 3 Admin Appliance

In an effort to make OpenStack available to the non-tech user and appear much less of a heavy lifting project for them, I have created the SUSE Cloud 3 Admin Appliance. I have worked with so many partners, vendors, and customers deploying OpenStack with SUSE Cloud that the idea came to me that SUSE had some great tools that would enable me to create something that they could use to easily deploy, test, and discover OpenStack on their own without a whole lot of effort required. SUSE has integrated Crowbar/Chef as part of the installation framework for our enterprise OpenStack distribution – SUSE Cloud – to improve the speed of deploying and managing OpenStack clouds. This has allowed us to be flexible in our deployment when working with partners and software vendors and provide greater ease of use.

The creation of the SUSE Cloud 3 Admin Appliance is intended to provide a quick and easy deployment. The partners and vendors we are working with find it useful to quickly test their applications in SUSE Cloud and validate their use. Beyond those cases it has become a great tool for deploying your production private cloud based on OpenStack.

I have developed two different appliances and you can find them here:

Standard v1.0.1: SUSE Cloud 3 Admin Standard
Embedded v1.0.1: SUSE Cloud 3 Admin Embedded

Standard has a process which will mirror all of the requiredrepositories to the Admin Server.

Embedded has all of the required repositories in the image ready for you to consume. It might take a little longer to download, but might be worth the wait if you need something portable that can quickly load a private cloud.

This is version 1.0.x

Its important that you answer several questions before proceeding. You can find those questions in the SUSE Cloud 3 Deployment Guide

This Questionnaire will help you as a companion to the Deployment Guide. SUSE Cloud Questionnaire

This guide on using the appliance can help walk you through step by step. SUSE Cloud Admin Appliance Guide

- This version contains the GM version of SUSE Cloud 3
- Disabled IPv6 - Added motd (Message of the day) to reflect next steps
- Updated logos and wallpaper to align with product
- Updated init and firstboot process and alignment with YaST firstboot

Enjoy!

Friday, April 4, 2014

VMware Workstation 10.01 and kernel 3.14 patch

Download this patch

Then follow these steps from a terminal as root user
# cd /usr/lib/vmware/modules/source/
# cp vmnet.tar vmnet.tar.original
# tar xvf vmnet.tar vmnet-only/filter.c
# patch vmnet-only/filter.c < /location_of_filter.c.diff/kernel-3.14-vmware-filter.c.diff
# tar -uvf vmnet.tar vmnet-only/filter.c
# rm -rf vmnet-only/
# vmware-modconfig --console --install-all 
 Enjoy!

openSUSE 13.1 with kernel 3.14 and NVIDIA

Run the following.

Download this kernel patch

Download the NVIDIA driver version NVIDIA-Linux-x86_64-331.49.bin

from root execute:
   # sh NVIDIA-Linux-x86_64-331.49.bin --apply-patch kernel-3.14-nvidia.patch

Now install the custom NVIDIA Driver.
Enjoy!

Running Blackboard Collaborate (Elluminate!) on SUSE SLE11 and openSUSE 13.1

So if your struggling to get the full functionality out of Blackboard Collaborate. Usually your unable to get the Application Sharing to work properly, but there might be other reasons. Here are a few scripts that I have created that will allow Blackboard to run properly either with Oracle Sun Java 1.7 or with openJDK Java.

For openJDK Java 64bit:

1) Download this script
2) Copy the script prepare-openjdk-blackboard.sh to your system anywhere you prefer locally
3) Login as root
4) execute from your locally preferred location.
     # ./prepare-openjdk-blackboard.sh
5) Open Firefox and launch Blackboard Collaborate from the Guest or Chair Link and Select the webstart that shows up automatically. Enjoy Blackboard Collaborate on openJDK 64bit Java.

For Oracle SUN Java 64bit (Supported):

1) Download this script
2) Copy the script prepare-oracle-java-blackboard.sh to your system anywhere you prefer locally
3) Login as root
4) execute from your locally preferred location.
     # ./prepare-oracle-java-blackboard.sh
5) Open Firefox, and select Preferences. Applications. In the search box, type 'jnlp' In the drop down under Action, choose 'Use Other', and browse to /opt/java/64/jre1.7.0_51/bin/javaws
6) Launch Blackboard Collaborate from the Guest or Chair Link. Enjoy Blackboard Collaborate on 64bit Oracle SUN Java.

Enjoy!

Greetings OpenStack Planet!

Joining the OpenStack blogosphere. I will soon have some posts around SUSE Cloud. Stay tuned.
-C