Sponsored Content
Full Discussion: Script in boot sequence
Top Forums UNIX for Dummies Questions & Answers Script in boot sequence Post 97005 by delphine on Wednesday 25th of January 2006 10:07:13 AM
Old 01-25-2006
Script in boot sequence

Hi ,
I have some problems with my library when the sytem boot :

When HPUX is booting, HPUX and STAPE claim the drive initially. HPUX assigns an instance

number. The instance number is tied to the hardware path. Near the end of the boot, the ATDD driver claims the drive from

STAPE based upon the Inquiry ID (either ULTRIUM-TDx or ULT3580.TDx, where x=1, 2 or 3 depending on the drive

generation.) When ATDD claims the drive, it generates the special file based on the instance number. This is the standard

way devices are handled with HPUX. If a drive is moved, host is rebooted or for other undefined reasons HPUX will assign

a different instance number, which will generate a new special file when ATDD claims the drive.

For some reason that is not understood, HPUX will sometimes claim a drive, or number of drives, with a different instance

number, even if the hardware path does not change. When this happens the new instance numbers do not match up with

the existing special files, and the customer has a problem. Although, it is not understood why this happens, but this is not

an uncommon problem for a HPUX customer to have.

====>
Answer from IBM :
The following commands can be run manually or scripted to run during bootup
So as an example, if they want to assign the instance number for the following two drives.

tape 90 1/0/0/0.97.19.255.2.6.0 atdd CLAIMED DEVICE IBM 03590E11

tape 35 1/0/0/0.97.20.255.2.7.0 atdd CLAIMED DEVICE IBM 03592J1A

You do this for each drive: STEP 1

rmsf -H 1/0/0/0.97.19.255.2.6.0

rmsf -H 1/0/0/0.97.20.255.2.7.0

ioscan -M atdd -H 1/0/0/0.97.19.255.2.6.0 -I 1 <=this change it to instance number 1

ioscan -M atdd -H 1/0/0/0.97.20.255.2.7.0 -I 2 <=this change it to instance number 2

Then you do this: STEP 2

/opt/atdd/bin/atdd_claim

These steps could be automated by creating a script and putting the new script in the boot up sequence."


Question :
====> Can you confirm me that i have to create my script with the differents drives .I have to create a sh file with the rmsf commands of my differents hardware path and ioscan with the new instance number.
It's only that?

Thanks

DElphine
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Unix Boot Sequence

Hello all Unix fans. What files are involved in the Unix boot sequence, i guess there is alot of them but some must be the main files? For example the service SENDMAIL starts on our Unix machine where should i edit so that it will not start at BOOT. initd.conf? rc2.d? I hope you... (6 Replies)
Discussion started by: sajjan2
6 Replies

2. UNIX for Dummies Questions & Answers

Boot Sequence

Hi everybody, I have to create a script and put it in the boot up sequence . Can you give me the path where i can put it? Sorry it's my first script. DElphine (3 Replies)
Discussion started by: delphine
3 Replies

3. UNIX for Dummies Questions & Answers

Wierd boot-up sequence

Hi, I have two machines, one is a E3500 and the other one is a V490; I face a strange issue with both of them. The boot up sequence gives the output of the devalias command. Has anybody faced this?? Please do let me know what needs to be done o resolve this. Regards, NP (1 Reply)
Discussion started by: nitinp82
1 Replies

4. Linux

linux 2.4 boot up sequence

I am running linux red hat and I need to know the command to view the boot up process.... (that is the driver initialization, drive mount, etc).... Does anyone know this command? (7 Replies)
Discussion started by: Franco
7 Replies

5. Solaris

how to change the boot sequence?

Hi all, I have solaris and xp installed... Usually solaris occupies the first boot slot. So i wanted to know if it is possible to change the boot sequence to xp first and then solaris? (5 Replies)
Discussion started by: wrapster
5 Replies

6. Shell Programming and Scripting

Unix script for Checking sequence

Hello, I need Unix script for Checking sequence and get output in a file for missing sequences information. We are moving archive log to a server for DR .if any files miss from sequence DR will fails. so we need script to monitor sequence of files which are FTP from the Production servers .... (2 Replies)
Discussion started by: Rata_raj
2 Replies

