user@srv: db2ccNo protocol specifiedError: Can not open display
11/01/2013
Не запускается 'Центр управления' (db2cc) - Can not open display
10/16/2013
Dynamic query variables in Maximo
:no – false
:&date& – current date
:&datetime& – current date/time
:&user& – logged in user
:&personid& – person ID of the logged in
:&appname& – application name
:&mboname& – name of the current business object
:&ownername& – name of the owner business object
:<relationshipname>.<attrname> – value of an attribute of a related business object of the current business object
:&owner&.<attrname> – value of an attribute of the owner business object
:&owner&.<relationshipname>.<attrname> – value of an attribute of the related business object of the owner business object
:$old_<attrname> – the initial value from the database of the attribute
10/04/2013
Cloning one Maximo 7.5 Administrative Environment to Another Machine
Question
Answer
2. Backup the database this Maximo connects
On the second machine:
9/16/2013
Принудительное обновление Старт-Центров MAXIMO
Для всех групп:
DELETE FROM MAXIMO.SCCONFIG;
или для конкретной группы:
DELETE FROM SCCONFIG WHERE GROUPNAME = 'SECURITYGROUPNAME';
8/12/2013
Installing JAD in Eclipse
Link for JAD for different platforms
p.s.
It's work's in Eclipse 4.2. But not in 4.3.
How to Create Application Restrictions via Presentation.xml
- Open Application Designer by choosing Go To > Configuration > Application Designer.
- Type the name of the application you wish to open, or press Enter to display a list of applications.
- As an example, open the Assets application in the Workspace tab.
- Click Select Action > Toggle Show All Controls.
- Click the "presentation..." control.
- Click the Control Properties button to open the Presentation Properties dialog box.
- In the Where Clause field, enter "inactive=’0’". Application Designer interprets the query as "select * from asset where inactive=’0’".
- Click Save.
8/08/2013
Определение переменных окружения в Linux при загрузке системы
2. Наполняем созданный файл переменными, например:
export EC2_HOME=/usr/ec2-api-tools-1.6.8.1/
export PATH=$PATH:$EC2_HOME/bin
export AWS_ACCESS_KEY=<AWS_ACCESS_KEY>
export AWS_SECRET_KEY=<AWS_SECRET_KEY>
Проверить можно командой, например: echo $EC2_HOME
8/04/2013
Создание, редактирование и удаление SWAP в Linux
1. Общая информация
SSH, аутентификация по ключам
Теперь переименуем id_rsa.pub в authorized_keys
На всякий случай перезапускаем SSHD: /etc/rc.d/sshd restart
Файл id_rsa копируем на компьютер с которого планируем подключаться. Используем в качестве закрытого ключа для подключения.
7/31/2013
IBM Maximo: Rebuilding and Deploying maximo.ear
7/30/2013
Changing configured database, password, server names in Maximo v7
1. Update the \ibm\SMP\maximo\applications\maximo\properties\maximo.properties file on the Admin Workstation to change the IP-Address/Hostname for either the database server or the webserver. Also to update the password
a. Delete the file named maximo.properties
b. Rename the file named maximo.properties_orig to maximo.properties (this is an unencrypted file)
c. Edit the maximo.properties file and update the hostname/IP-address for the database server.
d. If necessary, update the password for the user to access the database
e. Save the file
Note: The file will be automatically re-encrypted when you install a fixpack or other product. If this is not an immediate activity, you can run encryptproperties.bat file located in C:\ibm\smp\maximo\tools\maximo directory against the file to encrypt it.
2. Update the \ibm\SMP\etc\install.properties file on the Admin Workstation to change the IP-Address/Hostname for either the database server or the webserver.
3. Update the values in the maximo database to change the IP-Address/Hostname for a variety of servers, or to update passwords.
a. Connect to the maximo database using your favorite SQL editor utility.
b. Query the maxpropvalue table, and find the key you need to edit. For example, WAS.DeploymentManagerHostName is the key for the hostname or IP address of the WebSphere machine.
c. Create a query to update that value to the new value, and run the query.
d. Repeat for any passwords, ip addresses etc that need to be updated.
4. Rebuild and redeploy the EAR files.
7/29/2013
Maximo bind variables
7/28/2013
Maximo Post Install configuration
- Create Currency codes:
- Goto Financial->Currency codes.
- Click on New row.
- Enter a name (ex:- USD).
- Enter description (ex:- United States Dollar).
- Save.
7/26/2013
DB2: Восстановление бэкапа базы в существующую базу с другим именем
• Получена с базы данных с таким-то алиасом
• Числовое представление типа резервной копии такое-то (0 для полной копии базы, 3 для копии табличного пространства, 4 для копии полученной с помощью LOAD)
• База данных обслуживалась экземпляром (instance) DB2 с таким-то именем
• Копия содержит такой-то узел базы данных (всегда NODE0000 для однораздельных БД)
• Номер каталога узла (всегда CATN0000 для однораздельных баз)
• Время снятия резервной копии
• Номер образа
4/24/2013
2/28/2013
Sample Action Class
Sometimes you have to implement some complex logic in workflows or escalation and you feel limited by the out-of-the-box Maximo actions. In these cases you can unleash the Java power and code your algorithm in a custom action class.
In order to create a custom action class, you must extend the psdi.common.action.ActionCustomClass class.
import java.rmi.RemoteException;
import java.rmi.RemoteException;
import psdi.common.action.ActionCustomClass;
import psdi.mbo.MboRemote;
import psdi.util.MXException;
public class SampleAction implements ActionCustomClass
{
public SampleAction()
{
super();
}
public void applyCustomAction(MboRemote mbo, Object[] params)
{
// Write custom code here
}
}
2/27/2013
Maximo Developer 101: Lession 4 - Extending MBOs
One of the basic tasks in customizing Maximo is extending the MBOs. Remember, much of the business logic is placed in the MBOs so if you want to add custom business logic, you will need to extend the existing MBOs.
First, let's talk about the path (package) naming for your custom MBOs.
Standard IBM proceedure is to use the same path, only changing the top level value. For example, the Maximo class path for Asset is: psdi.app.asset.Asset.class. So you would name your customization: myCompany.app.asset.Asset.class.
Ok, now when you extend an MBO, you actually have to extend 6 class files. You have to extend the MBO class and the MBO Set class. Then there is a "remote" class for each. Finally the each has a "stub" file. I know this sounds like a lot but in truth, the most of your custom work will be in the MBO class and a maybe a little in the MBO Set file. The two "Remote" files will just be extensions of the base "remote" classes. And as for the two "Stub" files, you will use an XML file that will generate these for you.
At this point, I am going to strongly recommend you download and install the Maximo Developer for Eclipse. This tool will build the four files (MBO, MBO Set, and two remote files) for you. What makes build these files easier is that IBM uses a standing naming system for them. For example say you want to extend the Asset MBO. Well the four files are named as follows: Asset, AssetSet, AssetRemote, AssetSetRemote. (If you are using the Maximo Developer, then you will need to specify the MBO class file name and not the MBO set name.)
The last step is you need to create an ANT file (this is just a special XML file). This file is a set of instructions that will create the two ";stub" files. The following will compile the stub files for extending the Asset MBO.
Maximo Developer 101: Lesson 3 - Working with Business Objects
Although there are class files for different MBO in Maximo (one for Asset, WorkOrder, etc.), these all extend the same base object. This means you can use this based object to do 90% of what you need to do. When access an MBO, you first use what is called and MBO Set object. The main class you will use is called “MboSetRemote”. You get an MBO set object by using the MXServer object.
Now that we have our collection of records we want to work with, we now need to get each record. We do this by using the getMbo() method. Of course you need make sure you have any records to process and we can do that with the .count() method. This will return how many records match your “setWhere”.
Just like how all MBO Set objects extend the same object, so do each of the record objects. They extend the MboRemote object. Again, you can do 90% of what you need to do.
{
for (int i=0; i < myAssetSet.count(); i++) {
psdi.mbo.MboRemote currentAsset = myAssetSet.getMbo(i);
}
}
Maximo Developer 101: Lesson 2- Maximo Fundamentals
First thing to know is that when programming Maximo is that it is database agnostic. What I mean by this is that Maximo does know what database it is using. What does this mean to you? Well if you are trying to develop something in Maximo and hope to sell it, then you need to make sure that your enhancement is also database agnostic. If you are developing something in-house and will never change database platforms, then this is not that big of a programming concern, but it is a good practice to do it anyway.
Next thing to know is that Maximo is an Object Oriented database. Now you might be wondering how this can be since the physical database is a standard relational database (DB2, Oracle or SQL Server). Maximo does it the same way that the Java tool Hibernate does it, through a set of class files that manage all physical read/writes to the database. As a developer, you just would use the class files for accessing the database. IBM however did not use Hibernate for the Object Oriented interface. Instead, they created their own set of classes call Maximo Business Objects (MBOs) (pronounced M.B.Os or Maybows). Since Maximo is database agnostic, there is no guaranteed way to place business rules and all data integrity requirements in the database. As such, Maximo places almost all of this in the MBOs. In the database, the only data integrity you will find are unique indexes and required fields. None of the tables have primary keys, Foreign Keys or default values. This makes updating/adding data directly to the database tricky at best. It is entirely possible to enter data into the database and have it not show up in the front end because it does not meet Maximo’s data requirements. You are safe to query the database directly but all updated/inserts/deletes should be done in Java using the MBO objects. Another benefit of using the MBOs is that your code then becomes database agnostic too.
Maximo Developer 101 – Getting Started
So you want to be a Maximo developer. Well the first step is to setup your development environment. First you will need a Maximo development environment. This guide does not cover how to set that up. Although you can technically use any Java IDE, IBM recommends Eclipse IDE. All documentation from IBM is for Eclipse as well as an add-on or two are available for it. So the next question is always “What version?” Any version of 3.1 or above. You can download Eclipse here: http://www.eclipse.org/.
Next you will want to download the setup guides from IBM:
Maximo Eclipse Developer Setup Guide
Maximo Developer Remote Access Guide
Now these guides were created for Maximo 6 but they still work for Maximo 7 with the following changes
- The guide says Eclipse 3.1 but any newer version will work
- Step 1 of the Maximo Eclipse Developer Setup Guide says “Make sure that you have follow all the steps in the document MXES-Initial Eclipse 3.1.1 Setup”, this just means to make sure Eclipse is installed.
- Maximo 7 uses Java 1.5 while Maximo 6 uses Java 1.4
The setup guide talks about how to setup for doing MBO extension. This will also work for field classes and integration development. If you want to do screen development, then you will also need to add to your library the class folder %maximo%/maximouiweb/webmodule/WEB-INF/classes as this is where app beans and data beans are stored.
A couple of other useful tools are:
- Maximo Developer : This is an Eclipse plug-in that helps automate the creation of Mbo Class extensions.
- Maximo View Log : This is a web based tool for quickly viewing the Maximo Log
At this point, you should have a development environment for doing your Maximo work. So, what next? Here are some other resources available to you:
-
Problem(Abstract) Receiving errors on the Database Configuration screen when shutting down Admin Mode: BMXAA4030I - Starting to set Ad...
-
Technote (troubleshooting) Problem(Abstract) Unable to login to Maximo - receiving errors about connecting to the server has been tempor...
-
Technote (FAQ) Question How can I retry or delete a large number of messages without using the user interface to process small sets o...