Hi,
What is installation package and how to create it?
When we run:
in AIX:
or
in Linux
What is package1 or mypackage in the abov examples and how to create them and deploy them?
I hope my question is clear enough.
Thank you
Last edited by Don Cragun; 02-18-2019 at 02:16 AM..
What is installation package and how to create it?
Suppose you have a certain program /usr/bin/myprogram that you want to run also on another system. You could of course just copy the executable file to the remote system, but maybe the program needs some other files to work properly. For instance:
You could still take every single file and transfer it to another system but it make things a little easier to put that all together into one file which you then could transfer to the target system. i.e. you could use a tar archive, put the three files necessary into it and then unpack that on the target system to have all three files put into their respective place at once. That would at least guarantee that you will not forget one of the files when you copy the program to the new system.
Now, the program, in order to run properly, may need to have some adjustments be done on the system too: maybe it uses a special user account to run which has to be created, maybe it should be started at system start so you need to create startup routines and put their call to the system startup files (in AIX /etc/inittab, in Linux in systemd configuration files, etc.) and so on. So, in order to not forget any of these things, you may create some sort of script that does that for you and put that into the tar archive too.
But there still is a problem: you may need not only to put the program onto systems, you may eventually want to remove it from some of them after a while. For this you do not want to leave a trace of leftovers and ideally after installing it and removing it the system should be in the same state as before. That includes, in addition to removing the files you put there, you need to remove all changes made to already existing files, removing user accounts created, etc.. You may want to write another script to do this again because if you do it manually yo may forget the one or other thing.
Now, wouldn't it be great to have a program for all that? A program which you can tell which files to install, which actions to take upon installation, upon deinstallation, upon updating, and so forth? Exactly this is a package and the program to use such packages is called a package manager. rpm ("RedHat Package Manager") is one of such package managers, developed for Linux but now available on many systems. installp is the package manager for AIX. AIXpackages come in a certain format ("backup file format", bff, which is why they all have the extension ".bff") and there is a program makebff which you can use to create such packages.
You should read up on how to work with packages in general and AIX packages in specific (there is an IBM Redbook about this) before attempting to automate your work with packages though. Building and maintaining packages is not easy and you don't learn it in minutes. It is easy to create very bad packages which will even increase your administration work and make it more complicated. It can take some effort and experience to create well-crafted packages that will help you a great deal in your daily work.
I hope this helps.
bakunin
These 2 Users Gave Thanks to bakunin For This Post:
Hello,
i have installed a package by using the command
sudo rpm -i filepackage.rpm
package filepackage is already installed
when i try to remove it, i get an error saying "is not installed":
sudo rpm -e filepackage.rpm
error: package filepackage is not installed
How can... (4 Replies)
Hello,
i have downloaded an rpm package "hadoop-0.20.205.0-1.amd64.rpm"
in /usr/local/ directory.
I'm trying to install the rpm package in a new path/location (/usr/local/hadoop-0.20.205), but i can't.
I did:
1st try: Didn't work
sudo rpm -i --prefix=/usr/local/hadoop-0.20.205... (1 Reply)
Dear all,
I would like to install a new version of package without remove old version on Centos and vice versa.
Please give me advice!
thanks much, (2 Replies)
Friends,
Please let meknow, How we can find the dependancies of .dstream package & .rpm package before installation ?
For AIX, We can use the inutoc . command to create the .toc file for the bff package, What about Solaris & Linux ? (0 Replies)
Hello, I'm trying to build a (bff) package from an already installed program (clam antivirus) using mkinstallp. However, mkinstallp fails with "no such file: ./usr/lpp/<package name>/inst_root"
I'm not sure why all files get created ok except for these particular ones. Any help would be... (2 Replies)
hi i installed wine1.1.2-sol11-i386.pkg.bz2 but wine doesnt work error err:process:start_wineboot failed to start wineboot, err 1359
how can i uninstall that package and how can i fix that error (2 Replies)
Hi all^^
after upgrade joomla (1.5.7-1.5.11) this package , and then
portaudit -Fda
fetch: http://www.FreeBsd.org/ports/auditfile.tbz: No address record
Couldn't fetch database.
Old database restored.
portaudit: Download failed
what wrong??? (1 Reply)
I am working with sun solaris 9 and I want to install some packages but due to less disk space I am not able to install the packages.
I am giving the output of filesystem--
# df -k
Filesystem kbytes used avail capacity Mounted on
/dev/dsk/c0t0d0s0 2148263 1997593 107705 ... (10 Replies)
have following package installed
rpm -qa |grep ADMIN
It will give the following package installed:
ADMIN-4.0.0.1
Now I will upgrade the ADMIN package using the following command.
rpm --upgrade ADMIN-4.1.0.1
It will upgrade the ADMIN packagge to ADMIN-4.1.0.1
Now I want that... (0 Replies)