7. Shell Programming and Scripting

script to touch a sequence of files

Hi, My requirement is i need to touch a sequence of files like touch a touch b touch c now i need the script in a way that checks if all files are touched or not. if any file say b is not touched then i should get this notification. Please suggest as i am new to unix (2 Replies)
Discussion started by: sussane
2 Replies

8. Filesystems, Disks and Memory

Boot Sequence changed After Image Restore

Hello All, I backed up my RHEL 4 as an image. Then I restored the image on my machine. Everything went fine but I dont get the normal boot sequence as it used to come when I freshly installed RHEL4. The messages that are shown when the system boots are something like- " ..... EXT3-fs:... (2 Replies)
Discussion started by: shamik
2 Replies

9. UNIX for Advanced & Expert Users

script with a sequence of nohups

Hi, I have written this script below to run a mathematica notebook, and then I want to launch another one when the first one finishes doing what it must. The notebook includes a command which will exit the program math. If I do it like below the two math processes begin at the same time, and... (3 Replies)
Discussion started by: amen_corner
3 Replies

10. Shell Programming and Scripting

find common entries and match the number with long sequence and cut that sequence in output

Hi all, I have a file like this ID 3BP5L_HUMAN Reviewed; 393 AA. AC Q7L8J4; Q96FI5; Q9BQH8; Q9C0E3; DT 05-FEB-2008, integrated into UniProtKB/Swiss-Prot. DT 05-JUL-2004, sequence version 1. DT 05-SEP-2012, entry version 71. FT COILED 59 140 ... (1 Reply)
Discussion started by: manigrover
1 Replies
INSTALLBOOT(8)						      System Manager's Manual						    INSTALLBOOT(8)

NAME
installboot - make a device bootable SYNOPSIS
installboot -i(mage) image [label:]kernel mm fs ... init installboot -(e)x(tract) image installboot -d(evice) device bootblock boot [[label:]image ...] installboot -b(oot) device bootblock boot [label:]image ... installboot -m(aster) [fix] device masterboot DESCRIPTION
Installboot may be used to make a device bootable by constructing a kernel image and installing bootstrap code into the boot block of a Minix file system. To understand how this can be done one first has to know what happens when a PC is booted. When the power is turned on the typical PC will try to read the first sector from the first floppy disk or from the first hard disk into memory and execute it. The code obtained from the hard disk (from the so-called master boot sector) will immediately replace itself by the code found in the first sector of the active partition. Thus the PC is now executing the bootstrap code found in the first sector of /dev/fd0, /dev/hd1, /dev/hd2, /dev/hd3, or /dev/hd4. The bootstrap will locate the operating system on the device it itself was loaded from, load it, and execute it. To make a Minix file system /dev/fd0 mounted on /mnt bootable, enter the following: cp /usr/mdec/boot /mnt/boot installboot -i /mnt/minix kernel mm fs init installboot -d /dev/fd0 /usr/mdec/bootblock boot The "boot" program in the example is named the "boot monitor". It is loaded by the bootblock code placed in the boot sector of /dev/fd0 and it will take care of loading the kernel image "minix" from the root directory of the file system. See monitor(8) for a description of the boot monitor. Note that boot is a name in the file system on /dev/fd0 in this example, the same file as /mnt/boot. Making /mnt/minix is normally not necessary, there is usually a kernel image in the tools directory. OPTIONS
-i(mage) image [label:]kernel mm fs ... init The -image option (or the -i shorthand) combines the executable files needed to run Minix in one file. Only the names and a few zero bytes are inserted into the image. The name is for identification and the zeros are used to pad separate pieces to sector boundaries for fast loading. An executable may be prefixed by a label. The monitor may be instructed to load processes by label. So more than one kernel process may be included in the image, each with a different winchester driver for instance. So if you have compiled two different kernels with an AT or XT driver then installboot -i image AT:at_kernel XT:xt_kernel mm fs init will make an image with two different labeled kernels and one unlabeled set of the other binaries. -(e)x(tract) image Extract the binaries from image under the names stored in the image. (The name includes the optional label.) -d(evice) device bootblock boot [[label:]image ...] Installs bootblock in the boot sector of device together with the disk addresses to boot. These disk addresses are needed to load boot from the file system at boot time. The argument boot is first searched in the file system on device. If it is not found then it is read as a normal file and added at the end of the file system. The file system should be smaller than the device it is on to allow this. Any extra images are also added to the end as described under -boot. (Make sure you understand all this.) The device need not be mounted when installboot is run, nor does it matter if it is. Installboot needs to be run again if boot is rewritten, because it will then occupy a new place on the disk. Old boot parameters are kept if there are no images added. -b(oot) device bootblock boot [label:]image ... This option fills a blank floppy in device with boot code and kernel images. This "boot disk" does not have a root file system, only the boot monitor and Minix kernels. The boot parameters sector is filled with code that enables menu options for selecting an image. After loading an image, the monitor will ask you to insert a root file system diskette before starting Minix. The labels used on the images should match those on the executables used inside the image. You can put a comma separated list of labels on an image for each label used within the image. For the image created earlier one would create a boot floppy like this: installboot -b /dev/fd0 bootblock boot AT,XT:image If a label-list is omitted on an image, then that image will be selected by default. (Like in the normal one image, no labels case.) Note that -device and -boot together allow you to make a boot floppy with or without a root file system. With the boot code in the file system, attached to the end of it, or after the boot block. And with one or more kernel images in the file system or at the end of the device. Somewhat confusing. -m(aster) [fix] device masterboot This option installs the masterboot program into the boot sector of the given device. If another device is given instead of master- boot then its bootstrap code is copied to device. The master bootstrap on a hard disk boots the active partition on that disk at boot time. The MS-DOS fdisk command normally puts a master bootstrap on the hard disk. Minix has two bootstraps that can be used as a master bootstrap. A fairly normal one named masterboot that works as follows: If the ALT key is held down while booting then '/dev/hd?' appears and you are expected to type a number key (0 - 9) to select the device to boot. If fix (a small number) is given then the bootstrap is locked into booting the /dev/hdfix disk or primary partition. This is needed if 'boot *hdN' is used from the monitor to boot an O.S. that needs the active flag set. If installed on a Minix floppy then it will try to boot the next floppy or the first hard disk. Ideal for floppies with just data on it, they will no longer obstruct the boot process if left in the drive. Also a very useful trick to boot from floppy drive 1. If installed on a hard disk then the active partition is selected and booted as usual, unless none of the partitions is marked active, then it will boot the next disk. The latter is useful if you want to boot an operating system from the second disk by default. The second bootstrap is named extboot. It has only one function, to boot the logical partition named by fix. Fix is not optional for extboot and must be a number-letter pair, like 2c for /dev/hd2c. Extboot or masterboot with a fix key need not be installed in the hard disk master bootstrap per se if you don't want to mess with the DOS master bootstrap, or if you want keep the active flag functioning. An extended partition or a non-root Minix partition are better candidates. It seems logical to put extboot in the extended partition boot block. A backup copy of the current master bootstrap (including the partition table) can be made with: dd if=device of=backup-file count=1 A simple 'cat backup-file > device' will put it back. You can also use fdisk /mbr under MS-DOS 5.0 (or newer) to restore the master bootstrap. FILES
/usr/mdec/bootblock Minix bootstrap for the Minix root device. To be placed in the boot sector. /usr/mdec/boot Minix Boot Monitor. Can usually be found in the root directory of a bootable device. /usr/mdec/masterboot Master bootstrap. Can be placed in the first sector of a disk to select the active partition. In a Minix primary partition it selects the active subpartition. /usr/mdec/extboot Extended partition bootstrap. SEE ALSO
part(8), monitor(8). DIAGNOSTICS
Boot doesn't fit on device If there is no space on the device to add the boot code. This usually means that there is no boot code in the file system you use installboot -device on. Image doesn't fit on device If the device is too small for all the images you try to put on it. BUGS
It has four more options than the SunOS installboot program it is modeled after. The bootblock code has been crunched to such ugliness that you can use it to scare little kids out of your garden. AUTHOR
Kees J. Bot (kjb@cs.vu.nl) INSTALLBOOT(8)
All times are GMT -4. The time now is 10:33 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy